On 10/08/2013 05:09 PM, Mark Brown wrote:
> * PGP Signed by an unknown key
> 
> On Tue, Oct 08, 2013 at 02:09:02PM +0800, Wei Ni wrote:
> 
>> In the latest regulator framework, it default to provide dummy
>> regulators with full constraints by your patch "regulator: core: Provide
>> a dummy regulator with full constraints".
> 
>> I tried to use regulator_get() on lm90.c. If not set vcc-supply property
>> in the dts file to assume the regulator is physically present and
>> enabled, but it still can't get dummy regulator, just return -ENODEV.
>> I traced it, the regulator_dev_lookup() will return -ENODEV, and at that
>> time the has_full_constraints is still false, didn't be initialized in
>> regulator_init_complete() yet, so it will not return dummy regulator,
>> and will not return -EPROBE_DEFER either. This will cause the
>> lm90_probe() failed.
> 
>> Could you take a look ?
> 
> Could you take a look at why we're getting -ENODEV please - this
> indicates a problem with the device tree code since it should be what's
> requesting probe deferral when it sees a link is present.

In the regulator_dev_lookup(), it will try to read the "xx-supply" to
get the regnode, but I didn't set the vcc-supply in dts file for lm90,
so the of_get_regulator() will return NULL, then the
regulator_dev_lookup() will set the ret to -ENODEV, and return the rdev
as NULL.

Thanks.
Wei.

> 
> * Unknown Key
> * 0x7EA229BD
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to