21 May, 2015

2 commits


20 May, 2015

2 commits


19 Apr, 2015

17 commits


25 Oct, 2014

1 commit


22 Jul, 2014

1 commit


13 May, 2014

1 commit

  • Some functions in include/net.h are ported from
    include/linux/etherdevice.h of Linux Kernel.

    For ex.
    is_zero_ether_addr()
    is_multicast_ether_addr()
    is_broadcast_ether_addr()
    is_valid_ether_addr();

    So, we should use the same function name as that of Linux Kernel,
    eth_rand_addr(), for consistency.

    Besides, eth_rand_addr() has been implemented as an inline function.
    So it should not be surrounded by #ifdef CONFIG_RANDOM_MACADDR.

    Signed-off-by: Masahiro Yamada
    Acked-by: Joe Hershberger

    Masahiro Yamada
     

07 Feb, 2014

1 commit

  • In "common/Makefile" "miiphyutil.o" gets built if any of the following
    items enabled:
    * CONFIG_PHYLIB
    * CONFIG_MII
    * CONFIG_CMD_MII

    So it's possible to not define CONFIG_MII or CONFIG_CMD_MII and still
    use functions like "miiphy_get_dev_by_name".

    In its turn "miiphy_get_dev_by_name" traverses "mii_devs" list which is
    not initialized because "miiphy_init" never got called.

    Cc: Rob Herring
    Cc: Simon Glass
    Cc: Wolfgang Denk
    Acked-by: Joe Hershberger
    Signed-off-by: Alexey Brodkin

    Alexey Brodkin
     

24 Jul, 2013

1 commit


28 Sep, 2012

1 commit


25 Sep, 2012

2 commits

  • Previously u-boot would initialize the network interface for every
    network operation and then shut it down again. This makes sense for
    most operations where the network in not known to be needed soon after
    the operation is complete. In the case of netconsole, it will use the
    network for every interaction with the shell or every printf. This
    means that the network is being reinitialized very often. On many
    devices, this intialization is very slow.

    This patch checks for consecutive netconsole actions and leaves the
    ethernet hardware initialized between them. It will still behave the
    same old way for all other network operations and any time another
    network operation happens between netconsole operations.

    Signed-off-by: Joe Hershberger
    Cc: Stefano Babic
    Acked-by: Stefano Babic

    Joe Hershberger
     
  • If the requested length is too small to hold the received packet,
    eth_receive() will return -1 and will leave the packet in the receive
    buffers. Instead of returning an error in this case, we return the first
    portion of the received packet and remove it from the receive buffers.

    This fixes FreeBSD's ubldr. Without this patch it will just stop receiving
    packets if the NIC receives more than PKTBUFSRX too large packets.

    Signed-off-by: Michael Walle
    Cc: Joe Hershberger
    Cc: Rafal Jaworowski
    Cc: Piotr Kruszynski

    Michael Walle
     

12 Jul, 2012

2 commits


07 Jul, 2012

1 commit


16 May, 2012

3 commits


04 Apr, 2012

1 commit

  • Ignore the return value of eth_getenv_enetaddr_by_index(), and if it
    fails, fall back to use dev->enetaddr, which could be filled up by
    the ethernet device driver:

    With the current code, introduced with below commit, eth_write_hwaddr()
    will fail immediately if there is no ethaddr in the environment variables.

    However, e.g. for an overo based product that uses the SMSC911x ethernet
    chip (with the MAC address set via EEPROM connected to the SMSC911x chip),
    the MAC address is still OK.

    On mx28 boards that are depending on the OCOTP bits to set the MAC address
    (like the Denx m28 board), the OCOTP bits should be used instead of
    failing on the environment variables.

    Actually, this was the original behavior, and was later changed by
    commit 7616e7850804c7c69e0a22c179dfcba9e8f3f587.

    Signed-off-by: Eric Miao
    Acked-by: Simon Glass
    Acked-by: Dirk Behme
    CC: Stefan Roese
    CC: Eric Miao
    CC: Wolfgang Denk
    CC: Philip Balister
    CC: Zach Sadecki

    Eric Miao
     

19 Mar, 2012

4 commits