Re: [PATCH 11/15] iscsi_transport: Added new iscsi_host_param for iSCSI transport

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 06/11/2010 02:48 AM, Vikas Chaudhary wrote:
+	case ISCSI_HOST_PARAM_IF_TYPE:
+		len = sprintf(buf, "%s\n", ((ha->addl_fw_state&
+		    FW_ADDSTATE_OPTICAL_MEDIA) != 0) ?
+		    "Optical" : "Copper");

I think it is best to add a table that maps some enum ISCSI_IF_TYPE to a string in scsi_transport_iscsi.c, then have the driver set the type on the iscsi_cls_host struct. scsi_tranpoort_iscsi.c would then just do the work of concerting and printing. This way we can make sure all the drivers print out their values in the same format. It would be like scsi_transport_fc.c's fc_port_speed_names or cos.
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux