diff options
author | Maurizio Lombardi <mlombard@redhat.com> | 2016-03-04 10:41:49 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2016-03-14 20:50:11 +0100 |
commit | a41b2efb134bdeefe8c27fa77ffaaef0b974c390 (patch) | |
tree | 9f8b7e6c87078516d910d415785469d1f523a5ff /drivers | |
parent | sd: Fix discard granularity when LBPRZ=1 (diff) | |
download | linux-a41b2efb134bdeefe8c27fa77ffaaef0b974c390.tar.xz linux-a41b2efb134bdeefe8c27fa77ffaaef0b974c390.zip |
be2iscsi: set the boot_kset pointer to NULL in case of failure
In beiscsi_setup_boot_info(), the boot_kset pointer should be set to
NULL in case of failure otherwise an invalid pointer dereference may
occur later.
Cc: <stable@vger.kernel.org>
Signed-off-by: Maurizio Lombardi <mlombard@redhat.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Reviewed-by: Jitendra Bhivare <jitendra.bhivare@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/be2iscsi/be_main.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/be2iscsi/be_main.c b/drivers/scsi/be2iscsi/be_main.c index e89a0f8d2c6e..f05e7737107d 100644 --- a/drivers/scsi/be2iscsi/be_main.c +++ b/drivers/scsi/be2iscsi/be_main.c @@ -4493,6 +4493,7 @@ put_shost: scsi_host_put(phba->shost); free_kset: iscsi_boot_destroy_kset(phba->boot_kset); + phba->boot_kset = NULL; return -ENOMEM; } |