10 Mar, 2020

1 commit

  • doc/README.drivers.eth seems like a good source for understanding
    U-Boot's network subsystem, but is only talking about legacy network
    drivers. This is particularly sad as proper documentation would help in
    porting drivers over to the driver model.

    Rewrite the document to describe network drivers in the new driver model
    world. Most driver callbacks/methods are almost identical in their
    semantic, but recv() differs in some important details.

    Also keep some parts of the original text at the end, to help
    understanding old drivers. Add some hints on how to port drivers over.

    This also uses the opportunity to reformat the document in reST, on the
    way moving it into doc/driver-model and adding it into the structure
    there.

    Signed-off-by: Andre Przywara
    Reviewed-by: Simon Glass
    Acked-by: Joe Hershberger

    Andre Przywara
     

11 Feb, 2020

2 commits


06 Feb, 2020

1 commit

  • Following the recommendation of adding '#define DEBUG' at the top
    of drivers/core/lists.c does not cause the debug messages to be
    shown. Change it to '#define LOG_DEBUG' instead, which actually
    makes it work as per doc/README.log.

    While at it, provide the full path to lists.c to in order to make
    the instructions clearer.

    Signed-off-by: Fabio Estevam
    Reviewed-by: Simon Glass

    Fabio Estevam
     

15 Dec, 2019

1 commit


03 Nov, 2019

1 commit


25 Oct, 2019

2 commits

  • We need distinguish the following two situations in various SPI APIs:

    - given chip select num is invalid
    - given chip select num is valid, but no device is attached

    Currently -ENODEV is returned for both cases.

    For the first case, it's more reasonable to return -EINVAL instead of
    -ENODEV for invalid chip select numbers.

    Signed-off-by: Bin Meng
    Tested-by: Jagan Teki # SoPine
    Reviewed-by: Jagan Teki

    Bin Meng
     
  • If an SPI controller driver does not implement ops->cs_info, that
    probably means any chip select number could be valid, hence let's
    return 0 for spi_cs_info().

    Signed-off-by: Bin Meng
    Tested-by: Jagan Teki # SoPine
    Reviewed-by: Jagan Teki

    Bin Meng
     

15 Oct, 2019

1 commit


08 Oct, 2019

3 commits

  • Fix these spelling errors the header file and documentation.

    Fix a small typo in the PCI documentation.

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

    Simon Glass
     
  • Sandbox pci works using emulation drivers which are currently children of
    the pci device:

    pci-controller {
    pci@1f,0 {
    compatible = "pci-generic";
    reg = ;
    emul@1f,0 {
    compatible = "sandbox,swap-case";
    };
    };
    };

    In this case the emulation device is attached to pci device on address
    f800 (device 1f, function 0) and provides the swap-case functionality.

    However this is not ideal, since every device on a PCI bus has a child
    device. This is only really the case for sandbox, but we want to avoid
    special-case code for sandbox.

    Worse, child devices cannot be probed before their parents. This forces
    us to use 'find' rather than 'get' to obtain the emulator device. In fact
    the emulator devices are never probed. There is code in
    sandbox_pci_emul_post_probe() which tries to track when emulators are
    active, but at present this does not work.

    A better approach seems to be to add a separate node elsewhere in the
    device tree, an 'emulation parent'. This could be given a bogus address
    (such as -1) to hide the emulators away from the 'pci' command, but it
    seems better to keep it at the root node to avoid such hacks.

    Then we can use a phandle to point from the device to the correct
    emulator, and only on sandbox. The code to find an emulator does not
    interfere with normal pci operation.

    Add a new UCLASS_PCI_EMUL_PARENT uclass which allows finding an emulator
    given a bus, and finding a bus given an emulator. Update the existing
    device trees and the code for finding an emulator.

    This brings PCI emulators more into line with I2C.

    Signed-off-by: Simon Glass
    Reviewed-by: Bin Meng
    Tested-by: Bin Meng
    [bmeng: fix 3 typos in the commit message;
    encode bus number in the labels of swap_case_emul nodes;
    mention commit 4345998ae9df in sandbox_pci_get_emul()]
    Signed-off-by: Bin Meng

    Simon Glass
     
  • Sometimes devices don't appear and it can be confusing. Add a few notes to
    help with this situation.

    Signed-off-by: Simon Glass
    Reviewed-by: Bin Meng
    Tested-by: Bin Meng
    [bmeng: fix 2 issues in the doc and include the doc in the index.rst]
    Signed-off-by: Bin Meng

    Simon Glass
     

20 Sep, 2019

2 commits

  • For many sub-systems we already require the driver model to be used. Yet
    there is still a handful of boards that do not have CONFIG_DM enabled.

    We should make CONFIG_DM compulsory with release v2020.01

    Conversion dates for CONFIG_DM_SPL and CONFIG_DM_TPL are yet to be defined.

    Signed-off-by: Heinrich Schuchardt
    Reviewed-by: Simon Glass

    Heinrich Schuchardt
     
  • The of-plat.rst file till this change has been using

    This is at best misleading as SPL_OF_PLATDATA is always defined when we
    want to use this SPL tinification feature (also in U-Boot proper).
    As a result the OF_PLATDATA SPL specific code is also compiled in when
    U-Boot proper is build.

    Signed-off-by: Lukasz Majewski
    Reviewed-by: Peng Fan
    Reviewed-by: Simon Glass

    Lukasz Majewski
     

16 Sep, 2019

1 commit


05 Sep, 2019

1 commit


24 Jul, 2019

14 commits


11 Jul, 2019

1 commit


10 Jun, 2019

1 commit


23 Apr, 2019

1 commit


17 Apr, 2019

1 commit

  • Now that all boards using TI QSPI have moved to DM and DT, drop non DM
    code completely.

    Signed-off-by: Vignesh Raghavendra
    Reviewed-by: Tom Rini
    [jagan: update MIGRATION.txt, rebase config_whitelist.txt]
    Signed-off-by: Jagan Teki
    Reviewed-by: Jagan Teki

    Vignesh Raghavendra
     

10 Feb, 2019

1 commit


16 Jan, 2019

1 commit


09 Jan, 2019

2 commits


02 Jan, 2019

1 commit


13 Dec, 2018

1 commit

  • The function part_init() will only be built when we have both
    CONFIG_PARTITIONS and CONFIG_HAVE_BLOCK_DEVICE set. Protect the call to
    this function with both of these tests now.

    Cc: Simon Glass
    Cc: Philipp Tomsich
    Cc: Michal Simek
    Cc: York Sun
    Cc: Prabhakar Kushwaha
    Cc: Mingkai Hu
    Cc: Stefan Roese
    Cc: Marek Behún
    Cc: Vanessa Maegima
    Cc: Eugen Hristev
    Cc: Adam Ford
    Cc: Jagan Teki
    Cc: Tom Warren
    Cc: Stephen Warren
    Cc: Vitaly Andrianov
    Signed-off-by: Tom Rini
    Reviewed-by: Simon Glass

    Tom Rini