Thread (7 messages) flat view 7 messages, 2 authors, 2020-01-26

Re: [PATCH bpf-next v2 2/3] bpf: xdp, virtio_net use access ptr macro for xdp enable check

From: Jesper Dangaard Brouer <hidden>
Date: 2020-01-26 21:29:03
Also in: bpf

On Sat, 25 Jan 2020 19:58:52 -0800
John Fastabend [off-list ref] wrote:
virtio_net currently relies on rcu critical section to access the xdp
program in its xdp_xmit handler. However, the pointer to the xdp program
is only used to do a NULL pointer comparison to determine if xdp is
enabled or not.

Use rcu_access_pointer() instead of rcu_dereference() to reflect this.
Then later when we drop rcu_read critical section virtio_net will not
need in special handling.

Signed-off-by: John Fastabend <john.fastabend@gmail.com>
Acked-by: Jesper Dangaard Brouer <redacted>

-- 
Best regards,
  Jesper Dangaard Brouer
  MSc.CS, Principal Kernel Engineer at Red Hat
  LinkedIn: http://www.linkedin.com/in/brouer
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help