[Open-FCoE] [PATCH] libfc: use already defined fc_txrdy instead of fc_data_desc

Yi Zou yi.zou at intel.com
Thu Sep 18 19:22:46 UTC 2008


These two structs are the same thing. keep fc_txrdy as it is called
FCP_XFER_RDY IU in FCP.

Signed-off-by: Yi Zou <yi.zou at intel.com>
---

 drivers/scsi/libfc/fc_fcp.c |    6 +++---
 include/scsi/fc/fc_fs.h     |   12 ------------
 2 files changed, 3 insertions(+), 15 deletions(-)

diff --git a/drivers/scsi/libfc/fc_fcp.c b/drivers/scsi/libfc/fc_fcp.c
index 0c8fc30..604a91d 100644
--- a/drivers/scsi/libfc/fc_fcp.c
+++ b/drivers/scsi/libfc/fc_fcp.c
@@ -681,7 +681,7 @@ static void fc_fcp_recv(struct fc_seq *sp, struct fc_frame *fp, void *arg)
 	struct fc_fcp_pkt *fsp = (struct fc_fcp_pkt *)arg;
 	struct fc_lport *lp;
 	struct fc_frame_header *fh;
-	struct fc_data_desc *dd;
+	struct fcp_txrdy *dd;
 	u8 r_ctl;
 	int rc = 0;
 
@@ -716,8 +716,8 @@ static void fc_fcp_recv(struct fc_seq *sp, struct fc_frame *fp, void *arg)
 		WARN_ON(!dd);
 
 		rc = fc_fcp_send_data(fsp, sp,
-				      (size_t) ntohl(dd->dd_offset),
-				      (size_t) ntohl(dd->dd_len), fp,
+				      (size_t) ntohl(dd->ft_data_ro),
+				      (size_t) ntohl(dd->ft_burst_len), fp,
 				      lp->capabilities & TRANS_C_SG);
 		if (!rc)
 			lp->tt.seq_set_rec_data(sp, fsp->xfer_len);
diff --git a/include/scsi/fc/fc_fs.h b/include/scsi/fc/fc_fs.h
index ba6df64..3897c6c 100644
--- a/include/scsi/fc/fc_fs.h
+++ b/include/scsi/fc/fc_fs.h
@@ -329,16 +329,4 @@ enum fc_pf_rjt_reason {
 	FC_RJT_VENDOR =		0xff,	/* vendor specific reject */
 };
 
-/*
- * Data descriptor format (R_CTL == FC_RCTL_DD_DATA_DESC).
- * This is used for FCP SCSI transfer ready.
- */
-struct fc_data_desc {
-	__be32		dd_offset;	/* data relative offset in bytes */
-	__be32		dd_len;		/* transfer buffer size in bytes */
-	__u8		_dd_resvd[4];
-};
-
-#define FC_DATA_DESC_LEN    12	/* expected length of structure */
-
 #endif /* _FC_FS_H_ */




More information about the devel mailing list