summaryrefslogtreecommitdiff
path: root/drivers/net
AgeCommit message (Collapse)Author
2012-09-18dm: sparc: net: Fixup greth compile warningsMarek Vasut
greth.c: In function ‘greth_recv’: greth.c:507:3: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘unsigned int’ [-Wformat] greth.c:507:3: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘unsigned int’ [-Wformat] greth.c:541:6: warning: pointer targets in assignment differ in signedness [-Wpointer-sign] greth.c: In function ‘greth_initialize’: greth.c:623:2: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘struct greth_regs *’ [-Wformat] greth.c:655:3: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 2 has type ‘struct greth_regs *’ [-Wformat] greth.c:684:2: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 2 has type ‘struct greth_regs *’ [-Wformat] Signed-off-by: Marek Vasut <marex@denx.de> Cc: Joe Hershberger <joe.hershberger@gmail.com> Cc: Daniel Hellstrom <daniel@gaisler.com> Cc: u-boot-dm@lists.denx.de
2012-09-04Merge branch 'master' of git://git.denx.de/u-boot-avr32Wolfgang Denk
* 'master' of git://git.denx.de/u-boot-avr32: net:macb: add line break avr32:portmux: fix setup for macb1 avr32: Remove redundant LDSCRIPT definition Signed-off-by: Wolfgang Denk <wd@denx.de>
2012-09-03net:macb: add line breakAndreas Bießmann
Without this patch we see annoying output like this: ---8<--- U-Boot> dhcp macb1: PHY not foundmacb0: PHY present at 1 macb0: Starting autonegotiation... --->8--- Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com> cc: Joe Hershberger <joe.hershberger@gmail.com>
2012-09-01arm : Atmel : add at91sam9x5ek board supportBo Shen
Add at91sam9x5ek board support, this board support the following SoCs AT91SAM9G15, AT91SAM9G25, AT91SAM9G35, AT91SAM9X25, AT91SAM9X35 Using at91sam9x5ek_nandflash to configure for the board Now only supports NAND with software ECC boot up Signed-off-by: Bo Shen <voice.shen@atmel.com> [move MAINTAINERS entry to right place] Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
2012-09-01cpsw: add driver for cpsw ethernet deviceCyril Chemparathy
CPSW is an on-chip ethernet switch that is found on various SoCs from Texas Instruments. This patch adds a simple driver (based on the Linux driver) for this hardware module. This patch also adds support to clean and flush dcache during packet send and receive. Changes by Sandhya: Added support to clean and flush dcache during packet send/receive and added timeouts. Signed-off-by: Cyril Chemparathy <cyril@ti.com> Signed-off-by: Chandan Nath <chandan.nath@ti.com> Signed-off-by: Satyanarayana, Sandhya <sandhya.satyanarayana@ti.com> [Ilya: Cleaned cache handling, some style cleanup, some small fixes, use of internal RAM for descriptors] Signed-off-by: Ilya Yanok <ilya.yanok@cogentembedded.com>
2012-08-23powerpc/fsl-corenet: remove dead variant symbolsScott Wood
These are not supported as individual build targets, but instead are supported by another target. The dead p4040 defines in particular had bitrotted significantly. Signed-off-by: Scott Wood <scottwood@freescale.com> Acked-by: Kumar Gala <galak@kernel.crashing.org> Signed-off-by: Andy Fleming <afleming@freescale.com>
2012-08-23powerpc/85xx: remove support for the Freescale P3060Timur Tabi
The P3060 was cancelled before it went into production, so there's no point in supporting it. Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Andy Fleming <afleming@freescale.com>
2012-08-23fm-eth: use fdt_status_disabled() function in ft_fixup_port()Timur Tabi
We have a dedicated function for setting the node status now, so use it. Also improve a comment and fix the type of the phandle variable. Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Andy Fleming <afleming@freescale.com>
2012-08-23fm-eth: add function fm_info_get_phy_address()Timur Tabi
Function fm_info_get_phy_address() returns the PHY address for a given Fman port. This is handy when the MDIO code needs to fixup the Ethernet nodes in the device tree to point to PHY nodes for a specific PHY address. Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Andy Fleming <afleming@freescale.com>
2012-08-23powerpc/85xx: add support for FM2 DTSEC5Timur Tabi
Unlike previous SOCs, the Freescale P5040 has a fifth DTSEC on the second Fman, so add the Fman and SerDes macros for that DTSEC. Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Andy Fleming <afleming@freescale.com>
2012-07-30Merge branch 'next' of git://git.denx.de/u-bootWolfgang Denk
* 'next' of git://git.denx.de/u-boot: MPC8xx: Fixup warning in arch/powerpc/cpu/mpc8xx/cpu.c doc: cleanup - move board READMEs into respective board directories net: sh_eth: add support for SH7757's GETHER net: sh_eth: modify the definitions of regsiter net: sh_eth: add SH_ETH_TYPE_ condition net: sh_eth: clean up for the SH7757's code net: fec_mxc: Fix MDC for xMII net: fec_mxc: Fix setting of RCR for xMII net: nfs: make NFS_TIMEOUT configurable net: Inline the new eth_setenv_enetaddr_by_index function net: allow setting env enetaddr from net device setting net/designware: Consecutive writes to the same register to be avoided CACHE: net: asix: Fix asix driver to work with data cache on net: phy: micrel: make ksz9021 phy accessible net: abort network initialization if the PHY driver fails phylib: phy_startup() should return an error code on failure net: tftp: fix type of block arg to store_block Signed-off-by: Wolfgang Denk <wd@denx.de>
2012-07-24net: sh_eth: add support for SH7757's GETHERYoshihiro Shimoda
SH7757 has 2 ETHERs and 2 GETHERs. This patch supports the SH7757's GETHER. If CONFIG_SH_ETHER_USE_GETHER is defined using SH7757, the driver handles the GETHER. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Acked-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
2012-07-24net: sh_eth: modify the definitions of regsiterYoshihiro Shimoda
The previous code had many similar definitions in each CPU. This patch borrows from the sh_eth driver of Linux kernel. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Acked-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
2012-07-24net: sh_eth: add SH_ETH_TYPE_ conditionYoshihiro Shimoda
At the moment, the driver supports the following CPUs: - GETHER (Gigabit Ethernet) : SH7763, SH7734 - ETHER (Fast Ethernet) : SH7724, SH7757 And the driver had the following "#if": #if defined(CONFIG_CPU_SH7763) || defined(CONFIG_CPU_SH7734) #if !defined(CONFIG_CPU_SH7757) && !defined(CONFIG_CPU_SH7724) - Those are for GETHER #if defined(CONFIG_CPU_SH7724) || defined(CONFIG_CPU_SH7757) - This is for ETHER So, for clean up the code, this patch adds SH_ETH_TYPE_GETHER and SH_ETH_TYPE_ETHER. And then, the patch modifies the above "#if". Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Acked-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
2012-07-24net: sh_eth: clean up for the SH7757's codeYoshihiro Shimoda
The SH7757's ETHER can work using the SH7724's setting. So, the patch modifies it. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Acked-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
2012-07-19net: fec_mxc: Fix MDC for xMIIbenoit.thebaudeau@advans
The MDC signal is available on all xMII (i.e. 'not 7-wire') interfaces, so mii_speed has to be set for all these interfaces, and not only for MII. Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com> Cc: Joe Hershberger <joe.hershberger@gmail.com> Cc: Stefano Babic <sbabic@denx.de>
2012-07-19net: fec_mxc: Fix setting of RCR for xMIIbenoit.thebaudeau@advans
At least on i.MX25, the RMII mode did not work, which is fixed by this patch. The MII_MODE bit of the FEC RCR register means xMII, i.e. 'not 7-wire', so set it accordingly. According to the xMII and 7-wire (aka GPSI) standards, full duplex should be available on xMII, but not on 7-wire, so set FCE accordingly. The FEC may support full duplex for 7-wire too, but the reference manual does not say that, so avoid an invalid assumption. Actually, the choice between half and full duplex also depends on the endpoint/switch/repeater configuration, so a config option could be added for that, but there has been no need for it so far. Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com> Cc: Joe Hershberger <joe.hershberger@gmail.com> Cc: Stefano Babic <sbabic@denx.de>
2012-07-19Blackfin: bfin_mac: drop volatile markings on packet buffersMike Frysinger
Now that common code doesn't declare these as volatile, we don't need to either anymore. This fixes the build warning: bfin_mac.c: In function 'bfin_EMAC_recv': bfin_mac.c:193:23: warning: assignment discards qualifiers from pointer target type Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-07-12Merge branch 'next' of git://git.denx.de/u-boot-net into nextWolfgang Denk
* 'next' of git://git.denx.de/u-boot-net: net: Inline the new eth_setenv_enetaddr_by_index function net: allow setting env enetaddr from net device setting net/designware: Consecutive writes to the same register to be avoided CACHE: net: asix: Fix asix driver to work with data cache on net: phy: micrel: make ksz9021 phy accessible net: abort network initialization if the PHY driver fails phylib: phy_startup() should return an error code on failure net: tftp: fix type of block arg to store_block Signed-off-by: Wolfgang Denk <wd@denx.de>
2012-07-11net/designware: Consecutive writes to the same register to be avoidedDinh Nguyen
This commit is an add-on to f6c4191f. There are a few registers where consecutive writes to the same location should be avoided or have a delay. According to Synopsys, here is a list of the registers and bit(s) where consecutive writes should be avoided or a delay is required: DMA Registers: Register 0 Bit 7 Register 6 All bits except for 24, 16-13, 2-1. GMAC Registers: Registers 0-3 All bits Registers 6-7 All bits Register 10 All bits Register 11 All bits except for 5-6. Registers 16-47 All bits Register 48 All bits except for 18-16, 14. Register 448 Bit 4. Register 459 Bits 0-3. Signed-off-by: Dinh Nguyen <dinguyen@altera.com> Reviewed-by: Matthew Gerlach <mgerlach@altera.com> Acked-by: Amit Virdi <amit.virdi@st.com>
2012-07-11net: phy: micrel: make ksz9021 phy accessibleTroy Kisky
Micrel accidentally used the same part number for the KS8721 and KSZ9021. So, both cannot be in the same build of u-boot. Add a config option to handle this. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Acked-by: Vladimir Zapolskiy <vz@mleia.com>
2012-07-11net: abort network initialization if the PHY driver failsTimur Tabi
Now that phy_startup() can return an actual error code, check for that error code and abort network initialization if the PHY fails. Signed-off-by: Timur Tabi <timur@freescale.com> Acked-by: Nobuhiro Iwamamatsu <nobuhiro.iwamatsu.yj@renesas.com> (sh_eth part) Acked-by: Stephan Linz <linz@li-pro.net> (Xilinx part, xilinx_axi_emac and xilinx_ll_temac) Reviewed-by: Marek Vasut <marex@denx.de> (FEC part)
2012-07-11phylib: phy_startup() should return an error code on failureTimur Tabi
phy_startup() calls the PHY driver's startup function, but it ignores the return code from that function, and so it never returns any failures. Signed-off-by: Timur Tabi <timur@freescale.com>
2012-07-10net/sh-ether: Fix build by removing ECSIPR_BRCRXIP and otherNobuhiro Iwamatsu
When support sh7734 of sh-ether, ECSIPR_BRCRXIP and other were removed. Therefore SH7757 and SH7724 can not build. This revise this probelem. Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org> Tested-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
2012-07-07net: Multiple updates/enhancements to designware.cStefan Roese
This patch adds the following changes to designware ethernet driver found on the ST SPEAr SoC: - Don't init MAC & PHY upon startup. This causes a delay, waiting for the auto negotiation to complete. And we don't want this delay to always happen. Especially not on platforms where ethernet is not used at all (e.g. booting via flash). Instead postpone the MAC / PHY configuration to the stage, where ethernet is first used. - Add possibility for board specific PHY init code. This is needed for example on the X600 board, where the Vitesse PHY needs to be configured for GMII mode. This board specific PHY init is done via the function designware_board_phy_init(). And this driver now adds a weak default which can be overridden by board code. - Use common functions miiphy_speed() & miiphy_duplex() to read link status from PHY. - Print status and progress of auto negotiation. - Print link status (speed, dupex) upon first usage. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Amit Virdi <amit.virdi@st.com> Cc: Vipin Kumar <vipin.kumar@st.com> Cc: Joe Hershberger <joe.hershberger@gmail.com> Acked-by: Joe Hershberger <joe.hershberger@gmail.com>
2012-07-07SPEAr: Add interface information in initializationVipin Kumar
Few Designware peripheral registers need to be modified based on the ethernet interface selected by the board. This patch supports interface information in ethernet driver Signed-off-by: Vipin Kumar <vipin.kumar@st.com> Signed-off-by: Amit Virdi <amit.virdi@st.com> Signed-off-by: Stefan Roese <sr@denx.de>
2012-07-07da850/omap-l138: Enable auto negotiation in RMII modeRajashekhara, Sudhakar
On DA850/OMAP-L138 it was observed that in RMII mode, auto negotiation was not performed. This patch enables auto negotiation in RMII mode. Without this patch, EMAC initialization takes more time and sometimes tftp fails in RMII mode. Signed-off-by: Rajashekhara, Sudhakar <sudhakar.raj@ti.com> Signed-off-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Hadli, Manjunath <manjunath.hadli@ti.com>
2012-05-23net: sh-eth: Add support Gigabit of SH7734Nobuhiro Iwamatsu
SH7734 support GMII. This add register infomation and the function which enable GMII. Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
2012-05-23net: sh_eth: Add support SH7734 Ethernet deviceNobuhiro Iwamatsu
SH7734 has one channel ethernet device. This support 10/100/1000Base, and RMII/MII/GMII. And this has the same structure as SH7763. Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
2012-05-23net: Allow filtering on debug traces in the net subsystemJoe Hershberger
Add several levels of DEBUG prints so that you can limit the noise to the severety of your problem. DEBUG_LL_STATE = Link local state machine changes DEBUG_DEV_PKT = Packets or info directed to the device DEBUG_NET_PKT = Packets on info on the network at large DEBUG_INT_STATE = Internal network state changes Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-23net: Make sure NetLoop is initialized when using NetConsoleJoe Hershberger
Fix NetConsole bug that causes first packet header to claim a source IP address of 0.0.0.0 Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-23net: Refactor to separate the UDP handler from the ARP handlerJoe Hershberger
Call a built-in dummy if none is registered... don't require protocols to register a handler (eliminating dummies) NetConsole now uses the ARP handler when waiting on arp (instead of needing a #define hack in arp.c) Clear handlers at the end of net loop Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Acked-by: Simon Glass <sjg@chromium.org>
2012-05-23net: Refactor to protect access to the NetState variableJoe Hershberger
Changes to NetState now go through an accessor function called net_set_state() Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-23net: cosmetic: Un-typedef IP_tJoe Hershberger
Rename IP header related things to IP_UDP. The existing definition of IP_t includes UDP header, so name it to accurately describe the structure. Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-23net: Fix remaining API interface breakageJoe Hershberger
These are all the files which use the API incorrectly but did not get built using MAKEALL -a powerpc|arm. I have no compiler for them, but the remaining issues should be far less than without this patch. Any outstanding issues are left to the maintainers of boards that use these drivers. Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-23drivers/net/rtl8169.c: Fix compile warningJoe Hershberger
Fix this: rtl8169.c: In function 'rtl8169_initialize': rtl8169.c:907:13: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-23drivers/net/pcnet.c: Fix compile warningJoe Hershberger
Fix this: pcnet.c: In function 'pcnet_initialize': pcnet.c:224:13: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-23drivers/net/xilinx_axi_emac.c: Fix compile warningStephan Linz
Fix this: xilinx_axi_emac.c: In function 'xilinx_axiemac_initialize': xilinx_axi_emac.c:646: warning: assignment from incompatible pointer type Signed-off-by: Stephan Linz <linz@li-pro.net>
2012-05-23drivers/net/xilinx_emaclite.c: Fix compile warningStephan Linz
Fix this: xilinx_emaclite.c: In function 'xilinx_emaclite_initialize': xilinx_emaclite.c:371: warning: assignment from incompatible pointer type Signed-off-by: Stephan Linz <linz@li-pro.net>
2012-05-23drivers/net/xilinx_ll_temac.c: Fix compile warningStephan Linz
Fix this: xilinx_ll_temac.c: In function 'xilinx_ll_temac_initialize': xilinx_ll_temac.c:332: warning: assignment from incompatible pointer type xilinx_ll_temac.c:340: warning: assignment from incompatible pointer type Signed-off-by: Stephan Linz <linz@li-pro.net>
2012-05-22drivers/net/uli526x.c: Fix compile warningJoe Hershberger
Fix this: uli526x.c: In function 'uli526x_initialize': uli526x.c:243:13: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-22drivers/net/tsi108_eth.c: Fix compile warningJoe Hershberger
Fix this: tsi108_eth.c: In function 'tsi108_eth_initialize': tsi108_eth.c:745:13: warning: assignment from incompatible pointer type tsi108_eth.c: In function 'tsi108_eth_recv': tsi108_eth.c:989:4: warning: passing argument 1 of 'NetReceive' discards qualifiers from pointer target type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-22drivers/net/rtl8139.c: Fix compile warningJoe Hershberger
Fix this: rtl8139.c: In function 'rtl8139_initialize': rtl8139.c:234:13: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-22drivers/net/ns8382x.c: Fix compile warningJoe Hershberger
Fix this: ns8382x.c: In function 'ns8382x_initialize': ns8382x.c:352:13: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-22drivers/net/natsemi.c: Fix compile warningJoe Hershberger
Fix this: natsemi.c: In function 'natsemi_initialize': natsemi.c:338:13: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-22drivers/net/fm/eth.c: Fix compile warningJoe Hershberger
Fix this: eth.c: In function 'fm_eth_initialize': eth.c:651:12: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-22drivers/net/e1000.c: Fix compile warningJoe Hershberger
Fix this: e1000.c: In function 'e1000_initialize': e1000.c:5264:13: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-05-22drivers/net/smc91111.c: Fix compile warningJoe Hershberger
Fix this: smc91111.c: In function 'smc91111_initialize': smc91111.c:1363:12: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Cc: Joe Hershberger <joe.hershberger@gmail.com>
2012-05-22drivers/net/macb.c: Fix compile warningJoe Hershberger
Fix this: macb.c: In function 'macb_eth_initialize': macb.c:564:15: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Cc: Joe Hershberger <joe.hershberger@gmail.com>
2012-05-22drivers/net/lan91c96.c: Fix compile warningJoe Hershberger
Fix this: lan91c96.c: In function 'lan91c96_initialize': lan91c96.c:811:12: warning: assignment from incompatible pointer type Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Cc: Joe Hershberger <joe.hershberger@gmail.com>