[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1474837245-32512-1-git-send-email-robert.jarzmik@free.fr>
Date: Sun, 25 Sep 2016 23:00:45 +0200
From: Robert Jarzmik <robert.jarzmik@...e.fr>
To: Nicolas Pitre <nico@...xnic.net>,
"David S. Miller" <davem@...emloft.net>
Cc: netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
Robert Jarzmik <robert.jarzmik@...e.fr>
Subject: [PATCH] net: smc91x: take into account register shift
This aligns smc91x with its cousin, namely smc911x.c.
This also allows the driver to run also in a device-tree based lubbock
board build, on which it was tested.
Signed-off-by: Robert Jarzmik <robert.jarzmik@...e.fr>
---
drivers/net/ethernet/smsc/smc91x.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ethernet/smsc/smc91x.c b/drivers/net/ethernet/smsc/smc91x.c
index 726b80f45906..77ad2a3f59db 100644
--- a/drivers/net/ethernet/smsc/smc91x.c
+++ b/drivers/net/ethernet/smsc/smc91x.c
@@ -2316,6 +2316,9 @@ static int smc_drv_probe(struct platform_device *pdev)
} else {
lp->cfg.flags |= SMC91X_USE_16BIT;
}
+ if (!device_property_read_u32(&pdev->dev, "reg-shift",
+ &val))
+ lp->io_shift = val;
}
#endif
--
2.1.4
Powered by blists - more mailing lists