* [PATCH] driver/misc/fsa9480.c fix potential null-pointer dereference
@ 2011-07-26 8:19 jhbird.choi
2011-08-27 0:18 ` Andrew Morton
0 siblings, 1 reply; 2+ messages in thread
From: jhbird.choi @ 2011-07-26 8:19 UTC (permalink / raw)
To: linux-kernel; +Cc: Donggeun Kim, Andrew Morton, Kyungmin Park, Jonghwan Choi
From: Jonghwan Choi <jhbird.choi@samsung.com>
Signed-off-by: Jonghwan Choi <jhbird.choi@samsung.com>
---
drivers/misc/fsa9480.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/misc/fsa9480.c b/drivers/misc/fsa9480.c
index 5325a7e..0bd1e5b 100644
--- a/drivers/misc/fsa9480.c
+++ b/drivers/misc/fsa9480.c
@@ -400,7 +400,8 @@ static int fsa9480_irq_init(struct fsa9480_usbsw *usbsw)
return ret;
}
- device_init_wakeup(&client->dev, pdata->wakeup);
+ if (pdata)
+ device_init_wakeup(&client->dev, pdata->wakeup);
}
return 0;
--
1.7.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] driver/misc/fsa9480.c fix potential null-pointer dereference
2011-07-26 8:19 [PATCH] driver/misc/fsa9480.c fix potential null-pointer dereference jhbird.choi
@ 2011-08-27 0:18 ` Andrew Morton
0 siblings, 0 replies; 2+ messages in thread
From: Andrew Morton @ 2011-08-27 0:18 UTC (permalink / raw)
To: jhbird.choi; +Cc: linux-kernel, Donggeun Kim, Kyungmin Park
On Tue, 26 Jul 2011 17:19:35 +0900
jhbird.choi@samsung.com wrote:
> From: Jonghwan Choi <jhbird.choi@samsung.com>
>
> Signed-off-by: Jonghwan Choi <jhbird.choi@samsung.com>
> ---
> drivers/misc/fsa9480.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/misc/fsa9480.c b/drivers/misc/fsa9480.c
> index 5325a7e..0bd1e5b 100644
> --- a/drivers/misc/fsa9480.c
> +++ b/drivers/misc/fsa9480.c
> @@ -400,7 +400,8 @@ static int fsa9480_irq_init(struct fsa9480_usbsw *usbsw)
> return ret;
> }
>
> - device_init_wakeup(&client->dev, pdata->wakeup);
> + if (pdata)
> + device_init_wakeup(&client->dev, pdata->wakeup);
> }
>
> return 0;
So i2c_client.dev.platform_data was NULL. Is this an allowed state?
What would cause this?
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-08-27 0:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-07-26 8:19 [PATCH] driver/misc/fsa9480.c fix potential null-pointer dereference jhbird.choi
2011-08-27 0:18 ` Andrew Morton
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.