summaryrefslogtreecommitdiff
path: root/include/media/dvbdev.h
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2017-12-11 15:05:02 +0300
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2018-03-06 12:59:57 +0300
commitf410b4093fdd4d8f4644d3d486afe3040eceef7b (patch)
treec014accd66beade28d0ae75f4e28bcd0bc046c5e /include/media/dvbdev.h
parentcf68c22f106369f6124342c58c4a50f07edd2174 (diff)
downloadlinux-f410b4093fdd4d8f4644d3d486afe3040eceef7b.tar.xz
media: em28xx: split up em28xx_dvb_init to reduce stack size
With CONFIG_KASAN, the init function uses a large amount of kernel stack: drivers/media/usb/em28xx/em28xx-dvb.c: In function 'em28xx_dvb_init.part.4': drivers/media/usb/em28xx/em28xx-dvb.c:2061:1: error: the frame size of 3232 bytes is larger than 2048 bytes [-Werror=frame-larger-than=] Using gcc-7 with -fsanitize-address-use-after-scope makes this even worse: drivers/media/usb/em28xx/em28xx-dvb.c: In function 'em28xx_dvb_init': drivers/media/usb/em28xx/em28xx-dvb.c:2069:1: error: the frame size of 4280 bytes is larger than 3072 bytes [-Werror=frame-larger-than=] By splitting out each part of the switch/case statement that has its own local variables into a separate function, no single one of them uses more than 500 bytes, and with a noinline_for_stack annotation we can ensure that they are not merged back together. [mchehab@s-opensource.com: fix conflict with changeset be7fd3c3a8c5 ("media: em28xx: Hauppauge DualHD second tuner functionality")] Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Mauro Carvalho Chehab <> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'include/media/dvbdev.h')
0 files changed, 0 insertions, 0 deletions