The function ftmac100_probe() is only called with an openfirmware platform device. Therefore there is no need to check that the passed in device is NULL.
Signed-off-by: Zhang Shengju <zhangshen...@cmss.chinamobile.com> Signed-off-by: Tang Bin <tang...@cmss.chinamobile.com> --- drivers/net/ethernet/faraday/ftmac100.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/faraday/ftmac100.c b/drivers/net/ethernet/faraday/ftmac100.c index 6c247cbbd..2be173b03 100644 --- a/drivers/net/ethernet/faraday/ftmac100.c +++ b/drivers/net/ethernet/faraday/ftmac100.c @@ -1059,9 +1059,6 @@ static int ftmac100_probe(struct platform_device *pdev) struct ftmac100 *priv; int err; - if (!pdev) - return -ENODEV; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); if (!res) return -ENXIO; -- 2.20.1.windows.1