Re: [PATCH v2] bus: mhi: ep: Use kcalloc() instead of kzalloc()

2024-02-02 Thread Manivannan Sadhasivam
On Sun, Jan 28, 2024 at 12:27:22PM +0100, Erick Archer wrote: > This is an effort to get rid of all multiplications from allocation > functions in order to prevent integer overflows [1]. > > Here the multiplication is obviously safe because the "event_rings" > member never can have a value

Re: [PATCH v2] bus: mhi: ep: Use kcalloc() instead of kzalloc()

2024-01-30 Thread Manivannan Sadhasivam
/doc/html/next/process/deprecated.html#open-coded-arithmetic-in-allocator-arguments > [1] > Reviewed-by: Gustavo A. R. Silva > Signed-off-by: Erick Archer Reviewed-by: Manivannan Sadhasivam - Mani > --- > Changes in v2: > - Add more info in the commit message to better explain t

Re: [PATCH] bus: mhi: ep: Use kcalloc() instead of kzalloc()

2024-01-30 Thread Manivannan Sadhasivam
On Mon, Jan 22, 2024 at 10:15:20AM +0300, Dan Carpenter wrote: > This code does not have an integer overflow, but it might have a > different memory corruption bug. > > On Sat, Jan 20, 2024 at 04:25:18PM +0100, Erick Archer wrote: > > As noted in the "Deprecated Interfaces, Language Features,