lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <55B7DE43.9090008@synaptics.com>
Date:	Tue, 28 Jul 2015 12:55:47 -0700
From:	Andrew Duggan <aduggan@...aptics.com>
To:	Mika Westerberg <mika.westerberg@...ux.intel.com>
CC:	<linux-input@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
	Jiri Kosina <jkosina@...e.cz>,
	Benjamin Tissoires <benjamin.tissoires@...hat.com>
Subject: Re: [PATCH] HID: i2c-hid: Only disable irq wake if it was successfully
 enabled during suspend

On 07/28/2015 04:33 AM, Mika Westerberg wrote:
> On Mon, Jul 27, 2015 at 05:08:06PM -0700, Andrew Duggan wrote:
>> On at least one platform the kernel prints a warning on resume saying
>> "Unbalanced IRQ 37 wake disable". This is because enable_irq_wake in the
>> suspend function is failing. This patch checks to see if the call to
>> enable_irq_wake succeeded before calling disable_irq_wake.
> While this looks okay, I'm wondering if this can also be fixed from the
> irq chip side by setting IRQCHIP_SKIP_SET_WAKE to .flags, given that the
> driver does not provide such function?

Yes, setting IRQCHIP_SKIP_SET_WAKE does fix the problem. After looking 
into it a bit more it turns out commit 5613570 already fixed the issue. 
My test system was running an older kernel which didn't include it. 
Applying 5613570 fixed this particular issue. Thanks for pointing that 
out, now I have a better understanding of why enable_irq_wake was 
failing in this instance.

For this patch, I think it is still a good idea to check the return code 
of enable_irq_wake. In theory, an irqchip which does have a irq_set_wake 
callback set could return an error. I can update the commit comment, add 
a warning, and submit a v2.

Thanks,
Andrew
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ