diff options
author | Mike Christie <michaelc@cs.wisc.edu> | 2010-09-15 17:52:30 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-10-07 18:09:39 -0400 |
commit | d2b5f10e5b93633a40d9263383b914f06019f00b (patch) | |
tree | 65cfbf169eaa46a8ddf87769042c4a79277a75a2 /drivers | |
parent | a5110f2983bdf931d9819f88505775b16de8b99e (diff) |
[SCSI] qla2xxx: prep for fc host dev loss tmo support
This removes the driver's get_host_def_dev_loss_tmo
callback and just has the driver set the dev loss
using the fc class fc_host_dev_loss_tmo macro like is
done for other fc params.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Acked-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_attr.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c index c9781050c9ed..029fe6b9d463 100644 --- a/drivers/scsi/qla2xxx/qla_attr.c +++ b/drivers/scsi/qla2xxx/qla_attr.c | |||
@@ -1530,15 +1530,6 @@ qla2x00_set_rport_loss_tmo(struct fc_rport *rport, uint32_t timeout) | |||
1530 | } | 1530 | } |
1531 | 1531 | ||
1532 | static void | 1532 | static void |
1533 | qla2x00_get_host_def_loss_tmo(struct Scsi_Host *shost) | ||
1534 | { | ||
1535 | scsi_qla_host_t *vha = shost_priv(shost); | ||
1536 | struct qla_hw_data *ha = vha->hw; | ||
1537 | |||
1538 | fc_host_def_dev_loss_tmo(shost) = ha->port_down_retry_count; | ||
1539 | } | ||
1540 | |||
1541 | static void | ||
1542 | qla2x00_dev_loss_tmo_callbk(struct fc_rport *rport) | 1533 | qla2x00_dev_loss_tmo_callbk(struct fc_rport *rport) |
1543 | { | 1534 | { |
1544 | struct Scsi_Host *host = rport_to_shost(rport); | 1535 | struct Scsi_Host *host = rport_to_shost(rport); |
@@ -1785,6 +1776,7 @@ qla24xx_vport_create(struct fc_vport *fc_vport, bool disable) | |||
1785 | } | 1776 | } |
1786 | 1777 | ||
1787 | /* initialize attributes */ | 1778 | /* initialize attributes */ |
1779 | fc_host_dev_loss_tmo(vha->host) = ha->port_down_retry_count; | ||
1788 | fc_host_node_name(vha->host) = wwn_to_u64(vha->node_name); | 1780 | fc_host_node_name(vha->host) = wwn_to_u64(vha->node_name); |
1789 | fc_host_port_name(vha->host) = wwn_to_u64(vha->port_name); | 1781 | fc_host_port_name(vha->host) = wwn_to_u64(vha->port_name); |
1790 | fc_host_supported_classes(vha->host) = | 1782 | fc_host_supported_classes(vha->host) = |
@@ -1912,7 +1904,6 @@ struct fc_function_template qla2xxx_transport_functions = { | |||
1912 | .show_host_fabric_name = 1, | 1904 | .show_host_fabric_name = 1, |
1913 | .get_host_port_state = qla2x00_get_host_port_state, | 1905 | .get_host_port_state = qla2x00_get_host_port_state, |
1914 | .show_host_port_state = 1, | 1906 | .show_host_port_state = 1, |
1915 | .get_host_def_dev_loss_tmo = qla2x00_get_host_def_loss_tmo, | ||
1916 | 1907 | ||
1917 | .dd_fcrport_size = sizeof(struct fc_port *), | 1908 | .dd_fcrport_size = sizeof(struct fc_port *), |
1918 | .show_rport_supported_classes = 1, | 1909 | .show_rport_supported_classes = 1, |
@@ -1959,7 +1950,6 @@ struct fc_function_template qla2xxx_transport_vport_functions = { | |||
1959 | .show_host_fabric_name = 1, | 1950 | .show_host_fabric_name = 1, |
1960 | .get_host_port_state = qla2x00_get_host_port_state, | 1951 | .get_host_port_state = qla2x00_get_host_port_state, |
1961 | .show_host_port_state = 1, | 1952 | .show_host_port_state = 1, |
1962 | .get_host_def_dev_loss_tmo = qla2x00_get_host_def_loss_tmo, | ||
1963 | 1953 | ||
1964 | .dd_fcrport_size = sizeof(struct fc_port *), | 1954 | .dd_fcrport_size = sizeof(struct fc_port *), |
1965 | .show_rport_supported_classes = 1, | 1955 | .show_rport_supported_classes = 1, |
@@ -1988,6 +1978,7 @@ qla2x00_init_host_attr(scsi_qla_host_t *vha) | |||
1988 | struct qla_hw_data *ha = vha->hw; | 1978 | struct qla_hw_data *ha = vha->hw; |
1989 | u32 speed = FC_PORTSPEED_UNKNOWN; | 1979 | u32 speed = FC_PORTSPEED_UNKNOWN; |
1990 | 1980 | ||
1981 | fc_host_dev_loss_tmo(vha->host) = ha->port_down_retry_count; | ||
1991 | fc_host_node_name(vha->host) = wwn_to_u64(vha->node_name); | 1982 | fc_host_node_name(vha->host) = wwn_to_u64(vha->node_name); |
1992 | fc_host_port_name(vha->host) = wwn_to_u64(vha->port_name); | 1983 | fc_host_port_name(vha->host) = wwn_to_u64(vha->port_name); |
1993 | fc_host_supported_classes(vha->host) = FC_COS_CLASS3; | 1984 | fc_host_supported_classes(vha->host) = FC_COS_CLASS3; |