Re: [PATCH v4 7/8] hwmon: pwm-fan: Read PWM FAN configuration from device tree

Guenter Roeck
2015-02-23T16:23:05Z

On Mon, Feb 23, 2015 at 05:13:36PM +0100, Lukasz Majewski wrote:
> Hi Guenter,
>
[ ... ]

> >
> > If devicetree is not configured, of_property_count_elems_of_size
> > returns -ENOSYS, which is returned, causing the driver to fail
> > loading.
>
> Has of_property_count_elems_of_size() returns -ENOSYS?
>
> Maybe something has changed, but in my linux-vanila (3.19-rc4)
> at ./drivers/of/base.c it returns -EINVAL, -ENODATA or number of
> elements.
>
> Have I missed something?
>
Hi Lukasz,

Yes, you have. Check include/linux/of.h, line 484, in latest mainline.

Guenter