File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -708,7 +708,8 @@ static int veth_convert_skb_to_xdp_buff(struct veth_rq *rq,
708708 u32 frame_sz ;
709709
710710 if (skb_shared (skb ) || skb_head_is_locked (skb ) ||
711- skb_shinfo (skb )-> nr_frags ) {
711+ skb_shinfo (skb )-> nr_frags ||
712+ skb_headroom (skb ) < XDP_PACKET_HEADROOM ) {
712713 u32 size , len , max_head_size , off ;
713714 struct sk_buff * nskb ;
714715 struct page * page ;
@@ -773,9 +774,6 @@ static int veth_convert_skb_to_xdp_buff(struct veth_rq *rq,
773774
774775 consume_skb (skb );
775776 skb = nskb ;
776- } else if (skb_headroom (skb ) < XDP_PACKET_HEADROOM &&
777- pskb_expand_head (skb , VETH_XDP_HEADROOM , 0 , GFP_ATOMIC )) {
778- goto drop ;
779777 }
780778
781779 /* SKB "head" area always have tailroom for skb_shared_info */
You can’t perform that action at this time.
0 commit comments