]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
media: staging/intel-ipu3: reduce kernel stack usage
authorArnd Bergmann <arnd@arndb.de>
Tue, 5 Mar 2019 13:26:29 +0000 (08:26 -0500)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Wed, 20 Mar 2019 10:33:08 +0000 (06:33 -0400)
commitc3c2eca87dcded3626bc8f3a1b8bfa4b9f078fb1
treea0be384acc743d7a841478e65ffb3ca43987309e
parent948dff7cfa1d7653e7828e7b905863bd24ca5c02
media: staging/intel-ipu3: reduce kernel stack usage

The imgu_css_queue structure is too large to be put on the kernel
stack, as we can see in 32-bit builds:

drivers/staging/media/ipu3/ipu3-css.c: In function 'imgu_css_fmt_try':
drivers/staging/media/ipu3/ipu3-css.c:1863:1: error: the frame size of 1172 bytes is larger than 1024 bytes [-Werror=frame-larger-than=]

By dynamically allocating this array, the stack usage goes down to an
acceptable 140 bytes for the same x86-32 configuration.

Fixes: f5f2e4273518 ("media: staging/intel-ipu3: Add css pipeline programming")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Cao, Bingbu <bingbu.cao@intel.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/staging/media/ipu3/ipu3-css.c