linux-stable/arch/xtensa
Michal Sekletar ea02f9411d net: introduce SO_BPF_EXTENSIONS
For user space packet capturing libraries such as libpcap, there's
currently only one way to check which BPF extensions are supported
by the kernel, that is, commit aa1113d9f8 ("net: filter: return
-EINVAL if BPF_S_ANC* operation is not supported"). For querying all
extensions at once this might be rather inconvenient.

Therefore, this patch introduces a new option which can be used as
an argument for getsockopt(), and allows one to obtain information
about which BPF extensions are supported by the current kernel.

As David Miller suggests, we do not need to define any bits right
now and status quo can just return 0 in order to state that this
versions supports SKF_AD_PROTOCOL up to SKF_AD_PAY_OFFSET. Later
additions to BPF extensions need to add their bits to the
bpf_tell_extensions() function, as documented in the comment.

Signed-off-by: Michal Sekletar <msekleta@redhat.com>
Cc: David Miller <davem@davemloft.net>
Reviewed-by: Daniel Borkmann <dborkman@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2014-01-18 19:08:58 -08:00
..
boot xtensa: don't use echo -e needlessly 2013-09-06 09:48:29 -07:00
configs Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
include net: introduce SO_BPF_EXTENSIONS 2014-01-18 19:08:58 -08:00
kernel DeviceTree updates for 3.13. This is a bit larger pull request than 2013-11-12 16:52:17 +09:00
lib xtensa: clean up files to make them code-style compliant 2012-12-18 21:10:25 -08:00
mm xtensa: use buddy allocator for PTE table 2013-11-15 09:32:19 +09:00
oprofile xtensa: fix oprofile building as module 2013-05-09 01:07:09 -07:00
platforms xtensa: Cocci spatch "noderef" 2013-10-16 11:48:31 -07:00
variants xtensa: consolidate ccount access routines 2013-07-08 01:11:37 -07:00
Kconfig Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
Kconfig.debug xtensa: check TLB sanity on return to userspace 2013-07-08 01:18:56 -07:00
Makefile xtensa: don't use echo -e needlessly 2013-09-06 09:48:29 -07:00