]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
qla2xxx: Make the FC port capability mutual exclusive.
authorAndrew Vasquez <andrew.vasquez@qlogic.com>
Fri, 28 May 2010 22:08:22 +0000 (15:08 -0700)
committerAndi Kleen <ak@linux.intel.com>
Thu, 28 Apr 2011 15:20:49 +0000 (08:20 -0700)
[ upstream commit b0cd579cde8ee0c7ed52239531ba09bcbc5b54c2 ]

In case of both target and initiator capabilities reported by fc port,
the fc port port capability is made mutualy exclusive with priority given
for target capabilities.

Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Acked-by: Madhuranath Iyengar <Madhu.Iyengar@qlogic.com>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
drivers/scsi/qla2xxx/qla_isr.c

index be3d8bed2ecf6da8032fb7182b8c64b5dd9ef90e..f347ea4b4211b5ebd6676c2860963dc192aa59ce 100644 (file)
@@ -1119,9 +1119,9 @@ qla24xx_logio_entry(scsi_qla_host_t *vha, struct req_que *req,
                        fcport->port_type = FCT_TARGET;
                        if (iop[0] & BIT_8)
                                fcport->flags |= FCF_FCP2_DEVICE;
-               }
-               if (iop[0] & BIT_5)
+               } else if (iop[0] & BIT_5)
                        fcport->port_type = FCT_INITIATOR;
+
                if (logio->io_parameter[7] || logio->io_parameter[8])
                        fcport->supported_classes |= FC_COS_CLASS2;
                if (logio->io_parameter[9] || logio->io_parameter[10])