[lkml]   [2013]   [Feb]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 2/3] regulator: s5m8767: Fix using wrong dev argument at various places
2013/2/8, Mark Brown <>:
> On Wed, Feb 06, 2013 at 10:56:52AM +0800, Axel Lin wrote:
>> Use &pdev->dev rather than iodev->dev for dev_err(), dev_warn() and
>> dev_info().
> It's not clear to me that this is actually an improvement, the pdev is
> mostly just an internal Linux implementation detail so it's common to
> use the physical device for MFD logging in order to help the user
> understand what's causing the log message.

My understanding is if people (at least it's me) found some error message
in dmesg, they usually grep the driver that emit the error message.
If we use the parent device here, people might grep wrong files.

>> Use &pdev->dev rather than iodev->dev for devm_kzalloc() and
>> of_get_regulator_init_data(), this fixes memory leak.
> This is a good fix though. This sort of thing is one reason for
> splitting out unrelated changes.

Ok. I'll resend the patchs (for one topic a patch) a few days latter.
(It's Chinese New Year vacation in Taiwan now.)

 \ /
  Last update: 2013-02-10 12:01    [W:0.098 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site