media: dvb_ca_en50221: prevent using slot_info for Spectre attacs
authorMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Tue, 15 May 2018 12:31:38 +0000 (08:31 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Wed, 16 May 2018 14:17:22 +0000 (10:17 -0400)
commit4f5ab5d7a5e765ad231a132f82cec71de88b9aad
tree9a326c770e388b1b2ddc19dcc109fe299d8a5dac
parent782b9d201112ae526a823ddba522c88c761585c7
media: dvb_ca_en50221: prevent using slot_info for Spectre attacs

slot can be controlled by user-space, hence leading to
a potential exploitation of the Spectre variant 1 vulnerability,
as warned by smatch:
drivers/media/dvb-core/dvb_ca_en50221.c:1479 dvb_ca_en50221_io_write() warn: potential spectre issue 'ca->slot_info' (local cap)

Acked-by: "Jasmin J." <jasmin@anw.at>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/dvb-core/dvb_ca_en50221.c