@@ -1,17 +1,18 @@
-.TH MVBOOT 1 "2012-05-19"
+.TH MVBOOT 1 "2013-02-12"
.SH NAME
-mvboot \- Boot Marvell Kirkwood SoCs over a serial link.
+mvboot \- Boot Marvell Kirkwood/Dove SoCs over a serial link.
.SH SYNOPSIS
.B mvboot
.RB [ "-b \fIimage\fP" ]
+.RB [ "-n" ]
.RB [ "-p" ]
.RB [ "-t" ]
.RB [ "-B \fIbaudrate\fP" ]
.RB \fITTY\fP
.SH "DESCRIPTION"
-The \fBmkimage\fP program boots boards based on Marvell's Kirkwood
+The \fBmkimage\fP program boots boards based on Marvell's Kirkwood/Dove
platform over their integrated UART. Boot image files will typically
contain a second stage boot loader, such as U-Boot. The image file
must conform to Marvell's BootROM firmware image format
@@ -68,6 +69,12 @@ If standard I/O streams connect to a console, this mode will terminate
after receiving 'ctrl-\\' followed by 'c' from console input.
.TP
+.BI "\-n"
+Disables the UART boot mode sequence for platforms that do not support
+it (e.g. Dove). Usually, the UART boot mode must be selected by pressing
+a push button on power-up.
+
+.TP
.BI "\-B \fIbaudrate\fP"
Adjust the baud rate on \fITTY\fP. Default rate is 115200.
@@ -72,6 +72,7 @@ BIN_FILES-$(CONFIG_SMDK5250) += mksmdk5250spl$(SFX)
BIN_FILES-$(CONFIG_MX28) += mxsboot$(SFX)
BIN_FILES-$(CONFIG_NETCONSOLE) += ncb$(SFX)
BIN_FILES-$(CONFIG_SHA1_CHECK_UB_IMG) += ubsha1$(SFX)
+BIN_FILES-$(CONFIG_DOVE) += mvboot$(SFX)
BIN_FILES-$(CONFIG_KIRKWOOD) += mvboot$(SFX)
# Source files which exist outside the tools directory
@@ -103,6 +104,7 @@ OBJ_FILES-$(CONFIG_NETCONSOLE) += ncb.o
NOPED_OBJ_FILES-y += os_support.o
OBJ_FILES-$(CONFIG_SHA1_CHECK_UB_IMG) += ubsha1.o
NOPED_OBJ_FILES-y += ublimage.o
+OBJ_FILES-$(CONFIG_DOVE) += mvboot.o
OBJ_FILES-$(CONFIG_KIRKWOOD) += mvboot.o
# Don't build by default
@@ -1,5 +1,5 @@
/*
- * Boot a Marvell Kirkwood SoC, with Xmodem over UART0.
+ * Boot a Marvell Kirkwood and Dove SoCs, with Xmodem over UART0.
*
* (c) 2012 Daniel Stodden <daniel.stodden@gmail.com>
*
@@ -37,6 +37,10 @@ static unsigned char mvboot_msg_boot[] = {
0xBB, 0x11, 0x22, 0x33, 0x44, 0x55, 0x66, 0x77
};
+static unsigned char mvboot_msg_none[] = {
+ 0x00
+};
+
#define MVBOOT_MSG_REQ_DELAY 10 /* ms */
#define MVBOOT_MSG_RSP_TIMEO 50 /* ms */
@@ -268,17 +272,21 @@ mvboot_bootmsg(int tty, void *msg)
int rc;
char c;
- mvboot_printv("Sending boot message. Please reboot the target...");
+ mvboot_printv(msg != mvboot_msg_none
+ ? "Sending boot message. Please reboot the target..."
+ : "Sensing target. Please reboot target into UART mode...");
do {
rc = tcflush(tty, TCIOFLUSH);
if (rc)
break;
- rc = mvboot_tty_send(tty, msg, 8);
- if (rc) {
- usleep(MVBOOT_MSG_REQ_DELAY * 1000);
- continue;
+ if (msg != mvboot_msg_none) {
+ rc = mvboot_tty_send(tty, msg, 8);
+ if (rc) {
+ usleep(MVBOOT_MSG_REQ_DELAY * 1000);
+ continue;
+ }
}
rc = mvboot_tty_recv(tty, &c, 1, MVBOOT_MSG_RSP_TIMEO);
@@ -607,6 +615,7 @@ mvboot_usage(FILE *stream, char *progname)
fprintf(stream, " -b <image>: boot <image>\n");
fprintf(stream, " -p: patch <image> to type 0x69 (uart boot)\n");
fprintf(stream, "\n");
+ fprintf(stream, " -n: don't send boot message\n");
fprintf(stream, " -t: mini terminal\n");
fprintf(stream, "\n");
fprintf(stream, " -B <baud>: set baud rate\n");
@@ -636,7 +645,7 @@ main(int argc, char **argv)
mvboot_verbose = isatty(STDOUT_FILENO);
do {
- int c = getopt(argc, argv, "hb:ptB:");
+ int c = getopt(argc, argv, "hb:nptB:");
if (c < 0)
break;
@@ -646,6 +655,10 @@ main(int argc, char **argv)
imgpath = optarg;
break;
+ case 'n':
+ bootmsg = mvboot_msg_none;
+ break;
+
case 'p':
patch = 1;
break;