lkml.org 
[lkml]   [2008]   [Aug]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCHv3] leds-pca955x: Add proper error handling and fix bogus memory handling
From
Date
On Fri, 2008-08-08 at 09:27 +0200, Sven Wegener wrote:
> Check the return value of led_classdev_register and unregister all
> registered
> devices, if registering one device fails. Also the dynamic memory
> handling is
> totally bogus. You can't allocate multiple chunks via kzalloc() and
> expect them
> to be in order later.
>
> Signed-off-by: Sven Wegener <sven.wegener@stealer.net>

Acked-by: Nate Case <ncase@xes-inc.com>

Thanks for the fix. It looks correct and I tested it on my board with a
pca9553. I also confirmed that the original driver would in fact kernel
Oops if compiled as a module and you rmmod it. With this fix, I can
repeatedly insmod/rmmod successfully.

--
Nate Case <ncase@xes-inc.com>



\
 
 \ /
  Last update: 2008-08-12 22:23    [W:0.118 / U:0.688 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site