drivers/s390/scsi/zfcp_def.h

Source file repositories/reference/linux-study-clean/drivers/s390/scsi/zfcp_def.h

File Facts

System
Linux kernel
Corpus path
drivers/s390/scsi/zfcp_def.h
Extension
.h
Size
11545 bytes
Lines
354
Domain
Driver Families
Bucket
drivers/s390
Inferred role
Driver Families: implementation source
Status
source implementation candidate

Why This File Exists

Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.

Dependency Surface

Detected Declarations

Annotated Snippet

struct zfcp_erp_action {
	struct list_head list;
	enum zfcp_erp_act_type type;  /* requested action code */
	struct zfcp_adapter *adapter; /* device which should be recovered */
	struct zfcp_port *port;
	struct scsi_device *sdev;
	u32		status;	      /* recovery status */
	enum zfcp_erp_steps	step;	/* active step of this erp action */
	u64			fsf_req_id;
	struct timer_list timer;
};

/* holds various memory pools of an adapter */
struct zfcp_adapter_mempool {
	mempool_t *erp_req;
	mempool_t *gid_pn_req;
	mempool_t *scsi_req;
	mempool_t *scsi_abort;
	mempool_t *status_read_req;
	mempool_t *sr_data;
	mempool_t *gid_pn;
	mempool_t *qtcb_pool;
};

struct zfcp_adapter {
	struct kref		ref;
	u64			peer_wwnn;	   /* P2P peer WWNN */
	u64			peer_wwpn;	   /* P2P peer WWPN */
	u32			peer_d_id;	   /* P2P peer D_ID */
	struct ccw_device       *ccw_device;	   /* S/390 ccw device */
	struct zfcp_qdio	*qdio;
	u32			hydra_version;	   /* Hydra version */
	u32			fsf_lic_version;
	u32			adapter_features;  /* FCP channel features */
	u32			connection_features; /* host connection features */
	u32			hardware_version;  /* of FCP channel */
	u32			fc_security_algorithms; /* of FCP channel */
	u32			fc_security_algorithms_old; /* of FCP channel */
	u16			timer_ticks;       /* time int for a tick */
	struct Scsi_Host	*scsi_host;	   /* Pointer to mid-layer */
	struct list_head	port_list;	   /* remote port list */
	rwlock_t		port_list_lock;    /* port list lock */
	u64			req_no;		   /* unique FSF req number */
	struct zfcp_reqlist	*req_list;
	u32			fsf_req_seq_no;	   /* FSF cmnd seq number */
	rwlock_t		abort_lock;        /* Protects against SCSI
						      stack abort/command
						      completion races */
	atomic_t		stat_miss;	   /* # missing status reads*/
	unsigned int		stat_read_buf_num;
	struct work_struct	stat_work;
	atomic_t		status;	           /* status of this adapter */
	struct list_head	erp_ready_head;	   /* error recovery for this
						      adapter/devices */
	wait_queue_head_t	erp_ready_wq;
	struct list_head	erp_running_head;
	rwlock_t		erp_lock;
	wait_queue_head_t	erp_done_wqh;
	struct zfcp_erp_action	erp_action;	   /* pending error recovery */
	atomic_t		erp_counter;
	u32			erp_total_count;   /* total nr of enqueued erp
						      actions */
	u32			erp_low_mem_count; /* nr of erp actions waiting
						      for memory */
	struct task_struct	*erp_thread;
	struct zfcp_fc_wka_ports *gs;		   /* generic services */
	struct zfcp_dbf		*dbf;		   /* debug traces */
	struct zfcp_adapter_mempool	pool;      /* Adapter memory pools */
	struct fc_host_statistics *fc_stats;
	struct fsf_qtcb_bottom_port *stats_reset_data;
	unsigned long		stats_reset;
	struct delayed_work	scan_work;
	struct work_struct	ns_up_work;
	struct service_level	service_level;
	struct workqueue_struct	*work_queue;
	struct device_dma_parameters dma_parms;
	struct zfcp_fc_events events;
	unsigned long		next_port_scan;
	struct zfcp_diag_adapter	*diagnostics;
	struct work_struct	version_change_lost_work;
};

struct zfcp_port {
	struct device          dev;
	struct fc_rport        *rport;         /* rport of fc transport class */
	struct list_head       list;	       /* list of remote ports */
	struct zfcp_adapter    *adapter;       /* adapter used to access port */
	struct list_head	unit_list;	/* head of logical unit list */
	rwlock_t		unit_list_lock; /* unit list lock */
	atomic_t		units;	       /* zfcp_unit count */

Annotation

Implementation Notes