[PATCH] net: dm9000: Allow instantiation using device tree
Francois Romieu
romieu at fr.zoreil.com
Sun May 19 04:38:22 EDT 2013
Sascha Hauer <s.hauer at pengutronix.de> :
[...]
> > +#ifdef CONFIG_OF
> > +static struct dm9000_plat_data *dm9000_parse_dt(struct device *dev)
> > +{
> > + struct dm9000_plat_data *pdata;
> > + struct device_node *np = dev->of_node;
> > + const void *prop;
> > + int len;
> > +
> > + if (!np)
> > + return NULL;
>
> You should be able to kill the ifdef around this function by doing
>
> if (!IS_ENABLED(CONFIG_OF) || !np)
> return NULL;
It will be the first such use of IS_ENABLED in net land.
David, is it ok ?
--
Ueimor
More information about the linux-arm-kernel
mailing list