Message ID | 1304608693-28943-1-git-send-email-shawn.guo@linaro.org |
---|---|
State | New |
Headers | show |
diff --git a/drivers/net/fec.c b/drivers/net/fec.c index 65112a1..40b2a26 100644 --- a/drivers/net/fec.c +++ b/drivers/net/fec.c @@ -1376,7 +1376,7 @@ fec_probe(struct platform_device *pdev) struct resource *r; const struct of_device_id *of_id; - of_id = of_match_device(fec_dt_ids, &pdev->dev); + of_id = pdev->dev.of_match; if (of_id) pdev->id_entry = (struct platform_device_id *)of_id->data;
After fec dt support is added, the following compile error will be seen when building a pure non-dt kernel. drivers/net/fec.c: In function ‘fec_probe’: drivers/net/fec.c:1383: error: implicit declaration of function ‘of_match_device’ drivers/net/fec.c:1383: warning: assignment makes pointer from integer without a cast This patch is to fix the error. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> --- Changes since v1: * Use of_match pointer newly added to struct device to fix the error drivers/net/fec.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)