lkml.org 
[lkml]   [2014]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCHv3 9/9] extcon: palmas: Use devm_extcon_dev_allocate for extcon_dev
From
On Thu, Apr 24, 2014 at 11:47 PM, Felipe Balbi <balbi@ti.com> wrote:
> On Thu, Apr 24, 2014 at 09:34:57PM +0900, Chanwoo Choi wrote:
>> This patch use devm_extcon_dev_allocate() to simplify the memory control
>> of extcon device.
>>
>> Cc: Graeme Gregory <gg@slimlogic.co.uk>
>> Cc: Kishon Vijay Abraham I <kishon@ti.com>
>> Cc: Felipe Balbi <balbi@ti.com>
>> Cc: Samuel Ortiz <sameo@linux.intel.com>
>> Cc: Lee Jones <lee.jones@linaro.org>
>> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
>> Acked-by: Lee Jones <lee.jones@linaro.org>
>
> Tested-by: Felipe Balbi <balbi@ti.com>

Thanks for your test.

>
> *BUT* you need to fix NULL vs ERR_PTR return in your code. The way this
> is, we can easily dereference an ERR_PTR because the code doesn't test
> for it. I suggest always returning valid pointer or ERR_PTR and avoid
> returning NULL at all.

OK, as my reply on other mail, I'll fix return type by using ERR_PTR
instead of NULL.

Thanks,
Chanwoo Choi


\
 
 \ /
  Last update: 2014-04-24 18:01    [W:0.162 / U:0.312 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site