Lines Matching defs:lpfc_hba

542 struct lpfc_hba {  struct
547 (struct lpfc_hba *, struct lpfc_nodelist *); argument
549 (struct lpfc_hba *, struct lpfc_scsi_buf *); argument
551 (struct lpfc_hba *, struct lpfc_scsi_buf *); argument
553 (struct lpfc_hba *, struct lpfc_scsi_buf *); argument
555 (struct lpfc_hba *); argument
562 (struct lpfc_hba *, uint32_t, argument
564 void (*__lpfc_sli_release_iocbq)(struct lpfc_hba *, argument
566 int (*lpfc_hba_down_post)(struct lpfc_hba *phba); argument
570 (struct lpfc_hba *, struct lpfc_iocbq *, struct lpfc_iocbq *); argument
574 (struct lpfc_hba *, LPFC_MBOXQ_t *, uint32_t); argument
578 (struct lpfc_hba *phba, struct lpfc_sli_ring *pring, argument
583 (struct lpfc_hba *, uint32_t, struct hbq_dmabuf *); argument
585 (struct lpfc_hba *); argument
587 (struct lpfc_hba *, uint32_t); argument
589 (struct lpfc_hba *); argument
591 (struct lpfc_hba *); argument
592 int (*lpfc_hba_init_link) argument
594 int (*lpfc_hba_down_link) argument
597 (struct lpfc_hba *); argument
600 (struct lpfc_hba *, struct lpfc_scsi_buf *); argument
604 struct lpfc_sli4_hba sli4_hba;
606 struct lpfc_sli sli;
607 uint8_t pci_dev_grp; /* lpfc PCI dev group: 0x0, 0x1, 0x2,... */
608 uint32_t sli_rev; /* SLI2, SLI3, or SLI4 */
609 uint32_t sli3_options; /* Mask of enabled SLI3 options */
618 uint32_t iocb_cmd_size;
619 uint32_t iocb_rsp_size;
621 enum hba_state link_state;
622 uint32_t link_flag; /* link state flags */
629 uint32_t hba_flag; /* hba generic flags */
647 uint32_t fcp_ring_in_use; /* When polling test if intr-hndlr active*/
648 struct lpfc_dmabuf slim2p;
650 MAILBOX_t *mbox;
651 uint32_t *mbox_ext;
652 struct lpfc_mbox_ext_buf_ctx mbox_ext_buf_ctx;
653 uint32_t ha_copy;
654 struct _PCB *pcb;
655 struct _IOCB *IOCBs;
657 struct lpfc_dmabuf hbqslimp;
659 uint16_t pci_cfg_value;
661 uint8_t fc_linkspeed; /* Link speed after last READ_LA */
663 uint32_t fc_eventTag; /* event tag for link attention */
664 uint32_t link_events;
667 uint32_t fc_pref_DID; /* preferred D_ID */
668 uint8_t fc_pref_ALPA; /* preferred AL_PA */
669 uint32_t fc_edtovResol; /* E_D_TOV timer resolution */
670 uint32_t fc_edtov; /* E_D_TOV timer value */
671 uint32_t fc_arbtov; /* ARB_TOV timer value */
672 uint32_t fc_ratov; /* R_A_TOV timer value */
673 uint32_t fc_rttov; /* R_T_TOV timer value */
674 uint32_t fc_altov; /* AL_TOV timer value */
675 uint32_t fc_crtov; /* C_R_TOV timer value */
676 uint32_t fc_citov; /* C_I_TOV timer value */
678 struct serv_parm fc_fabparam; /* fabric service parameters buffer */
679 uint8_t alpa_map[128]; /* AL_PA map from READ_LA */
681 uint32_t lmt;
683 uint32_t fc_topology; /* link topology, from LINK INIT */
684 uint32_t fc_topology_changed; /* link topology, from LINK INIT */
686 struct lpfc_stats fc_stat;
688 struct lpfc_nodelist fc_fcpnodev; /* nodelist entry for no device */
689 uint32_t nport_event_cnt; /* timestamp for nlplist entry */
691 uint8_t wwnn[8];
692 uint8_t wwpn[8];
693 uint32_t RandomData[7];
696 uint32_t cfg_ack0;
697 uint32_t cfg_enable_npiv;
698 uint32_t cfg_enable_rrq;
699 uint32_t cfg_topology;
700 uint32_t cfg_link_speed;
703 uint32_t cfg_fcf_failover_policy;
704 uint32_t cfg_fcp_io_sched;
705 uint32_t cfg_fcp2_no_tgt_reset;
706 uint32_t cfg_cr_delay;
707 uint32_t cfg_cr_count;
708 uint32_t cfg_multi_ring_support;
709 uint32_t cfg_multi_ring_rctl;
710 uint32_t cfg_multi_ring_type;
711 uint32_t cfg_poll;
712 uint32_t cfg_poll_tmo;
713 uint32_t cfg_task_mgmt_tmo;
714 uint32_t cfg_use_msi;
715 uint32_t cfg_fcp_imax;
716 uint32_t cfg_fcp_cpu_map;
717 uint32_t cfg_fcp_io_channel;
718 uint32_t cfg_total_seg_cnt;
719 uint32_t cfg_sg_seg_cnt;
720 uint32_t cfg_prot_sg_seg_cnt;
721 uint32_t cfg_sg_dma_buf_size;
722 uint64_t cfg_soft_wwnn;
723 uint64_t cfg_soft_wwpn;
724 uint32_t cfg_hba_queue_depth;
725 uint32_t cfg_enable_hba_reset;
726 uint32_t cfg_enable_hba_heartbeat;
727 uint32_t cfg_fof;
728 uint32_t cfg_EnableXLane;
729 uint8_t cfg_oas_tgt_wwpn[8];
730 uint8_t cfg_oas_vpt_wwpn[8];
731 uint32_t cfg_oas_lun_state;
734 uint32_t cfg_oas_lun_status;
736 uint32_t cfg_oas_flags;
740 uint32_t cfg_XLanePriority;
741 uint32_t cfg_enable_bg;
742 uint32_t cfg_hostmem_hgp;
743 uint32_t cfg_log_verbose;
744 uint32_t cfg_aer_support;
745 uint32_t cfg_sriov_nr_virtfn;
746 uint32_t cfg_request_firmware_upgrade;
747 uint32_t cfg_iocb_cnt;
748 uint32_t cfg_suppress_link_up;
749 uint32_t cfg_rrq_xri_bitmap_sz;
753 uint32_t cfg_enable_dss;
754 lpfc_vpd_t vpd; /* vital product data */
756 struct pci_dev *pcidev;
757 struct list_head work_list;
758 uint32_t work_ha; /* Host Attention Bits for WT */
759 uint32_t work_ha_mask; /* HA Bits owned by WT */
760 uint32_t work_hs; /* HS stored in case of ERRAT */
761 uint32_t work_status[2]; /* Extra status from SLIM */
763 wait_queue_head_t work_waitq;
764 struct task_struct *worker_thread;
765 unsigned long data_flags;
767 uint32_t hbq_in_use; /* HBQs in use flag */
768 struct list_head rb_pend_list; /* Received buffers to be processed */
769 uint32_t hbq_count; /* Count of configured HBQs */
770 struct hbq_s hbqs[LPFC_MAX_HBQS]; /* local copy of hbq indicies */
772 atomic_t fcp_qidx; /* next work queue to post work to */
774 unsigned long pci_bar0_map; /* Physical address for PCI BAR0 */
775 unsigned long pci_bar1_map; /* Physical address for PCI BAR1 */
776 unsigned long pci_bar2_map; /* Physical address for PCI BAR2 */
777 void __iomem *slim_memmap_p; /* Kernel memory mapped address for
779 void __iomem *ctrl_regs_memmap_p;/* Kernel memory mapped address for
782 void __iomem *pci_bar0_memmap_p; /* Kernel memory mapped address for
784 void __iomem *pci_bar2_memmap_p; /* Kernel memory mapped address for
786 void __iomem *pci_bar4_memmap_p; /* Kernel memory mapped address for
791 void __iomem *MBslimaddr; /* virtual address for mbox cmds */
792 void __iomem *HAregaddr; /* virtual address for host attn reg */
793 void __iomem *CAregaddr; /* virtual address for chip attn reg */
794 void __iomem *HSregaddr; /* virtual address for host status
796 void __iomem *HCregaddr; /* virtual address for host ctl reg */
798 struct lpfc_hgp __iomem *host_gp; /* Host side get/put pointers */
799 struct lpfc_pgp *port_gp;
800 uint32_t __iomem *hbq_put; /* Address in SLIM to HBQ put ptrs */
801 uint32_t *hbq_get; /* Host mem address of HBQ get ptrs */
803 int brd_no; /* FC board number */
804 char SerialNumber[32]; /* adapter Serial Number */
805 char OptionROMVersion[32]; /* adapter BIOS / Fcode version */
806 char ModelDesc[256]; /* Model Description */
807 char ModelName[80]; /* Model Name */
808 char ProgramType[256]; /* Program Type */
809 char Port[20]; /* Port No */
810 uint8_t vpd_flag; /* VPD data flag */
818 uint8_t soft_wwn_enable;
820 struct timer_list fcp_poll_timer;
821 struct timer_list eratt_poll;
826 uint64_t fc4InputRequests;
827 uint64_t fc4OutputRequests;
828 uint64_t fc4ControlRequests;
829 uint64_t bg_guard_err_cnt;
830 uint64_t bg_apptag_err_cnt;
831 uint64_t bg_reftag_err_cnt;
834 spinlock_t scsi_buf_list_get_lock; /* SCSI buf alloc list lock */
835 spinlock_t scsi_buf_list_put_lock; /* SCSI buf free list lock */
836 struct list_head lpfc_scsi_buf_list_get;
837 struct list_head lpfc_scsi_buf_list_put;
838 uint32_t total_scsi_bufs;
839 struct list_head lpfc_iocb_list;
840 uint32_t total_iocbq_bufs;
841 struct list_head active_rrq_list;
842 spinlock_t hbalock;
845 struct pci_pool *lpfc_scsi_dma_buf_pool;
846 struct pci_pool *lpfc_mbuf_pool;
847 struct pci_pool *lpfc_hrb_pool; /* header receive buffer pool */
848 struct pci_pool *lpfc_drb_pool; /* data receive buffer pool */
849 struct pci_pool *lpfc_hbq_pool; /* SLI3 hbq buffer pool */
850 struct lpfc_dma_pool lpfc_mbuf_safety_pool;
852 mempool_t *mbox_mem_pool;
853 mempool_t *nlp_mem_pool;
854 mempool_t *rrq_pool;
855 mempool_t *active_rrq_pool;
857 struct fc_host_statistics link_stats;
858 enum intr_type_t intr_type;
859 uint32_t intr_mode;
861 struct msix_entry msix_entries[LPFC_MSIX_VECTORS];
863 struct list_head port_list;
864 struct lpfc_vport *pport; /* physical lpfc_vport pointer */
865 uint16_t max_vpi; /* Maximum virtual nports */
867 uint16_t max_vports; /*
873 uint16_t vpi_base;
874 uint16_t vfi_base;
875 unsigned long *vpi_bmask; /* vpi allocation table */
876 uint16_t *vpi_ids;
877 uint16_t vpi_count;
878 struct list_head lpfc_vpi_blk_list;
881 struct list_head fabric_iocb_list;
882 atomic_t fabric_iocb_count;
883 struct timer_list fabric_block_timer;
884 unsigned long bit_flags;
886 atomic_t num_rsrc_err;
887 atomic_t num_cmd_success;
888 unsigned long last_rsrc_error_time;
889 unsigned long last_ramp_down_time;
891 struct dentry *hba_debugfs_root;
892 atomic_t debugfs_vport_count;
893 struct dentry *debug_hbqinfo;
894 struct dentry *debug_dumpHostSlim;
895 struct dentry *debug_dumpHBASlim;
896 struct dentry *debug_dumpData; /* BlockGuard BPL */
897 struct dentry *debug_dumpDif; /* BlockGuard BPL */
898 struct dentry *debug_InjErrLBA; /* LBA to inject errors at */
899 struct dentry *debug_InjErrNPortID; /* NPortID to inject errors at */
900 struct dentry *debug_InjErrWWPN; /* WWPN to inject errors at */
901 struct dentry *debug_writeGuard; /* inject write guard_tag errors */
902 struct dentry *debug_writeApp; /* inject write app_tag errors */
903 struct dentry *debug_writeRef; /* inject write ref_tag errors */
904 struct dentry *debug_readGuard; /* inject read guard_tag errors */
905 struct dentry *debug_readApp; /* inject read app_tag errors */
906 struct dentry *debug_readRef; /* inject read ref_tag errors */
909 uint32_t lpfc_injerr_wgrd_cnt;
910 uint32_t lpfc_injerr_wapp_cnt;
911 uint32_t lpfc_injerr_wref_cnt;
912 uint32_t lpfc_injerr_rgrd_cnt;
913 uint32_t lpfc_injerr_rapp_cnt;
914 uint32_t lpfc_injerr_rref_cnt;
915 uint32_t lpfc_injerr_nportid;
916 struct lpfc_name lpfc_injerr_wwpn;
917 sector_t lpfc_injerr_lba;
920 struct dentry *debug_slow_ring_trc;
921 struct lpfc_debugfs_trc *slow_ring_trc;
922 atomic_t slow_ring_trc_cnt;
924 struct dentry *idiag_root;
925 struct dentry *idiag_pci_cfg;
926 struct dentry *idiag_bar_acc;
927 struct dentry *idiag_que_info;
928 struct dentry *idiag_que_acc;
929 struct dentry *idiag_drb_acc;
930 struct dentry *idiag_ctl_acc;
931 struct dentry *idiag_mbx_acc;
932 struct dentry *idiag_ext_acc;
936 struct list_head elsbuf;
937 int elsbuf_cnt;
938 int elsbuf_prev_cnt;
940 uint8_t temp_sensor_support;
942 unsigned long last_completion_time;
943 unsigned long skipped_hb;
944 struct timer_list hb_tmofunc;
945 uint8_t hb_outstanding;
946 struct timer_list rrq_tmr;
947 enum hba_temp_state over_temp_state;
949 spinlock_t ndlp_lock;
955 uint32_t buffer_tag_count;
956 int wait_4_mlo_maint_flg;
957 wait_queue_head_t wait_4_mlo_m_q;
962 uint8_t bucket_type;
963 uint32_t bucket_base;
964 uint32_t bucket_step;
968 atomic_t fast_event_count;
969 uint32_t fcoe_eventtag;
970 uint32_t fcoe_eventtag_at_fcf_scan;
971 uint32_t fcoe_cvl_eventtag;
972 uint32_t fcoe_cvl_eventtag_attn;
973 struct lpfc_fcf fcf;
974 uint8_t fc_map[3];
975 uint8_t valid_vlan;
976 uint16_t vlan_id;
977 struct list_head fcf_conn_rec_list;
979 spinlock_t ct_ev_lock; /* synchronize access to ct_ev_waiters */
1003 lpfc_set_loopback_flag(struct lpfc_hba *phba) in lpfc_set_loopback_flag() argument