[PATCH 38/75] niu: convert to SKB paged frag API.

Ian Campbell ian.campbell at citrix.com
Fri Aug 19 23:27:10 EST 2011


Signed-off-by: Ian Campbell <ian.campbell at citrix.com>
Cc: Grant Likely <grant.likely at secretlab.ca>
Cc: "David S. Miller" <davem at davemloft.net>
Cc: Ben Hutchings <bhutchings at solarflare.com>
Cc: Stephen Hemminger <shemminger at vyatta.com>
Cc: Eric Dumazet <eric.dumazet at gmail.com>
Cc: "Michał Mirosław" <mirq-linux at rere.qmqm.pl>
Cc: netdev at vger.kernel.org
Cc: linux-kernel at vger.kernel.org
Cc: devicetree-discuss at lists.ozlabs.org
---
 drivers/net/niu.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/niu.c b/drivers/net/niu.c
index ed47585..0191712 100644
--- a/drivers/net/niu.c
+++ b/drivers/net/niu.c
@@ -3291,7 +3291,7 @@ static void niu_rx_skb_append(struct sk_buff *skb, struct page *page,
 	int i = skb_shinfo(skb)->nr_frags;
 	skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
 
-	frag->page = page;
+	__skb_frag_set_page(frag, page);
 	frag->page_offset = offset;
 	frag->size = size;
 
@@ -6736,7 +6736,7 @@ static netdev_tx_t niu_start_xmit(struct sk_buff *skb,
 		skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
 
 		len = frag->size;
-		mapping = np->ops->map_page(np->device, frag->page,
+		mapping = np->ops->map_page(np->device, skb_frag_page(frag),
 					    frag->page_offset, len,
 					    DMA_TO_DEVICE);
 
-- 
1.7.2.5



More information about the devicetree-discuss mailing list