RE: [PATCH v5 5/6] scsi: ufs-bsg: Add support for raw upiu in ufs_bsg_request()

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

 




> > +static inline struct ufs_hba *dev_to_ufs_hba(struct device *d)
> > +{
> > +	struct Scsi_Host *shost = dev_to_shost(d->parent);
> > +
> > +	return shost_priv(shost);
> 
> This just has one caller that culd directly do:
> 
> 	struct ufs_hba *hba = shost_priv(dev_to_shost(job->dev-parent));
Done.
 
> > +		if (qr->opcode == UPIU_QUERY_OPCODE_WRITE_DESC) {
> > +			rw = WRITE;
> > +			desc_buff = ((uint8_t *)bsg_request) +
> > +				    sizeof(struct ufs_bsg_request);
> 
> 			desc_buff = bsg_request + 1;
Done.

> 
> > +			}
> > +		}
> > +
> > +		req_upiu = (struct utp_upiu_req *)&bsg_request->header;
> > +		rsp_upiu = (struct utp_upiu_req *)&bsg_reply->header;
> 
> Why do we define the bsg_request/reply separately from struct
> utp_upiu_req
> instead of moving struct utp_upiu_req to the UAPI header and including
> it?
Done.
Bart told me to that a while ago, but somehow it slipped away.
Will do that now.




[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