image-board: fix wrong implementation ram disk address setup from cmdline
PATCH 1/1 image-board: fix wrong implementation ram disk address setup from cmdline
Problem
Wrong implementation logic: ramdisk cmdline image address always ignored! Next block { rd_addr = hextoul(select, NULL) } unusable for raw initrd.
We have unbootable raw initrd images because, select_ramdisk for raw initrd images ignore submited select addr and setup rd_datap value to 0
Come-from: https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
--- common/image-board.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
common/image-board.c +3 -3
@@ -333,7 +333,7 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch,if (select) {ulong default_addr; -bool done = true; +bool done = false;if (CONFIG_IS_ENABLED (FIT )) {/*
@@ -351,13 +351,13 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch, &fit_uname_config)) {debug ("* ramdisk: config '%s' from image at 0x%08lx\n" , fit_uname_config, rd_addr); + done = true; } else if (fit_parse_subimage(select, default_addr, &rd_addr, &fit_uname_ramdisk)) {debug ("* ramdisk: subimage '%s' from image at 0x%08lx\n" , fit_uname_ramdisk, rd_addr); - } else { - done = false; + done = true; } }if (!done) {
Signature · 1 line
2.25.1
Hi Artem,
Quoted 9 lines · Artem Lapkin
Problem
Wrong implementation logic: ramdisk cmdline image address always ignored! Next block {
rd_addr=hextoul(select, NULL)} unusable for raw initrd.We have unbootable raw initrd images because,
select_ramdiskfor raw initrd images ignore submited select addr and setuprd_datapvalue to 0
Quoted 6 lines
Come-from: https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
Signed-off-by Artem Lapkin <[email protected]>--- common/image-board.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
(I believe, can you confirm?)
Quoted 33 lines
common/image-board.c +3
-4@@ -333,7 +333,7 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch,if (select) {ulong default_addr; -bool done = true; +bool done = false;if (CONFIG_IS_ENABLED (FIT )) {/* @@ -351,13 +351,13 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch, &fit_uname_config)) {debug ("* ramdisk: config '%s' from image at 0x%08lx\n" , fit_uname_config, rd_addr); + done = true; } else if (fit_parse_subimage(select, default_addr, &rd_addr, &fit_uname_ramdisk)) {debug ("* ramdisk: subimage '%s' from image at 0x%08lx\n" , fit_uname_ramdisk, rd_addr); - } else { - done = false; + done = true; } }if (!done) { --2.25.1
A message that is not in the archive (sent off-list or not yet received): [email protected]
hi Simon
Quoted 2 lines
Fixes f33a2c1bd0f ("image: Remove #ifdefs from select_ramdisk()")(I believe, can you confirm?)
confirm f33a2c1bd0f has wrong implementation logic for raw ramdisk image sure i have tested it ...
Quoted 60 lines · Simon Glass
Hi Artem,
Quoted 9 lines · Artem Lapkin
Problem
Wrong implementation logic: ramdisk cmdline image address always ignored! Next block {
rd_addr=hextoul(select, NULL)} unusable for raw initrd.We have unbootable raw initrd images because,
select_ramdiskfor raw initrd images ignore submited select addr and setuprd_datapvalue to 0Quoted 6 lines
Come-from: https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
Signed-off-by Artem Lapkin <[email protected]>--- common/image-board.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)Fixes f33a2c1bd0f ("image: Remove #ifdefs from select_ramdisk()")(I believe, can you confirm?)
Reviewed-by Simon Glass <[email protected]>Quoted 33 lines
common/image-board.c +3
-4@@ -333,7 +333,7 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch,if (select) {ulong default_addr; -bool done = true; +bool done = false;if (CONFIG_IS_ENABLED (FIT )) {/* @@ -351,13 +351,13 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch, &fit_uname_config)) {debug ("* ramdisk: config '%s' from image at 0x%08lx\n" , fit_uname_config, rd_addr); + done = true; } else if (fit_parse_subimage(select, default_addr, &rd_addr, &fit_uname_ramdisk)) {debug ("* ramdisk: subimage '%s' from image at 0x%08lx\n" , fit_uname_ramdisk, rd_addr); - } else { - done = false; + done = true; } }if (!done) { --2.25.1
Hi Art,
Quoted 8 lines · Art Nikpal
hi Simon
Quoted 2 lines
Fixes f33a2c1bd0f ("image: Remove #ifdefs from select_ramdisk()")(I believe, can you confirm?)
confirm
f33a2c1bd0fhas wrong implementation logic for raw ramdisk image sure i have tested it ...
Thanks!
BTW please can you try not to top-post?
Regards,
Simon
Quoted 62 lines · Simon Glass
Quoted 60 lines
Hi Artem,
Quoted 9 lines · Artem Lapkin
Problem
Wrong implementation logic: ramdisk cmdline image address always ignored! Next block {
rd_addr=hextoul(select, NULL)} unusable for raw initrd.We have unbootable raw initrd images because,
select_ramdiskfor raw initrd images ignore submited select addr and setuprd_datapvalue to 0Quoted 6 lines
Come-from: https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
Signed-off-by Artem Lapkin <[email protected]>--- common/image-board.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)Fixes f33a2c1bd0f ("image: Remove #ifdefs from select_ramdisk()")(I believe, can you confirm?)
Reviewed-by Simon Glass <[email protected]>Quoted 33 lines
common/image-board.c +3
-4@@ -333,7 +333,7 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch,if (select) {ulong default_addr; -bool done = true; +bool done = false;if (CONFIG_IS_ENABLED (FIT )) {/* @@ -351,13 +351,13 @@ static int select_ramdisk(bootm_headers_t *images, const char *select, u8 arch, &fit_uname_config)) {debug ("* ramdisk: config '%s' from image at 0x%08lx\n" , fit_uname_config, rd_addr); + done = true; } else if (fit_parse_subimage(select, default_addr, &rd_addr, &fit_uname_ramdisk)) {debug ("* ramdisk: subimage '%s' from image at 0x%08lx\n" , fit_uname_ramdisk, rd_addr); - } else { - done = false; + done = true; } }if (!done) { --2.25.1