Re: [PATCH -next v2 0/2] media: cx231xx: Add two macros and switch to use kmemdup() helper

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 2023/9/1 3:05, Andrzej Pietrasiewicz wrote:
> Hi Jinjie,
> 
> W dniu 22.08.2023 o 13:18, Jinjie Ruan pisze:
>> As Andrzej suggested, add BUF_SIZE and TIMEOUT_MS macros to replace
>> the magic constant 4096 and 2000.
>>
>> On the other hand, use kmemdup() helper instead of open-coding to
>> simplify the code.
>>
> 
> Sorry about the delay.
> 
> I think I'd prefer the kmemdup() patch as the first one so that it does not
> depend on the patch adding the macros. And then the one adding the macros
> becomes optional.
> 
> Speaking about the latter, maybe BUF_SIZE and TIMEOUT_MS are a bit too
> vague?
> No strong opinion, though. Also, BUF_SIZE is suspiciously identical to
> PAGE_SIZE on some/many architectures. Any thoughts about it?

So just use the PAGE_SIZE macro?

> 
> Regards,
> 
> Andrzej
> 
>> Jinjie Ruan (2):
>>    media: cx231xx: Add BUF_SIZE and TIMEOUT_MS macros
>>    media: cx231xx: Switch to use kmemdup() helper
>>
>>   drivers/media/usb/cx231xx/cx231xx-core.c | 7 +++----
>>   drivers/media/usb/cx231xx/cx231xx.h      | 3 +++
>>   2 files changed, 6 insertions(+), 4 deletions(-)
>>
> 



[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux