@@ -1395,7 +1395,7 @@ static unsigned int ark_hsuart_tx_empty(struct uart_port *port)
{
struct ark_hsuart_port *uap = (struct ark_hsuart_port *)port;
unsigned int status = readw(uap->port.membase + HSUART_UTS);
- return status & HSUART_UTS_TXFE ? 0 : TIOCSER_TEMT;
+ return status & HSUART_UTS_TXFE ? TIOCSER_TEMT : 0;
}
static unsigned int ark_hsuart_get_mctrl(struct uart_port *port)
@@ -2538,6 +2538,7 @@ static int pl011_tx_data(struct uart_amba_port *uap,
while(pl011_read(uap, REG_FR) & UART01x_FR_TXFF);
pl011_write(buf[c], uap, REG_DR);
+ spin_unlock_irqrestore(&uap->port.lock, flags);
return 0;
@@ -125,7 +125,8 @@ static void usb_controller_reset(void)
#define ARK_MMC_CLK 45000000
-struct dwmci_host dwmcihost[2];
+#define ARK_MMC_NUM 3
+struct dwmci_host dwmcihost[ARK_MMC_NUM];
static int ark_dwmci_init(char *name,u32 regbase, int bus_width, int index)
struct dwmci_host *host = NULL;
@@ -128,7 +128,8 @@ static void usb_controller_reset(void)