diff options
author | Naresh Kumar Inna <naresh@chelsio.com> | 2012-11-20 18:15:40 +0530 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2012-11-30 15:32:10 +0000 |
commit | 5036f0a0ecd31fc94360a944b352d082e1182b04 (patch) | |
tree | 98d5b957f1cd88b70b4965cf7dc16dc7862d0e42 /drivers/scsi/csiostor/csio_rnode.c | |
parent | 68d91cbd5267e15a7c6da1415a1c65a9506aed96 (diff) | |
download | blackbird-op-linux-5036f0a0ecd31fc94360a944b352d082e1182b04.tar.gz blackbird-op-linux-5036f0a0ecd31fc94360a944b352d082e1182b04.zip |
[SCSI] csiostor: Fix sparse warnings.
This patch fixes sparse warnings related to endian-ness, which were
reported by the 0-day kernel build and testing tool.
Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Naresh Kumar Inna <naresh@chelsio.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/csiostor/csio_rnode.c')
-rw-r--r-- | drivers/scsi/csiostor/csio_rnode.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/scsi/csiostor/csio_rnode.c b/drivers/scsi/csiostor/csio_rnode.c index b0ae430e436a..51c6a388de2b 100644 --- a/drivers/scsi/csiostor/csio_rnode.c +++ b/drivers/scsi/csiostor/csio_rnode.c @@ -303,9 +303,9 @@ csio_confirm_rnode(struct csio_lnode *ln, uint32_t rdev_flowid, uint8_t rport_type; struct csio_rnode *rn, *match_rn; uint32_t vnp_flowid; - uint32_t *port_id; + __be32 *port_id; - port_id = (uint32_t *)&rdevp->r_id[0]; + port_id = (__be32 *)&rdevp->r_id[0]; rport_type = FW_RDEV_WR_RPORT_TYPE_GET(rdevp->rd_xfer_rdy_to_rport_type); @@ -439,9 +439,9 @@ csio_rn_verify_rparams(struct csio_lnode *ln, struct csio_rnode *rn, uint8_t null[8]; uint8_t rport_type; uint8_t fc_class; - uint32_t *did; + __be32 *did; - did = (uint32_t *) &rdevp->r_id[0]; + did = (__be32 *) &rdevp->r_id[0]; rport_type = FW_RDEV_WR_RPORT_TYPE_GET(rdevp->rd_xfer_rdy_to_rport_type); switch (rport_type) { @@ -529,9 +529,10 @@ csio_rn_verify_rparams(struct csio_lnode *ln, struct csio_rnode *rn, rn->nport_id = (ntohl(*did) >> 8) & CSIO_DID_MASK; memcpy(csio_rn_wwnn(rn), rdevp->wwnn, 8); memcpy(csio_rn_wwpn(rn), rdevp->wwpn, 8); - rn->rn_sparm.csp.sp_bb_data = ntohs(rdevp->rcv_fr_sz); + rn->rn_sparm.csp.sp_bb_data = rdevp->rcv_fr_sz; fc_class = FW_RDEV_WR_CLASS_GET(rdevp->vft_to_qos); rn->rn_sparm.clsp[fc_class - 1].cp_class = htons(FC_CPC_VALID); + return 0; } |