We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 48f5cde commit 50d1e7dCopy full SHA for 50d1e7d
drivers/tty/serial/pxa.c
@@ -223,6 +223,7 @@ static void serial_pxa_start_tx(struct uart_port *port)
223
}
224
225
226
+/* should hold up->port.lock */
227
static inline void check_modem_status(struct uart_pxa_port *up)
228
{
229
int status;
@@ -255,12 +256,14 @@ static inline irqreturn_t serial_pxa_irq(int irq, void *dev_id)
255
256
iir = serial_in(up, UART_IIR);
257
if (iir & UART_IIR_NO_INT)
258
return IRQ_NONE;
259
+ spin_lock(&up->port.lock);
260
lsr = serial_in(up, UART_LSR);
261
if (lsr & UART_LSR_DR)
262
receive_chars(up, &lsr);
263
check_modem_status(up);
264
if (lsr & UART_LSR_THRE)
265
transmit_chars(up);
266
+ spin_unlock(&up->port.lock);
267
return IRQ_HANDLED;
268
269
0 commit comments