From d7863de8cdea75c9a4747621b1587fc70855460c Mon Sep 17 00:00:00 2001 From: Hans Ulli Kroll Date: Thu, 13 Jun 2019 17:07:35 +0200 Subject: usb: host: fotg2: add device tree probing Add device tree probing to the fotg2 driver. Signed-off-by: Hans Ulli Kroll [Drop DMA mask coercion, drivers/of/platform.c does the job] Signed-off-by: Linus Walleij Signed-off-by: Greg Kroah-Hartman --- drivers/usb/host/fotg210-hcd.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'drivers/usb/host/fotg210-hcd.c') diff --git a/drivers/usb/host/fotg210-hcd.c b/drivers/usb/host/fotg210-hcd.c index 0da68df259c8..e835a22b12af 100644 --- a/drivers/usb/host/fotg210-hcd.c +++ b/drivers/usb/host/fotg210-hcd.c @@ -10,6 +10,7 @@ * Most of code borrowed from the Linux-3.7 EHCI driver */ #include +#include #include #include #include @@ -5669,9 +5670,18 @@ static int fotg210_hcd_remove(struct platform_device *pdev) return 0; } +#ifdef CONFIG_OF +static const struct of_device_id fotg210_of_match[] = { + { .compatible = "faraday,fotg210" }, + {}, +}; +MODULE_DEVICE_TABLE(of, fotg210_of_match); +#endif + static struct platform_driver fotg210_hcd_driver = { .driver = { .name = "fotg210-hcd", + .of_match_table = of_match_ptr(fotg210_of_match), }, .probe = fotg210_hcd_probe, .remove = fotg210_hcd_remove, -- cgit v1.2.3