Skip to contentSkip to conversation

common: print \n in initr_scsi()

PATCH New Heinrich Schuchardt 3 participants 4 messages Jun 15, 2018 – Jul 12, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 common: print \n in initr_scsi()

Typically init_scsi() does not output anything. So initr_scsi() should provide a \n or we may see borked output like

SCSI: Net: No ethernet found.

as observed with sandbox_defconfig.

---
 common/board_r.c | 1 +
 1 file changed, 1 insertion(+)
common/board_r.c +1 -0
index 6b297068bd..23b5d2c21b 100644
@@ -553,6 +553,7 @@ static int initr_scsi(void)
 {
 	puts("SCSI:  ");
 	scsi_init();
+	puts("\n");
 
 	return 0;
 }
Signature · 1 line
2.17.1
#1 lore raw

PATCH 1/1 common: print \n in initr_scsi()

Hi Heinrich,

Quoted 11 lines · Heinrich Schuchardt

Typically init_scsi() does not output anything. So initr_scsi() should provide a \n or we may see borked output like

SCSI: Net: No ethernet found.

as observed with sandbox_defconfig.

---
 common/board_r.c | 1 +
 1 file changed, 1 insertion(+)

Instead of this, we should enable DM_SCSI on sandbox.

Regards,
Simon

#2 lore raw

PATCH 1/1 common: print \n in initr_scsi()

Quoted 15 lines · Simon Glass

Hi Heinrich,

Quoted 11 lines · Heinrich Schuchardt

Typically init_scsi() does not output anything. So initr_scsi() should provide a \n or we may see borked output like

SCSI: Net: No ethernet found.

as observed with sandbox_defconfig.

---
 common/board_r.c | 1 +
 1 file changed, 1 insertion(+)
Quoted 5 lines

Instead of this, we should enable DM_SCSI on sandbox.

Regards,
Simon

The function initr_scsi() is built for
#if defined(CONFIG_SCSI) && !defined(CONFIG_DM_SCSI)

Once all boards that support CONFIG_SCSI can be configured with CONFIG_DM_SCSI we should remove the symbol CONFIG_SCSI and function initr_scsi(). But we have not even enabled BLK for all supported boards. BLK is required for DM_SCSI.

Till then problem I observed will be reproducible on other architectures than sandbox if no SCSI disk is attached.

Best regards

Heinrich

#3 lore raw

PATCH 1/1 common: print \n in initr_scsi()

In reply to Heinrich Schuchardt
Quoted 8 lines · Heinrich Schuchardt

Typically init_scsi() does not output anything. So initr_scsi() should provide a \n or we may see borked output like

SCSI: Net: No ethernet found.

as observed with sandbox_defconfig.

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180711/ccc435ac/attachment.sig>