]> git.baikalelectronics.ru Git - kernel.git/commit
Move stack parameters for sed_ioctl to prevent oversized stack with CONFIG_KASAN
authorScott Bauer <scott.bauer@intel.com>
Wed, 15 Feb 2017 00:29:36 +0000 (17:29 -0700)
committerJens Axboe <axboe@fb.com>
Wed, 15 Feb 2017 02:47:18 +0000 (19:47 -0700)
commite0ea90b21633554aad44b56a8ed714b70eb51ecf
tree16caa1d305159a1306478a58483278fe13d2e9b2
parentee1d4fa7dbe26b7d19ae4ba07d3ca04ac9de82c0
Move stack parameters for sed_ioctl to prevent oversized stack with CONFIG_KASAN

When CONFIG_KASAN is enabled, compilation fails:

block/sed-opal.c: In function 'sed_ioctl':
block/sed-opal.c:2447:1: error: the frame size of 2256 bytes is larger than 2048 bytes [-Werror=frame-larger-than=]

Moved all the ioctl structures off the stack and dynamically allocate
using _IOC_SIZE()

Fixes: 4c623f64a260 ("block: Add Sed-opal library")
Reported-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Scott Bauer <scott.bauer@intel.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
block/sed-opal.c
drivers/nvme/host/core.c
include/linux/sed-opal.h