[PATCH] arm: mach-omap2: potential NULL dereference

2011-01-17 Thread Vasiliy Kulikov
If kzalloc() failed, return -ENOMEM. sr_dev_init() should signal by return value that there is an error. Signed-off-by: Vasiliy Kulikov --- Cannot compile this driver, so it is not tested at all. arch/arm/mach-omap2/sr_device.c | 19 +++ 1 files changed, 15 insertions(+), 4 d

[PATCH] arm: mach-omap2: potential NULL dereference

2011-01-17 Thread Vasiliy Kulikov
kzalloc() may fail, if so return -ENOMEM. Signed-off-by: Vasiliy Kulikov --- Cannot compile this driver, so it is not tested at all. arch/arm/mach-omap2/smartreflex.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/smartreflex.c b/arch/arm/mach-o

Re: [PATCH] arm: mach-omap2: potential NULL dereference

2011-01-17 Thread walter harms
Am 17.01.2011 11:08, schrieb Vasiliy Kulikov: > kzalloc() may fail, if so return -ENOMEM. > > Signed-off-by: Vasiliy Kulikov > --- > Cannot compile this driver, so it is not tested at all. > > arch/arm/mach-omap2/smartreflex.c |3 +++ > 1 files changed, 3 insertions(+), 0 deletions(-) >

Re: [PATCH] arm: mach-omap2: potential NULL dereference

2011-01-17 Thread Sergei Shtylyov
Hello. On 17-01-2011 13:08, Vasiliy Kulikov wrote: kzalloc() may fail, if so return -ENOMEM. Signed-off-by: Vasiliy Kulikov [...] diff --git a/arch/arm/mach-omap2/smartreflex.c b/arch/arm/mach-omap2/smartreflex.c index 77ecebf..871bca9 100644 --- a/arch/arm/mach-omap2/smartreflex.c +++ b