android_kernel_samsung_sm8650/init
Norihiko Hama bc4d82ee40 ANDROID: KMI workaround for CONFIG_NETFILTER_FAMILY_BRIDGE
Enabling CONFIG_NETFILTER_FAMILY_BRIDGE causes the new element,
hooks_bridge[] to be added to netns_nf. Since the KMI is frozen
this could not be added.

The only instantiation of struct netns_nf is as an embedded field
of struct net. So instead of adding the field to struct netns_nf,
a new "struct ext_net" is added that contains struct net and
the new hooks_bridge[] field. An accessor function,
get_nf_hooks_bridge() is added to get a pointer to the new
field.

There is a global init_net of type struct net which must be special
cased since it is not a member of a struct ext_net. All other
instances of struct net are allocated via net_alloc() which now
allocates a struct ext_net.

Since CONFIG_NETFILTER_FAMILY_BRIDGE is a hidden config that is
needed for vendor modules, it is enabled via init/Kconfig.gki.

Bug: 316040984
Fixes: 0145780bfc78 ("fix KASAN-related kernel crash by KMI W/A for NETFILTER_FAMILY_BRIDGE")

Change-Id: I2c7384e3df9b88f12464dc0138986fed12ca626a
Signed-off-by: Norihiko Hama <Norihiko.Hama@alpsalpine.com>
2024-01-09 23:37:43 +00:00
..
.gitignore kbuild: build init/built-in.a just once 2022-09-29 04:40:15 +09:00
build-version kbuild: build init/built-in.a just once 2022-09-29 04:40:15 +09:00
calibrate.c
do_mounts_initrd.c freezer,umh: Clean up freezer/initrd interaction 2022-09-07 21:53:48 +02:00
do_mounts_rd.c init: add an init_unlink helper 2020-07-31 08:17:52 +02:00
do_mounts.c init: move from strlcpy with unused retval to strscpy 2022-09-11 21:55:10 -07:00
do_mounts.h init: add an init_mknod helper 2020-07-31 08:17:54 +02:00
init_task.c ANDROID: Configure out the macros in android_kabi and android_vendor 2022-10-10 16:46:40 +05:30
initramfs.c initramfs: mark my_inptr as __initdata 2022-09-11 21:55:11 -07:00
Kconfig This is the 6.1.53 stable release 2023-09-18 09:57:37 +00:00
Kconfig.gki ANDROID: KMI workaround for CONFIG_NETFILTER_FAMILY_BRIDGE 2024-01-09 23:37:43 +00:00
main.c Merge 6.1.44 into android14-6.1-lts 2023-09-12 15:09:42 +00:00
Makefile kbuild: generate include/generated/compile.h in top Makefile 2022-09-29 04:40:15 +09:00
noinitramfs.c init: move usermodehelper_enable() to populate_rootfs() 2021-09-08 11:50:27 -07:00
version-timestamp.c kbuild: build init/built-in.a just once 2022-09-29 04:40:15 +09:00
version.c kbuild: build init/built-in.a just once 2022-09-29 04:40:15 +09:00