]> git.baikalelectronics.ru Git - kernel.git/commit
net: simplify cBPF setsockopt compat handling
authorChristoph Hellwig <hch@lst.de>
Fri, 17 Jul 2020 06:23:13 +0000 (08:23 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 20 Jul 2020 01:16:40 +0000 (18:16 -0700)
commit95ba9a529727117af7ea2ab5406c930b290210f5
tree11f6ced04b1be8c3c59e8d62031c1e4c9f157a36
parent6a4cb53b98ef2840a0ab5c85e826fc5a5e0bd6cb
net: simplify cBPF setsockopt compat handling

Add a helper that copies either a native or compat bpf_fprog from
userspace after verifying the length, and remove the compat setsockopt
handlers that now aren't required.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/filter.h
include/net/compat.h
net/compat.c
net/core/filter.c
net/core/sock.c
net/packet/af_packet.c