Skip to contentSkip to conversation

Make bootretry work when command line editing is enabled

PATCH New Andreas Engel 2 participants 2 messages Jan 9, 2008 – Jan 12, 2008

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Make bootretry work when command line editing is enabled

Currently, when CONFIG_CMDLINE_EDITING is set, bootretry doesn't work. This patch fixes the problem.

---

common/main.c +7 -0
diff -urpN u-boot-1.3.1/common/main.c u-boot-local/common/main.c
@@ -710,6 +710,13 @@ static int cread_line(char *buf, unsigne
 
 	while (1) {
 		rlen = 1;
+#ifdef CONFIG_BOOT_RETRY_TIME
+		while (!tstc()) {	/* while no incoming data */
+			if (retry_time >= 0 && get_ticks() > endtime)
+				return (-2);	/* timed out */
+		}
+#endif
+
 		ichar = getcmd_getch();
 
 		if ((ichar == '\n') || (ichar == '\r')) {
#1 lore raw

PATCH 1/1 Make bootretry work when command line editing is enabled

Quoted 4 lines · In message <94BF386B051B5849BA84A45DDFC4E60A02090095@esealmw118.eemea.ericsson.…

Currently, when CONFIG_CMDLINE_EDITING is set, bootretry doesn't work. This patch fixes the problem.

Applied, thank.s

Best regards,

Wolfgang Denk

Signature · 10 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Q:  How many DEC repairman does it take to fix a flat?
A:  Five; four to hold the car up and one to swap tires.
Q:  How long does it take?
A:  It's indeterminate.  It will depend upon how many flats they've
    brought with them.
Q:  What happens if you've got TWO flats?
A:  They replace your generator.