RE: Unbalanced IRQ wake disable during resume from static suspend

Santosh Shilimkar
2010-12-03T11:08:10Z

> -----Original Message-----
> From: Paul Walmsley [mailto:paul@pwsan.com]
> Sent: Friday, December 03, 2010 3:53 PM
> To: Santosh Shilimkar
> Cc: linux-omap@vger.kernel.org; Govindraj; khilman@deeprootsystems.com
> Subject: RE: Unbalanced IRQ wake disable during resume from static
suspend
>
> Hello Santosh
>
> On Thu, 2 Dec 2010, Santosh Shilimkar wrote:
>
> > Just a wild guess here but is this because the 'set_wake' is
> > not setup and then fw might be returning some error whenever
> > driver invoke this API as part of enable_irq_wake() callback
> >
> > If that being the case, below patch might might help. Can
> > somebody try this out ?
>
> This patch might remove the warnings, but I doubt that it solves the
root
> cause. In any case, it doesn't seem correct to unconditionally return 0
> (success) from an omap_irq_wake() function, given that the OMAP INTC has
> no functionality in this regard.
>
> The real problem appears to be in drivers/serial/serial_core.c.
> uart_suspend_port() doesn't check the return value of enable_irq_wake().
> Seems to me that it needs to save that return value somewhere and not
> bother calling disable_irq_wake() in uart_resume_port() if
> enable_irq_wake() returned an error.
>
> That's the patch that I'd suggest that you guys put together and send to
> the Linux serial people.
>
You are right Paul. This will actually fix the broken driver rather than
masking it. Will spin a patch for the same