Skip to content

Commit 826d821

Browse files
jbeulichdavem330
authored andcommitted
xen-netback: use local var in xenvif_tx_check_gop() instead of re-calculating
shinfo already holds the result of skb_shinfo(skb) at this point - no need to re-invoke the construct even twice. Signed-off-by: Jan Beulich <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 73f476a commit 826d821

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/net/xen-netback/netback.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -557,8 +557,8 @@ static int xenvif_tx_check_gop(struct xenvif_queue *queue,
557557
}
558558

559559
if (skb_has_frag_list(skb) && !first_shinfo) {
560-
first_shinfo = skb_shinfo(skb);
561-
shinfo = skb_shinfo(skb_shinfo(skb)->frag_list);
560+
first_shinfo = shinfo;
561+
shinfo = skb_shinfo(shinfo->frag_list);
562562
nr_frags = shinfo->nr_frags;
563563

564564
goto check_frags;

0 commit comments

Comments
 (0)