Commit Graph

377 Commits

Author SHA1 Message Date
Tianling Shen
c47fe16af0
kernel: disable BTF for sifiveu and 32bit x86 by default
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-06-27 16:01:37 +08:00
Tianling Shen
b0063446b8
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-06-17 14:19:10 +08:00
Robert Marko
f02f6aaa8d
ipq807x: rename target to qualcommax
Currently, ipq807x only covers Qualcomm IPQ807x SoC-s.
However, Qualcomm also has IPQ60xx and IPQ50xx SoC-s under the AX WiSoC-s
and they share a lot of stuff with IPQ807x, especially IPQ60xx so to avoid
duplicating kernel patches and everything lets make a common target with
per SoC subtargets.

Start doing that by renaming ipq807x to qualcommax so that dependencies
on ipq807x target can be updated.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2023-06-16 11:11:08 +02:00
Tianling Shen
3810066f16
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-06-15 00:50:02 +08:00
Tianling Shen
6f053d268e
Config-images: build qcow2 image for armsr target
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-06-13 03:04:53 +08:00
Tianling Shen
9f0e1eb555
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-06-11 13:16:13 +08:00
Mathew McBride
40ce6a7920
config: change references from armvirt to armsr
armvirt target has been renamed to armsr (Arm SystemReady),
so the config defaults need to be changed as well.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2023-06-10 21:30:20 +02:00
Tianling Shen
3495f95618
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-06-06 23:19:38 +08:00
Tianling Shen
95d86d92c9
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-06-02 19:52:24 +08:00
Mathew McBride
f899e0e024
build: enable vmdk/vmware images for arm64 target
This is useful for VMware's ARM64 products, e.g Fusion for M1/ARM Macs.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2023-06-02 11:36:19 +02:00
Mathew McBride
71e56b2ff1
build: use 128MiB as the boot/kernel partition size on armvirt target
The nominal partition type for EFI boot partitions is FAT32,
which has a minimum size of 32MiB on a 512-byte-sector block device.

To ensure that the boot partition is created as FAT32 set a size
well above this minimum.

A useful discussion about EFI partition sizes can be found here:
https://superuser.com/questions/1310927/what-is-the-absolute-minimum-size-a-uefi-system-partition-can-be

I have found 128MiB works pretty consistently across both
tools (mkfs.fat) and firmwares (EDKII)

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2023-06-02 11:36:18 +02:00
Mathew McBride
8f29b1573d
grub2: enable EFI for armvirt
This adds a separate package for EFI on Arm SystemReady
compatible machines. 32-bit Arm UEFI is supported as well.

It is very similar to x86-64 EFI setup, without the
need for BIOS backward compatibility and slightly
different default modules.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2023-06-02 11:36:12 +02:00
Hauke Mehrtens
16a20512d8
kernel: Set CONFIG_FRAME_WARN depending on target
This set the CONFIG_FRAME_WARN option depending on some target settings.
It will use the default from the upstream kernel and not the hard coded
value of 1024 now.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2023-06-02 11:19:32 +02:00
Tianling Shen
90719e02f0 kernel: add option for BPF_STREAM_PARSER and XDP_SOCKETS_DIAG
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-05-23 15:44:27 +08:00
Tianling Shen
c07038da27 kernel: add MODULE_ALLOW_BTF_MISMATCH option
BTF mismatch can occur for a separately-built module even when the ABI
is otherwise compatible and nothing else would prevent successfully
loading. Add a new config to control how mismatches are handled. By
default, preserve the current behavior of refusing to load the
module. If MODULE_ALLOW_BTF_MISMATCH is enabled, load the module but
ignore its BTF information.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-05-18 16:17:52 +02:00
Tianling Shen
73e56799fe
kernel: allow loading modules with non-matching BTF type info by default
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-05-16 12:39:58 +08:00
Tianling Shen
85d11b468b
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-05-12 19:20:08 +08:00
Nick Hainke
047361dee4
treewide: cleanup kernel symbol references
We only use 5.15 kernel. So remove all those unnecessary symbols
referencing 5.10 or 5.15 kernel.

Can be found with:
  git grep -E 'LINUX_5_1(0|5)'

Note that we remove the dependency from "sound-soc-chipdip-dac" instead
of removing the complete kernel package. The 5.15 version bump forgot to
delete the "@LINUX_5_10" dependency. The kernel package is still needed
in 5.15 kernel.

Signed-off-by: Nick Hainke <vincent@systemli.org>
2023-05-12 13:02:44 +02:00
Tianling Shen
963553fef9
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-05-05 19:43:20 +08:00
Tony Ambardar
3d66f55161 kernel: improve handling of CONFIG_IO_URING
Kernel setting CONFIG_IO_URING supports high-performance I/O for file
access and servers, generally for more performant platforms, and adds
~45 KB to kernel sizes. The need for this on less "beefy" devices is
questionable, as is the size cost considering many platforms have kernel
size limits which require tricky repartitioning if outgrown. The size
cost is also large relative to the ~180 KB bump expected between major
OpenWRT kernel releases.

No OpenWrt packages have hard dependencies on this; samba4 and mariadb
can take advantage if available (+KERNEL_IO_URING:liburing) but
otherwise build and work fine.

Since CONFIG_IO_URING is already managed via the KERNEL_IO_URING setting
in Config-kernel.in (default Y), remove it from those target configs
which unconditionally enable it, and update the defaults to enable it
conditionally only on more powerful 64-bit x86 and arm devices. It may
still be manually enabled as needed for high-performance custom builds.

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
2023-05-03 10:26:17 -07:00
Tianling Shen
4cde61350f
Config-images: adjust default rootfs size
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-05-02 21:37:31 +08:00
Tianling Shen
62b1521045
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-28 15:51:22 +08:00
Tianling Shen
7ee0b160bd
kernel: refine BTF targets
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-27 22:10:24 +08:00
Tianling Shen
dc582c8c3d
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-24 00:26:44 +08:00
Andre Heider
9ea7019ffd
build: add a config knob to enable LTO for all packages
This enables LTO for all packages which haven't opted-out.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-03-21 18:28:24 +01:00
Andre Heider
aef8bab9d7
build: add a config knob to enable gc-sections for all packages
This enables the linker's garbage collection for all packages which haven't
opted-out.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-03-21 18:28:23 +01:00
Tianling Shen
0b394ff960
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-21 23:04:47 +08:00
Tianling Shen
a3bf13ded1
kernel: enable KERNEL_BPF_EVENTS by default
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-21 16:16:22 +08:00
Hauke Mehrtens
b844716158 kernel: Add CONFIG_KERNEL_HARDLOCKUP_DETECTOR
Make it possible to change the kernel configuration option
CONFIG_HARDLOCKUP_DETECTOR from OpenWrt.

Signed-off-by: Hauke Mehrtens <hmehrtens@maxlinear.com>
2023-03-19 18:44:46 +01:00
Tianling Shen
dcc8c8beaf
kernel: disable BTF for arm/mt7622 by default
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-15 13:22:04 +08:00
Tianling Shen
19c154ecba
kernel: enable BTF support for ARM/x86 devices by default
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-14 16:58:06 +08:00
Tianling Shen
8df50f3b41
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-07 11:18:41 +08:00
Stijn Tintel
4448b27930 kernel: set default for KERNEL_BPF_KPROBE_OVERRIDE
Without the default value this still causes a missing symbol. Disable by
default as it depends on FUNCTION_ERROR_INJECTION, which is disabled in
the generic config and we don't have a build symbol to enable that.

Fixes: 500c37c56f ("kernel: add missing symbol")
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2023-03-05 18:36:01 +02:00
Tianling Shen
db5e542439
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-03-02 21:40:40 +08:00
Prasun Maiti
522a60cd31 build: fix for sourcing targets image config installed via feeds
Sourcing of image/Config.in will not happen
When a target is installed from target/linux/feeds/

Signed-off-by: Prasun Maiti <prasunmaiti87@gmail.com>
Acked-by: Petr Štetiar <ynezz@true.cz>
2023-02-26 22:22:48 +01:00
Tianling Shen
d956b863aa
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-02-10 00:47:41 +08:00
Robert Marko
721206a1b1 kernel: set default values for ARM low level debugging symbols
Set default values for KERNEL_DEBUG_LL and KERNEL_DEBUG_LL_UART_NONE again
as both of these symbols are non visible if KERNEL_EARLY_PRINTK is not
selected and KConfig wont write their value to .config.

This usually is the intended behaviour, but in OpenWrt we are relying on
the KConfig to set these and disable the debug console settings that
multiple targets like mvebu have set in their kernel config.
This was the behaviour before removing all of the "default n" settings
as KConfig by default considers symbols disabled but they are not visible
anymore and thus their value is not set in .config and build system then
later does not override the values from target kernel config.

So, to restore the behaviour to the previous one lets a default value for
KERNEL_DEBUG_LL and KERNEL_DEBUG_LL_UART_NONE.

Fixes: 8bc72ea7be ("treewide: strip useless default n Kconfig lines")
Tested-by: Georgi Valkov <gvalkov@gmail.com>
Signed-off-by: Robert Marko <robimarko@gmail.com>
2023-02-08 16:21:05 +01:00
Tianling Shen
4580230440
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-02-06 03:37:49 +08:00
Tony Butler
8bc72ea7be treewide: strip useless default n Kconfig lines
Kconfig docs say:
> The default value deliberately defaults to 'n' in order to avoid
> bloating the build.

Apply this rule everywhere, to avoid more cloning of bad examples

Signed-off-by: Tony Butler <spudz76@gmail.com>
2023-02-03 12:50:15 +01:00
Tianling Shen
63675e8ce5
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-01-29 22:15:46 +08:00
Felix Fietkau
d02d455678 kernel: make it possible for packages to select page pool support
Will be used by the next mt76 update

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2023-01-29 10:08:21 +01:00
Tianling Shen
771411ebc4
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2023-01-17 18:34:04 +08:00
Tony Butler
4a444e576f build: fix incomplete initramfs compression options
Requires: tools/lz4, tools/lzop

complete the wiring so that these options work:
* `CONFIG_KERNEL_INITRAMFS_COMPRESSION_LZO`
* `CONFIG_KERNEL_INITRAMFS_COMPRESSION_LZ4`

Signed-off-by: Tony Butler <spudz76@gmail.com>
[remove blocking dependencies for separate ramdisk, fix lzop options]
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2023-01-17 00:16:35 +00:00
Robert Marko
b5f32064ed ipq807x: add Qualcomm Atheros IPQ807x target
Qualcomm Atheros IPQ807x is a modern WiSoC featuring:
* Quad Core ARMv8 Cortex A-53
	* @ 2.2 GHz (IPQ8072A/4A/6A/8A) Codename Hawkeye
	* @ 1.4 GHz (IPQ8070A/1A) Codename Acorn
* Dual Band simultaneaous IEEE 802.11ax
	* 5G: 8x8/80 or 4x4/160MHz (IPQ8074A/8A)
	* 5G: 4x4/80 or 2x2/160MHz (IPQ8071A/2A/6A)
	* 5G: 2x2/80MHz (IPQ8070A)
	* 2G: 4x4/40MHz (IPQ8072A/4A/6A/8A)
	* 2G: 2x2/40MHz (IPQ8070A/1A)
* 1x PSGMII via QCA8072/5 (Max 5x 1GbE ports)
* 2x SGMII/USXGMII (1/2.5/5/10 GbE) on Hawkeye
* 2x SGMII/USXGMII (1/2.5/5 GbE) on Acorn
* DDR3L/4 32/16 bit up to 2400MT/s
* SDIO 3.0/SD card 3.0/eMMC 5.1
* Dual USB 3.0
* One PCIe Gen2.1 and one PCIe Gen3.0 port (Single lane)
* Parallel NAND (ONFI)/LCD
* 6x QUP BLSP SPI/I2C/UART
* I2S, PCM, and TDMA
* HW PWM
* 1.8V configurable GPIO
* Companion PMP8074 PMIC via SPMI (GPIOS, RTC etc)

Note that only v2 SOC models aka the ones ending with A suffix are
supported, v1 models do not comply to the final 802.11ax and have
lower clocks, lack the Gen3 PCIe etc.

SoC itself has two UBI32 cores for the NSS offloading system, however
currently no offloading is supported.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2023-01-16 12:42:23 +01:00
Tianling Shen
1a6e5870e3
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2022-12-08 01:35:38 +08:00
Tony Butler
6cee46def0 build: images: squashfs: add help, fix description
add help text for `TARGET_SQUASHFS_BLOCK_SIZE` to match the only valid
settings accepted by `mksquashfs4` ("block size not power of two or not
between 4096 and 1Mbyte") thus for this setting in "KB", the set:
  `4, 8, 16, 32, 64, 128, 256, 512, 1024`

replace `squashfs-lzma` with `squashfs` in the description for
`TARGET_ROOTFS_SQUASHFS` because it has various compressions, and not
just lzma as it did in the past

cosmetic change with no functional effect

Signed-off-by: Tony Butler <spudz76@gmail.com>
2022-12-06 23:12:14 +01:00
Tianling Shen
758fe33877
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2022-12-06 02:58:58 +08:00
Tony Butler
7e83cdf3f7 build: config: cleanup impossible dependency logic
some config `depends on` lines contained outdated kernel version checks
that can no longer happen and had become non-operational; clean them up

cosmetic change with no functional effect

Signed-off-by: Tony Butler <spudz76@gmail.com>
2022-12-03 20:45:55 +01:00
Christian Marangi
901366ad66
Revert "build: fix for sourcing target image config a when target is being replaced"
This reverts commit ce1346a8fc.

Seems to cause buildbot compilation to fail and require more testing.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2022-11-09 22:28:53 +01:00
Prasun Maiti
ce1346a8fc build: fix for sourcing target image config a when target is being replaced
Sourcing of image/Config.in will not happen
When a target is installed from target/linux/feeds/

Signed-off-by: Prasun Maiti <prasunmaiti87@gmail.com>
2022-11-09 20:47:43 +01:00