Re: [PATCH 2/2] regulator: max8660: Add error message for missing regulator data

From: Wolfram Sang
Date: Tue Mar 24 2015 - 08:37:58 EST



> 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;
> + }

I'd rather save the string and go for -ENOENT instead. But I don't mind
much...

Attachment: signature.asc
Description: Digital signature