Re: [PATCH] tty: serial: replace spin_lock_irqsave by spin_lock in hard IRQ

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 19. 11. 20, 10:01, Tian Tao wrote:
The code has been in a irq-disabled context since it is hard IRQ. There
is no necessity to do it again.

Signed-off-by: Tian Tao <tiantao6@xxxxxxxxxxxxx>

Reviewed-by: Jiri Slaby <jirislaby@xxxxxxxxxx>

---
  drivers/tty/serial/owl-uart.c | 5 ++---
  1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/tty/serial/owl-uart.c b/drivers/tty/serial/owl-uart.c
index c149f8c3..472fdaf 100644
--- a/drivers/tty/serial/owl-uart.c
+++ b/drivers/tty/serial/owl-uart.c
@@ -251,10 +251,9 @@ static void owl_uart_receive_chars(struct uart_port *port)
  static irqreturn_t owl_uart_irq(int irq, void *dev_id)
  {
  	struct uart_port *port = dev_id;
-	unsigned long flags;
  	u32 stat;
- spin_lock_irqsave(&port->lock, flags);
+	spin_lock(&port->lock);
stat = owl_uart_read(port, OWL_UART_STAT); @@ -268,7 +267,7 @@ static irqreturn_t owl_uart_irq(int irq, void *dev_id)
  	stat |= OWL_UART_STAT_RIP | OWL_UART_STAT_TIP;
  	owl_uart_write(port, stat, OWL_UART_STAT);
- spin_unlock_irqrestore(&port->lock, flags);
+	spin_unlock(&port->lock);
return IRQ_HANDLED;
  }



--
js
suse labs



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux