Re: [PATCH 07/11] net/stmmac: mark probe function as __devinit

From: David Miller
Date: Wed Aug 08 2012 - 19:09:06 EST


From: Arnd Bergmann <arnd@xxxxxxxx>
Date: Wed, 8 Aug 2012 16:47:24 +0200

> Driver probe functions are generally __devinit so they will be
> discarded after initialization for non-hotplug kernels.
> This was found by a new warning after patch 6a228452d "stmmac: Add
> device-tree support" adds a new __devinit function that is called
> from stmmac_pltfr_probe.
>
> Without this patch, building socfpga_defconfig results in:
>
> WARNING: drivers/net/ethernet/stmicro/stmmac/stmmac.o(.text+0x5d4c): Section mismatch in reference from the function stmmac_pltfr_probe() to the function .devinit.text:stmmac_probe_config_dt()
> The function stmmac_pltfr_probe() references
> the function __devinit stmmac_probe_config_dt().
> This is often because stmmac_pltfr_probe lacks a __devinit
> annotation or the annotation of stmmac_probe_config_dt is wrong.
>
> Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx>
> Cc: Stefan Roese <sr@xxxxxxx>
> Cc: Giuseppe Cavallaro <peppe.cavallaro@xxxxxx>
> Cc: David S. Miller <davem@xxxxxxxxxxxxx>
> Cc: netdev@xxxxxxxxxxxxxxx

Applied, thanks.
--
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/