[PATCH] ARM: i.MX: OCOTP: read serial number with correct endianness

2020-12-03 Thread Robert Karszniewicz
i.MX: Introduce imx_ocotp_read_uid()") Signed-off-by: Robert Karszniewicz --- arch/arm/mach-imx/include/mach/ocotp.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/arm/mach-imx/include/mach/ocotp.h b/arch/arm/mach-imx/include/mach/ocotp.h index 7ba5da156b76..20205c5da7

Re: Using bootspec with RAUC and redundant partitions

2020-09-30 Thread Robert Karszniewicz
Hello, Robin. On 9/30/20 11:19 AM, robin wrote: Hi Enrico, Sascha, On 2020-09-30 10:09, Enrico Jörns wrote: Hi Robin, Am Mittwoch, den 30.09.2020, 09:39 +0200 schrieb Sascha Hauer: > Is there a door number 3 or am I missing something here? What's the reason for additional kernel partitions?

[PATCH] scripts: compiler.h: include

2020-09-19 Thread Robert Karszniewicz
ulong is not a standard type, so it has to be defined explicitly. Signed-off-by: Robert Karszniewicz --- This fixes compile errors on musl when building the sandbox. scripts/compiler.h | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/compiler.h b/scripts/compiler.h index 0ad25f9e8

[PATCH] README: add some commas for clarity

2020-09-19 Thread Robert Karszniewicz
Signed-off-by: Robert Karszniewicz --- README | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README b/README index d8077d21b..0a837b2de 100644 --- a/README +++ b/README @@ -114,7 +114,7 @@ in board/sandbox/env: # ./scripts/bareboxenv -s -p 0x1 arch

Re: [PATCH v3] bootm: add global.bootm.root_dev env var for booting via PARTUUID

2020-08-20 Thread Robert Karszniewicz
On 8/20/20 9:05 AM, Sascha Hauer wrote: On Mon, Aug 10, 2020 at 02:20:08PM +0200, Robert Karszniewicz wrote: Introduces a new env var which specifies which device is the rootfs device to be used in Linux, passed to Linux via bootargs, identified by the rootfs partition's PAR

Re: [PATCH v3] bootm: add global.bootm.root_dev env var for booting via PARTUUID

2020-08-19 Thread Robert Karszniewicz
What's the status on this, please? Greetings. On 8/10/20 2:20 PM, Robert Karszniewicz wrote: Introduces a new env var which specifies which device is the rootfs device to be used in Linux, passed to Linux via bootargs, identified by the rootfs partition's PARTUUID. global.boot

[PATCH v3] bootm: add global.bootm.root_dev env var for booting via PARTUUID

2020-08-10 Thread Robert Karszniewicz
picks the partition that the kernel resides on (global.bootm.image). Example: detect mmc2 global.bootm.image='/mnt/mmc2.0/zImage' global.bootm.appendroot=1 global.bootm.root_dev=/dev/mmc2.1 boot mmc Signed-off-by: Robert Karszniewicz --- Changes from v2: - correct commit message line l

[PATCH v2] bootm: add global.bootm.root_dev env var for booting via PARTUUID

2020-08-10 Thread Robert Karszniewicz
picks the partition that the kernel resides on (global.bootm.image). Example: detect mmc2 global.bootm.image='/mnt/mmc2.0/zImage' global.bootm.appendroot=1 global.bootm.root_dev=/dev/mmc2.1 boot mmc Signed-off-by: Robert Karszniewicz --- Changes from v1: - minor commit message change

[PATCH] bootm: add global.bootm.root_dev env var for booting via PARTUUID

2020-08-10 Thread Robert Karszniewicz
ult, which picks the partition that the kernel resides on (global.bootm.image). Example: detect mmc2 global.bootm.image='/mnt/mmc2.0/zImage' global.bootm.appendroot=1 global.bootm.root_dev=/dev/mmc2.1 boot mmc Signed-off-by: Robert Karszniewicz --- Changes from RFC v2: - replaced pa

Re: [RFC PATCH v2 3/3] bootm: handle global.bootm.root_dev

2020-08-05 Thread Robert Karszniewicz
On 8/5/20 12:10 PM, Robert Karszniewicz wrote: --- common/bootm.c | 13 - 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/common/bootm.c b/common/bootm.c index 73409bf9f70c..01b54ab93958 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -656,7 +656,18 @@ int

[RFC PATCH v2 3/3] bootm: handle global.bootm.root_dev

2020-08-05 Thread Robert Karszniewicz
--- common/bootm.c | 13 - 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/common/bootm.c b/common/bootm.c index 73409bf9f70c..01b54ab93958 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -656,7 +656,18 @@ int bootm_boot(struct bootm_data *bootm_data) if (boot

[RFC PATCH v2 2/3] globalvar: add bootm.root_dev

2020-08-05 Thread Robert Karszniewicz
--- common/bootm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/common/bootm.c b/common/bootm.c index 311d0e058321..73409bf9f70c 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -743,6 +743,7 @@ static int bootm_init(void) globalvar_add_simple("bootm.image", NULL); global

[RFC PATCH v2 0/3] Introduce global.bootm.root_dev env var for booting via PARTUUID

2020-08-05 Thread Robert Karszniewicz
var s/root/root_dev/ - used filesystem-agnostic approach (root_dev now takes a /dev/ instead of a mounted partition) Robert Karszniewicz (3): bootm: add env var root_dev globalvar: add bootm.root_dev bootm: handle global.bootm.root_dev common/bootm.c | 18 -- include/boot

[RFC PATCH v2 1/3] bootm: add env var root_dev

2020-08-05 Thread Robert Karszniewicz
--- common/bootm.c | 4 +++- include/bootm.h | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/common/bootm.c b/common/bootm.c index 8fec1ee34dd8..311d0e058321 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -64,6 +64,7 @@ void bootm_data_init_defaults(struct bootm_data *d

[PATCH] ARM: boards: phytec-som-imx6: Add mmc and emmc-boot bbu update handler

2020-07-20 Thread Robert Karszniewicz
From: Stefan Riedmueller Add mmc and emmc-boot bbu update handler to update barebox on SD card and eMMC boot partitions easily. Signed-off-by: Stefan Riedmueller Signed-off-by: Robert Karszniewicz --- arch/arm/boards/phytec-som-imx6/board.c | 16 1 file changed, 16

Re: [RFC PATCH 0/4] Introduce global.bootm.root env var for booting via PARTUUID

2020-07-13 Thread Robert Karszniewicz
On 7/9/20 4:14 PM, Sascha Hauer wrote: On Tue, Jun 30, 2020 at 03:48:30PM +0200, Robert Karszniewicz wrote: This patch introduces a new env var which specifies which device is the rootfs device to be used in Linux, passed to Linux via bootargs, identified by the rootfs partition's PAR

[PATCH 1/2] ARM: configs: imx_v7_defconfig: Add state framework

2020-07-07 Thread Robert Karszniewicz
From: Daniel Schultz Signed-off-by: Daniel Schultz Signed-off-by: Robert Karszniewicz --- arch/arm/configs/imx_v7_defconfig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/configs/imx_v7_defconfig b/arch/arm/configs/imx_v7_defconfig index 24bdc0122c6a..ad5d43a68b62 100644

[PATCH 2/2] ARM: configs: imx_v7_defconfig: Add bootchooser

2020-07-07 Thread Robert Karszniewicz
From: Daniel Schultz Signed-off-by: Daniel Schultz Signed-off-by: Robert Karszniewicz --- arch/arm/configs/imx_v7_defconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/configs/imx_v7_defconfig b/arch/arm/configs/imx_v7_defconfig index ad5d43a68b62..76bf63bb2065 100644

[PATCH] ARM: configs: Update configs to use new Kconfig FASTBOOT_* names

2020-07-07 Thread Robert Karszniewicz
Some Kconfig symbols have been moved and renamed in commit 2879373370eb ("fastboot: split generic code from USB gadget") Signed-off-by: Robert Karszniewicz --- I used `make savedefconfig` to make Kbuild move them to the new place. arch/arm/configs/imx23_defconfig | 2 +-

[PATCH] ARM: configs: Remove unused Kconfig symbol 'NAND_IMX_BBM'

2020-07-06 Thread Robert Karszniewicz
This Kconfig symbol has been removed in 2ad441bb7e78 ("mtd: nand-imx: Create BBT automatically when necessary") Signed-off-by: Robert Karszniewicz --- arch/arm/configs/eukrea_cpuimx35_defconfig| 1 - arch/arm/configs/freescale-mx21-ads_defconfig | 1 - arch/arm/configs/imx

Re: [RFC PATCH 0/4] Introduce global.bootm.root env var for booting via PARTUUID

2020-06-30 Thread Robert Karszniewicz
The problem is that we want to be able to have the rootfs and kernel on separate partitions. We've looked into the Boot Loader Specification, but from what we saw, it makes A-B systems difficult (according to the spec, there can only be one "$BOOT" filesystem on a device). For reference: https

[RFC PATCH 0/4] Introduce global.bootm.root env var for booting via PARTUUID

2020-06-30 Thread Robert Karszniewicz
of scope for barebox? Example: detect mmc2 global.bootm.image='/mnt/mmc2.0/zImage' global.bootm.appendroot=1 global.bootm.root='/mnt/mmc2.1/' boot mmc Note that the trailing slash is important. See comment in follow_automount() in fs/fs.c Robert Karszniewicz (4): bootm: add env

[RFC PATCH 1/4] bootm: add env var root_dev

2020-06-30 Thread Robert Karszniewicz
--- common/bootm.c | 4 +++- include/bootm.h | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/common/bootm.c b/common/bootm.c index 8fec1ee34dd8..af9f9b8f447d 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -64,6 +64,7 @@ void bootm_data_init_defaults(struct bootm_data *d

[RFC PATCH 3/4] bootm: handle global.bootm.root

2020-06-30 Thread Robert Karszniewicz
--- common/bootm.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/common/bootm.c b/common/bootm.c index 3772fa4c2c51..1a9ef0673e55 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -656,7 +656,11 @@ int bootm_boot(struct bootm_data *bootm_data) if (bootm_data->a

[RFC PATCH 4/4] bootm: mount root device before accessing linux_rootarg

2020-06-30 Thread Robert Karszniewicz
--- common/bootm.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/common/bootm.c b/common/bootm.c index 1a9ef0673e55..b7c15cac0ba4 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -657,6 +657,8 @@ int bootm_boot(struct bootm_data *bootm_data) char *rootarg;

[RFC PATCH 2/4] globalvar: add bootm.root

2020-06-30 Thread Robert Karszniewicz
--- common/bootm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/common/bootm.c b/common/bootm.c index af9f9b8f447d..3772fa4c2c51 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -743,6 +743,7 @@ static int bootm_init(void) globalvar_add_simple("bootm.image", NULL); global

[PATCH] blspec: Allow the "options" key to be given multiple times

2020-05-18 Thread Robert Karszniewicz
The Boot Loader Spec says: "This key is optional and may appear more than once in which case all specified parameters are used in the order they are listed." Signed-off-by: Robert Karszniewicz --- common/blspec.c | 12 1 file changed, 12 insertions(+) diff --git a/commo

[PATCH] ARM: dts: imx6: phycard: remove baseboard compatible

2020-05-14 Thread Robert Karszniewicz
This devicetree isn't baseboard-specific, so keep it compatible at SOM-level. Signed-off-by: Robert Karszniewicz --- arch/arm/dts/imx6q-phytec-phycard.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/dts/imx6q-phytec-phycard.dts b/arch/arm/dts/imx6q-p

Re: [PATCH] usb: storage: Increase retries for usb_stor_transport()

2019-11-04 Thread Robert Karszniewicz
On 11/4/19 4:21 PM, Marco Felsch wrote: Hi Robert, On 19-11-04 15:59, Robert Karszniewicz wrote: On 11/4/19 3:54 PM, Marco Felsch wrote: Hi Sascha, On 19-11-04 10:42, Sascha Hauer wrote: On Fri, Oct 25, 2019 at 05:56:08PM +0200, Robert Karszniewicz wrote: This should make writing and

[PATCH v2] usb: storage: Increase retries for usb_stor_transport()

2019-11-04 Thread Robert Karszniewicz
This should make writing and reading more reliable. Also: - change loop condition to make "retries" semantically correct - add a debug message in case of fatal failure Signed-off-by: Robert Karszniewicz --- drivers/usb/storage/usb.c | 7 --- 1 file changed, 4 insertions(+), 3

Re: [PATCH] usb: storage: Increase retries for usb_stor_transport()

2019-11-04 Thread Robert Karszniewicz
On 11/4/19 3:54 PM, Marco Felsch wrote: Hi Sascha, On 19-11-04 10:42, Sascha Hauer wrote: On Fri, Oct 25, 2019 at 05:56:08PM +0200, Robert Karszniewicz wrote: This should make writing and reading more reliable. Also: - change loop condition to make "retries" semantically corre

Re: [PATCH] usb: storage: Increase retries for usb_stor_transport()

2019-11-04 Thread Robert Karszniewicz
On 11/4/19 10:42 AM, Sascha Hauer wrote: On Fri, Oct 25, 2019 at 05:56:08PM +0200, Robert Karszniewicz wrote: This should make writing and reading more reliable. Also: - change loop condition to make "retries" semantically correct - add a debug message in case of fatal failure ---

[PATCH] test: usb: storage: Increase retries for usb_stor_transport()

2019-10-25 Thread Robert Karszniewicz
This should make writing and reading more reliable. Also: - change loop condition to make "retries" semantically correct - add a debug message in case of fatal failure --- And here is the test for how many retries were required at maximum. In case anyone wants to try for themselves. barebox:/ usb

[PATCH] usb: storage: Increase retries for usb_stor_transport()

2019-10-25 Thread Robert Karszniewicz
This should make writing and reading more reliable. Also: - change loop condition to make "retries" semantically correct - add a debug message in case of fatal failure --- We've had problems writing (and even reading) a 10 MiB file from barebox to multiple USB flash drives. The 10 MiB file copy fa

[PATCH v2] sandbox: add_image: mmap block devices

2019-10-25 Thread Robert Karszniewicz
This makes it possible to mount block devices from the host machine, which have been passed as arguments to --image Signed-off-by: Robert Karszniewicz --- Changes from v1: - move -1 to the right side of the comparison arch/sandbox/os/common.c | 8 1 file changed, 8 insertions(+) diff

Re: [PATCH] sandbox: add_image: mmap block devices

2019-10-25 Thread Robert Karszniewicz
On 10/24/19 6:07 PM, Ahmad Fatoum wrote: On 10/24/19 6:02 PM, Robert Karszniewicz wrote: This makes it possible to mount block devices from the host machine, which have been passed as arguments to --image Signed-off-by: Robert Karszniewicz --- arch/sandbox/os/common.c | 8 1 file

[PATCH] sandbox: add_image: mmap block devices

2019-10-24 Thread Robert Karszniewicz
This makes it possible to mount block devices from the host machine, which have been passed as arguments to --image Signed-off-by: Robert Karszniewicz --- arch/sandbox/os/common.c | 8 1 file changed, 8 insertions(+) diff --git a/arch/sandbox/os/common.c b/arch/sandbox/os/common.c

[PATCH v4] libfile: copy_file: fix error handling

2019-10-22 Thread Robert Karszniewicz
Before this, ret was falsely polluted, which caused a misleading error message if the function bailed out at a later point. Signed-off-by: Robert Karszniewicz --- lib/libfile.c | 17 - 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/lib/libfile.c b/lib/libfile.c

[PATCH] sandbox: add_image: output errno string on mmap failure

2019-10-21 Thread Robert Karszniewicz
Signed-off-by: Robert Karszniewicz --- arch/sandbox/os/common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/sandbox/os/common.c b/arch/sandbox/os/common.c index 86118822a..1b2daa396 100644 --- a/arch/sandbox/os/common.c +++ b/arch/sandbox/os/common.c @@ -264,7 +264,7

Re: [PATCH v3] libfile: copy_file: prevent spurious error message

2019-10-18 Thread Robert Karszniewicz
In all this haste, I forgot my question. What error codes should be used? For each goto its own code, in sequence, starting from -1? ___ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox

[PATCH v3] libfile: copy_file: prevent spurious error message

2019-10-18 Thread Robert Karszniewicz
Before this, ret was falsely polluted, which caused a misleading error message if the function bailed out at a later point. Signed-off-by: Robert Karszniewicz --- lib/libfile.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/libfile.c b/lib/libfile.c index

[PATCH] cp: complete command help

2019-10-16 Thread Robert Karszniewicz
Signed-off-by: Robert Karszniewicz --- commands/cp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/commands/cp.c b/commands/cp.c index 54934dd..845dae6 100644 --- a/commands/cp.c +++ b/commands/cp.c @@ -100,13 +100,14 @@ BAREBOX_CMD_HELP_START(cp) BAREBOX_CMD_HELP_TEXT

Re: readling, ctrl-u is not working like linux console

2019-10-16 Thread Robert Karszniewicz
On 10/16/19 10:57 AM, Roland Hieber wrote: On Wed, Oct 16, 2019 at 04:57:45AM +0800, duhuanpeng wrote: Hi, I find it the barebox console's ctrl-u is not working like my linux host. for now, the barebox's ctrl-u discard the whole line. but the linux consle just remove characters before cursor. i

[PATCH v2] libfile: copy_file: prevent spurious error message

2019-10-16 Thread Robert Karszniewicz
Before this, if the function bails out somewhere at a later point, this return value will be outdated and will produce a misleading error message down the line. Signed-off-by: Robert Karszniewicz --- Changes from v1: - commit message lib/libfile.c | 1 + 1 file changed, 1 insertion(+) diff

[PATCH] libfile: copy_file: prevent spurious error message

2019-10-15 Thread Robert Karszniewicz
Signed-off-by: Robert Karszniewicz --- lib/libfile.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/libfile.c b/lib/libfile.c index 3f3ec21..319e66b 100644 --- a/lib/libfile.c +++ b/lib/libfile.c @@ -349,6 +349,7 @@ int copy_file(const char *src, const char *dst, int verbose

[PATCH] chdir(): add LOOKUP_DIRECTORY flag to filename_lookup()

2019-09-18 Thread Robert Karszniewicz
This makes sure that automount points get handled even if the path doesn't end with a '/'. Signed-off-by: Robert Karszniewicz --- fs/fs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/fs.c b/fs/fs.c index c6cb499..901beab 100644 --- a/fs/fs.c +++ b/fs/

[PATCH] readline: add ctrl-u (unix-line-discard)

2019-02-01 Thread Robert Karszniewicz
Signed-off-by: Robert Karszniewicz --- lib/readline.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/readline.c b/lib/readline.c index 904a77639..d026af110 100644 --- a/lib/readline.c +++ b/lib/readline.c @@ -290,6 +290,7 @@ int readline(const char *prompt, char *buf, int len