aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/scsi/zfcp_ext.h
diff options
context:
space:
mode:
authorChristof Schmitt <christof.schmitt@de.ibm.com>2010-09-08 08:39:55 -0400
committerJames Bottomley <James.Bottomley@suse.de>2010-09-16 22:54:17 -0400
commitb62a8d9b45b971a67a0f8413338c230e3117dff5 (patch)
treea38acd9f0fcb14e41e26503d8a25d8f1539dd27d /drivers/s390/scsi/zfcp_ext.h
parentfdbd1c5e27dabfa950d4b0f52a20069aeaf67b9d (diff)
[SCSI] zfcp: Use SCSI device data zfcp_scsi_dev instead of zfcp_unit
This is the large change to switch from using the data in zfcp_unit to zfcp_scsi_dev. Keeping everything working requires doing the switch in one piece. To ensure that no code keeps using the data in zfcp_unit, this patch also removes the data from zfcp_unit that is now being replaced with zfcp_scsi_dev. For zfcp, the scsi_device together with zfcp_scsi_dev exist from the call of slave_alloc to the call of slave_destroy. The data in zfcp_scsi_dev is initialized in zfcp_scsi_slave_alloc and the LUN is opened; the final shutdown for the LUN is run from slave_destroy. Where the scsi_device or zfcp_scsi_dev is needed, the pointer to the scsi_device is passed as function argument and inside the function converted to the pointer to zfcp_scsi_dev; this avoids back and forth conversion betweeen scsi_device and zfcp_scsi_dev. While changing the function arguments from zfcp_unit to scsi_device, the functions names are renamed form "unit" to "lun". This is to have a seperation between zfcp_scsi_dev/LUN and the zfcp_unit; only code referring to the remaining configuration information in zfcp_unit struct uses "unit". Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/s390/scsi/zfcp_ext.h')
-rw-r--r--drivers/s390/scsi/zfcp_ext.h32
1 files changed, 15 insertions, 17 deletions
diff --git a/drivers/s390/scsi/zfcp_ext.h b/drivers/s390/scsi/zfcp_ext.h
index 3c90604076e0..80714679f5d6 100644
--- a/drivers/s390/scsi/zfcp_ext.h
+++ b/drivers/s390/scsi/zfcp_ext.h
@@ -42,10 +42,10 @@ extern void zfcp_dbf_rec_thread(char *, struct zfcp_dbf *);
42extern void zfcp_dbf_rec_thread_lock(char *, struct zfcp_dbf *); 42extern void zfcp_dbf_rec_thread_lock(char *, struct zfcp_dbf *);
43extern void zfcp_dbf_rec_adapter(char *, void *, struct zfcp_dbf *); 43extern void zfcp_dbf_rec_adapter(char *, void *, struct zfcp_dbf *);
44extern void zfcp_dbf_rec_port(char *, void *, struct zfcp_port *); 44extern void zfcp_dbf_rec_port(char *, void *, struct zfcp_port *);
45extern void zfcp_dbf_rec_unit(char *, void *, struct zfcp_unit *); 45extern void zfcp_dbf_rec_lun(char *, void *, struct scsi_device *);
46extern void zfcp_dbf_rec_trigger(char *, void *, u8, u8, void *, 46extern void zfcp_dbf_rec_trigger(char *, void *, u8, u8, void *,
47 struct zfcp_adapter *, struct zfcp_port *, 47 struct zfcp_adapter *, struct zfcp_port *,
48 struct zfcp_unit *); 48 struct scsi_device *);
49extern void zfcp_dbf_rec_action(char *, struct zfcp_erp_action *); 49extern void zfcp_dbf_rec_action(char *, struct zfcp_erp_action *);
50extern void _zfcp_dbf_hba_fsf_response(const char *, int, struct zfcp_fsf_req *, 50extern void _zfcp_dbf_hba_fsf_response(const char *, int, struct zfcp_fsf_req *,
51 struct zfcp_dbf *); 51 struct zfcp_dbf *);
@@ -76,20 +76,20 @@ extern void zfcp_erp_port_shutdown(struct zfcp_port *, int, char *, void *);
76extern void zfcp_erp_port_forced_reopen(struct zfcp_port *, int, char *, 76extern void zfcp_erp_port_forced_reopen(struct zfcp_port *, int, char *,
77 void *); 77 void *);
78extern void zfcp_erp_port_failed(struct zfcp_port *, char *, void *); 78extern void zfcp_erp_port_failed(struct zfcp_port *, char *, void *);
79extern void zfcp_erp_modify_unit_status(struct zfcp_unit *, char *, void *, u32, 79extern void zfcp_erp_modify_lun_status(struct scsi_device *, char *, void *,
80 int); 80 u32, int);
81extern void zfcp_erp_unit_reopen(struct zfcp_unit *, int, char *, void *); 81extern void zfcp_erp_lun_reopen(struct scsi_device *, int, char *, void *);
82extern void zfcp_erp_unit_shutdown(struct zfcp_unit *, int, char *, void *); 82extern void zfcp_erp_lun_shutdown(struct scsi_device *, int, char *, void *);
83extern void zfcp_erp_unit_shutdown_wait(struct zfcp_unit *, char *); 83extern void zfcp_erp_lun_shutdown_wait(struct scsi_device *, char *);
84extern void zfcp_erp_unit_failed(struct zfcp_unit *, char *, void *); 84extern void zfcp_erp_lun_failed(struct scsi_device *, char *, void *);
85extern int zfcp_erp_thread_setup(struct zfcp_adapter *); 85extern int zfcp_erp_thread_setup(struct zfcp_adapter *);
86extern void zfcp_erp_thread_kill(struct zfcp_adapter *); 86extern void zfcp_erp_thread_kill(struct zfcp_adapter *);
87extern void zfcp_erp_wait(struct zfcp_adapter *); 87extern void zfcp_erp_wait(struct zfcp_adapter *);
88extern void zfcp_erp_notify(struct zfcp_erp_action *, unsigned long); 88extern void zfcp_erp_notify(struct zfcp_erp_action *, unsigned long);
89extern void zfcp_erp_port_boxed(struct zfcp_port *, char *, void *); 89extern void zfcp_erp_port_boxed(struct zfcp_port *, char *, void *);
90extern void zfcp_erp_unit_boxed(struct zfcp_unit *, char *, void *); 90extern void zfcp_erp_lun_boxed(struct scsi_device *, char *, void *);
91extern void zfcp_erp_port_access_denied(struct zfcp_port *, char *, void *); 91extern void zfcp_erp_port_access_denied(struct zfcp_port *, char *, void *);
92extern void zfcp_erp_unit_access_denied(struct zfcp_unit *, char *, void *); 92extern void zfcp_erp_lun_access_denied(struct scsi_device *, char *, void *);
93extern void zfcp_erp_adapter_access_changed(struct zfcp_adapter *, char *, 93extern void zfcp_erp_adapter_access_changed(struct zfcp_adapter *, char *,
94 void *); 94 void *);
95extern void zfcp_erp_timeout_handler(unsigned long); 95extern void zfcp_erp_timeout_handler(unsigned long);
@@ -117,8 +117,8 @@ extern int zfcp_fsf_open_wka_port(struct zfcp_fc_wka_port *);
117extern int zfcp_fsf_close_wka_port(struct zfcp_fc_wka_port *); 117extern int zfcp_fsf_close_wka_port(struct zfcp_fc_wka_port *);
118extern int zfcp_fsf_close_port(struct zfcp_erp_action *); 118extern int zfcp_fsf_close_port(struct zfcp_erp_action *);
119extern int zfcp_fsf_close_physical_port(struct zfcp_erp_action *); 119extern int zfcp_fsf_close_physical_port(struct zfcp_erp_action *);
120extern int zfcp_fsf_open_unit(struct zfcp_erp_action *); 120extern int zfcp_fsf_open_lun(struct zfcp_erp_action *);
121extern int zfcp_fsf_close_unit(struct zfcp_erp_action *); 121extern int zfcp_fsf_close_lun(struct zfcp_erp_action *);
122extern int zfcp_fsf_exchange_config_data(struct zfcp_erp_action *); 122extern int zfcp_fsf_exchange_config_data(struct zfcp_erp_action *);
123extern int zfcp_fsf_exchange_config_data_sync(struct zfcp_qdio *, 123extern int zfcp_fsf_exchange_config_data_sync(struct zfcp_qdio *,
124 struct fsf_qtcb_bottom_config *); 124 struct fsf_qtcb_bottom_config *);
@@ -134,12 +134,10 @@ extern int zfcp_fsf_send_ct(struct zfcp_fc_wka_port *, struct zfcp_fsf_ct_els *,
134 mempool_t *, unsigned int); 134 mempool_t *, unsigned int);
135extern int zfcp_fsf_send_els(struct zfcp_adapter *, u32, 135extern int zfcp_fsf_send_els(struct zfcp_adapter *, u32,
136 struct zfcp_fsf_ct_els *, unsigned int); 136 struct zfcp_fsf_ct_els *, unsigned int);
137extern int zfcp_fsf_send_fcp_command_task(struct zfcp_unit *, 137extern int zfcp_fsf_fcp_cmnd(struct scsi_cmnd *);
138 struct scsi_cmnd *);
139extern void zfcp_fsf_req_free(struct zfcp_fsf_req *); 138extern void zfcp_fsf_req_free(struct zfcp_fsf_req *);
140extern struct zfcp_fsf_req *zfcp_fsf_send_fcp_ctm(struct zfcp_unit *, u8); 139extern struct zfcp_fsf_req *zfcp_fsf_fcp_task_mgmt(struct scsi_cmnd *, u8);
141extern struct zfcp_fsf_req *zfcp_fsf_abort_fcp_command(unsigned long, 140extern struct zfcp_fsf_req *zfcp_fsf_abort_fcp_cmnd(struct scsi_cmnd *);
142 struct zfcp_unit *);
143extern void zfcp_fsf_reqid_check(struct zfcp_qdio *, int); 141extern void zfcp_fsf_reqid_check(struct zfcp_qdio *, int);
144 142
145/* zfcp_qdio.c */ 143/* zfcp_qdio.c */