15 May, 2018

1 commit

  • When the following configuration is set

    # CONFIG_CMD_DHCP is not set
    CONFIG_CMD_BOOTP=y
    CONFIG_BOOTP_NTPSERVER=y

    The following compile error is observed

    error: used struct type value where scalar is required
    if (net_ntp_server)
    ^~~~~~~~~~~~~~

    Resolve this by checking net_ntp_server.s_addr instead.

    Signed-off-by: Chris Packham
    Acked-by: Joe Hershberger

    Chris Packham
     

11 May, 2018

1 commit

  • As part of the main conversion a few files were missed. These files had
    additional whitespace after the '*' and before the SPDX tag and my
    previous regex was too strict. This time I did a grep for all SPDX tags
    and then filtered out anything that matched the correct styles.

    Fixes: 83d290c56fab ("SPDX: Convert all of our single license tags to Linux Kernel style")
    Reported-by: Heinrich Schuchardt
    Signed-off-by: Tom Rini

    Tom Rini
     

07 May, 2018

1 commit

  • When U-Boot started using SPDX tags we were among the early adopters and
    there weren't a lot of other examples to borrow from. So we picked the
    area of the file that usually had a full license text and replaced it
    with an appropriate SPDX-License-Identifier: entry. Since then, the
    Linux Kernel has adopted SPDX tags and they place it as the very first
    line in a file (except where shebangs are used, then it's second line)
    and with slightly different comment styles than us.

    In part due to community overlap, in part due to better tag visibility
    and in part for other minor reasons, switch over to that style.

    This commit changes all instances where we have a single declared
    license in the tag as both the before and after are identical in tag
    contents. There's also a few places where I found we did not have a tag
    and have introduced one.

    Signed-off-by: Tom Rini

    Tom Rini
     

28 Apr, 2018

1 commit


14 Apr, 2018

3 commits


09 Apr, 2018

1 commit

  • In order that we can use eth_env_* even when CONFIG_NET isn't set, move
    these functions to environment code from net code.

    This fixes failures such as:

    board/ti/am335x/built-in.o: In function `board_late_init':
    board/ti/am335x/board.c:752: undefined reference to `eth_env_set_enetaddr'
    u-boot/board/ti/am335x/board.c:766: undefined reference to `eth_env_set_enetaddr'

    which caters for use cases such as:

    commit f411b5cca48f ("board: am335x: Always set eth/eth1addr environment
    variable")

    when Ethernet is required in Linux, but not U-Boot.

    Signed-off-by: Alex Kiernan

    Alex Kiernan
     

23 Mar, 2018

2 commits

  • In the efi_loader main loop we call eth_rx() occasionally. This rx function
    might end up calling into devices that haven't been initialized yet,
    potentially resulting in a lot of transfer timeouts.

    Instead, let's make sure the ethernet device is actually initialized before
    reading from or writing to it.

    Signed-off-by: Alexander Graf
    Acked-by: Joe Hershberger

    Alexander Graf
     
  • The "net_try_count" counter starts from "1".
    And the "retrycnt" contains requested amount of retries.

    With current logic, that means that the actual retry amount
    will be one time less then what we set in "netretry" env.
    For example setting "netretry" to "once" will make "retrycnt"
    equal "1", so no retries will be triggered at all.

    Fix the logic by changing the statement of "if" condition.

    Signed-off-by: Leonid Iziumtsev
    Acked-by: Joe Hershberger

    Leonid Iziumtsev
     

28 Feb, 2018

1 commit


24 Feb, 2018

1 commit

  • This converts the following to Kconfig:
    CONFIG_BOOTP_BOOTPATH
    CONFIG_BOOTP_DNS
    CONFIG_BOOTP_GATEWAY
    CONFIG_BOOTP_HOSTNAME
    CONFIG_BOOTP_PXE
    CONFIG_BOOTP_SUBNETMASK
    CONFIG_CMDLINE_EDITING
    CONFIG_AUTO_COMPLETE
    CONFIG_SYS_LONGHELP
    CONFIG_SUPPORT_RAW_INITRD
    CONFIG_ENV_VARS_UBOOT_CONFIG

    Signed-off-by: Adam Ford
    [trini: Re-run the migration]
    Signed-off-by: Tom Rini

    Adam Ford
     

09 Feb, 2018

1 commit

  • config_fallbacks.h had some logic to automatically select
    LIB_RAND if RANDOM_UUID or CMD_UUID were set if LIB_HW_RAND wasn't
    already selected. By migrating LIB_HW_RAND to Kconfig, we can
    remove this check from config_fallbacks.h and put it into Kconfig

    Signed-off-by: Adam Ford
    Reviewed-by: Lukasz Majewski
    [trini: Turn into a choice, add NET_RANDOM_ETHADDR]
    Signed-off-by: Tom Rini

    Adam Ford
     

16 Jan, 2018

2 commits


22 Sep, 2017

1 commit


08 Sep, 2017

1 commit

  • In the general case, CONFIG_NFS_READ_SIZE is unchanged from the default
    of 1024. There are in fact no in-tree users that increase this size.
    Adjust the comment to reflect what could be done in the future in
    conjunction with CONFIG_IP_DEFRAG.

    Cc: Joe Hershberger
    Signed-off-by: Tom Rini
    Acked-by: Joe Hershberger

    Tom Rini
     

16 Aug, 2017

7 commits


08 Aug, 2017

4 commits

  • PXE boot is broken with GCC 7.1 due option '-fstore-merging' enabled
    by default for '-O2':

    BOOTP broadcast 1
    data abort
    pc : [] lr : []
    reloc pc : [] lr : []
    sp : 8f558bc0 ip : 00000000 fp : 8ffef5a4
    r10: 8ffed248 r9 : 8f558ee0 r8 : 8ffef594
    r7 : 0000000e r6 : 8ffed700 r5 : 00000000 r4 : 8ffed74e
    r3 : 00060101 r2 : 8ffed230 r1 : 8ffed706 r0 : 00000ddd
    Flags: nzcv IRQs off FIQs off Mode SVC_32
    Resetting CPU ...

    Core reason is usage of structures for network headers without packed
    attribute.

    Reviewed-by: Yauheni Kaliuta
    Signed-off-by: Denis Pynkin
    Acked-by: Joe Hershberger

    Denis Pynkin
     
  • Add missing "defined" statement to fix the compile failures.

    Signed-off-by: Holger Dengler
    Acked-by: Joe Hershberger

    Holger Dengler
     
  • For strncpy() select a minimal string length of destination and source
    strings, here DEFAULT_NAME_LEN is preferable to MAX_LEN.

    Due to the NUL-terminated contents of default_string the change is
    a noop, however it removes a compilation warning if SH2/3/4 platform
    specific strncpy() function is used:

    In file included from include/linux/string.h:21:0,
    from include/common.h:28,
    from net/tftp.c:9:

    net/tftp.c: In function 'tftp_start':
    arch/sh/include/asm/string.h:52:42: warning: array subscript is above array bounds [-Warray-bounds]
    : "0" (__dest), "1" (__src), "r" (__src+__n)

    Signed-off-by: Vladimir Zapolskiy
    Acked-by: Joe Hershberger

    Vladimir Zapolskiy
     
  • Previously seeded by obtaining mac addr from env. If mac addr was
    never set, rand would output 0. This fix obtains the mac addr
    from driver instead.

    Signed-off-by: Jimmy Du
    Acked-by: Joe Hershberger

    Jimmy Du
     

03 Jun, 2017

1 commit


12 May, 2017

2 commits

  • We will see warnings such as:
    net/eth_common.c:57:61: warning: data argument not used by format string [-Wformat-extra-args]
    sprintf(enetvar, index ? "%s%daddr" : "%saddr", base_name, index);
    ~~~~~~~~ ^
    With clang. In this case we do not want to re-write our code to be less
    compact as the above is intentional and readable. Add a comment above
    the disabling so that it's clear why we want that warning off.

    Signed-off-by: Tom Rini

    Tom Rini
     
  • The value of variable pkt is never used.

    The problem was indicated by clang scan-build.

    Signed-off-by: Heinrich Schuchardt

    xypron.glpk@gmx.de
     

26 Mar, 2017

1 commit

  • The network mask must be stored in network order when in a
    'struct in_addr'.

    This fix removes the "gatewayip needed but not set" message on the
    console when using a link-local IP setup.

    Signed-off-by: Alexandre Messier
    Signed-off-by: Sylvain Lemieux
    Acked-by: Joe Hershberger

    Alexandre Messier
     

21 Mar, 2017

1 commit


08 Feb, 2017

3 commits


22 Jan, 2017

1 commit

  • Move all of the status LED feature to drivers/led/Kconfig.
    The LED status definitions were moved from the board configuration
    files to the defconfig files.

    TBD: Move all of the definitions in the include/status_led.h to the
    relevant board's defconfig files.

    Tested boards: CL-SOM-AM57x, CM-T335

    Signed-off-by: Uri Mashiach

    Uri Mashiach
     

14 Nov, 2016

1 commit

  • If mac-address is changed using "setenv ethaddr ...." command the new
    mac-adress also must be written into the responsible ethernet driver.
    This fixes the legacy ethernet handling.

    Signed-off-by: Marek Vasut
    Cc: Hannes Schmelzer
    Cc: Joe Hershberger
    Cc: Tom Rini
    Reviewed-by: Hannes Schmelzer

    Marek Vasut
     

08 Nov, 2016

1 commit


14 Oct, 2016

1 commit