summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/rdc
Commit message (Collapse)AuthorAgeFilesLines
* r6040: Do a Proper deinit at errorpath and also when driver unloads (calling ↵Devendra Naga2012-05-301-0/+5
| | | | | | | | | | | | | r6040_remove_one) so if mdiobus_alloc fails, the errorpath doesnt do a netif_napi_del and also doesn't set the priv data of the driver to NULL. at the driver unload stage the driver doesn't remove the NAPI context, and doesnt' set the priv data to NULL, and also doesn't call the pci_iounmap. Signed-off-by: Devendra Naga <devendra.aaru@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: disable pci device if the subsequent calls (after pci_enable_device) ↵Devendra Naga2012-05-301-4/+6
| | | | | | | | | | fails the calls after the pci_enable_device may fail, and will error out with out disabling it. disable the device at error paths. Signed-off-by: Devendra Naga <devendra.aaru@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: update copyright from 2007 to nowFlorian Fainelli2012-04-121-1/+1
| | | | | Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: define and use bits of register PHY_CCFlorian Fainelli2012-04-121-2/+10
| | | | | | | Define and use the bits of the PHY_CC (status change configuration) register. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: define and use MTPR transmit enable bitFlorian Fainelli2012-04-121-2/+3
| | | | | | | Define MTPR bit 0 of the register and use it where it is appropriate. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: define and use MLSR register bitsFlorian Fainelli2012-04-121-2/+5
| | | | | | | | | | Define the MLSR (MAC Last Status Register bits) for: - tx fifo under-run - tx exceed collision - tx late collision Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: fix typo on stats update in tx pathFlorian Fainelli2012-04-121-1/+1
| | | | | | | | We are currently updating the rx fifo error counter in the tx path while it should have been the tx fifo error counter, fix that. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: add a MAC operation timeout defineFlorian Fainelli2012-04-121-3/+5
| | | | | | | | 2048 is the usual value for busy-waiting on a register r/w, define it as MAC_DEF_TIMEOUT and use it where it is appropriate. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: remove unused variable mcr1 from private structureFlorian Fainelli2012-04-121-1/+1
| | | | | Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: consolidate MAC reset to its own functionFlorian Fainelli2012-04-121-19/+18Star
| | | | | | | | | | The reset of the MAC is currently done identically from two places and one place is not waiting for the MAC_SM bit to be set after reset. Everytime the MAC is software resetted a state machine is also needed so consolidate the reset to its own function. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: Support the get_ts_info ethtool method.Richard Cochran2012-04-041-0/+1
| | | | | Signed-off-by: Richard Cochran <richardcochran@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* net: replace random_ether_addr() with eth_hw_addr_random()Danny Kukawka2012-02-151-1/+1
| | | | | | | | | | | | Replace usage of random_ether_addr() with eth_hw_addr_random() to set addr_assign_type correctly to NET_ADDR_RANDOM. Change the trivial cases. v2: adapt to renamed eth_hw_addr_random() Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* drivers/net: Remove alloc_etherdev error messagesJoe Perches2012-01-311-1/+0Star
| | | | | | | | alloc_etherdev has a generic OOM/unable to alloc message. Remove the duplicative messages after alloc_etherdev calls. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: fix typo in use of MCR0 register bitsCesar Eduardo Barros2012-01-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | Commit 4e16d6ebd65b4f2c4e3f780b4c5704beef64019c (r6040: define more MCR0 register bits) added #define values for MCR0 register bits and converted uses of hardcoded magic values to uses of these defines. However, one of the conversions looks suspicious: #define MCR0 0x00 /* Control register 0 */ +#define MCR0_RCVEN 0x0002 /* Receive enable */ +#define MCR0_XMTEN 0x1000 /* Transmission enable */ /* Init RDC private data */ - lp->mcr0 = 0x1002; + lp->mcr0 = MCR0_XMTEN | MCR0; I believe what was meant here was MCR0_XMTEN | MCR0_RCVEN, which makes sense and matches the original values. Signed-off-by: Cesar Eduardo Barros <cesarb@cesarb.net> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: place comments before codeFlorian Fainelli2012-01-041-3/+4
| | | | | | | | checkpatch.pl complained about the line exceding 80 columns, and the comment was actually on the same line as the code, fix that. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: use __aligned(size)Florian Fainelli2012-01-041-1/+1
| | | | | | | instead of __attribute__((__aligned(size)__)) Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: use definitions for MAC_SM register read/writesFlorian Fainelli2012-01-041-2/+3
| | | | | | | | Bit 1 is the reset bit of the MAC status machine register, define and use it. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: use MAC_RST bit definition with MCR1 read/writesFlorian Fainelli2012-01-041-3/+3
| | | | | | | MAC_RST bit is already defined, use it instead of 0x1 where applicable. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: define more MCR0 register bitsFlorian Fainelli2012-01-041-3/+6
| | | | | | | Define more MCR0-register bits and use them in place of the bits values. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: remove unused variables and definitionsFlorian Fainelli2012-01-041-13/+1Star
| | | | | | | | Since the conversion to phylib (3831861b: r6040: implement phylib) some PHY-related variables and definitions are now useless, remove them. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: use an unique MDIO bus nameFlorian Fainelli2012-01-041-1/+2
| | | | | | | | | | We should use an unique MDIO bus name which does not clash with anything else in the system like the Fixed MDIO bus. The bus is now named: r6040-<card number> which is unique in the system. Reported-by: Vladimir Kolpakov <vova.kolpakov@gmail.com> Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: fix check against MCRO_HASHEN bit in r6040_multicast_listFlorian Fainelli2011-11-171-1/+1
| | | | | | | | We are checking whether the MCR0_HASHEN bit is set using a logical and instead of bitwise and, fix that. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: bump version to 0.28 and date to 07Oct2011.Florian Fainelli2011-10-101-2/+2
| | | | | Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: invoke phy_{start,stop} when appropriateFlorian Fainelli2011-10-101-0/+4
| | | | | | | | | | | Joe reported to me that right after a bring up of a r6040 interface the ethtool output had no consistent output with respect to link duplex and speed. Fix this by adding a missing phy_start call in r6040_up and conversely a phy_stop call in r6040_down to properly initialize phy states. Reported-by: Joe Chou <Joe.Chou@rdc.com.tw> Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* MII: fix Kconfig dependencies for MIIJeff Kirsher2011-09-151-0/+1
| | | | | | | | | | | | | | | | MII Kconfig option is apart of the core networking drivers and by default NET_CORE is enabled so drivers selecting MII will have MII enabled as well. It was found using the randconfig option during testing, MII would be selected but NET_CORE could be disabled. This caused a dependency error. Resolved the dependency by selecting NET_CORE when MII is selected. Reported-by: Emil Tantilov <emil.s.tantilov@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* drivers/net/ethernet/*: Enabled vendor Kconfig optionsJeff Kirsher2011-08-271-0/+1
| | | | | | | | | | | | | | Based on finds for Stephen Rothwell, where current defconfig's enable a ethernet driver and it is not compiled due to the newly added NET_VENDOR_* component of Kconfig. This patch enables all the "new" Kconfig options so that current defconfig's will continue to compile the expected drivers. In addition, by enabling all the new Kconfig options does not add any un-expected options. CC: Stephen Rothwll <sfc@canb.auug.org.au> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* net: remove use of ndo_set_multicast_list in driversJiri Pirko2011-08-181-1/+1
| | | | | | | replace it by ndo_set_rx_mode Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* r6040: Move the RDC driverJeff Kirsher2011-08-123-0/+1314
Move the RDC driver into drivers/net/ethernet/rdc/ and make the necessary Kconfig and Makefile changes. CC: Florian Fainelli <florian@openwrt.org> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>