v2022.09.0

2022-09-13 Thread Sascha Hauer
Hi All, I am happy to announce barebox-2022.09.0. This time we have a few new board supports: Support for the 96Boards Meerkat96 board is added as well as support for the Enclustra AA1 (SoCFPGA). Also worth noting is that we now have ROMAPI support for the i.MX8MP and i.MX8MN. This allows us to

[PATCH 2/6] RISC-V: add riscv_vendor_id() support

2022-09-13 Thread Marco Felsch
Add the support to query the vendorid which is stored within the mvendorid register. This register is only accessible from M-Mode so we need to use the sbi interface if we are running from S-Mode. Signed-off-by: Marco Felsch --- arch/riscv/include/asm/system.h | 31 ++

[PATCH 0/6] RISC-V Allwinner D1 Support 2nd Stage Support

2022-09-13 Thread Marco Felsch
Hi, this small series adds the basic support for the Allwinner sun20i D1 Nezsha board. It is very limited only serial is supported right now. Patches 1-4 can be applied independently. Patch 5 may need some more attention since Ahmad told me in person that not all softcores implementing the vendo

[PATCH 6/6] RISC-V: add Allwinner Sun20i D1 Nezha support

2022-09-13 Thread Marco Felsch
Add Allwinner sun20i SoC and D1-Nezha board support. Signed-off-by: Marco Felsch --- Documentation/boards/riscv.rst| 102 + arch/riscv/Kconfig.socs | 16 +++ arch/riscv/boards/Makefile| 1 + arch/riscv/boards/allwinner-d1/Makefile

[PATCH 4/6] RISC-V: use m/sscratch registers for barebox_riscv_pbl_flags

2022-09-13 Thread Marco Felsch
Use the dedicated scratch register for setting the pbl flags. Each mode has it's own scratch register so we are not conflicting with M-mode running firmware e.g. OpenSBI. Using the scratch register has two main advantages: 1st) It can be used in PBL and non-PBL use-case. 2nd) It is not affected b

[PATCH 1/6] RISC-V: cache: fix local_flush_icache_all enabling

2022-09-13 Thread Marco Felsch
Commit fe181ffda9 ("RISC-V: support incoherent I-Cache") added the support to handle non-coherent caches and introduced the HAS_CACHE Kconfig symbol. The symbol must be used with CONFIG_ prefixed since this is the final Kconfig symbol which can be used within the code. Fixes: fe181ffda9 ("RISC-V:

[PATCH 3/6] RISC-V: import vendorid list from linux

2022-09-13 Thread Marco Felsch
Import the vendor id list from upstream linux. Signed-off-by: Marco Felsch --- arch/riscv/include/asm/vendorid_list.h | 11 +++ 1 file changed, 11 insertions(+) create mode 100644 arch/riscv/include/asm/vendorid_list.h diff --git a/arch/riscv/include/asm/vendorid_list.h b/arch/riscv/i

[PATCH 5/6] RISC-V: implement cache-management errata for T-Head SoCs

2022-09-13 Thread Marco Felsch
Since riscv_vendor_id() can be used from pbl and non-pbl context as well as from relocated and non-relocated code, we are able to query the vendor id and add special vendor handlings. This is required since the T-Head C906 and C910 implement a scheme for handling cache operations different from the

Re: [PATCH next] Documentation: filesystems: tftp: fix code blocks

2022-09-13 Thread Sascha Hauer
On Tue, Sep 13, 2022 at 12:54:11PM +0300, Antony Pavlov wrote: > On Tue, 13 Sep 2022 10:08:37 +0200 > Sascha Hauer wrote: > > Hi Sascha! > > > On Mon, Sep 12, 2022 at 11:50:47AM +0300, Antony Pavlov wrote: > > > The patch fixes these sphinx errors: > > > > > > Documentation/filesystems/tftp.r

[PATCH] ubifs: Fix pointer type mismatch in gzip decompressor

2022-09-13 Thread Sascha Hauer
deflate_decompress() takes a unsigned int * for the out_len argument whereas ubifs passes a size_t * argument. Adjust the argument type accordingly. Signed-off-by: Sascha Hauer --- fs/ubifs/ubifs.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/fs/ubifs/ubifs.c b/fs/

Re: [PATCH next] Documentation: filesystems: tftp: fix code blocks

2022-09-13 Thread Antony Pavlov
On Tue, 13 Sep 2022 10:08:37 +0200 Sascha Hauer wrote: Hi Sascha! > On Mon, Sep 12, 2022 at 11:50:47AM +0300, Antony Pavlov wrote: > > The patch fixes these sphinx errors: > > > > Documentation/filesystems/tftp.rst:44: ERROR: Error in "code-block" > > directive: > > maximum 1 argument(s)

[PATCH 1/2] ARM: rdu2: Drop redundant of graph link

2022-09-13 Thread Sascha Hauer
The link is also present in the upstream dtsi file in the same way, so remove it from the barebox overlay. Signed-off-by: Sascha Hauer --- arch/arm/dts/imx6qdl-zii-rdu2.dtsi | 10 -- 1 file changed, 10 deletions(-) diff --git a/arch/arm/dts/imx6qdl-zii-rdu2.dtsi b/arch/arm/dts/imx6qdl-

[PATCH 2/2] ARM: rdu2: fix dtc warning

2022-09-13 Thread Sascha Hauer
This fixes: dts/src/arm/imx6qdl.dtsi:1332.32-1334.7: Warning (graph_endpoint): /soc/ipu@240/port@2/endpoint@0: graph connection to node '/soc/bus@210/i2c@21a/edp-bridge@68/ports/port@1/endpoint' is not bidirectional also defined at dts/src/arm/imx6qdl-zii-rdu2.dtsi:647.17-649.3

TFTP RFC7440 windowsize support

2022-09-13 Thread Sascha Hauer
Hi All, As you might have noticed Enrico added RFC7440 support to our TFTP support. This greatly improves the speed for TFTP transfers when the server also has RFC7440 support. RFC7440 support has just appeared in the latest atftpd release (version 0.8.0), so you can give this a try without local

[PATCH] ARM: imx_v7_defconfig: Limit TFTP window size

2022-09-13 Thread Sascha Hauer
The FEC ethernet controller is too slow to catch up with a gigabit link. This hasn't been a problem until now, because the protocols we use in barebox only have a single packet in flight. With TFTP window size support and a gigabit link though we get receive buffer overruns resulting in messages li

Re: [PATCH] fs: ubifs: remove always-false check

2022-09-13 Thread Ahmad Fatoum
On 13.09.22 10:37, Sascha Hauer wrote: > On Thu, Aug 11, 2022 at 03:58:04PM +0200, Ahmad Fatoum wrote: >> GCC correctly warns that two bit wide compr_type can't >> exceed or be equal to UBIFS_COMPR_TYPES_CNT (== 4). >> >> Remove the check. The check is there in the kernel as well, >> but the warnin

Re: [PATCH master] ARM: sync_caches_for_execution: don't flush disabled data cache

2022-09-13 Thread Sascha Hauer
On Thu, Sep 01, 2022 at 12:41:36PM +0200, Ahmad Fatoum wrote: > We unconditionally clean and then invalidate D-cache entries in > sync_caches_for_execution by calling arm_early_mmu_cache_flush(). > > The function afterwards takes care to invalidate the I-cache. > > This misbehaves though when the

Re: [PATCH] fs: ubifs: remove always-false check

2022-09-13 Thread Sascha Hauer
On Thu, Aug 11, 2022 at 03:58:04PM +0200, Ahmad Fatoum wrote: > GCC correctly warns that two bit wide compr_type can't > exceed or be equal to UBIFS_COMPR_TYPES_CNT (== 4). > > Remove the check. The check is there in the kernel as well, > but the warning is disabled there. > > Signed-off-by: Ahma

Re: [PATCH] of: of_probe: create board's machine device at the earliest

2022-09-13 Thread Sascha Hauer
On Mon, Sep 05, 2022 at 09:02:08AM +0200, Ahmad Fatoum wrote: > We currently create devices for matching reserved memory entries and > firmware before creating the machine device. In a deep probe system, the > machine driver would be probed directly at registration and as such > needs to be probed

Re: [PATCH] soc: imx: gpcv2: make available to all i.MX8M

2022-09-13 Thread Sascha Hauer
On Mon, Sep 05, 2022 at 09:04:06AM +0200, Ahmad Fatoum wrote: > Now that the driver supports i.MX8M Mini, Nano and Plus, we should no > longer restrict it to just i.MX7 and i.MX8MQ. > > Signed-off-by: Ahmad Fatoum > --- > drivers/soc/imx/Kconfig | 4 ++-- > 1 file changed, 2 insertions(+), 2 del

Re: [PATCH] blspec: fix memory leak handling NFS URLs

2022-09-13 Thread Sascha Hauer
On Mon, Sep 05, 2022 at 09:02:47AM +0200, Ahmad Fatoum wrote: > parse_nfs_url() returns either an allocated string on success or an > error pointer otherwise. blspec_bootentry_provider() will early > exit if the path couldn't be resolved and thus not free() the string. > > Fix this memory leak. Wh

Re: [PATCH] test: self: provide selftest_is_running()

2022-09-13 Thread Sascha Hauer
On Mon, Sep 05, 2022 at 09:01:25AM +0200, Ahmad Fatoum wrote: > For debugging during self-test run, it can be useful to enable select > logging only when the selftest is running. Provide a selftest_is_running() > function that can be used to determine whether a test is running. > > Signed-off-by:

Re: [PATCH 0/7] Documentation misc fixes

2022-09-13 Thread Sascha Hauer
On Mon, Sep 12, 2022 at 11:44:23AM +0300, Antony Pavlov wrote: > Antony Pavlov (7): > Documentation: OKUD Max9331: fix sphinx warning > Documentation: Altera SOCFPGA FPGA Manager: fix sphinx error > Documentation: Altera FPGAs in passive-serial mode: fix sphinx issues > Documentation: bareb

Re: [PATCH next] Documentation: filesystems: tftp: fix code blocks

2022-09-13 Thread Sascha Hauer
On Mon, Sep 12, 2022 at 11:50:47AM +0300, Antony Pavlov wrote: > The patch fixes these sphinx errors: > > Documentation/filesystems/tftp.rst:44: ERROR: Error in "code-block" > directive: > maximum 1 argument(s) allowed, 3 supplied. > Documentation/filesystems/tftp.rst:53: ERROR: Error in

Re: [PATCH v2] of: implement of_prepend_property

2022-09-13 Thread Sascha Hauer
On Mon, Sep 12, 2022 at 05:54:36PM +0200, Ahmad Fatoum wrote: > Like of_append_property for adding at the end of properties, implement > of_prepend_property for placing data into the front. > > This is especially useful to fixup most-specific compatibles into > existing nodes. > > Signed-off-by: