* [PATCH] Input: h3600_ts_input - bugfix for request_irq()/free_irq() parameters
@ 2011-04-13 12:37 Axel Lin
2011-04-28 16:26 ` Dmitry Torokhov
0 siblings, 1 reply; 4+ messages in thread
From: Axel Lin @ 2011-04-13 12:37 UTC (permalink / raw)
To: linux-kernel; +Cc: Dmitry Torokhov, linux-input
The dev field of h3600_dev is a pointer, thus use ts->dev instead of &ts->dev
as the dev_id argument while calling request_irq()/free_irq().
Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
drivers/input/touchscreen/h3600_ts_input.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/input/touchscreen/h3600_ts_input.c b/drivers/input/touchscreen/h3600_ts_input.c
index 45f93d0..211811a 100644
--- a/drivers/input/touchscreen/h3600_ts_input.c
+++ b/drivers/input/touchscreen/h3600_ts_input.c
@@ -396,14 +396,14 @@ static int h3600ts_connect(struct serio *serio, struct serio_driver *drv)
set_GPIO_IRQ_edge(GPIO_BITSY_NPOWER_BUTTON, GPIO_RISING_EDGE);
if (request_irq(IRQ_GPIO_BITSY_ACTION_BUTTON, action_button_handler,
- IRQF_SHARED | IRQF_DISABLED, "h3600_action", &ts->dev)) {
+ IRQF_SHARED | IRQF_DISABLED, "h3600_action", ts->dev)) {
printk(KERN_ERR "h3600ts.c: Could not allocate Action Button IRQ!\n");
err = -EBUSY;
goto fail1;
}
if (request_irq(IRQ_GPIO_BITSY_NPOWER_BUTTON, npower_button_handler,
- IRQF_SHARED | IRQF_DISABLED, "h3600_suspend", &ts->dev)) {
+ IRQF_SHARED | IRQF_DISABLED, "h3600_suspend", ts->dev)) {
printk(KERN_ERR "h3600ts.c: Could not allocate Power Button IRQ!\n");
err = -EBUSY;
goto fail2;
@@ -439,8 +439,8 @@ static void h3600ts_disconnect(struct serio *serio)
{
struct h3600_dev *ts = serio_get_drvdata(serio);
- free_irq(IRQ_GPIO_BITSY_ACTION_BUTTON, &ts->dev);
- free_irq(IRQ_GPIO_BITSY_NPOWER_BUTTON, &ts->dev);
+ free_irq(IRQ_GPIO_BITSY_ACTION_BUTTON, ts->dev);
+ free_irq(IRQ_GPIO_BITSY_NPOWER_BUTTON, ts->dev);
input_get_device(ts->dev);
input_unregister_device(ts->dev);
serio_close(serio);
--
1.7.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] Input: h3600_ts_input - bugfix for request_irq()/free_irq() parameters
2011-04-13 12:37 [PATCH] Input: h3600_ts_input - bugfix for request_irq()/free_irq() parameters Axel Lin
@ 2011-04-28 16:26 ` Dmitry Torokhov
2011-05-01 16:23 ` Axel Lin
0 siblings, 1 reply; 4+ messages in thread
From: Dmitry Torokhov @ 2011-04-28 16:26 UTC (permalink / raw)
To: Axel Lin; +Cc: linux-kernel, linux-input
On Wed, Apr 13, 2011 at 08:37:11PM +0800, Axel Lin wrote:
> The dev field of h3600_dev is a pointer, thus use ts->dev instead of &ts->dev
> as the dev_id argument while calling request_irq()/free_irq().
dev_id does not need to have specific type, it is just a cookie so as
long as it's value is unique we are OK. &ts->dev works as well as
ts->dev.
Thanks.
--
Dmitry
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Input: h3600_ts_input - bugfix for request_irq()/free_irq() parameters
2011-04-28 16:26 ` Dmitry Torokhov
@ 2011-05-01 16:23 ` Axel Lin
2011-05-01 16:50 ` Dmitry Torokhov
0 siblings, 1 reply; 4+ messages in thread
From: Axel Lin @ 2011-05-01 16:23 UTC (permalink / raw)
To: Dmitry Torokhov; +Cc: linux-kernel, linux-input
Hi Dmitry,
2011/4/29 Dmitry Torokhov <dmitry.torokhov@gmail.com>:
> On Wed, Apr 13, 2011 at 08:37:11PM +0800, Axel Lin wrote:
>> The dev field of h3600_dev is a pointer, thus use ts->dev instead of &ts->dev
>> as the dev_id argument while calling request_irq()/free_irq().
>
> dev_id does not need to have specific type, it is just a cookie so as
> long as it's value is unique we are OK. &ts->dev works as well as
> ts->dev.
Then you might want to apply below patch:
http://www.spinics.net/lists/linux-input/msg15042.html
My original intension was to fix the irq driver data mismatch.
Regards,
Axel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Input: h3600_ts_input - bugfix for request_irq()/free_irq() parameters
2011-05-01 16:23 ` Axel Lin
@ 2011-05-01 16:50 ` Dmitry Torokhov
0 siblings, 0 replies; 4+ messages in thread
From: Dmitry Torokhov @ 2011-05-01 16:50 UTC (permalink / raw)
To: Axel Lin; +Cc: linux-kernel, linux-input
On Mon, May 02, 2011 at 12:23:43AM +0800, Axel Lin wrote:
> Hi Dmitry,
>
> 2011/4/29 Dmitry Torokhov <dmitry.torokhov@gmail.com>:
> > On Wed, Apr 13, 2011 at 08:37:11PM +0800, Axel Lin wrote:
> >> The dev field of h3600_dev is a pointer, thus use ts->dev instead of &ts->dev
> >> as the dev_id argument while calling request_irq()/free_irq().
> >
> > dev_id does not need to have specific type, it is just a cookie so as
> > long as it's value is unique we are OK. &ts->dev works as well as
> > ts->dev.
>
> Then you might want to apply below patch:
> http://www.spinics.net/lists/linux-input/msg15042.html
>
> My original intension was to fix the irq driver data mismatch.
>
Ah, I see. Then I'll apply it but with teh above as commit message.
--
Dmitry
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2011-05-01 16:59 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-13 12:37 [PATCH] Input: h3600_ts_input - bugfix for request_irq()/free_irq() parameters Axel Lin
2011-04-28 16:26 ` Dmitry Torokhov
2011-05-01 16:23 ` Axel Lin
2011-05-01 16:50 ` Dmitry Torokhov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).