lkml.org 
[lkml]   [2015]   [Mar]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] regulator: max8660: Add error message for missing regulator data
On Tue, Mar 24, 2015 at 01:08:03PM +0100, Markus Pargmann wrote:
> The driver probe fails when there is a subdevice without platform_data.
> Add a error message so it is clear what failed.

...

> for (i = 0; i < pdata->num_subdevs; i++) {
> - if (!pdata->subdevs[i].platform_data)
> + if (!pdata->subdevs[i].platform_data) {
> + dev_err(dev, "No data for %d regulator\n", i);
> return -EINVAL;
> + }

Why is the platform data mandatory? In general the goal is that a
regulator driver should be able to probe with no platform data.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2015-03-24 17:21    [W:0.050 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site