summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorPhilip Craig <philipc@snapgear.com>2006-06-21 03:33:26 +0200
committerJeff Garzik <jeff@garzik.org>2006-06-23 05:20:29 +0200
commitd73f1e3c3b0703e25728ce5bdda9806d6f2c576f (patch)
tree5bb928aa9d053bf14cc5a2a2eeb63e6ffa6160d6 /drivers
parent[PATCH] b44: update b44 Kconfig entry (diff)
downloadlinux-d73f1e3c3b0703e25728ce5bdda9806d6f2c576f.tar.xz
linux-d73f1e3c3b0703e25728ce5bdda9806d6f2c576f.zip
[PATCH] 8139cp: fix eeprom read command length
The read command for the 93C46/93C56 EEPROMS should be 3 bits plus the address. This doesn't appear to affect the operation of the read command, but similar errors for write commands do cause failures. Signed-off-by: Philip Craig <philipc@snapgear.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/8139cp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/8139cp.c b/drivers/net/8139cp.c
index 46d8c01437e9..b49be8f2c107 100644
--- a/drivers/net/8139cp.c
+++ b/drivers/net/8139cp.c
@@ -1628,7 +1628,7 @@ static int read_eeprom (void __iomem *ioaddr, int location, int addr_len)
eeprom_delay ();
/* Shift the read command bits out. */
- for (i = 4 + addr_len; i >= 0; i--) {
+ for (i = 3 + addr_len - 1; i >= 0; i--) {
int dataval = (read_cmd & (1 << i)) ? EE_DATA_WRITE : 0;
writeb (EE_ENB | dataval, ee_addr);
eeprom_delay ();