Commit Graph

20959 Commits

Author SHA1 Message Date
David Andrey 62d7dba7be PHY: micrel.c: add support for KSZ9031
Add support for Micrel PHY KSZ9031 in phylib,
including small rework for KSZ9021 to avoid
code duplication

Signed-off-by: David Andrey <david.andrey@netmodule.com>
Cc: Troy Kisky <troy.kisky@boundarydevices.com>
Cc: Joe Herschberger <joe.hershberger@gmail.com>
Cc: Andy Fleming <afleming@freescale.com>
Acked-by: Stefan Roese <sr@denx.de>
2013-06-24 19:11:13 -05:00
Kim Phillips 61fdd4f7c3 net/tftp: sparse fixes
tftp.c:464:17: warning: cast to restricted __be16
tftp.c:552:29: warning: cast to restricted __be16
tftp.c:640:33: warning: cast to restricted __be16
tftp.c:642:25: warning: cast to restricted __be16

Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Cc: Joe Hershberger <joe.hershberger@gmail.com>
2013-06-24 19:11:12 -05:00
Kim Phillips 3d49412d56 net: make IPaddr type big endian
for use with sparse.

Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Cc: Joe Hershberger <joe.hershberger@gmail.com>
2013-06-24 19:11:12 -05:00
Joe Hershberger 1b8c18b971 net: Fix build regression in macb.c
The added weak symbol must not be static.

This was introduced in 416ce623fb

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2013-06-24 19:10:42 -05:00
Shiraz Hashim 416ce623fb net/macb: Add arch specific routine to get mdio control
SPEAr310 and SPEAr320 Ethernet interfaces share same MDIO lines to control their
respective phys. Currently there is a fixed configuration in which only a
particular MAC can use the MDIO lines.

Call an arch specific function to take control of specific mdio lines at
runtime.

Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com>
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Acked-by: Stefan Roese <sr@denx.de>
2013-06-24 19:10:16 -05:00
Vipin Kumar 7091915ad7 net/designware: Do not select MIIPORT for RGMII interface
Do not select MIIPORT for RGMII interface

Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Acked-by: Stefan Roese <sr@denx.de>
2013-06-24 19:10:16 -05:00
Matthias Brugger fa84fa708c net: nfs: add dynamic wait period
This patch tackles the time out problem which leads to break the
boot process, when loading file over nfs. The patch does two things.

First of all, we just ignore messages that arrive with a rpc_id smaller
then the client id. We just interpret this messages as answers to
formaly timed out messages.

Second, when a time out occurs we double the time to wait, so that we
do not stress the server resending the last message.

Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
Tested-by: Enric Balletbo i Serra <eballetbo@gmail.com>
2013-06-24 19:10:15 -05:00
Sebastian Hesselbarth fb4879b3c7 NET: mvgbe: add support for Dove
Marvell Dove also uses mvgbe as ethernet driver, therefore add support
for Dove to reuse the current driver.

Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
2013-06-24 19:10:15 -05:00
Sebastian Hesselbarth cd3ca3ff49 NET: mvgbe: add phylib support
This add phylib support to the Marvell GBE driver.

Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
2013-06-24 19:10:14 -05:00
Sebastian Hesselbarth aeceec0d0e NET: phy: add 88E1310 PHY initialization
This adds PHY initialization for Marvell Alaska 88E1310 PHY.

Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
2013-06-24 19:10:14 -05:00
Rob Herring 98f646764d pxe: add ipappend support
Add ipappend support to pass network device information to the kernel.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:10:14 -05:00
Joe Hershberger 58d9ff936f net: Fix build regression in cmd_pxe.c
Not all boards define an SOC.  As a result, we can't depend on that.

This was introduced in 39f985536d

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2013-06-24 19:10:03 -05:00
Rob Herring 39f985536d pxe: add support for per arch and SoC default paths
A pxelinux server setup for "default" menu is typically an x86 binary.
This does not work well with a mixed architecture setup. Extend the default
search to look for default-<arch>-<soc> and then default-<arch> before
falling back to just "default".

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:34 -05:00
Rob Herring 8577fec976 pxe: add support for ontimeout token
ontimeout is similar to default, but is the selection on menu timeout.
This is how cobbler sets a default. The label default is supposed to be
the default selection when <enter> is pressed. If both default and
ontimeout are set, last one parsed wins.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:34 -05:00
Rob Herring 32d2ffe731 pxe: simplify menu display and selection
Menus with lots of entries and long append lines are hard to read.
Just show a numbered list using the label or name and make the choice
by entering the number.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:34 -05:00
Rob Herring e82eeb5709 pxe: always display a menu when present
The prompt flag is for displaying a "boot:" prompt in pxelinux. This
doesn't make sense for u-boot as we don't support the pxelinux command
interface. So we should just ignore prompt statements and always show the
menu if a menu is present.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:34 -05:00
Rob Herring e6b6ccf203 pxe: try bootz if bootm fails to find a valid image
Standard pxelinux servers will typically use a zImage rather than u-boot
image format, so fallback to bootz if bootm fails.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:34 -05:00
Rob Herring da620222f8 bootz: un-staticize do_bootz
Make do_bootz available for other functions like do_bootm is.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:33 -05:00
Rob Herring 500f304b6b pxe: fix handling of different localboot values
Add support for value of -1 For localboot. A value of -1 means return to
u-boot prompt.

The localboot value is often 0, so we need to distinguish the value from
localboot being selected. A value of greater than or equal to 0 means
attempt local boot command.

If localboot is selected, we don't want to try other entries.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:33 -05:00
Rob Herring 23b7194e61 pxe: make string parameters const
Convert a bunch of string parameters to be const.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:33 -05:00
Rob Herring ef034c9d70 pxe: Use ethact setting for pxe
Get the MAC address using eth_getenv_enetaddr_by_index so that the MAC
address of ethact is used. This enables using the a NIC other than the
first one for PXE boot.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-06-24 19:07:32 -05:00
Yegor Yefremov 0fae25089d net: add ICPlus PHY driver
The driver code was taken from Linux kernel source:
drivers/net/phy/icplus.c

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
2013-06-24 19:07:32 -05:00
Yegor Yefremov e2043f5c27 phy: export genphy_parse_link()
Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
2013-06-24 19:07:32 -05:00
Henrik Nordström 518ce472f7 net: Add sunxi (Allwinner) wemac driver
This patch adds support for the WEMAC, the ethernet controller included
in the Allwinner A10 SoC. It will get used in the upcoming A10 board
support.

From: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Signed-off-by: Henrik Nordstrom <henrik@henriknordstrom.net>
2013-06-24 19:07:31 -05:00
Bo Shen 9e79a8d17c checkpatch: add ignore for network block comment style checking
When use checkpatch.pl to check network related patch, it will report
--->8---
WARNING: networking block comments don't use an empty /* line,
use /* Comment...
---<8---

So, add --ignore NETWORKING_BLOCK_COMMENT_STYLE into .checkpatch.conf
This will help to keep all driver include network related driver use
the same comment style

Signed-off-by: Bo Shen <voice.shen@atmel.com>
2013-06-24 19:07:31 -05:00
Heiko Schocher a67cc37e69 dfu, nand: before write a buffer to nand, erase the nand sectors
before writing the received buffer to nand, erase the nand
sectors. If not doing this, nand write fails. See for
more info here:

http://lists.denx.de/pipermail/u-boot/2013-June/156361.html

Using the nand erase option "spread", maybe overwrite
blocks on, for example another mtd partition, if the
erasing range contains bad blocks.
So a limit option is added to nand_erase_opts()

Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Pantelis Antoniou <panto@antoniou-consulting.com>
Cc: Lukasz Majewski <l.majewski@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Marek Vasut <marex@denx.de>
Cc: Tom Rini <trini@ti.com>
Signed-off-by: Scott Wood <scottwood@freescale.com>
2013-06-24 18:17:23 -05:00
Tom Rini 4e78e0317d Merge branch 'master' of git://git.denx.de/u-boot-mpc5xxx 2013-06-24 16:44:15 -04:00
Tom Rini f9c1456cf6 Merge branch 'master' of git://git.denx.de/u-boot-spi 2013-06-24 16:37:01 -04:00
Gerhard Sittig 6c5001d542 ac14xx: rephrase network boot config for development
- remove the builtin 'rootpath' spec (according to U-Boot project
  policy) and require user provided environments to contain these
- rephrase the evaluation of the 'muster_nr' approach which allows to
  quickly switch among several network boot setups (make the setting
  transparent when empty, resulting in default DULG behaviour)
- reduce the ARP timeout for faster network boot

Signed-off-by: Gerhard Sittig <gsi@denx.de>
2013-06-24 22:29:05 +02:00
Gerhard Sittig 4779025c1e ac14xx: use the official product name everywhere
remove remaining "k6" code names, switch to the official 'ac14xx' name

Signed-off-by: Gerhard Sittig <gsi@denx.de>
2013-06-24 22:27:13 +02:00
Gerhard Sittig 81b0fb0410 ac14xx: remove obsolete board config items
- use the default baudrate table for serial communication
- remove hostname/boofile/rootpath defines which were not referenced elsewhere

Signed-off-by: Gerhard Sittig <gsi@denx.de>
2013-06-24 22:27:06 +02:00
Gerhard Sittig 14d4c5f39e ac14xx: re-order the recovery condition checks
re-order the conditions which make the recovery system startup: combine
those conditions which were explicitly initiated (key press, software
request) and those which post-process error conditions (installer issues)

Signed-off-by: Gerhard Sittig <gsi@denx.de>
2013-06-24 22:26:57 +02:00
Gerhard Sittig 527a1c71fb ac14xx: minor improvement in diagnostics
- minor rewording of diagnostics output
- make diagnostics optional and off by default

Signed-off-by: Gerhard Sittig <gsi@denx.de>
2013-06-24 22:26:30 +02:00
Gerhard Sittig b5992e77ef ac14xx: cleanup comments in the board support
fix typos, minor rephrasing, remove obsolete notes and TODO items

Signed-off-by: Gerhard Sittig <gsi@denx.de>
2013-06-24 22:25:57 +02:00
Gerhard Sittig 186f9c130f ac14xx: fix a potential NULL deref in diagnostics
getenv() immediately after setenv() may perfectly legally return NULL, so
make sure to not deference an invalid pointer when creating diagnostic output

Signed-off-by: Gerhard Sittig <gsi@denx.de>
2013-06-24 22:24:29 +02:00
Jagannadha Sutradharudu Teki b9e31be0f8 sf: Warn to use BAR for > 16MiB flashes
Warning for > 16MiB flashes to #define CONFIG_SPI_FLASH_BAR

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:10:36 +05:30
Jagannadha Sutradharudu Teki 29fbfc10f4 sf: Add debug messages on spi_flash_read_common
- Added debug's on spi_flash_read_common()
- Added space

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:10:36 +05:30
Jagannadha Sutradharudu Teki 95e779e4f4 sf: Place the sf calls in proper order
Placed the sf calls in proper order - erase/write/read

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:10:36 +05:30
Jagannadha Sutradharudu Teki acc237544a sf: Unify spi_flash write code
Move common flash write code into spi_flash_write_common().

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Acked-by: Simon Glass <sjg@chromium.org>
2013-06-23 22:10:35 +05:30
Jagannadha Sutradharudu Teki 615a156167 sf: Add flag status register polling support
Flag status register polling is required for micron 512Mb flash
devices onwards, for performing erase/program operations.

Like polling for WIP(Write-In-Progress) bit in read status register,
spi_flash_cmd_wait_ready will poll for PEC(Program-Erase-Control)
bit in flag status register.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2013-06-23 22:02:51 +05:30
Jagannadha Sutradharudu Teki ba549de6c5 sf: Remove spi_flash_cmd_poll_bit()
There is no other call other than spi_flash_cmd_wait_ready(),
hence removed spi_flash_cmd_poll_bit and use the poll status code
spi_flash_cmd_wait_ready() itself.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2013-06-23 22:02:51 +05:30
Jagannadha Sutradharudu Teki 76e98d4817 sf: spansion: Add support for S25FL512S_64K
Add support for Spansion S25FL512S_64K SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:02:51 +05:30
Jagannadha Sutradharudu Teki 4e2904311d sf: stmicro: Add support for N25Q1024A
Add support for Numonyx N25Q1024A SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:02:51 +05:30
Jagannadha Sutradharudu Teki 221cb084ad sf: stmicro: Add support for N25Q1024
Add support for Numonyx N25Q1024 SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:02:51 +05:30
Jagannadha Sutradharudu Teki fd60c0ac31 sf: stmicro: Add support for N25Q512A
Add support for Numonyx N25Q512A SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:02:51 +05:30
Jagannadha Sutradharudu Teki 0569f3b9be sf: stmicro: Add support for N25Q512
Add support for Numonyx N25Q512 SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
2013-06-23 22:02:50 +05:30
Jagannadha Sutradharudu Teki f76b1bd08b sf: Use spi_flash_addr() in write call
Use the existing spi_flash_addr() for 3-byte addressing
cmd filling in write call.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2013-06-23 22:02:50 +05:30
Jagannadha Sutradharudu Teki 1dcd6d0381 sf: Add bank addr code in CONFIG_SPI_FLASH_BAR
Defined bank addr code on CONFIG_SPI_FLASH_BAR macro, to reduce the
size for existing boards which has < 16Mbytes SPI flashes.

It's upto user which has provision to use the bank addr code for
flashes which has > 16Mbytes.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2013-06-23 22:02:50 +05:30
Jagannadha Sutradharudu Teki fc207ee4db sf: Update sf read to support all sizes of flashes
This patch updated the spi_flash read func to support all
sizes of flashes using bank reg addr facility.

The same support has been added in below patch for erase/write
spi_flash functions:
"sf: Support all sizes of flashes using bank addr reg facility"
(sha1: c956f600cbb0943d0afe1004cdb503f4fcd8f415)

With these new updates on sf framework, the flashes which has < 16MB
are not effected as per as performance is concern and but the
u-boot.bin size incrased ~460 bytes.

sf update(for first 16MBytes), Changes before:
U-Boot> sf update 0x1000000 0x0 0x1000000
- N25Q256
  16777216 bytes written, 0 bytes skipped in 199.72s, speed 86480 B/s
- W25Q128BV
  16777216 bytes written, 0 bytes skipped in 351.739s, speed 48913 B/s
- S25FL256S_64K
  16777216 bytes written, 0 bytes skipped in 65.659s, speed 262144 B/s

sf update(for first 16MBytes), Changes before:
U-Boot> sf update 0x1000000 0x0 0x1000000
- N25Q256
  16777216 bytes written, 0 bytes skipped in 198.953s, speed 86480 B/s
- W25Q128BV
  16777216 bytes written, 0 bytes skipped in 350.90s, speed 49200 B/s
- S25FL256S_64K
  16777216 bytes written, 0 bytes skipped in 66.521s, speed 262144 B/s

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2013-06-23 22:02:50 +05:30
Jagannadha Sutradharudu Teki e3ff9d51ec sf: Update sf to support all sizes of flashes
Updated the spi_flash framework to handle all sizes of flashes
using bank/extd addr reg facility

The current implementation in spi_flash supports 3-byte address mode
due to this up to 16Mbytes amount of flash is able to access for those
flashes which has an actual size of > 16MB.

As most of the flashes introduces a bank/extd address registers
for accessing the flashes in 16Mbytes of banks if the flash size
is > 16Mbytes, this new scheme will add the bank selection feature
for performing write/erase operations on all flashes.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2013-06-23 22:02:50 +05:30