virtio_net: small: avoid code duplication in xdp scenarios
authorXuan Zhuo <xuanzhuo@linux.alibaba.com>
Mon, 8 May 2023 06:14:14 +0000 (14:14 +0800)
committerJakub Kicinski <kuba@kernel.org>
Wed, 10 May 2023 02:44:27 +0000 (19:44 -0700)
commit7af70fc169bd254aea780115b0f355956f84902b
tree76d56c1d69b29c8b41f3ad1f9581f38372584285
parentfc8ce84b09bcc7306f3128f783967ecbfa617207
virtio_net: small: avoid code duplication in xdp scenarios

Avoid the problem that some variables(headroom and so on) will repeat
the calculation when process xdp.

Signed-off-by: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/virtio_net.c