diff options
Diffstat (limited to 'drivers/tty/serial/imx.c')
| -rw-r--r-- | drivers/tty/serial/imx.c | 16 | 
1 files changed, 3 insertions, 13 deletions
| diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c index 8257597d034d..7d5a8dfa3e91 100644 --- a/drivers/tty/serial/imx.c +++ b/drivers/tty/serial/imx.c @@ -394,11 +394,7 @@ static void imx_uart_rts_inactive(struct imx_port *sport, u32 *ucr2)  static void start_hrtimer_ms(struct hrtimer *hrt, unsigned long msec)  { -       long sec = msec / MSEC_PER_SEC; -       long nsec = (msec % MSEC_PER_SEC) * 1000000; -       ktime_t t = ktime_set(sec, nsec); - -       hrtimer_start(hrt, t, HRTIMER_MODE_REL); +       hrtimer_start(hrt, ms_to_ktime(msec), HRTIMER_MODE_REL);  }  /* called with port.lock taken and irqs off */ @@ -922,14 +918,8 @@ static irqreturn_t imx_uart_int(int irq, void *dev_id)  	struct imx_port *sport = dev_id;  	unsigned int usr1, usr2, ucr1, ucr2, ucr3, ucr4;  	irqreturn_t ret = IRQ_NONE; -	unsigned long flags = 0; -	/* -	 * IRQs might not be disabled upon entering this interrupt handler, -	 * e.g. when interrupt handlers are forced to be threaded. To support -	 * this scenario as well, disable IRQs when acquiring the spinlock. -	 */ -	spin_lock_irqsave(&sport->port.lock, flags); +	spin_lock(&sport->port.lock);  	usr1 = imx_uart_readl(sport, USR1);  	usr2 = imx_uart_readl(sport, USR2); @@ -999,7 +989,7 @@ static irqreturn_t imx_uart_int(int irq, void *dev_id)  		ret = IRQ_HANDLED;  	} -	spin_unlock_irqrestore(&sport->port.lock, flags); +	spin_unlock(&sport->port.lock);  	return ret;  } | 
