Skip to content

Commit

Permalink
qede: qede_fp: simplify a bit 'qede_rx_build_skb()'
Browse files Browse the repository at this point in the history
Use 'skb_put_data()' instead of rewritting it.
This improves readability.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
  • Loading branch information
Christophe JAILLET authored and Jakub Kicinski committed Sep 22, 2019
1 parent b6b6cc9 commit 24ccb0a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/net/ethernet/qlogic/qede/qede_fp.c
Original file line number Diff line number Diff line change
Expand Up @@ -779,8 +779,7 @@ qede_rx_build_skb(struct qede_dev *edev,
return NULL;

skb_reserve(skb, pad);
memcpy(skb_put(skb, len),
page_address(bd->data) + offset, len);
skb_put_data(skb, page_address(bd->data) + offset, len);
qede_reuse_page(rxq, bd);
goto out;
}
Expand Down

0 comments on commit 24ccb0a

Please sign in to comment.