1
0
Fork 0
remarkable-linux/drivers/message/fusion
Dan Carpenter 62d16de310 scsi: mptfusion: Add bounds check in mptctl_hp_targetinfo()
[ Upstream commit a7043e9529 ]

My static checker complains about an out of bounds read:

    drivers/message/fusion/mptctl.c:2786 mptctl_hp_targetinfo()
    error: buffer overflow 'hd->sel_timeout' 255 <= u32max.

It's true that we probably should have a bounds check here.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 16:17:47 +02:00
..
lsi License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
Kconfig scsi: use 'depends' instead of 'select' for SCSI_FC_ATTRS 2014-09-16 16:55:55 -04:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mptbase.c scsi: fusion: fix string overflow warning 2017-08-07 14:04:02 -04:00
mptbase.h fusion: remove dead MTRR code 2015-06-13 08:44:14 -07:00
mptctl.c scsi: mptfusion: Add bounds check in mptctl_hp_targetinfo() 2018-05-25 16:17:47 +02:00
mptctl.h
mptdebug.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mptfc.c scsi: mptfc: Do not call fc_block_scsi_eh() on host reset 2017-08-25 17:21:10 -04:00
mptlan.c net: use core MTU range checking in misc drivers 2016-10-20 14:51:10 -04:00
mptlan.h scsi: mptlan: Remove linux/miscdevice.h from mptlan.h 2017-01-05 00:21:12 -05:00
mptsas.c scsi: mptsas: Disable WRITE SAME 2018-04-29 11:33:16 +02:00
mptsas.h mptfusion: combine fw_event_work and its event_data 2014-07-25 17:16:58 -04:00
mptscsih.c scsi: mpt: Move scsi_remove_host() out of mptscsih_remove_host() 2017-04-24 18:21:17 -04:00
mptscsih.h scsi: drop reason argument from ->change_queue_depth 2014-11-24 14:45:27 +01:00
mptspi.c scsi: mpt: Move scsi_remove_host() out of mptscsih_remove_host() 2017-04-24 18:21:17 -04:00