Re: [PATCH 06/26] dma-buf: system_heap: use array_size

2023-06-23 Thread John Stultz
On Fri, Jun 23, 2023 at 2:15 PM Julia Lawall wrote: > > Use array_size to protect against multiplication overflows. > > The changes were done using the following Coccinelle semantic patch: > > // > @@ > size_t e1,e2; > expression COUNT; > identifier alloc =

[PATCH 06/26] dma-buf: system_heap: use array_size

2023-06-23 Thread Julia Lawall
Use array_size to protect against multiplication overflows. The changes were done using the following Coccinelle semantic patch: // @@ size_t e1,e2; expression COUNT; identifier alloc = {vmalloc,vzalloc,kvmalloc,kvzalloc}; @@ ( alloc( - (e1) * (e2) +