kernel_samsung_a53x/Documentation
Patrick Rohr f7ec824ac0 net: change accept_ra_min_rtr_lft to affect all RA lifetimes
commit 5027d54a9c30bc7ec808360378e2b4753f053f25 upstream.

accept_ra_min_rtr_lft only considered the lifetime of the default route
and discarded entire RAs accordingly.

This change renames accept_ra_min_rtr_lft to accept_ra_min_lft, and
applies the value to individual RA sections; in particular, router
lifetime, PIO preferred lifetime, and RIO lifetime. If any of those
lifetimes are lower than the configured value, the specific RA section
is ignored.

In order for the sysctl to be useful to Android, it should really apply
to all lifetimes in the RA, since that is what determines the minimum
frequency at which RAs must be processed by the kernel. Android uses
hardware offloads to drop RAs for a fraction of the minimum of all
lifetimes present in the RA (some networks have very frequent RAs (5s)
with high lifetimes (2h)). Despite this, we have encountered networks
that set the router lifetime to 30s which results in very frequent CPU
wakeups. Instead of disabling IPv6 (and dropping IPv6 ethertype in the
WiFi firmware) entirely on such networks, it seems better to ignore the
misconfigured routers while still processing RAs from other IPv6 routers
on the same network (i.e. to support IoT applications).

The previous implementation dropped the entire RA based on router
lifetime. This turned out to be hard to expand to the other lifetimes
present in the RA in a consistent manner; dropping the entire RA based
on RIO/PIO lifetimes would essentially require parsing the whole thing
twice.

Fixes: 1671bcfd76fd ("net: add sysctl accept_ra_min_rtr_lft")
Cc: Lorenzo Colitti <lorenzo@google.com>
Signed-off-by: Patrick Rohr <prohr@google.com>
Reviewed-by: Maciej Żenczykowski <maze@google.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Link: https://lore.kernel.org/r/20230726230701.919212-1-prohr@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-11-08 11:25:47 +01:00
..
ABI Backport mac80211 patches from linux-6.1.y 2024-06-15 16:29:20 -03:00
accounting Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
admin-guide Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
arm Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
arm64 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
block Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bpf Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cdrom Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
core-api Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cpu-freq Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
crypto Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dev-tools Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
device-mapper Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
devicetree Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
doc-guide Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
driver-api Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fault-injection Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fb Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
features Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
filesystems Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
firmware-guide Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
firmware_class Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fpga Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
gpu Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
hid Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
hwmon Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
i2c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ia64 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ide Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
iio Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
infiniband Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
input Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
isdn Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
kbuild Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
kernel-hacking Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
leds Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
litmus-tests Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
livepatch Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
locking Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
m68k Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
maintainer Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
mhi Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
mips Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
misc-devices Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
netlabel Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
networking net: change accept_ra_min_rtr_lft to affect all RA lifetimes 2024-11-08 11:25:47 +01:00
nios2 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
nvdimm Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
openrisc Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
parisc Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
PCI Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pcmcia Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
power Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
powerpc Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
process Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
RCU Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
riscv Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
s390 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
scheduler Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
scsi Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
security Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sh Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sound Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sparc Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sphinx Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sphinx-static Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
spi Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
staging Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
target Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
timers Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
trace Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
translations Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
usb Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
userspace-api Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
virt Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
vm Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
w1 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
watchdog Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
x86 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
xtensa Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
asm-annotations.rst Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
atomic_bitops.txt Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
atomic_t.txt Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Changes Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
CodingStyle Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
conf.py Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
COPYING-logo Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
docutils.conf Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dontdiff Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
index.rst Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
logo.gif Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
memory-barriers.txt Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
SubmittingPatches Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
watch_queue.rst Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00