<feed xmlns='http://www.w3.org/2005/Atom'>
<title>staging/neocturne/include/kernel.mk, branch main</title>
<subtitle>Staging tree of Nora Schiffer</subtitle>
<id>https://git-03.infra.openwrt.org/openwrt/staging/neocturne/atom?h=main</id>
<link rel='self' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/'/>
<updated>2024-05-04T06:14:16Z</updated>
<entry>
<title>loongarch64: new target</title>
<updated>2024-05-04T06:14:16Z</updated>
<author>
<name>Weijie Gao</name>
</author>
<published>2024-01-06T19:10:45Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=7fcb82665e96a50174084c8bfcd0302ce31291f4'/>
<id>urn:sha1:7fcb82665e96a50174084c8bfcd0302ce31291f4</id>
<content type='text'>
Add target for Loongson LoongArch64-based boards.

LoongArch is a new RISC ISA developed by Loongson. It's a bit like
MIPS or RISC-V. LoongArch includes both 32-bit and 64-bit versions
(LoongArch32/LoongArch64).

Loongson 3A5000 and 3A6000 are the two existing CPUs of LoongArch64
and is used for PC products. It's BIOS supports ACPI and UEFI-only
boot. These CPUs supports SMP and SMT.

At present only LoongArch64 is supported by linux kernel.

Toolchain requirement:
binutils &gt;= 2.40
gcc &gt;= 13.1

For details, please check the following links:
https://lwn.net/Articles/861951/
https://loongson.github.io/LoongArch-Documentation/README-EN.html

Signed-off-by: Weijie Gao &lt;hackpascal@gmail.com&gt;
</content>
</entry>
<entry>
<title>treewide: remove implicit SUBTARGET</title>
<updated>2024-04-08T19:53:05Z</updated>
<author>
<name>Paul Spooren</name>
</author>
<published>2024-04-08T06:05:29Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=d997477775bf5447000f1d300a027878b566f5d1'/>
<id>urn:sha1:d997477775bf5447000f1d300a027878b566f5d1</id>
<content type='text'>
Historically it's possible to leave the `SUBTARGETS` undefined and
automatically fallback to a "generic" subtarget. This however breaks
various downstream scripts which may have expectations around filenames:

While some targets with an explicit generic subtarget contain `generic`
in the filenames of artifacts, implicit "subtargets" don't.

Right now this breaks the CI[1], possibly also scripts using the ImageBuilders.

This commit removes all code that support implicit handling of
subtargets and instead requires every target to define "SUBTARGETS".

[1]: https://github.com/openwrt/openwrt/actions/runs/8592821105/job/23548273630

Signed-off-by: Paul Spooren &lt;mail@aparcar.org&gt;
</content>
</entry>
<entry>
<title>treewide: use APK compatible version schema</title>
<updated>2024-03-22T21:14:22Z</updated>
<author>
<name>Paul Spooren</name>
</author>
<published>2024-03-17T17:43:10Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=e8725a932e16eaf6ec51add8c084d959cbe32ff2'/>
<id>urn:sha1:e8725a932e16eaf6ec51add8c084d959cbe32ff2</id>
<content type='text'>
Different from OPKG, APK uses a deterministic version schema which chips
the version into chunks and compares them individually. This enforces a
certain schema which was previously entirely flexible.

 - Releases are added at the very and end prefixed with an `r` like
`1.2.3-r3`.
- Hashes are prefixed with a `~` like `1.2.3~abc123`.
- Dates become semantic versions, like `2024.04.01`
- Extra tags are possible like `_git`, `_alpha` and more.

For full details see the APK test list:
https://gitlab.alpinelinux.org/alpine/apk-tools/-/blob/master/test/version.data

Signed-off-by: Paul Spooren &lt;mail@aparcar.org&gt;
</content>
</entry>
<entry>
<title>build: cache kernel module package compiling</title>
<updated>2023-10-28T19:34:20Z</updated>
<author>
<name>Zeyu Dong</name>
</author>
<published>2023-09-30T00:54:58Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=52751b12320599b557d8c7779b612102b963595d'/>
<id>urn:sha1:52751b12320599b557d8c7779b612102b963595d</id>
<content type='text'>
Kernel module packages compiling is not cached (e.g. mac80211)
even with CONFIG_CCACHE on.

CC should be set to KERNEL_CC in KERNEL_MAKE_FLAGS at kernel.mk
to allow kernel module packages using ccache.

Signed-off-by: Zeyu Dong &lt;dzy201415@gmail.com&gt;
</content>
</entry>
<entry>
<title>kernel: fix KernelPackage when all KCONFIG are versioned</title>
<updated>2023-07-04T17:29:41Z</updated>
<author>
<name>John Thomson</name>
</author>
<published>2023-07-01T00:23:35Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=b3448b3fdb59d25dce05991dc8f322c1020b090b'/>
<id>urn:sha1:b3448b3fdb59d25dce05991dc8f322c1020b090b</id>
<content type='text'>
If a kernel package was defined where all KCONFIG symbols were dynamic,
and versioned, no FILES would be installed, as the foreach evaluation was
providing the value of the variable defined by the KCONFIG symbol name
including the version test

Fix this by calling the version_filter function on the list of KCONFIG
variable names run through by foreach

Example, kernel 6.1:
KCONFIG:=CONFIG_OLD@lt6.1 CONFIG_NEW@ge6.1
filter-out any KCONFIG settings forced by package:
CONFIG_OLD@lt6.1 CONFIG_NEW@ge6.1
there are dynamic settings, so for each of them,
get the value of the make variable defined by symbol name:
    CONFIG_OLD@lt6.1 is not set
    CONFIG_NEW@ge6.1 is not set
  versus
    CONFIG_OLD is not set
    CONFIG_NEW=m
test if any of these are m, or y
if yes, install files, otherwise, nothing to install

Signed-off-by: John Thomson &lt;git@johnthomson.fastmail.com.au&gt;
</content>
</entry>
<entry>
<title>generic: groundwork for RISC-V</title>
<updated>2023-05-28T11:19:10Z</updated>
<author>
<name>Zoltan HERPAI</name>
</author>
<published>2018-12-16T09:45:53Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=50c05f6cd721130701cbbc77a75d2e090259c4e5'/>
<id>urn:sha1:50c05f6cd721130701cbbc77a75d2e090259c4e5</id>
<content type='text'>
Add build infrastructure for RISC-V.

Signed-off-by: Zoltan HERPAI &lt;wigyori@uid0.hu&gt;
</content>
</entry>
<entry>
<title>kernel: Make KERNEL_MAKEOPTS recursively expanded</title>
<updated>2022-12-17T19:12:31Z</updated>
<author>
<name>Hauke Mehrtens</name>
</author>
<published>2022-12-14T15:29:16Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=06ad3adeecc27859313e60c173c435d45ac2b345'/>
<id>urn:sha1:06ad3adeecc27859313e60c173c435d45ac2b345</id>
<content type='text'>
KERNEL_MAKEOPTS will get expanded when it is used and not when it is
defined in the kernel.mk file now. This fixes problems finding dependent
kernel modules when it is used by a kernel module package.

Without this change the build of packages which depend on other out of
tree modules failed when they used KERNEL_MAKE because some symbols could
not be found. This happened because KERNEL_MAKE_FLAGS which contains a
"if $(__package_mk)" was  evaluated where KERNEL_MAKEOPTS was defined
and not when the KERNEL_MAKE was used. For packages which included
kernel.mk before package.mk we saw this problem. One workaround
was to use the correct include order and the other one was to not
use KERNEL_MAKE_FLAGS, but copy its content.

Signed-off-by: Hauke Mehrtens &lt;hmehrtens@maxlinear.com&gt;
</content>
</entry>
<entry>
<title>kernel: disable stack validation for external module builds as needed</title>
<updated>2022-10-20T07:53:23Z</updated>
<author>
<name>Mark Mentovai</name>
</author>
<published>2022-09-11T17:48:17Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=802bfe080678b3a8a94868b717bd127afcabc5b7'/>
<id>urn:sha1:802bfe080678b3a8a94868b717bd127afcabc5b7</id>
<content type='text'>
c3e31b6a9b04 and 5f8e5872406d disable stack validation when the build
host is not running Linux, as the objtool kernel build tool required for
stack validation is not portable to other build host environments. This
was achieved by setting CONFIG_STACK_VALIDATION= in KERNEL_MAKEOPTS, and
by setting SKIP_STACK_VALIDATION=1 in the environment. KERNEL_MAKEOPTS
only has effect for the kernel build, not for external module builds,
but through kernel 5.14, SKIP_STACK_VALIDATION worked to disable this
feature too, so stack validation was disabled for external module builds
as well. Since kernel 0d989ac2c90b, the kernel build no longer considers
SKIP_STACK_VALIDATION, so the feature will be disabled for the kernel
build, but not for external module builds.

When building OpenWrt on a non-Linux build host targeting x86 (the only
target architecture for which OpenWrt enables the kernel
CONFIG_STACK_VALIDATION) and using kernel 5.15 (such as via
CONFIG_TESTING_KERNEL), this caused a build failure during any external
module build, such as kmod-button-hotplug. This manifested as build
errors such as:

  make[4]: *** No rule to make target
  '.../build_dir/target-x86_64_musl/linux-x86_64/button-hotplug/button-hotplug.o',
  needed by
  '.../build_dir/target-x86_64_musl/linux-x86_64/button-hotplug/button-hotplug.mod'.
  Stop.

Although button-hotplug.c was present, the implicit rule to make
$(obj)/%.o from $(src)/%.c in the kernel's scripts/Makefile.build could
not be satisfied in this case, as it also depends on $(objtool_dep),
non-empty as a result of the failure to propagate disabling of stack
validation to external module builds, in a configuration where it is not
possible to build objtool.

KERNEL_MAKEOPTS is used for just the kernel build itself, while
KERNEL_MAKE_FLAGS is used for both the kernel build and for external
module builds. This restores the ability to build OpenWrt in such
configurations by moving the CONFIG_STACK_VALIDATION= make argument from
KERNEL_MAKEOPTS to KERNEL_MAKE_FLAGS where it is able to affect external
module builds properly.

Note that the kernel's objtool and related configuration have seen a
major overhaul since kernel 5.15, and may need more attention again
after 22922deae13f, in kernel 5.19.

Signed-off-by: Mark Mentovai &lt;mark@mentovai.com&gt;
</content>
</entry>
<entry>
<title>kernel: filter -no-plt from KCFLAGS</title>
<updated>2022-06-21T15:41:17Z</updated>
<author>
<name>Kevin Darbyshire-Bryant</name>
</author>
<published>2022-06-21T13:15:40Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=24e27bec9a6df1511a504cf04cd9578a23e74657'/>
<id>urn:sha1:24e27bec9a6df1511a504cf04cd9578a23e74657</id>
<content type='text'>
Compiler option -no-plt will break kernel builds on some architectures
eg. (x86)  Filter this option from the recently introduced handling of
KCFLAGS vs EXTRA_OPTIMISATION

Fixes: 1d42af720c6b ("kernel: use KCFLAGS for passing EXTRA_OPTIMIZATION flags")

Suggested-by: Felix Fietkau &lt;nbd@nbd.name&gt;

Signed-off-by: Kevin Darbyshire-Bryant &lt;ldir@darbyshire-bryant.me.uk&gt;
</content>
</entry>
<entry>
<title>kernel: support setting extra CFLAGS for kernel compilation</title>
<updated>2022-06-20T20:17:38Z</updated>
<author>
<name>Rafał Miłecki</name>
</author>
<published>2022-06-15T10:36:36Z</published>
<link rel='alternate' type='text/html' href='https://git-03.infra.openwrt.org/openwrt/staging/neocturne/commit/?id=907d7d747243044f86588f0d82993e8c106cb02c'/>
<id>urn:sha1:907d7d747243044f86588f0d82993e8c106cb02c</id>
<content type='text'>
They may be used e.g. to optimize kernel size or performance.

Signed-off-by: Rafał Miłecki &lt;rafal@milecki.pl&gt;
</content>
</entry>
</feed>
