Disable uboot input
Follow CPE way to block uboot input.
Change-Id: Idc16d9326699f73e6ebd5d66b72b35a22300ca57
diff --git a/common/console.c b/common/console.c
index 99f1724..da3c53d 100755
--- a/common/console.c
+++ b/common/console.c
@@ -162,6 +162,10 @@
int getc (void)
{
+
+#ifdef CONFIG_SYS_BLOCK_INPUT
+ return -1;
+#else
if (gd->flags & GD_FLG_DEVINIT) {
/* Get from the standard input */
return fgetc (stdin);
@@ -169,6 +173,7 @@
/* Send directly to the handler */
return serial_getc ();
+#endif
}
int tstc (void)
diff --git a/include/953x.h b/include/953x.h
index 3fd411e..c293ae5 100755
--- a/include/953x.h
+++ b/include/953x.h
@@ -3491,6 +3491,7 @@
#define CONFIG_BOOTDELAY 0 /* autoboot w/o delay */
#define CONFIG_SYS_CTRLC_IGNORE 1 /* shutdown ctrl-c backdoor to enter interactive mode */
+#define CONFIG_SYS_BLOCK_INPUT 1 /* block uboot getc(console input) */
#define CONFIG_BAUDRATE 115200
#define CFG_BAUDRATE_TABLE {115200}