Re: [PATCH] firmware: Kconfig: unify whitespace used for indentation

2023-01-12 Thread Sascha Hauer
On Thu, Jan 12, 2023 at 01:55:28PM +0100, Ahmad Fatoum wrote: > File has a mixture of tabs, spaces and even both in the same line. > Use tabs throughout. > > Signed-off-by: Ahmad Fatoum > --- > firmware/Kconfig | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) Applied, thanks

Re: [PATCH 09/15] lib: provide stub Linux "generic" allocator API

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 06:40:17PM +0100, Ahmad Fatoum wrote: > We may want to port the whole of the Linux generic allocator > implementation in future as it would come in handy in drivers that need > special memory for DMA. For now, support just the use case of the > incoming Atmel NAND driver, wh

Re: [PATCH 00/15] mtd: nand: atmel: import Linux NAND controller driver

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 06:40:08PM +0100, Ahmad Fatoum wrote: > For a few years, Linux has been using the new EBI bindings for NAND > controllers on all AT91 SoCs newer than the AT91RM2000. We have so far > only supported the old bindings by hacking the DT, but this doesn't > suffice for the SAMA5D

Re: [PATCH 1/2] mci: atmel_mci: fix off-by-1000 in poll timeout

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 06:39:20PM +0100, Ahmad Fatoum wrote: > read_poll_timeout assumes microsecond timeouts, not nanoseconds. One > second instead of a thousand is still plenty time when polling for a > MCI controller to change state, so use that. > > Fixes: 4fc0369b1a55 ("mci: atmel_mci: add P

Re: [PATCH v2] mtd: consult CONFIG_OFDEVICE in mtd_get_of_node

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 06:35:48PM +0100, Ahmad Fatoum wrote: > Get barebox on non-DT platforms with NAND a tiny bit smaller by > directly returning NULL if CONFIG_OFDEVICE is not enabled, thereby > allowing more code to be discarded at compile-time in absence of > link-time optimization. > > Sign

Re: [PATCH v3 1/2] ARM: at91: sama5d4: enable for DT use

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 06:22:18PM +0100, Ahmad Fatoum wrote: > The sama5d4[devices].c files are for non-OF instantiation of platform > devices. We don't need anything out of these two files, so don't build > them when compiling for CONFIG_AT91_MULTI_BOARDS. We use that instead of > CONFIG_OFDEVICE

Re: [PATCH v2 1/2] ARM: i.MX8M: bootrom-cmd: clean up pointer casting

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 04:28:36PM +0100, Ahmad Fatoum wrote: > At first glance: > > const u32 *rom_log_addr; > kstrtoul(optarg, 0, (ulong *)&rom_log_addr) with > > looks like it would conflate u32/ulong. While the code is fine, > it is better to just use the correct types and forego

Re: [PATCH v2 00/11] net: dsa: ksz9477: use regmap to add I2C support next to SPI

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 02:29:45PM +0100, Ahmad Fatoum wrote: > The Linux DSA driver supports both I2C and SPI as management interface > by using regmaps as abstraction. barebox regmaps were not quite that > powerful yet, so we rework our regmaps to support optional formatting > and then use that t

Re: [PATCH v4] ARM: i.MX8M: separate function call for clock_init

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 12:37:29PM +0100, Johannes Schneider wrote: > Add a separate function call for imx8mp_early_clock_init, to avoid > confusion with imx8mm. > > Signed-off-by: Johannes Schneider > --- > arch/arm/boards/nxp-imx8mp-evk/lowlevel.c | 2 +- > arch/arm/boards/tqma8mpxl/low

Re: [PATCH v4] ARM: i.MX8M: smccc: allow SIP_BUILDINFO call on all imx8m variants

2023-01-12 Thread Sascha Hauer
On Thu, Jan 12, 2023 at 01:57:27PM +, SCHNEIDER Johannes wrote: > Hoi, > > reasoning is that the common config switch limits the codeblock to > imx8m boards only... or at least was, since on second thought: this is > inside imx8m.c... so the previous version with current_el might be > better?

Re: [PATCH] driver: drop no longer used RW_SIZE/_MASK macros

2023-01-12 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 01:00:02PM +0100, Ahmad Fatoum wrote: > O_RWSIZE_MASK is what's now used and it's passed as argument to open. > There remain no users of either RW_SIZE or RW_SIZE_MASK. Remove to avoid > confusion. > > Signed-off-by: Ahmad Fatoum > --- > include/driver.h | 3 --- > 1 file

[PATCH] ARM: dts: remove duplicate reserved-memory nodes

2023-01-12 Thread Sascha Hauer
reseved-memory nodes are duplicated in some dts file, remove the duplicates. Signed-off-by: Sascha Hauer --- arch/arm/dts/imx6qdl-prti6q-emmc.dtsi | 11 --- arch/arm/dts/imx6ul-prti6g.dts| 11 --- arch/arm/dts/imx6ull-jozacp.dts | 11 --- 3 files changed

Re: [PATCH v1 1/8] ARM: imx6sx: udoo-neo: port to driver model

2023-01-16 Thread Sascha Hauer
On Fri, Jan 13, 2023 at 12:34:00PM +0100, Oleksij Rempel wrote: > Port board code to the driver model > > Signed-off-by: Oleksij Rempel > --- > arch/arm/boards/udoo-neo/board.c | 18 +- > 1 file changed, 13 insertions(+), 5 deletions(-) Applied, thanks Sascha > > diff --git a

Re: [PATCH] ddr_spd: use unsigned type for crc bytes in DDR3/4 SPD check

2023-01-16 Thread Sascha Hauer
On Fri, Jan 13, 2023 at 05:06:48PM +0300, Denis Orlov wrote: > Using signed char type for computed CRC bytes leads to them being sign > extended on comparison with unsigned char values from SPD EEPROM struct. > This happens as when being compared those values undergo integer > promotion that conver

Re: [PATCH] net: e1000: read EEPROM through EERD register on 8257x adapters

2023-01-16 Thread Sascha Hauer
On Fri, Jan 13, 2023 at 05:09:09PM +0300, Denis Orlov wrote: > For some reason, we would only use EERD if Flash is used as non-volatile > memory. However, looking at e1000e driver sources from Linux this is how > they are reading NVM on those cards for both EEPROM and Flash. > > This fixes issues

Re: [PATCH] of: implement of_device_enable_by_alias

2023-01-16 Thread Sascha Hauer
On Mon, Jan 16, 2023 at 02:35:00PM +0100, Ahmad Fatoum wrote: > For symmetry with of_device_disable, which already has direct, path and > by alias variants, implement the missing of_device_enable_by alias as > well. > > Signed-off-by: Ahmad Fatoum > --- > drivers/of/base.c | 15 +++ >

Re: [PATCH] state: backend: direct: open backend in read-only mode if possible

2023-01-16 Thread Sascha Hauer
On Mon, Jan 16, 2023 at 01:54:43PM +0100, Ahmad Fatoum wrote: > We unconditionally open the device backing a direct bucket in read-write > mode. We already populate struct state_backend_storage::readonly though, > which we could consult at device open time. Do so. This could possibly > be done for

Re: [PATCH 1/3] of: platform: call struct device::detect in of_device_create_on_demand

2023-01-19 Thread Sascha Hauer
On Mon, Jan 16, 2023 at 02:36:37PM +0100, Ahmad Fatoum wrote: > Most devices featuring a detect callback use it to probe an underlying > bus. However, of_device_create_on_demand so far created devices on the > platform bus, ignoring that it might be e.g. an I2C device that's > supposed to be crated

Re: [PATCH] net: eth: skip opening disabled interfaces when going interactive

2023-01-19 Thread Sascha Hauer
On Tue, Jan 17, 2023 at 10:49:34AM +0100, Ahmad Fatoum wrote: > Ethernet device global mode (ethX.mode) may be set to disabled when > ports should not be used. This setting is already respect in ifup, so do > likewise for eth_open_all(), which is called when going interactive. > > Signed-off-by: A

v2023.01.0

2023-01-20 Thread Sascha Hauer
D check net: e1000: read EEPROM through EERD register on 8257x adapters Johannes Zink (1): mfd: axp20x: support AXP313A PMIC Marcin Niestroj (1): ARM: rpi: parse memory from vc fdt Sascha Hauer (26): mtd: nand: nand-mxs: Move register definitions to separate file ARM

Re: [PATCH 0/9] net: dsa: add Realtek (rtl8365mb/rtl8366rb) switch support

2023-01-23 Thread Sascha Hauer
On Mon, Jan 16, 2023 at 02:44:52PM +0100, Ahmad Fatoum wrote: > This imports the Linux v6.1 state of the driver into barebox. This has > been tested with the RTL8365MB in (bitbanged) SMI mode connected > to an i.MX8MM FEC. > > Ahmad Fatoum (9): > driver: alias of_match_ptr and DRV_OF_COMPAT >

Re: [RFT PATCH] ARM: stm32mp: odyssey-som: use upstream device trees

2023-01-23 Thread Sascha Hauer
On Mon, Jan 16, 2023 at 02:29:11PM +0100, Ahmad Fatoum wrote: > When board support was first added, it used a version of the device tree > of the Linux kernel mailing list. The device tree is now upstream, so > replace the copy we have with the version already existing in dts/. > > Signed-off-by:

[PATCH 3/3] arm: rockchip_v8_defconfig: Disable PIO mode for MCI_DW

2023-01-23 Thread Sascha Hauer
MCI_DW in PIO mode doesn't work for me. We should search for the reason, but in the end we want to do DMA anyway, which works here. Disable PIO mode for now. Signed-off-by: Sascha Hauer --- arch/arm/configs/rockchip_v8_defconfig | 1 - 1 file changed, 1 deletion(-) diff --git a/arc

[PATCH 2/3] arm: rockchip: oldconfig rockchip_v8_defconfig

2023-01-23 Thread Sascha Hauer
Just an oldconfig to make changing the defconfig easier in the next step. Signed-off-by: Sascha Hauer --- arch/arm/configs/rockchip_v8_defconfig | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/arch/arm/configs/rockchip_v8_defconfig b/arch/arm/configs

[PATCH 1/3] Documentation: Rockchip: Update documentation to latest binaries

2023-01-23 Thread Sascha Hauer
Upstream rkbin repository has been updated, update the paths in the documentation accordingly. Signed-off-by: Sascha Hauer --- Documentation/boards/rockchip.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Documentation/boards/rockchip.rst b/Documentation/boards

Re: [PATCH] spi: Fix probing SPI drivers without a cs-gpios node

2023-01-23 Thread Sascha Hauer
On Sun, Jan 22, 2023 at 09:09:38PM +0300, Alexander Shiyan wrote: > I dont know. I said how would I do it if it was my patch. I hope > Sasсha will decide how it will be better. I would also prefer a dedicated function that just returns 0 if there are no CS GPIOs found. Sascha -- Pengutronix e.K

Re: [PATCH 1/5] ARM: novena: Add Kosagi Novena board

2023-01-23 Thread Sascha Hauer
On Mon, Jan 23, 2023 at 04:51:37AM +1100, John Watts wrote: > The Kosagi Novena is an open source laptop released in 2014. > > This patch adds the initial project skeleton for running the PBL > and debugging over the UART2 port (labeled DEBUG on the board.) > > Signed-off-by: John Watts > --- >

Re: [PATCH 4/5] ARM: novena: Read Ethernet MAC address from EEPROM

2023-01-23 Thread Sascha Hauer
On Mon, Jan 23, 2023 at 04:51:40AM +1100, John Watts wrote: > The Novena has an EEPROM used for storing information about the board, > including the Ethernet MAC address. > > The reference for the EEPROM fields is the novena-eeprom source code. > > Signed-off-by: John Watts > --- > arch/arm/boa

Re: [PATCH 3/3] arm: rockchip_v8_defconfig: Disable PIO mode for MCI_DW

2023-01-23 Thread Sascha Hauer
On Mon, Jan 23, 2023 at 10:17:11AM +0100, Ahmad Fatoum wrote: > On 23.01.23 09:35, Sascha Hauer wrote: > > MCI_DW in PIO mode doesn't work for me. We should search for the > > reason, but in the end we want to do DMA anyway, which works here. > > Disable PIO mode for now.

Re: [PATCH 0/7] Support generating DIMM parameters on more systems

2023-01-24 Thread Sascha Hauer
On Sun, Jan 22, 2023 at 01:44:22AM +1100, John Watts wrote: > Boards that with swappable RAM sticks need to read SPD data and generate > useful parameters for the board's memory controller. > > Currently the only board that does this is the ls1046ardb. > This patch series modifies and re-organizes

[PATCH 2/2] i2c: Make i2c_recover_bus() to return -EBUSY if bus recovery unimplemented

2023-01-24 Thread Sascha Hauer
r_bus() to return -EBUSY instead. Signed-off-by: Sascha Hauer --- drivers/i2c/i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/i2c/i2c.c b/drivers/i2c/i2c.c index 7e1cea49f3..f3efb62087 100644 --- a/drivers/i2c/i2c.c +++ b/drivers/i2c/i2c.c @@ -353,7 +353,7 @

[PATCH 1/2] i2c: i.MX: Use better error code when bus recovery failed

2023-01-24 Thread Sascha Hauer
Signed-off-by: Sascha Hauer --- drivers/i2c/busses/i2c-imx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c index e4b04327ee..3be3b158c7 100644 --- a/drivers/i2c/busses/i2c-imx.c +++ b/drivers/i2c/busses/i2c-imx.c

Re: [PATCH v3 1/2] ARM: i.MX8MM: split barebox dts into dtsi file

2023-01-25 Thread Sascha Hauer
On Thu, Jan 19, 2023 at 04:56:01PM +0100, Marco Felsch wrote: > Move the dts file into a dtsi file. This is in preparation for the > imx8mm-evkb support which will reuse the config. No functional change. > > Signed-off-by: Marco Felsch > --- > v3: > - new in this series > > arch/arm/dts/imx8mm-

Re: [PATCH 4/5] ARM: novena: Read Ethernet MAC address from EEPROM

2023-01-25 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 05:35:53AM +1100, John Watts wrote: > On Mon, Jan 23, 2023 at 10:33:05AM +0100, Sascha Hauer wrote: > > And here is the point where you have to request that the EEPROM is > > actually availabe to support the deep probe mechanism. Before reading > > the

[PATCH] gpio: Fix unused variable warning

2023-01-25 Thread Sascha Hauer
gpio_suffixes is only used inside #ifdef CONFIG_OFDEVICE, so put it into this ifdef as well. Fixes: 9fb2fa240d58 ("gpiolib: implement dev_gpiod_get_index") Signed-off-by: Sascha Hauer --- drivers/gpio/gpiolib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dr

Re: [PATCH 4/5] ARM: novena: Read Ethernet MAC address from EEPROM

2023-01-25 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 07:11:36PM +1100, John Watts wrote: > On Wed, Jan 25, 2023 at 09:04:06AM +0100, Sascha Hauer wrote: > > It looks like something is not initialized correctly yet. Normally > > the usual suspects are pinctrl, clocks or regulators. Each of them > > sho

Re: [PATCH master 1/2] net: dsa: realtek: support enabling only one of the drivers

2023-01-25 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 08:53:53AM +0100, Ahmad Fatoum wrote: > We have drivers for both rtl8365mb and rtl8366rb and each uses a > different tagger. realtek-dsa didn't know that and caused a reference to > an unavailable symbol when one of them was disabled. Add IS_ENABLED() > guards to fix this. >

[PATCH] i2c: i.MX: Use initialized dev for dev_dbg()

2023-01-25 Thread Sascha Hauer
i2c_fsl_set_clk() is called before the i2c device has been initialized, so the dev_dbg() messages therein show up as: : I2C_CLK=6600, REQ DIV=660 Use the parent device instead for printing these messages. Signed-off-by: Sascha Hauer --- drivers/i2c/busses/i2c-imx.c | 16

Re: [PATCH 1/2] i2c: i.MX: Use better error code when bus recovery failed

2023-01-25 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 10:21:29AM +0100, Marco Felsch wrote: > On 23-01-25, Sascha Hauer wrote: > > Signed-off-by: Sascha Hauer > > --- > > drivers/i2c/busses/i2c-imx.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/dri

Re: [PATCH 4/5] ARM: novena: Read Ethernet MAC address from EEPROM

2023-01-25 Thread Sascha Hauer
On Thu, Jan 26, 2023 at 12:31:04AM +1100, John Watts wrote: > On Wed, Jan 25, 2023 at 09:19:23AM +0100, Sascha Hauer wrote: > > Yes, normally it should be set up already, unless of course there is > > some needed pinctrl configuration in an unrelated device tree node. > >

Re: [PATCH v2 1/2] imx6-mmdc: Work around ERR050070

2023-01-25 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 04:41:15AM +1100, John Watts wrote: > The MPWLGCR registers clear the error bits before software can read them, > so rely on the MPWLHWERR registers for error reporting instead. > > This errata was announced in 2019 but it seems to apply to all chip revisions. > > U-Boot c

Re: [PATCH v2 1/4] ARM: novena: Add Kosagi Novena board

2023-01-25 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 08:33:57PM +0100, Marco Felsch wrote: > Hi John, > > thanks for your patch. > > On 23-01-26, John Watts wrote: > > The Kosagi Novena is an open source laptop released in 2014. > > > > This patch adds the initial project skeleton for running the PBL > > and debugging over

Re: [PATCH v2 2/4] ARM: novena: Setup RAM using static configuration

2023-01-26 Thread Sascha Hauer
On Thu, Jan 26, 2023 at 06:54:06PM +1100, John Watts wrote: > On Wed, Jan 25, 2023 at 08:39:40PM +0100, Marco Felsch wrote: > > Hi John, > > > > this patch should be part of patch1 since without this one you can't > > boot the board, right? > > Yes, but I wanted to do a separate commit so I can d

Re: [PATCH v2] spi: Fix probing SPI drivers with no cs-gpios

2023-01-26 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 07:05:55AM +1100, John Watts wrote: > of_gpio_named_count returns a negative value on error but this > is discarded and cast to a u16, making error handling impossible. > > With debug logging enabled this effectively halts booting so the board can > print an error over seri

Re: [PATCH] phy: stm32-usphyc: add mdelay(1) to fix timeout on some machines

2023-01-26 Thread Sascha Hauer
On Tue, Jan 24, 2023 at 09:31:19PM +0100, Michael Grzeschik wrote: > An mdelay of 1 seems to be necessary on some machines, since > the monsel status does not seem to be accurate. On rare occasions just > working with the phy after this pll check lead to no functional usb. > With this short mdelay

Re: [PATCH v2] phy: stm32-usphyc: add mdelay(1) to fix timeout on some machines

2023-01-26 Thread Sascha Hauer
On Tue, Jan 24, 2023 at 09:44:34PM +0100, Michael Grzeschik wrote: > An mdelay of 1 seems to be necessary on some machines, since > the monsel status does not seem to be accurate. On rare occasions just > working with the phy after this pll check lead to no functional usb. > With this short mdelay

Re: [PATCH] ddr_spd: remove unused local variable

2023-01-26 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 01:48:40PM +0100, Marco Felsch wrote: > From: Marco Felsch > > The buf8 variable was never used so remove it. > > Fixes: 2f1fc1c92 ("ddr_spd: Add function to read eeprom") > Signed-off-by: Marco Felsch > --- > common/ddr_spd.c | 1 - > 1 file changed, 1 deletion(-) App

Re: [PATCH] i2c: implement detect callback for virtual adapter device as well

2023-01-26 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 08:53:23AM +0100, Ahmad Fatoum wrote: > For MMCs, we already support detect on both the hardware device and the > mmcX virtual device. Let's do the same for i2c, so users have the option > to do `detect i2c0` instead of `detect 30a3@30a3.of`. > > `detect -a` sti

Re: [RFC PATCH 1/2] net: ifup: prefer interfaces where the link is already up

2023-01-26 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 10:52:35AM +0100, Ahmad Fatoum wrote: > ifup -a on a platform with a DSA switch can take quite a while, because > barebox will attempt sending a DHCP DISCOVER on every port in sequence > and waiting until timeout. This could use some refactoring to make it > possible to make

Re: [RFC PATCH 2/2] net: ifup: have ifup -a stop at the first interface

2023-01-26 Thread Sascha Hauer
On Wed, Jan 25, 2023 at 10:52:36AM +0100, Ahmad Fatoum wrote: > The normal use case for ifup -a is to get *some* interface working and > not really wait for all interfaces to come up and then timeout waiting > for those without link up to get their DHCP lease. Thus repurpose ifup > -a to mean bring

Re: [PATCH 1/3] nvmem: ocotp: add support for second MAC address on i.MX8MP

2023-01-27 Thread Sascha Hauer
On Wed, Jan 11, 2023 at 07:21:55PM +0100, Lucas Stach wrote: > i.MX8MP has the same quirk as the i.MX6UL: the MAC address for the > second ethernet interface is stored at an unaligned location and thus > needs to be handled by skipping the first 2 bytes from the OCOTP > register. > > Signed-off-by

Re: [PATCH] I2C: i.MX: early: Use internal udelay

2023-01-30 Thread Sascha Hauer
On Fri, Jan 27, 2023 at 05:56:43AM +1100, John Watts wrote: > udelay isn't provided in the PBL, so use our own definition. > > This avoids boards having to define udelay in their code. > > Signed-off-by: John Watts > --- > drivers/i2c/busses/i2c-imx-early.c | 9 - > 1 file changed, 8 in

Re: [PATCH] I2C: i.MX: early: Use internal udelay

2023-01-30 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 11:24:55PM +1100, John Watts wrote: > On Mon, Jan 30, 2023 at 01:17:52PM +0100, Sascha Hauer wrote: > > On Mon, Jan 30, 2023 at 09:42:53PM +1100, John Watts wrote: > > > On Mon, Jan 30, 2023 at 11:27:27AM +0100, Sascha Hauer wrote: > > > > This

Re: [PATCH] I2C: i.MX: early: Use internal udelay

2023-01-30 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 11:56:20PM +1100, John Watts wrote: > On Mon, Jan 30, 2023 at 01:31:42PM +0100, Sascha Hauer wrote: > > As said, the code is also for other i.MX SoCs, so a fixed base address > > won't do it. You would first have to detect the SoC type, but we can > &

Re: [PATCH v2] ARM: i.MX6: Specify OCRAM base address and size

2023-01-30 Thread Sascha Hauer
On Fri, Jan 27, 2023 at 07:56:42PM +1100, John Watts wrote: > On Fri, Jan 27, 2023 at 09:06:33AM +0100, Marco Felsch wrote: > > Hi John, > > > > On 23-01-27, John Watts wrote: > > > The i.MX6 includes some on-chip RAM: 128KiB on most variants, with 256KiB > > > on > > > the Dual and Quad variants

Re: [PATCH v2] ARM: i.MX6: Specify OCRAM base address and size

2023-01-30 Thread Sascha Hauer
On Fri, Jan 27, 2023 at 06:02:58AM +1100, John Watts wrote: > The i.MX6 includes some on-chip RAM: 128KiB on most variants, with 256KiB on > the Dual and Quad variants. > > This region is where the first stage of Barebox gets loaded if RAM > initialization isn't hard coded using DCD information. >

Re: [PATCH] I2C: i.MX: early: Use internal udelay

2023-01-30 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 09:42:53PM +1100, John Watts wrote: > On Mon, Jan 30, 2023 at 11:27:27AM +0100, Sascha Hauer wrote: > > This takes around 5 times too long on a i.MX8MM and around 50 times too > > long on a i.MX6Q. This was measured under a regular barebox on the > &g

Re: [PATCH] I2C: i.MX: early: Use internal udelay

2023-01-30 Thread Sascha Hauer
On Tue, Jan 31, 2023 at 05:42:29AM +1100, John Watts wrote: > On Mon, Jan 30, 2023 at 05:36:58PM +0100, Sascha Hauer wrote: > > You can't disable MMU during runtime, but you can compile without MMU > > support, just disable CONFIG_MMU. However, the early I2C code already > &

Re: [PATCH] net: phy: remove duplicate definition of PHY_AN_TIMEOUT

2023-01-31 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 12:34:05PM +0100, Ahmad Fatoum wrote: > Same macro is already defined in . > > Signed-off-by: Ahmad Fatoum > --- > drivers/net/phy/phy.c | 2 -- > 1 file changed, 2 deletions(-) Applied, thanks Sascha > > diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c > in

Re: [PATCH 1/2] net: ks8851_mll: drop platform_device usage

2023-01-31 Thread Sascha Hauer
On Tue, Jan 31, 2023 at 12:45:00AM +0100, Marco Felsch wrote: > The pdev member is unused neither do have barebox support for 'struct > platform_device' so remove the usage. > > Signed-off-by: Marco Felsch > --- > drivers/net/ks8851_mll.c | 2 -- > 1 file changed, 2 deletions(-) Applied, thanks

Re: [PATCH v2 0/4] video: add support for QEMU ramfb

2023-01-31 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 08:27:03AM +0100, Ahmad Fatoum wrote: > QEMU's ramfb is a very simple Qemu fw_cfg protocol, where the guest > need only write a video settings structure to /etc/ramfb to get > DMA from the framebuffer working. Add a driver for this on top > of a newly added character device

Re: [PATCH] ARM: i.MX8MM: innocomm-wb15: use revised PMIC settings

2023-01-31 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 08:21:57AM +0100, Ahmad Fatoum wrote: > Original values used when WB15 support was upstreamed were taken from > EVK, but original U-Boot port, we had been running for years now, is > configured differently and is known to be stable. Revert to those values. > > Signed-off-by

Re: [PATCH] mfd: add regmap driver for rohm-bd718x7

2023-01-31 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 08:16:22AM +0100, Ahmad Fatoum wrote: > Rohm BD71837 is a PMIC for i.MX8MM, which is used on most boards > supported by barebox. So far, we didn't need to change PMIC > configuration after the initial setup in PBL, but to support future > debugging and development, let's por

Re: [PATCH] ARM: add DEBUG_LL support for ARM64 QEMU Virt

2023-01-31 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 07:45:10AM +0100, Ahmad Fatoum wrote: > From: Ahmad Fatoum > > We have DEBUG_LL for the PL011 on the ARM64 QEMU Virt, > but it is unused. Wire it in. > > Signed-off-by: Ahmad Fatoum > --- > arch/arm/Kconfig| 1 + > arch/arm/cpu/board-dt-2nd.c | 2 +

Re: [PATCH v2 1/2] ARM: dts: stm32mp15x: adjust USB OTG gadget tx fifo sizes

2023-01-31 Thread Sascha Hauer
On Tue, Jan 24, 2023 at 09:01:13PM +0100, Michael Grzeschik wrote: > There are in sum 952 dwords available for g-rx-fifo-size, > g-np-tx-fifo-size and the eight entries of g-tx-fifo-size. For high > speed endpoints the maximal packet size is 512 (for full speed it's 64) > bytes. So a tx-fifo-size o

Re: [PATCH v2 2/2] usb: dwc2: fix multiplier handling in endpoint setup

2023-02-01 Thread Sascha Hauer
On Wed, Feb 01, 2023 at 07:13:24PM +0100, Ahmad Fatoum wrote: > On 24.01.23 21:01, Michael Grzeschik wrote: > > If the multiplier is 0 in the descriptor bitfield the multiplier count > > is one. For calculating the multiplier count the extra function > > usb_endpoint_maxp_mult should be used. Rewor

Re: [PATCH] ddr_dimms: Check spd->mem_type before computing parameters

2023-02-01 Thread Sascha Hauer
On Wed, Feb 01, 2023 at 04:33:34PM +1100, John Watts wrote: > Checking the mem_type here as well as the CRC means developers can > just read the SPD and pass it directly to parameter computation. > > This makes it so developers can rely fully on parameters for checking > if RAM is compatible with

Re: [PATCH] I2C: i.MX: early: Use a custom delay on i.MX6

2023-02-01 Thread Sascha Hauer
On Wed, Feb 01, 2023 at 08:44:35PM +1100, John Watts wrote: > The i.MX early I2C code requires waiting for the controller to settle > after configuration. This is currently done using udelay which is > supported on ARMv8 but not on ARMv7. > > For the i.MX6 we will have to use a custom delay. This

Re: [PATCH] fs: nfs: Error if a port is unregistered

2023-02-01 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 09:34:04AM +1100, John Watts wrote: > If a server doesn't provide a service the port lookup will return 0. > Check for this and return an appropriate error code. > > This was tested by running NFS with UDP disabled, which seems to be > the default in Arch at least. > > Sig

Re: [PATCH master] fs: align truncate return codes with POSIX

2023-02-02 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 01:20:00PM +0100, Ahmad Fatoum wrote: > Writing past end of a file results in a cryptic error code: > > barebox@board:/ cp /dev/zero /dev/mmc0.part > write: Operation not permitted > cp: Operation not permitted > > Because the cdev's truncate is not implemented and a

Re: [PATCH] clk: imx8mp: add USB suspend clock

2023-02-02 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 01:05:24PM +0100, Lucas Stach wrote: > Linux added another USB clock to properly describe the controller root > and suspend clocks. As new DTs are using this clock to keep the shared > gate enabled, access to the USB controller will hang Barebox without > support for this cl

Re: [PATCH] fs: remove unused members of struct stat

2023-02-02 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 03:25:12PM +0100, Ahmad Fatoum wrote: > Some members in struct stat are never written, so drop them. > > Signed-off-by: Ahmad Fatoum > --- > fs/fs.c | 4 ++-- > include/linux/stat.h | 3 --- > 2 files changed, 2 insertions(+), 5 deletions(-) Applied, thanks

Re: [PATCH master v2 1/3] include: linux/printk: implement pr_*_once macros

2023-02-03 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 02:34:13PM +0100, Ahmad Fatoum wrote: > These are useful as a less verbose alternative to WARN_ONCE, which also > prints a stack trace if possible. > > Signed-off-by: Ahmad Fatoum > --- > v1 -> v2: > unchanged > --- > include/linux/printk.h | 20 >

Re: [PATCH v2] fs: align write return codes with POSIX

2023-02-03 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 02:27:34PM +0100, Ahmad Fatoum wrote: > Writing past end of a file results in a cryptic error code: > > barebox@board:/ cp /dev/zero /dev/mmc0.part > write: Operation not permitted > cp: Operation not permitted > > Because the cdev's truncate is not implemented and a

Re: [PATCH v2] fs: nfs: Error if a port is unregistered

2023-02-03 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 10:20:24PM +1100, John Watts wrote: > If a server doesn't provide a service the port lookup will return 0. > > Check for this, return an appropriate error code and give a hint as to > why this might be happening. > > This was tested by running NFS with UDP disabled, which

Re: [PATCH v4 0/5] Add support for the Kosagi Novena board

2023-02-03 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 06:57:37PM +1100, John Watts wrote: > This patch series introduces support for the Novena board. > This support is basic but enough to boot Barebox. > > The EEPROM code here is included in anticipation for reading the features > flag in the future when more board features a

Re: [PATCH] RISC-V: virt: riscvemu: fix unit address in node name

2023-02-03 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 03:20:00PM +0100, Ahmad Fatoum wrote: > The overlay adds a SRAM at address 0x1000, but the unit address was > still 0, which is confusing. Change it to sram@1000 instead. > > Reported-by: Marco Felsch > Signed-off-by: Ahmad Fatoum > --- > arch/riscv/boards/riscvemu/overl

Re: [PATCH 1/3] RISC-V: Makefile: cleanup layout

2023-02-03 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 02:26:10PM +0100, Marco Felsch wrote: > The cflag and cppflag handling is rather complicated for this small > Makefile. The code uses two helper variables riscv-cflags-y cflags-y > which are assigned later to PBL_CPPFLAGS, KBUILD_CPPFLAGS and > KBUILD_CFLAGS. > > Remove thi

Re: [PATCH v2 0/3] net: ifup: greatly reduce ifup -a time for multiple network interface

2023-02-03 Thread Sascha Hauer
On Mon, Jan 30, 2023 at 08:20:54AM +0100, Ahmad Fatoum wrote: > So far, ifup -a tries to up all non-disabled interfaces in sequence. > This can take a quite a while, because interfaces with the link down, > will be polled for 10s, before giving up on doing DHCP on them. > > This series accelerates

Re: [PATCH v2] ratp: Fix retransmission for header-only packets

2023-02-03 Thread Sascha Hauer
Hi Jules, On Wed, Jan 25, 2023 at 04:39:59PM +0100, Jules Maselbas wrote: > Using sendmsg_current to detect if a packet needs to be retransmitted is > brittle as only packets containing data will ever be considered, packets > only containing a header (without data) were never being retransmitted.

Re: [PATCH] clk: imx8mp: add USB suspend clock

2023-02-05 Thread Sascha Hauer
On Fri, Feb 03, 2023 at 10:07:22AM +0100, Lucas Stach wrote: > Am Freitag, dem 03.02.2023 um 08:55 +0100 schrieb Sascha Hauer: > > On Thu, Feb 02, 2023 at 01:05:24PM +0100, Lucas Stach wrote: > > > Linux added another USB clock to properly describe the controller root > >

Re: [PATCH 1/5] nvmem: add support for post processing

2023-02-05 Thread Sascha Hauer
On Thu, Feb 02, 2023 at 06:33:08PM +0100, Lucas Stach wrote: > This is a port of the Linux commit 5008062f1c3f ("nvmem: core: add nvmem > cell post processing callback"). It looks a little different, as Linux > switched to create nvmem cells at registration time, effectively > deduplicating the cel

[PATCH 1/3] ARM: i.MX Riotboard: Add SD card update handler

2023-02-07 Thread Sascha Hauer
The Riotboard has an SD card slot from which the board can be booted. Add an update handler for it. Signed-off-by: Sascha Hauer --- arch/arm/boards/embest-riotboard/board.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/boards/embest-riotboard/board.c b/arch/arm/boards/embest

[PATCH 2/3] ARM: i.MX Riotboard: Switch to board driver

2023-02-07 Thread Sascha Hauer
Switch the Riotboard to board driver with deep probe enabled. Signed-off-by: Sascha Hauer --- arch/arm/boards/embest-riotboard/board.c | 20 +++- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/arch/arm/boards/embest-riotboard/board.c b/arch/arm/boards/embest

[PATCH 3/3] ARM: i.MX Riotboard: Let phy driver initialize the phy

2023-02-07 Thread Sascha Hauer
The phy setup done in the board code is done by the phy driver already, so drop the board code. Signed-off-by: Sascha Hauer --- arch/arm/boards/embest-riotboard/board.c | 35 arch/arm/mach-imx/Kconfig| 1 + 2 files changed, 1 insertion(+), 35 deletions

Re: [PATCH] ARM: i.MX8MP-EVK: increase VDD_ARM to OD voltage

2023-02-07 Thread Sascha Hauer
On Mon, Feb 06, 2023 at 09:59:28PM +0100, Lucas Stach wrote: > The Linux kernel or whatever is started from Barebox might switch the > ARM frequency to OD level, without first reprogramming the PMIC as > required. This might lead to system instability. To avoid this, > increase VDD_ARM to OD level.

Re: [PATCH 1/3] ARM: i.MX8M: esdctl: limit i.MX8MP early memory size

2023-02-08 Thread Sascha Hauer
On Mon, Feb 06, 2023 at 10:00:02PM +0100, Lucas Stach wrote: > Limit detected early memory size to 1GB on i.MX8MP, as the default DT > has a reserved memory region at 0x9240, which will conflict with > our malloc area in some configurations. Until we can properly parse > and exclude the reserve

Re: [PATCH] Documentation: networking: improve net.* variable description

2023-02-08 Thread Sascha Hauer
On Mon, Feb 06, 2023 at 02:45:51PM +0100, Roland Hieber wrote: > Signed-off-by: Roland Hieber > --- > Documentation/user/booting-linux.rst | 2 ++ > Documentation/user/networking.rst| 10 ++ > 2 files changed, 8 insertions(+), 4 deletions(-) Applied, thanks Sascha > > diff --git

Re: [PATCH 1/3] ARM: i.MX8M: esdctl: limit i.MX8MP early memory size

2023-02-08 Thread Sascha Hauer
On Wed, Feb 08, 2023 at 09:20:15AM +0100, Sascha Hauer wrote: > On Mon, Feb 06, 2023 at 10:00:02PM +0100, Lucas Stach wrote: > > Limit detected early memory size to 1GB on i.MX8MP, as the default DT > > has a reserved memory region at 0x9240, which will conflict with > &g

Re: [PATCH 1/2] net: rtl8139: remove dependence on MIPS

2023-02-08 Thread Sascha Hauer
On Wed, Feb 08, 2023 at 11:13:06AM +0300, Denis Orlov wrote: > This driver seems to work fine on ARM64 Virtual Machine in QEMU. > > Signed-off-by: Denis Orlov > --- > drivers/net/Kconfig | 1 - > drivers/net/rtl8139.c | 2 -- > 2 files changed, 3 deletions(-) Applied including the fixup! Tha

Re: [PATCH v3 1/3] ARM: i.MX8M: esdctl: use common compatible to detect i.MX8MQ/MM/MP DDRC

2023-02-10 Thread Sascha Hauer
On Wed, Feb 08, 2023 at 02:34:06PM +0100, Lucas Stach wrote: > All i.MX8M* DDRC nodes are compatible to "fsl,imx8m-ddrc". As the memory > size detection works the same on most of them, with the only exception > being the i.MX8MN, which only has a 16bit data bus, there is no need to > match the more

Re: [PATCH v2 1/2] ddr: imx8m: add support for 3720 MHz DDR rate

2023-02-10 Thread Sascha Hauer
On Wed, Feb 08, 2023 at 02:35:18PM +0100, Lucas Stach wrote: > From: Ahmad Fatoum > > Signed-off-by: Ahmad Fatoum > Signed-off-by: Lucas Stach > --- > drivers/ddr/imx8m/ddrphy_utils.c | 3 +++ > 1 file changed, 3 insertions(+) Applied, thanks Sascha > > diff --git a/drivers/ddr/imx8m/ddrph

Re: [PATCH v2 2/2] ARM: i.MX8MP: add initial Polyhex DEBIX Model A support

2023-02-10 Thread Sascha Hauer
On Wed, Feb 08, 2023 at 02:35:19PM +0100, Lucas Stach wrote: > From: Ahmad Fatoum > > The Polyhex DEBIX Model A is an i.MX8MP based Rpi form factor board. > This commit imports the v6 of the Linux device tree[1], and the timings > from the vendor U-Boot[2] and combines it with existing barebox i.

Re: [PATCH] pinctrl: rockchip: fix get_value

2023-02-10 Thread Sascha Hauer
On Thu, Feb 09, 2023 at 10:56:40AM +0100, Kilian Strasser wrote: > Function gpioinfo returns wrong gpio values. > In the file pinctrl.rockchip.c a wrong register offset is used by the > function rockchip_gpiov2_get_value. Also the bit-mask for this register > is wrong. Change register offset for th

Re: [PATCH] nvme: parse partition table when registering a block device

2023-02-10 Thread Sascha Hauer
On Thu, Feb 09, 2023 at 05:37:51PM +0300, Denis Orlov wrote: > Otherwise, we can not access file systems located on partitioned NVME > drives. > > Signed-off-by: Denis Orlov > --- > drivers/nvme/host/core.c | 5 + > 1 file changed, 5 insertions(+) Applied, thanks Sascha > > diff --git a/

Re: [PATCH 0/2] Initial LS1021-IOT board support

2023-02-10 Thread Sascha Hauer
On Wed, Feb 08, 2023 at 01:26:21PM +, Renaud Barbier wrote: > The LS1021A-IOT is NXP ARMv7 Layerscape evaluation board. > > These patches provide a basic board support with: > - UART > - boot from SPI > - One Ethernet port - eth1* > > The content of the EEPROM having been lo

Re: [PATCH 2/2] ARM: Layerscape: Add LS1021A IOT board support

2023-02-10 Thread Sascha Hauer
On Wed, Feb 08, 2023 at 01:26:30PM +, Renaud Barbier wrote: > The LS1021A-IOR is a NXP reference board. > Currently supported: > > - DDR3 RAM fixed settings > - UART > - SPI boot > - One SGMII network ports > > Signed-off-by: Renaud Barbier > --- > arch/arm/boards/Makefile

Re: [PATCH 0/2] Initial LS1021-IOT board support

2023-02-10 Thread Sascha Hauer
though it's never compiled together as they are different compiler architectures. Sascha > > > -Original Message- > > From: Sascha Hauer > > Sent: 10 February 2023 11:26 > > To: Renaud Barbier > > Cc: Barebox List > > Subject: Re: [PATCH 0/2

Re: [PATCH 2/2] defaultenv: boot/net: allow customising NFS port and path

2023-02-12 Thread Sascha Hauer
On Fri, Feb 10, 2023 at 11:48:31PM +0100, Roland Hieber wrote: > There are use cases where the port and mount path of the NFS root need > to be changed from the default values, e.g. with the userspace NFS > daemon used by 'ptxdist nfsroot', which tells you: > > Mount rootfs with nfsroot=/root,

Re: [PATCH v2 4/4] boards: qemu-virt: support passing in FIT public key

2023-02-13 Thread Sascha Hauer
On Fri, Feb 10, 2023 at 05:53:53PM +0100, Ahmad Fatoum wrote: > FIT public key is usually passed in via board DT. Usual way to use > barebox with QEMU Virt however is to use DT supplied by Qemu and apply > overlay to it. mkimage doesn't generate overlay DTB though. To make > barbebox Qemu Virt beha

  1   2   3   4   5   6   7   8   9   10   >