#include <linux/io.h>
#include <linux/iopoll.h>
#include <linux/mii.h>
-#include <linux/of.h>
#include <linux/of_mdio.h>
#include <linux/phy.h>
+#include <linux/property.h>
#include <linux/slab.h>
#include "dwxgmac2.h"
struct gpio_desc *reset_gpio;
if (data->reset_gpio < 0) {
- struct device_node *np = priv->device->of_node;
-
reset_gpio = devm_gpiod_get_optional(priv->device,
"snps,reset",
GPIOD_OUT_LOW);
if (IS_ERR(reset_gpio))
return PTR_ERR(reset_gpio);
- of_property_read_u32_array(np,
- "snps,reset-delays-us", data->delays, 3);
+ device_property_read_u32_array(priv->device,
+ "snps,reset-delays-us",
+ data->delays, 3);
} else {
reset_gpio = gpio_to_desc(data->reset_gpio);