]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
qla2xxx: Reset reserved field in firmware options to 0
authorHimanshu Madhani <himanshu.madhani@cavium.com>
Wed, 13 Sep 2017 11:05:26 +0000 (16:35 +0530)
committerBrian Maly <brian.maly@oracle.com>
Thu, 2 Nov 2017 18:14:16 +0000 (14:14 -0400)
Orabug: 2684419726923029

During NVRAM initialization in target mode, reset reserved
fields in firmware options to Zero (BIT 15)

Signed-off-by: Himanshu Madhani <himanshu.madhani@cavium.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@cavium.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
Signed-off-by: Brian Maly <brian.maly@oracle.com>
Reviewed-by: Jack Vogel <jack.vogel@oracle.com>
drivers/scsi/qla2xxx/qla_target.c

index 498c8e42bc1e29f22651c76af3fd7c7378c9c9a7..fd08de62d3e8dc01c77d59d19b718fedd1d93050 100644 (file)
@@ -6528,6 +6528,12 @@ qlt_24xx_config_nvram_stage1(struct scsi_qla_host *vha, struct nvram_24xx *nv)
 
                /* Disable Full Login after LIP */
                nv->host_p &= __constant_cpu_to_le32(~BIT_10);
+               /*
+                * clear BIT 15 explicitly as we have seen at least
+                * a couple of instances where this was set and this
+                * was causing the firmware to not be initialized.
+                */
+               nv->firmware_options_1 &= cpu_to_le32(~BIT_15);
                /* Enable target PRLI control */
                nv->firmware_options_2 |= __constant_cpu_to_le32(BIT_14);
        } else {
@@ -6607,6 +6613,13 @@ qlt_81xx_config_nvram_stage1(struct scsi_qla_host *vha, struct nvram_81xx *nv)
                nv->firmware_options_1 &= __constant_cpu_to_le32(~BIT_13);
                /* Enable initial LIP */
                nv->firmware_options_1 &= __constant_cpu_to_le32(~BIT_9);
+               /*
+                * clear BIT 15 explicitly as we have seen at
+                * least a couple of instances where this was set
+                * and this was causing the firmware to not be
+                * initialized.
+                */
+               nv->firmware_options_1 &= cpu_to_le32(~BIT_15);
                if (ql2xtgt_tape_enable)
                        /* Enable FC tape support */
                        nv->firmware_options_2 |= cpu_to_le32(BIT_12);