Lines Matching refs:ha

116 #define ql4_printk(level, ha, format, arg...) \  argument
117 dev_printk(level , &((ha)->pdev->dev) , format , ## arg)
236 struct scsi_qla_host *ha; /* HA the SP is queued on */ member
272 struct scsi_qla_host *ha; member
295 struct scsi_qla_host *ha; member
306 int (*ddb_change)(struct scsi_qla_host *ha, uint32_t fw_ddb_index,
427 int (*iospace_config) (struct scsi_qla_host *ha);
833 struct scsi_qla_host *ha; member
856 static inline int is_ipv4_enabled(struct scsi_qla_host *ha) in is_ipv4_enabled() argument
858 return ((ha->ip_config.ipv4_options & IPOPT_IPV4_PROTOCOL_ENABLE) != 0); in is_ipv4_enabled()
861 static inline int is_ipv6_enabled(struct scsi_qla_host *ha) in is_ipv6_enabled() argument
863 return ((ha->ip_config.ipv6_options & in is_ipv6_enabled()
867 static inline int is_qla4010(struct scsi_qla_host *ha) in is_qla4010() argument
869 return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP4010; in is_qla4010()
872 static inline int is_qla4022(struct scsi_qla_host *ha) in is_qla4022() argument
874 return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP4022; in is_qla4022()
877 static inline int is_qla4032(struct scsi_qla_host *ha) in is_qla4032() argument
879 return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP4032; in is_qla4032()
882 static inline int is_qla40XX(struct scsi_qla_host *ha) in is_qla40XX() argument
884 return is_qla4032(ha) || is_qla4022(ha) || is_qla4010(ha); in is_qla40XX()
887 static inline int is_qla8022(struct scsi_qla_host *ha) in is_qla8022() argument
889 return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP8022; in is_qla8022()
892 static inline int is_qla8032(struct scsi_qla_host *ha) in is_qla8032() argument
894 return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP8324; in is_qla8032()
897 static inline int is_qla8042(struct scsi_qla_host *ha) in is_qla8042() argument
899 return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP8042; in is_qla8042()
902 static inline int is_qla80XX(struct scsi_qla_host *ha) in is_qla80XX() argument
904 return is_qla8022(ha) || is_qla8032(ha) || is_qla8042(ha); in is_qla80XX()
907 static inline int is_aer_supported(struct scsi_qla_host *ha) in is_aer_supported() argument
909 return ((ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP8022) || in is_aer_supported()
910 (ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP8324) || in is_aer_supported()
911 (ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP8042)); in is_aer_supported()
914 static inline int adapter_up(struct scsi_qla_host *ha) in adapter_up() argument
916 return (test_bit(AF_ONLINE, &ha->flags) != 0) && in adapter_up()
917 (test_bit(AF_LINK_UP, &ha->flags) != 0) && in adapter_up()
918 (!test_bit(AF_LOOPBACK, &ha->flags)); in adapter_up()
926 static inline void __iomem* isp_semaphore(struct scsi_qla_host *ha) in isp_semaphore() argument
928 return (is_qla4010(ha) ? in isp_semaphore()
929 &ha->reg->u1.isp4010.nvram : in isp_semaphore()
930 &ha->reg->u1.isp4022.semaphore); in isp_semaphore()
933 static inline void __iomem* isp_nvram(struct scsi_qla_host *ha) in isp_nvram() argument
935 return (is_qla4010(ha) ? in isp_nvram()
936 &ha->reg->u1.isp4010.nvram : in isp_nvram()
937 &ha->reg->u1.isp4022.nvram); in isp_nvram()
940 static inline void __iomem* isp_ext_hw_conf(struct scsi_qla_host *ha) in isp_ext_hw_conf() argument
942 return (is_qla4010(ha) ? in isp_ext_hw_conf()
943 &ha->reg->u2.isp4010.ext_hw_conf : in isp_ext_hw_conf()
944 &ha->reg->u2.isp4022.p0.ext_hw_conf); in isp_ext_hw_conf()
947 static inline void __iomem* isp_port_status(struct scsi_qla_host *ha) in isp_port_status() argument
949 return (is_qla4010(ha) ? in isp_port_status()
950 &ha->reg->u2.isp4010.port_status : in isp_port_status()
951 &ha->reg->u2.isp4022.p0.port_status); in isp_port_status()
954 static inline void __iomem* isp_port_ctrl(struct scsi_qla_host *ha) in isp_port_ctrl() argument
956 return (is_qla4010(ha) ? in isp_port_ctrl()
957 &ha->reg->u2.isp4010.port_ctrl : in isp_port_ctrl()
958 &ha->reg->u2.isp4022.p0.port_ctrl); in isp_port_ctrl()
961 static inline void __iomem* isp_port_error_status(struct scsi_qla_host *ha) in isp_port_error_status() argument
963 return (is_qla4010(ha) ? in isp_port_error_status()
964 &ha->reg->u2.isp4010.port_err_status : in isp_port_error_status()
965 &ha->reg->u2.isp4022.p0.port_err_status); in isp_port_error_status()
968 static inline void __iomem * isp_gp_out(struct scsi_qla_host *ha) in isp_gp_out() argument
970 return (is_qla4010(ha) ? in isp_gp_out()
971 &ha->reg->u2.isp4010.gp_out : in isp_gp_out()
972 &ha->reg->u2.isp4022.p0.gp_out); in isp_gp_out()
975 static inline int eeprom_ext_hw_conf_offset(struct scsi_qla_host *ha) in eeprom_ext_hw_conf_offset() argument
977 return (is_qla4010(ha) ? in eeprom_ext_hw_conf_offset()
982 int ql4xxx_sem_spinlock(struct scsi_qla_host * ha, u32 sem_mask, u32 sem_bits);
983 void ql4xxx_sem_unlock(struct scsi_qla_host * ha, u32 sem_mask);
984 int ql4xxx_sem_lock(struct scsi_qla_host * ha, u32 sem_mask, u32 sem_bits);
1043 static inline int ql4xxx_reset_active(struct scsi_qla_host *ha) in ql4xxx_reset_active() argument
1045 return test_bit(DPC_RESET_ACTIVE, &ha->dpc_flags) || in ql4xxx_reset_active()
1046 test_bit(DPC_RESET_HA, &ha->dpc_flags) || in ql4xxx_reset_active()
1047 test_bit(DPC_RETRY_RESET_HA, &ha->dpc_flags) || in ql4xxx_reset_active()
1048 test_bit(DPC_RESET_HA_INTR, &ha->dpc_flags) || in ql4xxx_reset_active()
1049 test_bit(DPC_RESET_HA_FW_CONTEXT, &ha->dpc_flags) || in ql4xxx_reset_active()
1050 test_bit(DPC_HA_UNRECOVERABLE, &ha->dpc_flags); in ql4xxx_reset_active()
1054 static inline int qla4_8xxx_rd_direct(struct scsi_qla_host *ha, in qla4_8xxx_rd_direct() argument
1057 return ha->isp_ops->rd_reg_direct(ha, ha->reg_tbl[crb_reg]); in qla4_8xxx_rd_direct()
1060 static inline void qla4_8xxx_wr_direct(struct scsi_qla_host *ha, in qla4_8xxx_wr_direct() argument
1064 ha->isp_ops->wr_reg_direct(ha, ha->reg_tbl[crb_reg], value); in qla4_8xxx_wr_direct()