net: ethernet: lpc_eth: remove CONFIG_OF guard from the driver
authorVladimir Zapolskiy <vz@mleia.com>
Thu, 18 Oct 2018 22:58:41 +0000 (01:58 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sat, 20 Oct 2018 00:04:38 +0000 (17:04 -0700)
The MAC controller device is available on NXP LPC32xx platform only,
and the LPC32xx platform supports OF builds only, so additional
checks in the device driver are not needed.

Signed-off-by: Vladimir Zapolskiy <vz@mleia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/nxp/lpc_eth.c

index 5eb2aacf60d9774ce8f6099fff0b2ec85ce03f1d..7128cd05f79ce8be45dae131e98bcffbd48f7c7a 100644 (file)
@@ -1517,13 +1517,11 @@ static int lpc_eth_drv_resume(struct platform_device *pdev)
 }
 #endif
 
-#ifdef CONFIG_OF
 static const struct of_device_id lpc_eth_match[] = {
        { .compatible = "nxp,lpc-eth" },
        { }
 };
 MODULE_DEVICE_TABLE(of, lpc_eth_match);
-#endif
 
 static struct platform_driver lpc_eth_driver = {
        .probe          = lpc_eth_drv_probe,
@@ -1534,7 +1532,7 @@ static struct platform_driver lpc_eth_driver = {
 #endif
        .driver         = {
                .name   = MODNAME,
-               .of_match_table = of_match_ptr(lpc_eth_match),
+               .of_match_table = lpc_eth_match,
        },
 };