Re: [RFC][PATCH] of: add a dummy implementation ofof_get_property() in of.h

From: Tobias Klauser
Date: Fri Aug 05 2011 - 05:05:23 EST


On 2011-08-05 at 10:56:14 +0200, Axel Lin <axel.lin@xxxxxxxxx> wrote:
> Then we can avoid having #ifdef CONFIG_OF splattered around the place
> calling of_get_property(), it leads to errors.

You shouldn't redefine of_get_property in the driver. Rather add a
wrapper function to the driver which will extract the device tree
information in CONFIG_OF is enabled and which will just return -ENODEV
if CONFIG_OF is not set.

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