Re: [PATCH][next] fbdev/fb.h: Use struct_size() helper in kzalloc()

2020-07-10 Thread Bartlomiej Zolnierkiewicz
On 6/20/20 1:27 PM, Sam Ravnborg wrote: > Hi Gustavo. > > On Wed, Jun 17, 2020 at 12:56:47PM -0500, Gustavo A. R. Silva wrote: >> Make use of the struct_size() helper instead of an open-coded version >> in order to avoid any potential type mistakes. >> >> This code was detected with the help of

Re: [PATCH][next] fbdev/fb.h: Use struct_size() helper in kzalloc()

2020-07-10 Thread Bartlomiej Zolnierkiewicz
On 6/17/20 7:56 PM, Gustavo A. R. Silva wrote: > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > > Signed-off-by: Gustavo A. R. Silv

Re: [PATCH][next] fbdev/fb.h: Use struct_size() helper in kzalloc()

2020-06-20 Thread Sam Ravnborg
Hi Gustavo. On Wed, Jun 17, 2020 at 12:56:47PM -0500, Gustavo A. R. Silva wrote: > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > >

[PATCH][next] fbdev/fb.h: Use struct_size() helper in kzalloc()

2020-06-17 Thread Gustavo A. R. Silva
Make use of the struct_size() helper instead of an open-coded version in order to avoid any potential type mistakes. This code was detected with the help of Coccinelle and, audited and fixed manually. Signed-off-by: Gustavo A. R. Silva --- include/linux/fb.h | 5 +++-- 1 file changed, 3 inserti