phy: Use device_get_match_data()
[linux-2.6-microblaze.git] / drivers / phy / marvell / phy-berlin-usb.c
index 78ef6ae..f26bf63 100644 (file)
@@ -8,9 +8,10 @@
 
 #include <linux/io.h>
 #include <linux/module.h>
-#include <linux/of_device.h>
+#include <linux/of.h>
 #include <linux/phy/phy.h>
 #include <linux/platform_device.h>
+#include <linux/property.h>
 #include <linux/reset.h>
 
 #define USB_PHY_PLL            0x04
@@ -162,8 +163,6 @@ MODULE_DEVICE_TABLE(of, phy_berlin_usb_of_match);
 
 static int phy_berlin_usb_probe(struct platform_device *pdev)
 {
-       const struct of_device_id *match =
-               of_match_device(phy_berlin_usb_of_match, &pdev->dev);
        struct phy_berlin_usb_priv *priv;
        struct phy *phy;
        struct phy_provider *phy_provider;
@@ -180,7 +179,7 @@ static int phy_berlin_usb_probe(struct platform_device *pdev)
        if (IS_ERR(priv->rst_ctrl))
                return PTR_ERR(priv->rst_ctrl);
 
-       priv->pll_divider = *((u32 *)match->data);
+       priv->pll_divider = *((u32 *)device_get_match_data(&pdev->dev));
 
        phy = devm_phy_create(&pdev->dev, NULL, &phy_berlin_usb_ops);
        if (IS_ERR(phy)) {