Re: [PATCH][next] zd1211rw: zd_usb: Use struct_size() helper

2019-09-03 Thread Kalle Valo
"Gustavo A. R. Silva" wrote: > One of the more common cases of allocation size calculations is finding > the size of a structure that has a zero-sized array at the end, along > with memory for some number of elements for that array. For example: > > struct usb_int_regs { > ... >

Re: [PATCH][next] zd1211rw: zd_usb: Use struct_size() helper

2019-08-31 Thread kbuild test robot
Hi "Gustavo, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on linus/master] [cannot apply to v5.3-rc6 next-20190830] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url:

[PATCH][next] zd1211rw: zd_usb: Use struct_size() helper

2019-08-30 Thread Gustavo A. R. Silva
One of the more common cases of allocation size calculations is finding the size of a structure that has a zero-sized array at the end, along with memory for some number of elements for that array. For example: struct usb_int_regs { ... struct reg_data regs[0]; } __packed; Make