summaryrefslogtreecommitdiff
path: root/Makefile
Commit message (Collapse)AuthorAgeFilesLines
* Release v2023.04.0v2023.04.0Sascha Hauer2023-04-181-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Kbuild: export CROSS_PKG_CONFIGAhmad Fatoum2023-04-111-1/+1
| | | | | | | | | | | | | | | | | | CROSS_PKG_CONFIG is referenced in both Kconfig and Makefiles. To be visibile everywhere, its default needs to be exported, but it wasn't. This wasn't noticed, because usual usage was: CROSS_PKG_CONFIG=some-pkg-config make scripts where the shell took care to export the variable. On NixOS, cross pkg-config is actually called ${CROSS_COMPILE}pkg-config and it didn't work out of the box. Fix this. Fixes: 1c1198a3f252 ("scripts: allow building USB loader tools for target as well") Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20230411071436.1630752-12-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'next'Sascha Hauer2023-03-171-2/+2
|\
| * ARM: drop unused am35xx code in MakefileSascha Hauer2023-03-031-1/+1
| | | | | | | | | | | | | | | | All users of AM335x SPI images are multi-image, so the SPI image generation code in arch/arm/Makefile is unused. Drop it. Link: https://lore.barebox.org/20230302111606.1054037-10-s.hauer@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: drop unused mvebu code in MakefileSascha Hauer2023-03-031-1/+1
| | | | | | | | | | | | | | | | All mvebu boards are multi-image, so they don't need image generation in arch/arm/Makefile anymore. Drop it. Link: https://lore.barebox.org/20230302111606.1054037-9-s.hauer@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * ARM: drop unused zynq code in MakefileSascha Hauer2023-03-031-1/+1
| | | | | | | | | | | | | | | | The Zynq board in tree is converted to multi-image, thus doesn't need image generation in arch/arm/Makefile anymore. Drop it. Link: https://lore.barebox.org/20230302111606.1054037-8-s.hauer@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Release v2023.03.0v2023.03.0Sascha Hauer2023-03-171-1/+1
|/ | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2023.02.0v2023.02.0Sascha Hauer2023-02-231-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2023.01.0v2023.01.0Sascha Hauer2023-01-201-2/+2
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.12.0v2022.12.0Sascha Hauer2022-12-091-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/misc'Sascha Hauer2022-11-141-2/+8
|\
| * Kbuild: link with -z noexecstack and --no-warn-rwx-segmentsSascha Hauer2022-11-081-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Users of GNU ld (BFD) from binutils 2.39+ will observe multiple instances of a new warning when linking barebox and PBL in the form: ld: warning: defaultenv/defaultenv-2-dfu.bbenv.o: missing .note.GNU-stack section implies executable stack ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker ld: warning: .tmp_barebox1 has a LOAD segment with RWX permissions We don't need executable stack, so disable with -z noexecstack. We also do not use the permissions from ELF segments, so disable the warning with --no-warn-rwx-segments. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * Kbuild: create LDFLAGS_commonSascha Hauer2022-11-081-2/+4
| | | | | | | | | | | | | | | | The same linker flags are passed to both LDFLAGS_barebox and LDFLAGS_pbl. Instead of duplicating it create a LDFLAGS_common variable for these common flags. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/arm64-entry'Sascha Hauer2022-11-141-2/+1
|\ \
| * | ARM64: asm: rewrite ENTRY_FUNCTION(_WITHSTACK) fully in assemblyAhmad Fatoum2022-10-261-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recent episode with pointer authentication showed again that for platforms without __attribute__((naked)), we are better off writing the early header in assembly. We still want to keep the board specific entry points in C for ease of use, so we have ENTRY_FUNCTION_WITHSTACK generate two symbols: - A 32-bit stack top value that's placed in .rodata - An entry point with the normal C code, including stack-using prologues The new common assembly head code will access the stack pointer in a position-independent manner and set it up, before continuing with the C code. The barebox header is part of the common assembly head code ensuring it's not moved around due to compiler code generation. The common code will need access to board-specific entry point and stack top. The former is readily available as the alias __pbl_board_entry. The latter is a bit more complicated, as the symbol may not exist for boards not using the common header in a multi-image build. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20221024065716.1215046-6-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | Release v2022.11.0v2022.11.0Sascha Hauer2022-11-101-1/+1
|/ / | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Kbuild: disable ARM64 pointer authenticationAhmad Fatoum2022-10-241-0/+5
|/ | | | | | | | | | | | | | | | | | | | The aarch64 cross-compiler built with Yocto's kirkstone release configures -mbranch-protection=standard as default. The resulting PACIASP/AUTIASP instructions are interpreted as NOPs by existing CPUs, but they increase image size and misalign the barebox header in ENTRY_FUNCTION(). Also on ARMv8.3+, where they serve a purpose, we wouldn't benefit from them as we don't setup any pointer authentication keys. Thus disable it. The misaligned barebox header caused is_barebox_arm_head to fail, breaking all code that verified barebox' header, like i.MX8MM imx-usb-loader barebox-side support and barebox_update for some ARM64 SoCs without a SoC-specific header. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20221019135322.2283270-1-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.10.0v2022.10.0Sascha Hauer2022-10-131-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.09.0v2022.09.0Sascha Hauer2022-09-131-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.08.0v2022.08.0Sascha Hauer2022-08-101-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.06.0v2022.06.0Sascha Hauer2022-06-271-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.05.0v2022.05.0Sascha Hauer2022-05-181-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.04.0v2022.04.0Sascha Hauer2022-04-211-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2022.03.0v2022.03.0Sascha Hauer2022-03-141-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/misc'Sascha Hauer2022-02-181-1/+4
|\
| * Kbuild: add bareboxversion target to MakefileFrank Wunderlich2022-02-071-1/+4
| | | | | | | | | | | | | | | | | | This allows getting version string with make bareboxversion like for linux and uboot. Signed-off-by: Frank Wunderlich <frank-w@public-files.de> Link: https://lore.barebox.org/20220206150716.32531-1-linux@fw-web.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/dts'Sascha Hauer2022-02-181-1/+2
|\ \
| * | build: Include dts/include/ after include/Sascha Hauer2022-01-281-1/+2
| |/ | | | | | | | | | | | | | | | | | | | | | | dts/include/ contains Kernel upstream dt-binding include files. includes are searched for in this directory before our own include directories are used. This becomes a problem when we have files existing in the barebox include directory which then appear in dts/include/ due to a dts update. Make sure that we still use the barebox files in this case so that we can later drop the barebox custom file explicitly along with the fixes that might be needed to use the upstream file. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Release v2022.02.0v2022.02.0Sascha Hauer2022-02-181-1/+1
|/ | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/riscv'Sascha Hauer2022-01-191-0/+5
|\
| * RISC-V: add stacktrace support via frame pointer walkingAhmad Fatoum2022-01-121-0/+5
| | | | | | | | | | | | | | | | | | Make debugging more convenient by implementing stack_dump() and changing exception handlers to print stack trace along with the register dump. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220108171524.587144-8-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Release v2022.01.0v2022.01.0Sascha Hauer2022-01-181-2/+2
|/ | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/efi'Sascha Hauer2021-12-151-1/+1
|\
| * kbuild: force 16-bit wchar_t treewideAhmad Fatoum2021-11-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | -fshort-wchar ensures L"" expands to code units of 16-bit each. We already enforce this on x86, but as a small step towards ARM and RISC-V EFI support in barebox, enable it globally. We already treat wchar_t as 16-bit everywhere where it's used (It's typedef'ed in <linux/nls.h> and <linux/stddef.h>. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20211122084732.2597109-16-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Release v2021.12.0v2021.12.0Sascha Hauer2021-12-151-1/+1
|/ | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2021.11.0v2021.11.0Sascha Hauer2021-11-151-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/targettools'Sascha Hauer2021-10-071-1/+8
|\
| * scripts: allow building USB loader tools for target as wellAhmad Fatoum2021-10-021-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We currently build the USB loader tools only for the host (build) system, but it can be useful to cross compile them as well for the target. We already have some target tools, but support for those is easier, because they don't link against libraries. We use pkg-config to get cc and ld flags, but we always assume that pkg-config is for the host system and there is no well-defined way to request pkg-config for the target system. Support this by introducing a new CROSS_PKG_CONFIG. This will be consulted only for target tools and default to $(CROSS_COMPILE)pkgconfig. Users can override it as necessary, for example, with Yocto, pkg-config will be for the cross environment, so target tools can now be built with: export ARCH=sandbox CROSS_COMPILE=aarch64-linux-gnu- export CROSS_PKG_CONFIG=pkg-config scripts make targettools_defconfig make scripts Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20210917174127.23345-4-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Release v2021.10.0v2021.10.0Sascha Hauer2021-10-071-1/+1
|/ | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Release v2021.08.0v2021.08.0Sascha Hauer2021-08-231-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/nvmem'Sascha Hauer2021-07-181-1/+1
|\
| * sandbox: ship sample environmentAhmad Fatoum2021-07-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The idea of the stickypage was to have a 4K memory region persistent over resets. This region was implemented as mmap of a temporary hostfile, which was created on first barebox start and maintained over resets. Usability was a bit lacking however: - The temporary files weren't deleted - state always showed warnings and errors on first boot. The banner telling users to ignore this wasn't best user experience - In the same vein, the power driver had logic to handle a fresh (zeroed) stickypage and interpret that as POR boot We can avoid all that, by just shipping a default stickypage and referencing that from DT. Do that. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20210629063730.7001-1-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Release v2021.07.0v2021.07.0Sascha Hauer2021-07-181-1/+1
|/ | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/testing'Sascha Hauer2021-06-161-1/+27
|\
| * test: add basic barebox self-test infrastructureAhmad Fatoum2021-06-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Self tests is code written to run within barebox to exercise functionality. They offer flexibility to test specific units of barebox instead of the program as a whole. Add a very simple infrastructure for registering and executing self-tests. This is based on the Linux kselftest modules. We don't utilize modules for this, however, because we only have module support on ARM, but we need a generic solution. Selftests can be enabled individually and even tested without shell support to allow tests to happen for size-restricted barebox images as well. Acked-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20210604084704.17410-8-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * kbuild: add ARCH=um alias for sandboxAhmad Fatoum2021-06-091-0/+4
| | | | | | | | | | | | | | | | | | | | ARCH=um (User Mode) is the Linux kernel counterpart to our sandbox architecture. Add um as an alias, so we can interoperate with tools that handle ARCH=um specially. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20210604084704.17410-4-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * kbuild: add ARCH={i386, x86_64} as aliases for x86Ahmad Fatoum2021-06-091-0/+8
| | | | | | | | | | | | | | | | | | Linux already does this. Follow suit so we can interoperate with tools that assume Linux-like Kbuild structure. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20210604084704.17410-3-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * kbuild: add install targetAhmad Fatoum2021-06-091-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | For CI, it would be useful to have the barebox build install the artifacts into a directory. Add an install target that does this. Example usage: make install INSTALL_PATH=install/ Unlike Linux, we don't set INSTALL_PATH to a default value, because most barebox-enabled boards don't have barebox in a file system. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20210604084704.17410-2-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/kconfig'Sascha Hauer2021-06-161-6/+7
|\ \
| * | kconfig: update to Linux 5.13-rc1Masahiro Yamada2021-05-311-6/+7
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous sync was Linux 5.9-rc2. Resync scripts/kconfig/ with Linux 5.13-rc1. Highlights: - make header names in include/config/ and CONFIG symbols match (scripts/basic/fixdep.c was adjusted) - remove all 'option' syntax (common/Kconfig was adjusted) - introduce KCONFIG_DEFCONFIG_LIST instead of 'option defconfig_list' - bug fixes and cleanups of nconfig - drop Qt4 support from xconfig - bug fixes, improvements, cleanups of xconfig - print a short log for syncconfig Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Link: https://lore.barebox.org/20210530145842.2610109-2-masahiroy@kernel.org Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>