OpenCloudOS-Kernel/include
Andrey Ignatov 13193b0f39 bpf: Define cgroup_bpf_enabled for CONFIG_CGROUP_BPF=n
Static key is used to enable/disable cgroup-bpf related code paths at
run time.

Though it's not defined when cgroup-bpf is disabled at compile time,
i.e. CONFIG_CGROUP_BPF=n, and if some code wants to use it, it has to do
this:

	#ifdef CONFIG_CGROUP_BPF
		if (cgroup_bpf_enabled) {
			/* ... some work ... */
		}
	#endif

This code can be simplified by setting cgroup_bpf_enabled to 0 for
CONFIG_CGROUP_BPF=n case:

	if (cgroup_bpf_enabled) {
		/* ... some work ... */
	}

And it aligns well with existing BPF_CGROUP_RUN_PROG_* macros that
defined for both states of CONFIG_CGROUP_BPF.

Signed-off-by: Andrey Ignatov <rdna@fb.com>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
2018-05-28 17:41:01 +02:00
..
acpi xen: fixes for 4.17-rc1 2018-04-12 11:04:35 -07:00
asm-generic earlycon: Use a pointer table to fix __earlycon_table stride 2018-04-23 10:06:59 +02:00
clocksource ARM: SoC platform updates for 4.17 2018-04-05 21:21:08 -07:00
crypto crypto: api - Remove unused crypto_type lookup function 2018-03-31 01:32:57 +08:00
drm drm: Fix HDCP downstream dev count read 2018-04-16 12:10:48 -04:00
dt-bindings Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2018-05-11 20:53:22 -04:00
keys
kvm KVM: arm/arm64: vgic: Fix source vcpu issues for GICv2 SGI 2018-04-27 12:39:09 +01:00
linux bpf: Define cgroup_bpf_enabled for CONFIG_CGROUP_BPF=n 2018-05-28 17:41:01 +02:00
math-emu
media MAINTAINERS & files: Canonize the e-mails I use at files 2018-05-04 06:21:06 -04:00
memory
misc
net Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2018-05-26 19:46:15 -04:00
pcmcia
ras
rdma IB/uverbs: Fix uverbs_attr_get_obj 2018-05-23 15:25:53 -06:00
scsi scsi: core: remove reference to scsi_show_extd_sense() 2018-04-18 23:37:39 -04:00
soc soc: bcm2835: Make !RASPBERRYPI_FIRMWARE dummies return failure 2018-04-16 15:15:23 -07:00
sound ALSA: control: Hardening for potential Spectre v1 2018-04-25 10:37:46 +02:00
target
trace net/ipv4: Remove tracepoint in fib_validate_source 2018-05-24 23:01:15 -04:00
uapi Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2018-05-26 19:46:15 -04:00
video
xen xen/sndif: Sync up with the canonical definition in Xen 2018-04-17 08:26:33 -04:00