summaryrefslogtreecommitdiffstats
path: root/drivers/net/stmmac/stmmac_main.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/stmmac/stmmac_main.c')
-rw-r--r--drivers/net/stmmac/stmmac_main.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/net/stmmac/stmmac_main.c b/drivers/net/stmmac/stmmac_main.c
index cbe2404223d..dfeea96f681 100644
--- a/drivers/net/stmmac/stmmac_main.c
+++ b/drivers/net/stmmac/stmmac_main.c
@@ -1581,10 +1581,13 @@ static int stmmac_mac_device_setup(struct net_device *dev)
struct mac_device_info *device;
- if (priv->is_gmac)
+ if (priv->is_gmac) {
device = dwmac1000_setup(ioaddr);
- else
+ device->desc = &enh_desc_ops;
+ } else {
device = dwmac100_setup(ioaddr);
+ device->desc = &ndesc_ops;
+ }
if (!device)
return -ENOMEM;