aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Smart <james.smart@emulex.com>2015-04-07 15:07:18 -0400
committerJames Bottomley <JBottomley@Odin.com>2015-04-10 10:48:45 -0400
commitf0bf5f91908f7c8819d4111c7bd793178021aa3f (patch)
tree564bcf9e24f6afca9808e229fce019dc53b9bf4c
parent26d830ec7fb660130a00f5d27601f37da70a4c1e (diff)
lpfc: Fix provide host name and OS name in RSNN-NN FC-GS command
Signed-off-by: Dick Kennedy <dick.kennedy@emulex.com> Signed-off-by: James Smart <james.smart@emulex.com> Reviewed-by: Hannes Reinecke <hare@suse.de> Signed-off-by: James Bottomley <JBottomley@Odin.com>
-rw-r--r--drivers/scsi/lpfc/lpfc_ct.c21
1 files changed, 19 insertions, 2 deletions
diff --git a/drivers/scsi/lpfc/lpfc_ct.c b/drivers/scsi/lpfc/lpfc_ct.c
index 61a32cd23f79..5fb431a51588 100644
--- a/drivers/scsi/lpfc/lpfc_ct.c
+++ b/drivers/scsi/lpfc/lpfc_ct.c
@@ -1074,8 +1074,25 @@ lpfc_vport_symbolic_node_name(struct lpfc_vport *vport, char *symbol,
1074 1074
1075 lpfc_decode_firmware_rev(vport->phba, fwrev, 0); 1075 lpfc_decode_firmware_rev(vport->phba, fwrev, 0);
1076 1076
1077 n = snprintf(symbol, size, "Emulex %s FV%s DV%s", 1077 n = snprintf(symbol, size, "Emulex %s", vport->phba->ModelName);
1078 vport->phba->ModelName, fwrev, lpfc_release_version); 1078
1079 if (size < n)
1080 return n;
1081 n += snprintf(symbol + n, size - n, " FV%s", fwrev);
1082
1083 if (size < n)
1084 return n;
1085 n += snprintf(symbol + n, size - n, " DV%s", lpfc_release_version);
1086
1087 if (size < n)
1088 return n;
1089 n += snprintf(symbol + n, size - n, " HN:%s", init_utsname()->nodename);
1090
1091 /* Note :- OS name is "Linux" */
1092 if (size < n)
1093 return n;
1094 n += snprintf(symbol + n, size - n, " OS:%s", init_utsname()->sysname);
1095
1079 return n; 1096 return n;
1080} 1097}
1081 1098