Support command line parameters of the form:
earlycon=<name>,io|mmio|mmio32|mmio32be,<addr>,<options>
This commit seem to be needed even after commit:
serial: 8250: Add support for big-endian MMIO accesses
c627f2ceb692e8a9358b64ac2d139314e7bb0d17
Signed-off-by: Noam Camus <noamc@ezchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
                uart[8250],io,<addr>[,options]
                uart[8250],mmio,<addr>[,options]
                uart[8250],mmio32,<addr>[,options]
+               uart[8250],mmio32be,<addr>[,options]
                uart[8250],0x<addr>[,options]
                        Start an early, polled-mode console on the 8250/16550
                        UART at the specified I/O port or MMIO address.
                        MMIO inter-register address stride is either 8-bit
-                       (mmio) or 32-bit (mmio32).
-                       If none of [io|mmio|mmio32], <addr> is assumed to be
-                       equivalent to 'mmio'. 'options' are specified in the
-                       same format described for "console=ttyS<n>"; if
+                       (mmio) or 32-bit (mmio32 or mmio32be).
+                       If none of [io|mmio|mmio32|mmio32be], <addr> is assumed
+                       to be equivalent to 'mmio'. 'options' are specified
+                       in the same format described for "console=ttyS<n>"; if
                        unspecified, the h/w is not initialized.
 
                pl011,<addr>
 
 
        switch (port->iotype) {
        case UPIO_MEM32:
+       case UPIO_MEM32BE:
                port->regshift = 2;     /* fall-through */
        case UPIO_MEM:
                port->mapbase = addr;
                strlcpy(device->options, options, length);
        }
 
-       if (port->iotype == UPIO_MEM || port->iotype == UPIO_MEM32)
+       if (port->iotype == UPIO_MEM || port->iotype == UPIO_MEM32 ||
+           port->iotype == UPIO_MEM32BE)
                pr_info("Early serial console at MMIO%s 0x%llx (options '%s')\n",
-                       (port->iotype == UPIO_MEM32) ? "32" : "",
+                       (port->iotype == UPIO_MEM) ? "" :
+                       (port->iotype == UPIO_MEM32) ? "32" : "32be",
                        (unsigned long long)port->mapbase,
                        device->options);
        else
  *
  *     Registers the earlycon console matching the earlycon specified
  *     in the param string @buf. Acceptable param strings are of the form
- *        <name>,io|mmio|mmio32,<addr>,<options>
+ *        <name>,io|mmio|mmio32|mmio32be,<addr>,<options>
  *        <name>,0x<addr>,<options>
  *        <name>,<options>
  *        <name>
 
  *     @options: ptr for <options> field; NULL if not present (out)
  *
  *     Decodes earlycon kernel command line parameters of the form
- *        earlycon=<name>,io|mmio|mmio32,<addr>,<options>
- *        console=<name>,io|mmio|mmio32,<addr>,<options>
+ *        earlycon=<name>,io|mmio|mmio32|mmio32be,<addr>,<options>
+ *        console=<name>,io|mmio|mmio32|mmio32be,<addr>,<options>
  *
  *     The optional form
  *        earlycon=<name>,0x<addr>,<options>
        } else if (strncmp(p, "mmio32,", 7) == 0) {
                *iotype = UPIO_MEM32;
                p += 7;
+       } else if (strncmp(p, "mmio32be,", 9) == 0) {
+               *iotype = UPIO_MEM32BE;
+               p += 9;
        } else if (strncmp(p, "io,", 3) == 0) {
                *iotype = UPIO_PORT;
                p += 3;