aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsi_transport_iscsi.c
diff options
context:
space:
mode:
authorMike Christie <michaelc@cs.wisc.edu>2007-05-30 13:57:13 -0400
committerJames Bottomley <jejb@mulgrave.(none)>2007-06-01 12:56:40 -0400
commit8ad5781ae9702a8f95cfdf30967752e4297613ee (patch)
treecaafde966ac7e9cda0e27e3b5412f25021d2d561 /drivers/scsi/scsi_transport_iscsi.c
parent0801c242a33426fddc005c2f559a3d2fa6fca7eb (diff)
[SCSI] iscsi class, qla4xxx, iscsi_tcp, ib_iser: export/set initiator name
For iscsi root boot, software iscsi needs to know what the BIOS/OF initiator used for the initiator name so this puts it in sysfs for userspace to be able to pick up. For hw iscsi, it is nice to see what the card is using. This patch adds the new param, and hooks in qla4xxx, iscsi_tcp, and ib_iser. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Cc: Roland Dreier <rdreier@cisco.com> Cc: David C Somayajulu <david.somayajulu@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/scsi_transport_iscsi.c')
-rw-r--r--drivers/scsi/scsi_transport_iscsi.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_transport_iscsi.c
index 3fd2da451fe1..5ec2fbea8937 100644
--- a/drivers/scsi/scsi_transport_iscsi.c
+++ b/drivers/scsi/scsi_transport_iscsi.c
@@ -32,7 +32,7 @@
32 32
33#define ISCSI_SESSION_ATTRS 11 33#define ISCSI_SESSION_ATTRS 11
34#define ISCSI_CONN_ATTRS 11 34#define ISCSI_CONN_ATTRS 11
35#define ISCSI_HOST_ATTRS 1 35#define ISCSI_HOST_ATTRS 2
36#define ISCSI_TRANSPORT_VERSION "2.0-724" 36#define ISCSI_TRANSPORT_VERSION "2.0-724"
37 37
38struct iscsi_internal { 38struct iscsi_internal {
@@ -1253,6 +1253,7 @@ static ISCSI_CLASS_ATTR(host, field, S_IRUGO, show_host_param_##param, \
1253 NULL); 1253 NULL);
1254 1254
1255iscsi_host_attr(hwaddress, ISCSI_HOST_PARAM_HWADDRESS); 1255iscsi_host_attr(hwaddress, ISCSI_HOST_PARAM_HWADDRESS);
1256iscsi_host_attr(initiatorname, ISCSI_HOST_PARAM_INITIATOR_NAME);
1256 1257
1257#define SETUP_PRIV_SESSION_RD_ATTR(field) \ 1258#define SETUP_PRIV_SESSION_RD_ATTR(field) \
1258do { \ 1259do { \
@@ -1389,6 +1390,7 @@ iscsi_register_transport(struct iscsi_transport *tt)
1389 transport_container_register(&priv->t.host_attrs); 1390 transport_container_register(&priv->t.host_attrs);
1390 1391
1391 SETUP_HOST_RD_ATTR(hwaddress, ISCSI_HOST_HWADDRESS); 1392 SETUP_HOST_RD_ATTR(hwaddress, ISCSI_HOST_HWADDRESS);
1393 SETUP_HOST_RD_ATTR(initiatorname, ISCSI_HOST_INITIATOR_NAME);
1392 BUG_ON(count > ISCSI_HOST_ATTRS); 1394 BUG_ON(count > ISCSI_HOST_ATTRS);
1393 priv->host_attrs[count] = NULL; 1395 priv->host_attrs[count] = NULL;
1394 count = 0; 1396 count = 0;