kernel_optimize_test/ipc
Gustavo A. R. Silva 4a2ae92993 ipc/sem.c: replace kvmalloc/memset with kvzalloc and use struct_size
Use kvzalloc() instead of kvmalloc() and memset().

Also, make use of the struct_size() helper instead of the open-coded
version in order to avoid any potential type mistakes.

This code was detected with the help of Coccinelle.

Link: http://lkml.kernel.org/r/20190131214221.GA28930@embeddedor
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Cc: Davidlohr Bueso <dave@stgolabs.net>
Cc: Manfred Spraul <manfred@colorfullife.com>
Cc: Kees Cook <keescook@chromium.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2019-03-07 18:32:02 -08:00
..
compat.c
ipc_sysctl.c ipc: IPCMNI limit check for semmni 2018-10-31 08:54:14 -07:00
Makefile
mq_sysctl.c
mqueue.c y2038: syscalls: rename y2038 compat syscalls 2019-02-07 00:13:27 +01:00
msg.c ipc: rename old-style shmctl/semctl/msgctl syscalls 2019-01-25 17:22:50 +01:00
msgutil.c
namespace.c ipc: simplify ipc initialization 2018-08-22 10:52:52 -07:00
sem.c ipc/sem.c: replace kvmalloc/memset with kvzalloc and use struct_size 2019-03-07 18:32:02 -08:00
shm.c ipc: rename old-style shmctl/semctl/msgctl syscalls 2019-01-25 17:22:50 +01:00
syscall.c ipc: rename old-style shmctl/semctl/msgctl syscalls 2019-01-25 17:22:50 +01:00
util.c ipc/util.c: update return value of ipc_getref from int to bool 2018-08-22 10:52:52 -07:00
util.h ipc: rename old-style shmctl/semctl/msgctl syscalls 2019-01-25 17:22:50 +01:00