Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1731451
| From | Allen <allen.lkml@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] drivers:staging/media:Use ARRAY_SIZE() for the size calculation of the array |
| Date | 2017-09-13 10:40 +0200 |
| Message-ID | <upbnb-4Xu-3@gated-at.bofh.it> (permalink) |
| References | <upaU9-4Kl-1@gated-at.bofh.it> <upbdw-4Um-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
>>
>> -#define array_length(array) (sizeof(array)/sizeof(array[0]))
>> +#define array_length(array) (ARRAY_SIZE(array))
>
> Just get rid of this array_length macro and use ARRAY_SIZE() directly.
>
Sure.
- Allen
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] drivers:staging/media:Use ARRAY_SIZE() for the size calculation of the array Allen Pais <allen.lkml@gmail.com> - 2017-09-13 10:10 +0200
Re: [PATCH] drivers:staging/media:Use ARRAY_SIZE() for the size calculation of the array Dan Carpenter <dan.carpenter@oracle.com> - 2017-09-13 10:30 +0200
Re: [PATCH] drivers:staging/media:Use ARRAY_SIZE() for the size calculation of the array Allen <allen.lkml@gmail.com> - 2017-09-13 10:40 +0200
Re: [PATCH] drivers:staging/media:Use ARRAY_SIZE() for the size calculation of the array Dan Carpenter <dan.carpenter@oracle.com> - 2017-09-13 10:50 +0200
csiph-web