15 Nov, 2018

1 commit

  • When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be
    bound before relocation. However due to a bug in the DM core,
    the flag only takes effect when devices are statically declared
    via U_BOOT_DEVICE(). This bug has been fixed recently by commit
    "dm: core: Respect drivers with the DM_FLAG_PRE_RELOC flag in
    lists_bind_fdt()", but with the fix, it has a side effect that
    all existing drivers that declared DM_FLAG_PRE_RELOC flag will
    be bound before relocation now. This may expose potential boot
    failure on some boards due to insufficient memory during the
    pre-relocation stage.

    To mitigate this potential impact, the following changes are
    implemented:

    - Remove DM_FLAG_PRE_RELOC flag in the driver, if the driver
    only supports configuration from device tree (OF_CONTROL)
    - Keep DM_FLAG_PRE_RELOC flag in the driver only if the device
    is statically declared via U_BOOT_DEVICE()
    - Surround DM_FLAG_PRE_RELOC flag with OF_CONTROL check, for
    drivers that support both statically declared devices and
    configuration from device tree

    Signed-off-by: Bin Meng
    Reviewed-by: Simon Glass

    Bin Meng
     

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
     

01 Jun, 2017

1 commit

  • These support the flat device tree. We want to use the dev_read_..()
    prefix for functions that support both flat tree and live tree. So rename
    the existing functions to avoid confusion.

    In the end we will have:

    1. dev_read_addr...() - works on devices, supports flat/live tree
    2. devfdt_get_addr...() - current functions, flat tree only
    3. of_get_address() etc. - new functions, live tree only

    All drivers will be written to use 1. That function will in turn call
    either 2 or 3 depending on whether the flat or live tree is in use.

    Note this involves changing some dead code - the imx_lpi2c.c file.

    Signed-off-by: Simon Glass

    Simon Glass
     

08 Feb, 2017

1 commit

  • At present devices use a simple integer offset to record the device tree
    node associated with the device. In preparation for supporting a live
    device tree, which uses a node pointer instead, refactor existing code to
    access this field through an inline function.

    Signed-off-by: Simon Glass

    Simon Glass
     

20 Jun, 2016

1 commit

  • The following changes are made to the clock API:
    * The concept of "clocks" and "peripheral clocks" are unified; each clock
    provider now implements a single set of clocks. This provides a simpler
    conceptual interface to clients, and better aligns with device tree
    clock bindings.
    * Clocks are now identified with a single "struct clk", rather than
    requiring clients to store the clock provider device and clock identity
    values separately. For simple clock consumers, this isolates clients
    from internal details of the clock API.
    * clk.h is split so it only contains the client/consumer API, whereas
    clk-uclass.h contains the provider API. This aligns with the recently
    added reset and mailbox APIs.
    * clk_ops .of_xlate(), .request(), and .free() are added so providers
    can customize these operations if needed. This also aligns with the
    recently added reset and mailbox APIs.
    * clk_disable() is added.
    * All users of the current clock APIs are updated.
    * Sandbox clock tests are updated to exercise clock lookup via DT, and
    clock enable/disable.
    * rkclk_get_clk() is removed and replaced with standard APIs.

    Buildman shows no clock-related errors for any board for which buildman
    can download a toolchain.

    test/py passes for sandbox (which invokes the dm clk test amongst
    others).

    Signed-off-by: Stephen Warren
    Acked-by: Simon Glass

    Stephen Warren
     

25 May, 2016

2 commits


21 Oct, 2015

1 commit


31 Aug, 2015

1 commit

  • This is a convenient way for a driver to get the hardware address of a
    device, when regmap or syscon are not being used. Change existing callers
    to use it as an example to others.

    Signed-off-by: Simon Glass
    Reviewed-by: Joe Hershberger
    Acked-by: Stephen Warren

    Simon Glass
     

06 Aug, 2015

3 commits


23 Oct, 2014

1 commit


05 Feb, 2014

1 commit

  • This patch fix the u-boot shell problem on TRATS2 board.
    - If hold the key while booting is in progress,
    white spaces are written in u-boot shell.

    Set Automatically clears after resetting Rx FIFO.

    Signed-off-by: Inha Song
    Signed-off-by: Jaehoon Chung
    Acked-by: Lukasz Majewski
    Tested-by: Lukasz Majewski
    Signed-off-by: Minkyu Kang

    Inha Song
     

09 Nov, 2013

1 commit


24 Jul, 2013

1 commit


24 Jun, 2013

1 commit

  • This patch adds FDT support to the serial s5p driver.
    At present disabling the serial console (from the device tree) crashes
    U-Boot. Add checks for this case, so that execution can continue without
    a serial console.
    It also enables the serial_s5p driver recognize the silent_console option.

    Signed-off-by: Abhilash Kesavan
    Signed-off-by: Gabe Black
    Signed-off-by: Simon Glass
    Signed-off-by: Rajeshwari Shinde
    Signed-off-by: Minkyu Kang

    Rajeshwari Shinde
     

21 May, 2013

1 commit

  • This patch enables the uart tx/rx fifo. Now that fifo is enabled,
    the uart read/write functions are modfied to check the UFSTAT register
    for fifo status instead of UTRSTAT (as required with fifo's enabled).
    Tested by booting linux kernel. Before enabling tx/rx fifo
    "Uncompressing linux" message is garbled and after enabling it is proper.

    Signed-off-by: Alim Akhtar
    Signed-off-by: Akshay Saraswat
    Signed-off-by: Minkyu Kang

    Akshay Saraswat
     

16 Oct, 2012

2 commits

  • Move the registration of s5p_serialN_device ports from default
    serial_initialize() into driver specific function called from
    serial_initialize(). This slims down the serial_initialize() call
    to a bare tracker of all possible serial port registration routines
    in U-Boot.

    The newly implemented s5p_serial_initialize() function, which is
    implemented inside of the serial_s5p driver allows encapsulation
    of s5p_serialN_device within the serial_s5p driver itself.

    Also, remove the exports of s5p_serialN_device from include/serial.h
    as they are no longer needed. This is simply because the implementation of
    default_serial_console() is wrapped into the serial_s5p driver and
    the default console is picked by CONFIG_SERIAL macro in config file.

    Signed-off-by: Marek Vasut
    Cc: Marek Vasut
    Cc: Tom Rini
    Cc: Minkyu Kang

    Marek Vasut
     
  • Properly spell out the whole structure member names when an initialized
    varible is instantiated from the struct serial_driver. In case the
    structure definition for struct serial_driver undergoes reordering,
    there will be no impact on variables defined based on this structure.

    Signed-off-by: Marek Vasut
    Cc: Marek Vasut
    Cc: Tom Rini
    Cc: Anatolij Gustschin
    Cc: Stefan Roese
    Cc: Mike Frysinger
    Cc: C Nauman
    Cc: Minkyu Kang
    Cc: Michal Simek

    Marek Vasut
     

26 Jul, 2011

2 commits

  • The multi serial support has a "ctlr" field which almost no one uses,
    but everyone is forced to set to useless strings. So punt it.

    Funny enough, the only code that actually reads this field (the mpc8xx
    driver) has a typo where it meant to look for the SCC driver. Fix it
    while converting the check to use the name field.

    Signed-off-by: Mike Frysinger
    CC: Heiko Schocher
    CC: Anatolij Gustschin
    CC: Tom Rix
    CC: Minkyu Kang
    CC: Craig Nauman
    CC: Marek Vasut
    CC: Prafulla Wadaskar
    CC: Mahavir Jain

    Mike Frysinger
     
  • Rather than sticking arch/board/driver specific logic in the common
    serial code, push it all out to the respective drivers. The serial
    drivers declare these funcs weak so that boards can still override
    things with their own definition.

    Signed-off-by: Mike Frysinger
    CC: Heiko Schocher
    CC: Anatolij Gustschin
    CC: Tom Rix
    CC: Minkyu Kang
    CC: Craig Nauman
    CC: Prafulla Wadaskar
    CC: Mahavir Jain
    Tested-by: Minkyu Kang

    Mike Frysinger
     

02 Feb, 2011

1 commit


21 Dec, 2010

1 commit

  • It can be optimised out by the compiler otherwise resulting
    in obscure errors like a board not booting.

    This has been documented in README since 2006 when these were
    first fixed up for GCC 4.x.

    Signed-off-by: John Rigby

    Fix some additional places.

    Signed-off-by: Wolfgang Denk
    Acked-By: Albert ARIBAUD

    John Rigby
     

19 Oct, 2010

1 commit


30 Aug, 2010

1 commit

  • Because of peripheral devices can select clock sources,
    separate the peripheral clocks. (pwm, uart and so on)
    It just return the pclk at s5pc1xx SoC,
    but s5pc210 SoC must be calculated by own clock register setting.

    Signed-off-by: Minkyu Kang
    Signed-off-by: Kyungmin Park

    Minkyu Kang
     

17 Aug, 2010

1 commit


09 Jul, 2010

1 commit

  • remove below warnings
    serial_s5p.c: In function 'serial_getc_dev':
    serial_s5p.c:136: warning: dereferencing type-punned pointer will break strict-aliasing rules
    serial_s5p.c: In function 'serial_putc_dev':
    serial_s5p.c:152: warning: dereferencing type-punned pointer will break strict-aliasing rules

    Signed-off-by: Minkyu Kang
    Signed-off-by: Kyungmin Park

    Minkyu Kang
     

30 Apr, 2010

1 commit