/* Enable/Disable vport Write "1" to disable, write "0" to enable  */
static ssize_t store_fc_vport_disable(struct device *dev, struct device_attribute *attr, const char *buf, size_t count)
/* Enable/Disable vport Write "1" to disable, write "0" to enable  */
static ssize_t store_fc_vport_disable(struct device *dev, struct device_attribute *attr, const char *buf, size_t count)
{
	struct fc_vport *vport = transport_class_to_vport(dev);
	struct Scsi_Host *shost = vport_to_shost(vport);
	struct fc_internal *i = to_fc_internal(shost->transportt);
	int stat;
	if (vport->flags & (FC_VPORT_DEL | FC_VPORT_CREATING))
		return -EBUSY;
	if (*buf == '0') {
		if (vport->vport_state != FC_VPORT_DISABLED)
			return -EALREADY;
	} else if (*buf == '1') {
		if (vport->vport_state == FC_VPORT_DISABLED)
			return -EALREADY;
	} else
		return -EINVAL;
	stat = i->f->vport_disable(vport, ((*buf == '0') ? false : true));
	return stat ? stat : count;
}