Re: [PATCH] tty: serial: sc16is7xx: implemented our own oneshot-like handling

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

 





On 2016-03-13 11:25, Thomas Gleixner wrote:
On Fri, 11 Mar 2016, Sean Nyekjaer wrote:

  static irqreturn_t sc16is7xx_irq(int irq, void *dev_id)
  {
  	struct sc16is7xx_port *s = (struct sc16is7xx_port *)dev_id;
+	int i;
+
+	for (i = 0; i < s->devtype->nr_uart; ++i)
+		disable_irq_nosync(s->p[i].port.irq);
Aside of the lack of a changelog. This is completely bogus. You disable the
same interrupt a gazillion of times.
I can't see why the interrupt is disabled a gazillion times.
When the irq is disabled the function will not be called before it's enabled again... Or have i missed something?
  	queue_kthread_work(&s->kworker, &s->irq_work);
This driver should use a threaded interrupt instead of trying to emulate it
via dis/enable_irq and a worker thread.
I agree, I and "Sebastian Andrzej Siewior" have proposed this fix, but it was turned down. :-)

Then you simply call c16is7xx_port_irq() right from the interrupt routine and
the core code deals with the interrupt mask/unmask automatically.

Thanks,

	tglx

/Sean
--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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