summaryrefslogtreecommitdiffstats
path: root/drivers/net/at91_ether.c
Commit message (Collapse)AuthorAgeFilesLines
* drivers: net: convert drivers to spdxOleksij Rempel2018-12-061-14/+1
| | | | | | Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Reviewed-by: Roland Hieber <r.hieber@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* net: Make set_ethaddr argument constSascha Hauer2015-06-261-1/+1
| | | | | | | The set_ethaddr callback should not modify the MAC address passed to it, so make it const. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* net: at91_ether: convert to streaming DMA opsLucas Stach2015-03-061-2/+8
| | | | | | | | | Move to the common streaming DMA ops in order to get rid of the direct usage of the ARM MMU functions for the cache maintenance. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* ARM: move DMA alloc functions to dma.hLucas Stach2015-03-061-0/+1
| | | | | | | | | | This better separates the DMA from the MMU functionality. Also move all drivers that only depends on asm/mmu.h for the alloc functions over to the common header. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* ARM: change dma_alloc/free_coherent to match other architecturesLucas Stach2015-03-061-2/+4
| | | | | | | | | As a lot drivers currently rely on the 1:1 virt->phys mapping on ARM we define DMA_ADDRESS_BROKEN to mark them. In order to use them on other architectures with a different mapping they need proper fixing. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* net: Pass eth_device to net_receiveSascha Hauer2014-05-151-1/+1
| | | | | | | So that barebox has the information which interface a packet came from. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* drivers: treewide: Kill empty remove() implementationsAlexander Shiyan2014-04-021-5/+0
| | | | | Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* macb: rename platform dataJosh Cartwright2013-04-031-1/+1
| | | | | | | | | | The macb/gem core is used by the Zynq SoC. In preparation of sharing the macb driver between at91 and Zynq, rename the platform data to 'struct macb_platform_data', and move the definition to a common location. Signed-off-by: Josh Cartwright <joshc@eso.teric.us> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Use new device_platform_driver() macro for driversAlexander Shiyan2013-02-131-7/+1
| | | | | Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* macb: allow to pass the phy interfaceJean-Christophe PLAGNIOL-VILLARD2013-01-291-1/+1
| | | | | | | as we will add later the GMAC IP verion support (GEM) Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* macb/ether: split flags for drivers and phylibJean-Christophe PLAGNIOL-VILLARD2012-11-191-1/+1
| | | | | | | | | as in the kernel use is_rmii flags for pinctrl phy_flags for phylib flags Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* switch all platform_bus device/driver registering to ↵Jean-Christophe PLAGNIOL-VILLARD2012-10-041-1/+1
| | | | | | | | platform_driver/device_register now register_driver and register_device are for bus only usage. Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* Merge branch 'for-next/remove-fsf-address'Sascha Hauer2012-10-031-4/+0
|\ | | | | | | | | | | Conflicts: drivers/net/miidev.c include/miidev.h
| * Treewide: remove address of the Free Software FoundationSascha Hauer2012-09-171-4/+0
| | | | | | | | | | | | | | The FSF address has changed in the past. Instead of updating it each time the address changes, just drop it completely treewide. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | net: introduce phylibJean-Christophe PLAGNIOL-VILLARD2012-09-251-23/+26
|/ | | | | | | | | | | | | | | | Adapt phylib from linux switch all the driver to it reimplement mii bus This will allow to have - phy drivers - to only connect the phy at then opening of the device - if the phy is not ready or not up fail on open Same behaviour as in linux and will allow to share code and simplify porting. Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* net: at91_ether re-implement against new at91rm9200 apiJean-Christophe PLAGNIOL-VILLARD2012-04-021-232/+263
| | | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* net: make the ethernet device a child of the hardware deviceSascha Hauer2011-08-151-0/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Fix error handling with malloc, memalign etc. Introduce xmemalign().Krzysztof Halasa2011-01-071-1/+1
| | | | | | | | | | | | | | The idea is to panic() when there is no memory available for normal operation. Exception: code which can consume arbitrary amount of RAM (example: files allocated in ramfs) must report error instead of panic(). This patch also fixes code which didn't check for NULL from malloc() etc. Usage: malloc(), memalign() return NULL when out of RAM. xmalloc(), xmemalign() always return non-NULL or panic(). Signed-off-by: Krzysztof Hałasa <khc@pm.waw.pl> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* net: rework the mii supportJean-Christophe PLAGNIOL-VILLARD2010-08-271-5/+5
| | | | | | | this rework is done in order to add a phylib and allow to have phy driver support Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* network drivers: call net_receive directly instead of NetReceiveSascha Hauer2010-06-171-1/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* add a device_d to ethernet devicesSascha Hauer2009-07-211-1/+0
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Get rid of DEVICE_TYPE_ETHER usageSascha Hauer2009-07-211-1/+0
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* change functions containing 'mac' or 'enet' in its name to 'ethaddr'.sascha2007-10-181-4/+4
| | | | change the parameter name for ethernet devices to 'ethaddr' aswell.
* svn_rev_310Sascha Hauer2007-07-051-4/+4
| | | | use type_data instead of pric for edev
* svn_rev_251Sascha Hauer2007-07-051-70/+75
| | | | make it work again
* svn_rev_129Sascha Hauer2007-07-051-3/+19
| | | | make it work again
* svn_rev_107Sascha Hauer2007-07-051-8/+8
| | | | removed ifdefs
* svn_rev_095Sascha Hauer2007-07-051-10/+36
| | | | | | | | | | | | | | | | | | | | | | Currently U-Boot uses globally defined eth_* functions. This is horribly unflexible. This patch replaces the global functions with pointers from structs. We could also use CONFIG_NET_MULTI, but this has other implications, though we should merge this some day. Also, U-Boot has no unique way to handle MAC addresses. Each and every board and network driver uses it's own mechanism to set the MAC address. There are several problems which I've for too often. For example everything goes well if we boot from network, but when we boot from flash U-Boot forgets to set the MAC address and the linux network driver has none. This patch adds [gs]et_mac_address to the eth_device struct and handles it as follows: - First try to get a valid MAC address from the EEPROM and set 'ethaddr' accordingly. - If no valid MAC address is found in the EEPROM (or no EEPROM is connected), we set the devices MAC address from 'ethaddr' This is done in eth_initialize which is called on startup for every board.
* svn_rev_061Sascha Hauer2007-07-051-0/+299
rename