aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/sfc/ethtool.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2009-11-29 10:10:44 -0500
committerDavid S. Miller <davem@davemloft.net>2009-11-29 20:23:54 -0500
commit76884835684411264cda2f15585261eb02183541 (patch)
tree585b42235745acf3bf161838b14682428175e670 /drivers/net/sfc/ethtool.c
parentc1c4f453b61463df4df16f7aa5782fc0cfe05b9e (diff)
sfc: Extend MTD driver for use with new NICs
In new NICs flash is managed by firmware and we will use high-level operations on partitions rather than direct SPI commands. Add support for multiple MTD partitions per flash device and remove the direct link between MTD and SPI devices. Maintain a list of MTD partitions in struct efx_nic. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sfc/ethtool.c')
-rw-r--r--drivers/net/sfc/ethtool.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/net/sfc/ethtool.c b/drivers/net/sfc/ethtool.c
index 4fe874052e3e..08a9db993743 100644
--- a/drivers/net/sfc/ethtool.c
+++ b/drivers/net/sfc/ethtool.c
@@ -567,7 +567,8 @@ static int efx_ethtool_get_eeprom(struct net_device *net_dev,
567 rc = mutex_lock_interruptible(&efx->spi_lock); 567 rc = mutex_lock_interruptible(&efx->spi_lock);
568 if (rc) 568 if (rc)
569 return rc; 569 return rc;
570 rc = falcon_spi_read(spi, eeprom->offset + EFX_EEPROM_BOOTCONFIG_START, 570 rc = falcon_spi_read(efx, spi,
571 eeprom->offset + EFX_EEPROM_BOOTCONFIG_START,
571 eeprom->len, &len, buf); 572 eeprom->len, &len, buf);
572 mutex_unlock(&efx->spi_lock); 573 mutex_unlock(&efx->spi_lock);
573 574
@@ -590,7 +591,8 @@ static int efx_ethtool_set_eeprom(struct net_device *net_dev,
590 rc = mutex_lock_interruptible(&efx->spi_lock); 591 rc = mutex_lock_interruptible(&efx->spi_lock);
591 if (rc) 592 if (rc)
592 return rc; 593 return rc;
593 rc = falcon_spi_write(spi, eeprom->offset + EFX_EEPROM_BOOTCONFIG_START, 594 rc = falcon_spi_write(efx, spi,
595 eeprom->offset + EFX_EEPROM_BOOTCONFIG_START,
594 eeprom->len, &len, buf); 596 eeprom->len, &len, buf);
595 mutex_unlock(&efx->spi_lock); 597 mutex_unlock(&efx->spi_lock);
596 598