Commit Graph

92 Commits

Author SHA1 Message Date
Jianhui Zhao 43b498f669 kernel: remove non-existent config symbols
The crashlog patch as not ported to kernel 5.4.

Fixes: 4e0c54bc5b ("kernel: add support for kernel 5.4")
Signed-off-by: Jianhui Zhao <zhaojh329@gmail.com>
2021-11-20 18:53:14 +01:00
Stijn Tintel c5fa7ec2a6 kernel: add missing UBSAN config symbols
Enabling KERNEL_UBSAN exposes several missing symbols. Add new kernel
build options for UBSAN_BOUNDS and UBSAN_TRAP, disable CONFIG_TEST_UBSAN
in the generic kernel configs and enable CONFIG_UBSAN_MISC in generic
5.10 config. The latter symbol was removed in later kernels, as it was
causing some issues, so just disable it in 5.10 instead of adding a
build option for it.

Fixes build failures with KERNEL_UBSAN enabled.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
Acked-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-11-07 17:38:01 +02:00
Hauke Mehrtens a1939e7e37 kernel: Add extra configuration options
These options show up when compiling the at91 target.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-10-24 20:22:04 +02:00
Hauke Mehrtens 57b323ce38 kernel: Deactivate some ARM64 errata workarounds
This deactivates the following workarounds for erratas in ARM64 CPUS:
CONFIG_ARM64_ERRATUM_1165522: Cortex-A76 cores (r0p0, r1p0, r2p0)
CONFIG_ARM64_ERRATUM_1286807: Cortex-A76 cores (r0p0 to r3p0)
CONFIG_ARM64_ERRATUM_1418040: Cortex-A76/Neoverse-N1 cores (r0p0 to r3p1)
CONFIG_CAVIUM_TX2_ERRATUM_219: Cavium ThunderX2
CONFIG_FUJITSU_ERRATUM_010001: Fujitsu-A64FX

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-10-03 01:13:18 +02:00
Hauke Mehrtens 1a3b3dc797 kernel: Add missing kernel config options
These options are selectable when some of the kernel debug options like
KERNEL_SOFTLOCKUP_DETECTOR are selected.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-09-13 13:04:21 +02:00
Hauke Mehrtens b9cc16a5e8 kernel: Set CONFIG_RCU_CPU_STALL_TIMEOUT=21
The default value for CONFIG_RCU_CPU_STALL_TIMEOUT was changed from 60
seconds to 21 seconds in 2012 in the upstream kernel. Some targets
already use 21 seconds.

This patch changes the default value in the generic configuration to 21
seconds and removes the target specific configuration options.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Acked-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-09-09 20:24:12 +02:00
Rui Salvaterra 42ee7d8157 kernel: add missing CONFIG_SECURITY_NETWORK_XFRM ksym
Paul noticed a build failure [1] due to this missing symbol. Add it as disabled
to both generic kconfigs.

[1] https://github.com/aparcar/openwrt/runs/3480872706?check_suite_focus=true#step:11:63

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-08-31 22:41:46 -10:00
Rui Salvaterra 505b7a2d08 kernel: move two symbols to the generic kconfigs
CONFIG_RCU_{NEED_SEGCBLIST,STALL_COMMON} are set basically everywhere. Move them
to the generic kconfigs. And resort the generic kconfigs while at it.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-08-29 17:07:19 +02:00
Rui Salvaterra 7e135add24 kernel: disable CONFIG_RCU_EXPERT and friends
Based on the existing documentation [1][2], I dare anyone to demonstrate that
we need to fine-tune these RCU parameters. The (performance) breakage potential
for doing so is immense, so let's just please put down this loaded footgun.

Disable CONFIG_RCU_EXPERT and its dependent symbols. Additionally, remove the
CONFIG_RCU_EXPERT symbol from the target kconfigs which contain it.

[1] https://www.kernel.org/doc/Documentation/RCU/Design/Data-Structures/Data-Structures.html
[2] https://lwn.net/Articles/777214/

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-08-29 17:03:38 +02:00
David Bauer 5c88bf896e generic: add missing config symbol
Signed-off-by: David Bauer <mail@david-bauer.net>
2021-08-11 02:15:22 +02:00
David Bauer 1c9a9f7c7a treewide: add various missing config symbols
Fixes commit 91a52f22a1 ("treewide: backport support for nvmem on non platform devices")

Signed-off-by: David Bauer <mail@david-bauer.net>
2021-08-10 20:22:59 +02:00
David Bauer 191c4ff5e1 generic: add missing ARM64 crypto Kconfig symbols
bcm27xx-bcm2710 builds are stalling when compiled with V=s.

Explitily disable these unset symbols to avoid stalling
builds.

Signed-off-by: David Bauer <mail@david-bauer.net>
2021-07-31 22:14:02 +02:00
David Bauer f038a169a0 generic: add missing Kconfig symbol
Fixes build errors for sunxi as well as rockchip targets.

Signed-off-by: David Bauer <mail@david-bauer.net>
2021-07-31 11:49:02 +02:00
John Audia d15db2fe4d kernel: bump 5.4 to 5.4.134
All patches automatically rebased.

Build system: x86_64
Build-tested: ipq806x/R7800
Run-tested: ipq806x/R7800

Signed-off-by: John Audia <graysky@archlinux.us>
2021-07-25 13:52:38 +02:00
David Bauer 3446baad07 generic: add missing symbol
When compiling with all modules enabled, Kconfig complains about
CONFIG_I2C_DESIGNWARE_SLAVE being unset. Disable this symbol by default.

Fixes commit e9c9b5ec72 ("kernel: package Synopsys Designware PCI to I2C controller")

Signed-off-by: David Bauer <mail@david-bauer.net>
2021-07-17 22:34:12 +02:00
John Audia d8dc9f108a kernel: bump 5.4 to 5.4.126
Manually rebased:
  bcm27xx/patches-5.4/950-0089-cgroup-Disable-cgroup-memory-by-default.patch

All other patches automatically rebased.

Signed-off-by: John Audia <graysky@archlinux.us>
2021-06-26 12:49:15 +02:00
Tomasz Maciej Nowak 0b92b5b04f kernel: move some drm symbols to generic config
These are architecture independent, so move them to generic config.

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
2021-06-13 23:30:10 +02:00
Yangbo Lu 37b5f7c267 kernel: add missing symbol CONFIG_AHCI_XGENE
Add missing symbol CONFIG_AHCI_XGENE.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
[also add for 5.10, remove from layerscape target config]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-05-30 02:21:02 +02:00
Hauke Mehrtens 63d8117d37 kernel: Reorder kernel configuration options
Reorder the options and remove double entries.
This was generated by running this:
$ ./scripts/kconfig.pl '+' target/linux/generic/config-5.10 /dev/null > target/linux/generic/config-5.10.new
$ mv target/linux/generic/config-5.10.new target/linux/generic/config-5.10
$ ./scripts/kconfig.pl '+' target/linux/generic/config-5.4 /dev/null > target/linux/generic/config-5.4.new
$ mv target/linux/generic/config-5.4.new target/linux/generic/config-5.4

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-05-01 22:11:56 +02:00
Rui Salvaterra d7956c5728 netfilter: remove no-op kconfig symbols
These have long been obsolete. For reference, here's the Linux version where
each symbol has been dropped:

CONFIG_IP6_NF_QUEUE - 3.5
CONFIG_IP6_NF_TARGET_LOG - 3.4
CONFIG_IP_NF_MATCH_DSCP - 2.6.19
CONFIG_NF_CONNTRACK_IPV4 - 4.19
CONFIG_NF_CONNTRACK_IPV6 - 4.19
CONFIG_NF_CONNTRACK_RTCACHE - out-of-tree, superseded by flow offloading

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-05-01 00:37:15 +02:00
Chen Minqiang e219b7f38b kernel: add kmod-ipvlan support
This kmod is similar to macvlan with the difference being that the
endpoints have the same mac address.

It is useful on cloud where only one mac address allowed on port,
where macvlan not works but ipvlan would.

One use case is where multiple IPs and gateways assign on one net port

Signed-off-by: Chen Minqiang <ptpt52@gmail.com>
2021-04-30 23:51:23 +02:00
Rui Salvaterra 3326b5e75c treewide: switch the timer frequency to 100 Hz
Some targets select HZ=100, others HZ=250. There's no reason to select a higher
timer frequency (and 100 Hz are available in every architecture), so change all
targets to 100 Hz.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-04-21 10:31:10 +01:00
Rui Salvaterra be7b560278 kernel: enable lzo, zlib and zstd in ubifs
Make sure all compression algorithms are enabled, for the time being, in order
not to break sysupgrade. In the future, we'd like to disable all except zstd, as
it's the best all-around performer.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-04-21 10:31:07 +01:00
David Bauer 4b87fd1dc5 generic: add missing config symbols
Signed-off-by: David Bauer <mail@david-bauer.net>
2021-04-18 14:41:14 +02:00
Hauke Mehrtens ebfc94aee9 kernel: Move CONFIG_USERIO to generic config
The CONFIG_USERIO option is unset in multiple target configurations. On
the sunxi target it is activated. Move the kernel configuration option
to the generic kernel configuration.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-03-27 14:34:22 +01:00
Hauke Mehrtens 7d6553c72e kernel: Deactivate CONFIG_VFIO in generic kernel config
Instead of deactivating this in every target config, deactivate it once
in the generic kernel config. I was asked for this config option in a
x86 64 build in OpenWrt 21.02.

Fixes: 87046e87e2 ("kernel: add missing kernel config symbol")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-03-27 14:34:00 +01:00
Hauke Mehrtens 0c0cb97da7 kernel: Add missing kernel config options
These two options are missing when building the x86 target.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-03-19 18:48:32 +01:00
Hauke Mehrtens 0b5a67aa03 kernel: Reorder kernel configuration options
Reorder the options and remove double entries.
This was generated by running this:
$ ./scripts/kconfig.pl '+' target/linux/generic/config-5.10 /dev/null > target/linux/generic/config-5.10.new
$ mv target/linux/generic/config-5.10.new target/linux/generic/config-5.10
$ ./scripts/kconfig.pl '+' target/linux/generic/config-5.4 /dev/null > target/linux/generic/config-5.4.new
$ mv target/linux/generic/config-5.4.new target/linux/generic/config-5.4

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-03-19 18:38:35 +01:00
Rosen Penev a50441b6e9 kernel: add exfat again
With kernel 5.10, exfat is out of staging and in tree.

Added small hack to make it work with kernel 5.4 as well.

Added removed config options for 5.4 to generic config.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
[Set CONFIG_EXFAT_ config options to default values]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-03-19 16:08:12 +01:00
Tony Ambardar 9662da770e kernel: add missing config symbols, fix typos
Update 5.10 generic config to add missing options prompting during builds,
when setting CONFIG_ALL_KMODS. Refresh the x86 subtargets to drop symbols
added to the generic config.

Also fix a typo in 5.4/5.10 generic configs: "CONFIG_CONFIG_KVM_AMD_SEV".

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
2021-03-19 14:02:47 +00:00
Aleksander Jan Bajkowski 12e942b1fd kernel: move some disabled symbols to generic
Move some disabled symbols found in armvirt target to generic.

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
2021-03-19 00:59:22 +01:00
Ilya Lipnitskiy 89744dc741 kernel: generic: filter out CONFIG_PLUGIN_HOSTCC
It appears to be an automatic Kconfig symbol that varies depending on
the host platform. There is no need to define it in target configs, so
filter it out.

Also sort config-filter entries alphabetically.

Cc: Adrian Schmutzler <mail@adrianschmutzler.de>
Cc: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy@gmail.com>
2021-03-06 03:52:33 +00:00
Ilya Lipnitskiy 23b801d3ba kernel: 5.4: generic: add missing symbols
Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy@gmail.com>
2021-02-26 20:41:01 +01:00
Adrian Schmutzler 8d766aa669 kernel: add further missing symbols
CONFIG_NET_DSA_MV88E6XXX_PTP was simply missing in generic config.

CONFIG_I2C_PXA_SLAVE was previously enabled via i2c-pxa package,
but got removed there without moving the symbol to generic config.

Fixes: dd13add3ce ("kernel: i2c-pxa: remove slave")

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-02-24 02:53:53 +01:00
Daniel Golle e6aac8d98f image: add support for building FIT image with filesystem
Allow for single (external-data) FIT image to hold kernel, dtb and
squashfs. In that way, the bootloader verifies the system integrity
including the rootfs, because what's the point of checking that the
hash of the kernel is correct if it won't boot in case of squashfs
being corrupted? Better allow bootloader to check everything needed
to make it at least up to failsafe mode. As a positive side effect
this change also makes the sysupgrade process on nand potentially
much easier as it is now.
In short: mkimage has a parameter '-E' which allows generating FIT
images with 'external' data rather than embedding the data into the
device-tree blob itself. In this way, the FIT structure itself remains
small and can be parsed easily (rather than having to page around
megabytes of image content). This patch makes use of that and adds
support for adding sub-images of type 'filesystem' which are used to
store the squashfs. Now U-Boot can verify the whole OS and the new
partition parsers added in the Linux kernel can detect the filesystem
sub-images, create partitions for them, and select the active rootfs
volume based on the configuration in FIT (passing configuration via
device tree could be implemented easily at a later stage).

This new FIT partition parser works for NOR flash (on top of mtdblock),
NAND flash (on top of ubiblock) as well as classic block devices
(ie. eMMC, SDcard, SATA, NVME, ...).
It could even be used to mount such FIT images via `losetup -P` on a
user PC if this patch gets included in Linux upstream one day ;)

Signed-off-by: John Crispin <john@phrozen.org>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2021-02-24 01:35:20 +00:00
David Bauer 55ed4bf6d7 generic: add missing symbols
Signed-off-by: David Bauer <mail@david-bauer.net>
2021-02-23 20:13:37 +01:00
Álvaro Fernández Rojas 7405ff5d4b kernel: mtdsplit: add support for BCM63XX CFE firmware
Broadcom CFE bootloader relies on a tag for identifying the current firmware,
such as version, image start address, kernel address and size, rootfs size,
board id, signatures, etc.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2021-02-22 18:09:03 +01:00
Aleksander Jan Bajkowski 777e67301a kernel: sort config
This was done by executing this script:

find . -name "config-*"  > ../configs.txt
for config in $(cat ../configs.txt); do
	./scripts/kconfig.pl '+' $config /dev/null > $config-new
	mv $config-new $config
done
rm ../configs.txt

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
2021-02-21 23:52:26 +01:00
Sungbo Eo 22061b2880 kernel: enable CONFIG_LEDS_TRIGGER_HEARTBEAT
The heartbeat trigger is used by luci-mod-system, which is installed
as a part of the standard luci package set. It seems the LED trigger
will be required quite often, so let's enable it by default.

This increases uncompressed kernel size by about 100 bytes on ath79/generic.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
2021-01-15 18:20:55 +01:00
Etan Kissling 39add246c1 nf-conntrack: allow querying conntrack info in nfqueue
This allows libnetfilter_queue to access connection tracking information
by requesting NFQA_CFG_F_CONNTRACK. Connection tracking information is
provided in the NFQA_CT attribute.
CONFIG_NETFILTER_NETLINK_GLUE_CT enables the interaction between
nf_queue and nf_conntrack_netlink. Without this option, trying to access
connection tracking information results in "Operation not supported".

Signed-off-by: Etan Kissling <etan_kissling@apple.com>
2021-01-14 00:52:49 +00:00
Nick Hainke a1a7f3274e kernel: enable SRv6 support by enabling lwtunnel
Enable the ability to use segment routing based on IPv6. It allows the
packet to specify a path that the packet should take through the
network.

Lwtunnel allow an easy encapsulation of a package. You can just install
ip-full package and use it:

  ip -6 route add  2003::/64 dev eth0 encap seg6 mode encap \
    segs 2001::1,2002::2

An IPv6 package looks like this:
  [IPv6 HDR][IPv6 RH][IPv6 HDR][Data...]

Netifd support:
  https://git.openwrt.org/?p=project/netifd.git;
     a=commit;h=458b1a7e9473c150a40cae5d8be174f4bb03bd39

Increases imagesize by 24.125 KiB. Therefore, only enable for devices
with enough flash.

Signed-off-by: Nick Hainke <vincent@systemli.org>
2021-01-11 11:09:05 -10:00
Sungbo Eo ccf65613da kernel: add disabled PROC_STRIPPED
Otherwise the missing symbol is added to target config for every kernel
config refresh.

While at it, remove the disabled symbol from target configs.

Fixes: 4943bc5cff ("kernel: only strip proc for small flash devices")
Signed-off-by: Sungbo Eo <mans0n@gorani.run>
2020-12-27 19:07:42 +01:00
Nick Hainke 4943bc5cff kernel: only strip proc for small flash devices
Currently, you are not able to get statistics about IPv4 and IPv6
usage. This information can be collected via the snmp and snmp6.
However, in the current state this interface is disabled as you can
read in the "902-debloat_proc.patch":
 "Strip non-essential /proc functionality to reduce code size"

Tools like netstat use the snmp/6 interface to collect interface
statistics. Some prometheus exporters also mention this:
- prometheus-collectors/netstat.lua
- prometheus-collectors/snmp6 (still a PR)
- collectd/snmp6 (still a PR)

PRs:
- https://github.com/collectd/collectd/pull/3789
- https://github.com/openwrt/packages/pull/14158

Instead of enabling it as default for all devices we condition it
 default y if SMALL_FLASH

A test shows it needs around 16 kiB.

Signed-off-by: Nick Hainke <vincent@systemli.org>
[fixed whitespace issue]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-12-22 19:11:50 +01:00
Aleksander Jan Bajkowski 77575d4c02 kernel: move some disabled symbols to generic
Move some disabled config options found in lantiq target to generic.

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
2020-12-22 19:11:50 +01:00
Rosen Penev bc3edae488 target/linux: disable CONFIG_CIFS_STATS
CIFS_STATS is a debugging option. It is not really useful for end users

Signed-off-by: Rosen Penev <rosenp@gmail.com>
[fixed missing config-4.19 file]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-12-22 18:59:10 +01:00
DENG Qingfang 03d178727a kernel: remove mvsw61xx swconfig driver
All targets that used mvsw61xx have switched to upstream mv88e6xxx DSA
driver, so it can be removed.

Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn>
2020-11-16 13:55:05 +01:00
Adrian Schmutzler 54fad3f32b kernel: add disabled CONFIG_IP6_NF_TARGET_MASQUERADE
In kernel commit adf82accc5f5 ("netfilter: x_tables: merge ip and
ipv6 masquerade modules") the config symbols IP_NF_TARGET_MASQUERADE
and IP6_NF_TARGET_MASQUERADE have been demoted to simple backwards-
compat options for NETFILTER_XT_TARGET_MASQUERADE.

In netfilter.mk, this has already been updated in OpenWrt commit
d1592306cc ("netfilter.mk: use CONFIG_NETFILTER_XT_TARGET_MASQUERADE"),
having us use the new config symbol.

However, enabling IP_NF_NAT or IP6_NF_NAT still makes the relevant
legacy options selectable, so we need to disable them in generic
config (and forget about them afterwards).
Since CONFIG_IP_NF_TARGET_MASQUERADE is already present there, this
just adds the missing CONFIG_IP6_NF_TARGET_MASQUERADE.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-11-02 18:14:20 +01:00
Adrian Schmutzler 89a2a6c870 kernel: drop obsolete symbol CONFIG_NF_NAT_IPV6
Kernel has removed the symbols CONFIG_NF_NAT_IPV4 and
CONFIG_NF_NAT_IPV6 in favor of CONFIG_NF_NAT in commit
3bf195ae6037 ("netfilter: nat: merge nf_nat_ipv4,6 into nat core").

This drops the obsolete symbol CONFIG_NF_NAT_IPV6 from generic
config-5.4.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-11-02 17:27:05 +01:00
Yousong Zhou 4c21415350 generic: 5.4: make nf nat masquerade in unset state by default
Upstream linux 5.1 commit d1aca8ab ("netfilter: nat: merge ipv4 and ipv6
masquerade functionality") replaces the following 2 options

 - CONFIG_NF_NAT_MASQUERADE_IPV4
 - CONFIG_NF_NAT_MASQUERADE_IPV6

with CONFIG_NF_NAT_MASQUERADE.  The new option is one without prompt and
will be selected by CONFIG_NETFILTER_XT_TARGET_MASQUERADE introduced
still later in 5.2.

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2020-10-24 22:28:37 +08:00
Rui Salvaterra e788e9bd87 treewide: enable the vDSO
The vDSO is used to accelerate some syscalls. It should work fine wherever it's
available, so enable it globally for all targets.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2020-10-13 20:08:41 +02:00