RE: [PATCH 3/3] mptsas: add SMP passthrough support via bsg

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

 



On Sunday, July 29, 2007 1:37 AM, FUJITA Tomonori wrote:
> > Eric, can I get your ACK on this patch?
> 
> One comment on the the patch:
> 
> +	if (!(ioc->sas_mgmt.status & MPT_IOCTL_STATUS_COMMAND_GOOD)) {
> +		printk(KERN_ERR "%s: smp response invalid!\n", 
> __FUNCTION__);
> +		ret = -ENXIO;
> +	}
> 
> We don't need this part since user-space can get mpt's reply, I think.
>

Correct, this should be removed. The processing of the mpt reply has
been pushed to user-space.    On another note, according to the mpi
specification, its says there should always be a reply message frame
returned for every smp passthru.  So I thinking this would be the best
way to close out the end of this function.  What do you think?


+	if (ioc->sas_mgmt.status & MPT_IOCTL_STATUS_RF_VALID) {
+		SmpPassthroughReply_t *smprep;
+
+		smprep = (SmpPassthroughReply_t *)ioc->sas_mgmt.reply;
+		memcpy(req->sense, smprep, sizeof(*smprep));
+		req->sense_len = sizeof(*smprep);
+	} else
+		printk(KERN_ERR "%s: smp passthru reply failed to be
returned\n", __FUNCTION__);
+		ret = -ENXIO;
+	}

-
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