fastboot: Add USB cable detect check
PATCH 1/1 fastboot: Add USB cable detect check
Add a check for USB cable attached and only enter fastboot when a cable is attached.
--- common/cmd_fastboot.c | 6 ++++++ 1 file changed, 6 insertions(+)
common/cmd_fastboot.c +6 -0
@@ -20,6 +20,12 @@ static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])if (ret)return ret; +if (!g_dnl_board_usb_cable_connected ()) { +puts ("\rUSB cable not detected.\n" \ +"Command exit.\n" ); +return CMD_RET_FAILURE ; + } +while (1 ) {if (g_dnl_detach ())break ;
Signature · 1 line
2.1.0
PATCH 1/1 fastboot: Add USB cable detect check
Hi Rob,
Quoted 15 lines
Add a check for USB cable attached and only enter fastboot when a cable is attached.
Signed-off-by Rob Herring <[email protected]>--- common/cmd_fastboot.c | 6 ++++++ 1 file changed, 6 insertions(+)common/cmd_fastboot.c +0
-0@@ -20,6 +20,12 @@ static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) if (ret) return ret;
common/cmd_fastboot.c static int do_fastboot(cmd_tbl_t *cmdtp, int flag, · line 31
Quoted 10 lines
common/cmd_fastboot.c +6
-0+if (!g_dnl_board_usb_cable_connected ()) { +puts ("\rUSB cable not detected.\n" \ +"Command exit.\n" ); +return CMD_RET_FAILURE ; + } +while (1 ) {if (g_dnl_detach ())break ;
Signature · 5 lines
Best regards, Lukasz Majewski Samsung R&D Institute Poland (SRPOL) | Linux Platform Group
PATCH 1/1 fastboot: Add USB cable detect check
In reply to Rob HerringQuoted 16 lines · Rob Herring
Add a check for USB cable attached and only enter fastboot when a cable is attached.
Signed-off-by Rob Herring <[email protected]>--- common/cmd_fastboot.c | 6 ++++++ 1 file changed, 6 insertions(+)common/cmd_fastboot.c +0
-0@@ -20,6 +20,12 @@ static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])if (ret)return ret;
common/cmd_fastboot.c static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) · line 31
Quoted 10 lines
common/cmd_fastboot.c +6
-0+if (!g_dnl_board_usb_cable_connected ()) { +puts ("\rUSB cable not detected.\n" \ +"Command exit.\n" ); +return CMD_RET_FAILURE ; + } +while (1 ) {if (g_dnl_detach ())break ;
(question: the leading "\r" ?!?!)
Thanks, Steve
PATCH 1/1 fastboot: Add USB cable detect check
Quoted 21 lines · Steve Rae
Quoted 18 lines · Rob Herring
Add a check for USB cable attached and only enter fastboot when a cable is attached.
Signed-off-by Rob Herring <[email protected]>--- common/cmd_fastboot.c | 6 ++++++ 1 file changed, 6 insertions(+)common/cmd_fastboot.c +0
-0@@ -20,6 +20,12 @@ static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])if (ret)return ret;
Quoted 12 lines
Quoted 10 lines
common/cmd_fastboot.c +6
-0+if (!g_dnl_board_usb_cable_connected ()) { +puts ("\rUSB cable not detected.\n" \ +"Command exit.\n" ); +return CMD_RET_FAILURE ; + } +while (1 ) {if (g_dnl_detach ())break;(question: the leading "\r" ?!?!)
Humm, good question. It's copy and paste from USB MS implementation.
Rob
Quoted 3 lines
Reviewed-by Steve Rae <[email protected]>Thanks, Steve
PATCH 1/1 fastboot: Add USB cable detect check
Hi Rob,
Quoted 35 lines · Steve Rae
Quoted 21 lines · Rob Herring
Quoted 18 lines
Add a check for USB cable attached and only enter fastboot when a cable is attached.
Signed-off-by Rob Herring <[email protected]>--- common/cmd_fastboot.c | 6 ++++++ 1 file changed, 6 insertions(+)common/cmd_fastboot.c +0
-0@@ -20,6 +20,12 @@ static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])if (ret)return ret;Quoted 12 lines
Quoted 10 lines
common/cmd_fastboot.c +6
-0+if (!g_dnl_board_usb_cable_connected ()) { +puts ("\rUSB cable not detected.\n" \ +"Command exit.\n" ); +return CMD_RET_FAILURE ; + } +while (1 ) {if (g_dnl_detach ())break;(question: the leading "\r" ?!?!)
Quoted 7 lines
Humm, good question. It's copy and paste from USB MS implementation.
Rob
Quoted 3 lines
Reviewed-by Steve Rae <[email protected]>Thanks, Steve
Queued for u-boot-dfu branch.
Thanks for development and sorry for delay.
Signature · 5 lines
Best regards, Lukasz Majewski Samsung R&D Institute Poland (SRPOL) | Linux Platform Group