aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/fcoe
diff options
context:
space:
mode:
authorIan Campbell <Ian.Campbell@citrix.com>2011-08-24 18:28:15 -0400
committerDavid S. Miller <davem@davemloft.net>2011-08-26 12:38:43 -0400
commit165c68d5a291537eaf2d3821a19335c9ec100ba6 (patch)
tree4ea485969cad853819e7034398898ce0b0bff9eb /drivers/scsi/fcoe
parent94b06fdbfce46f3126810e30698bdf010617179b (diff)
fcoe: convert to SKB paged frag API.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Cc: Robert Love <robert.w.love@intel.com> Cc: "James E.J. Bottomley" <JBottomley@parallels.com> Cc: devel@open-fcoe.org Cc: linux-scsi@vger.kernel.org Cc: netdev@vger.kernel.org Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/scsi/fcoe')
-rw-r--r--drivers/scsi/fcoe/fcoe.c2
-rw-r--r--drivers/scsi/fcoe/fcoe_transport.c5
2 files changed, 4 insertions, 3 deletions
diff --git a/drivers/scsi/fcoe/fcoe.c b/drivers/scsi/fcoe/fcoe.c
index ba710e350ac5..3416ab673814 100644
--- a/drivers/scsi/fcoe/fcoe.c
+++ b/drivers/scsi/fcoe/fcoe.c
@@ -1514,7 +1514,7 @@ int fcoe_xmit(struct fc_lport *lport, struct fc_frame *fp)
1514 return -ENOMEM; 1514 return -ENOMEM;
1515 } 1515 }
1516 frag = &skb_shinfo(skb)->frags[skb_shinfo(skb)->nr_frags - 1]; 1516 frag = &skb_shinfo(skb)->frags[skb_shinfo(skb)->nr_frags - 1];
1517 cp = kmap_atomic(frag->page, KM_SKB_DATA_SOFTIRQ) 1517 cp = kmap_atomic(skb_frag_page(frag), KM_SKB_DATA_SOFTIRQ)
1518 + frag->page_offset; 1518 + frag->page_offset;
1519 } else { 1519 } else {
1520 cp = (struct fcoe_crc_eof *)skb_put(skb, tlen); 1520 cp = (struct fcoe_crc_eof *)skb_put(skb, tlen);
diff --git a/drivers/scsi/fcoe/fcoe_transport.c b/drivers/scsi/fcoe/fcoe_transport.c
index 41068e8748e7..f6613f9f1bdb 100644
--- a/drivers/scsi/fcoe/fcoe_transport.c
+++ b/drivers/scsi/fcoe/fcoe_transport.c
@@ -108,8 +108,9 @@ u32 fcoe_fc_crc(struct fc_frame *fp)
108 len = frag->size; 108 len = frag->size;
109 while (len > 0) { 109 while (len > 0) {
110 clen = min(len, PAGE_SIZE - (off & ~PAGE_MASK)); 110 clen = min(len, PAGE_SIZE - (off & ~PAGE_MASK));
111 data = kmap_atomic(frag->page + (off >> PAGE_SHIFT), 111 data = kmap_atomic(
112 KM_SKB_DATA_SOFTIRQ); 112 skb_frag_page(frag) + (off >> PAGE_SHIFT),
113 KM_SKB_DATA_SOFTIRQ);
113 crc = crc32(crc, data + (off & ~PAGE_MASK), clen); 114 crc = crc32(crc, data + (off & ~PAGE_MASK), clen);
114 kunmap_atomic(data, KM_SKB_DATA_SOFTIRQ); 115 kunmap_atomic(data, KM_SKB_DATA_SOFTIRQ);
115 off += clen; 116 off += clen;