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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 8 Nov 2011 09:18:28 +0530
From:	Viresh Kumar <viresh.kumar@...com>
To:	Linus Walleij <linus.walleij@...aro.org>
Cc:	Rabin VINCENT <rabin.vincent@...ricsson.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"sameo@...ux.intel.com" <sameo@...ux.intel.com>,
	Armando VISCONTI <armando.visconti@...com>,
	Shiraz HASHIM <shiraz.hashim@...com>,
	Vipin KUMAR <vipin.kumar@...com>,
	Rajeev KUMAR <rajeev-dlh.kumar@...com>,
	Deepak SIKRI <deepak.sikri@...com>,
	Vipul Kumar SAMAR <vipulkumar.samar@...com>,
	Amit VIRDI <Amit.VIRDI@...com>,
	Pratyush ANAND <pratyush.anand@...com>,
	Bhupesh SHARMA <bhupesh.sharma@...com>,
	"viresh.linux@...il.com" <viresh.linux@...il.com>,
	Bhavna YADAV <bhavna.yadav@...com>,
	Vincenzo FRASCINO <Vincenzo.FRASCINO@...com>,
	Mirko GARDI <mirko.gardi@...com>,
	Srinidhi KASAGAR <srinidhi.kasagar@...ricsson.com>,
	Linus WALLEIJ <linus.walleij@...ricsson.com>
Subject: Re: [PATCH] mfd/stmpe: Add support for irq over gpio pin

On 11/7/2011 5:59 PM, Linus Walleij wrote:
> On Thu, Nov 3, 2011 at 10:26 AM, Viresh Kumar <viresh.kumar@...com> wrote:

>> +free_gpio:
>> +       gpio_free(pdata->irq_gpio);
> 
> Will that work if you didn't request irq over GPIO?
> 
> If you did not request GPIO and stmpe_chip_init()
> fails this will still be executed.
> 
> Maybe:
> 
> if (pdata->irq_over_gpio)
>    gpio_free(pdata->irq_gpio);
> 

:(
Silly mistake.

>> diff --git a/include/linux/mfd/stmpe.h b/include/linux/mfd/stmpe.h
>> index be1af7c..7901351 100644
>> --- a/include/linux/mfd/stmpe.h
>> +++ b/include/linux/mfd/stmpe.h
>> @@ -76,6 +76,7 @@ struct stmpe {
>>        struct stmpe_variant_info *variant;
>>        const u8 *regs;
>>
>> +       int irq;
>>        int irq_base;
>>        int num_gpios;
>>        u8 ier[2];
>> @@ -194,6 +195,8 @@ struct stmpe_platform_data {
>>        unsigned int irq_trigger;
>>        bool irq_invert_polarity;
>>        bool autosleep;
>> +       bool irq_over_gpio;
>> +       int irq_gpio;
>>        int autosleep_timeout;
> 
> Please also update the kerneldoc for struct stmpe.

Sure.

-- 
viresh
--
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