05 Oct, 2019

1 commit

  • At this point we are using part number sub-command to retrieve UUID
    of the partition using it's name.

    e.g.:
    part number mmc $mmcdev system_a system_a_index
    part uuid mmc $mmcdev:${system_a_index} system_a_uuid

    Since 'part uuid' sub-command expects partition index in hex format and
    'part number' returns decimal value, 'part uuid' command will provide
    wrong UUID or fail.

    Fixes: be683756f62034 ("cmd: part: Add 'number' sub-command")
    Cc: Dirk Behme
    Reported-by: Pontus Fuchs
    Signed-off-by: Roman Stratiienko
    Signed-off-by: Eugeniu Rosca
    Reviewed-by: Tom Rini
    Reviewed-by: Igor Opaniuk

    Roman Stratiienko
     

12 Aug, 2019

1 commit


25 Jul, 2019

1 commit

  • This sub-command serves for getting the partition index from
    partition name. Also it can be used to test the existence of specified
    partition.

    Use case:
    For example, in most CI environments this U-Boot command for automatic
    testing of Linux rootfs is used:

    => setenv bootpart 1:f

    where 0xf is "userdata" partition. But the number of "userdata"
    partition can be changed any time, when partition table is changed.

    So it would be nice to get rid of that 0xf magic number and use
    partition name instead, like this:

    => part number mmc 1 userdata part_num
    => setenv bootpart 1:${part_num}

    Signed-off-by: Ruslan Trofymenko
    Signed-off-by: Igor Opaniuk
    Reviewed-by: Alistair Strachan
    Reviewed-by: Sam Protsenko
    Reviewed-by: Simon Glass
    Reviewed-by: Sam Protsenko

    Ruslan Trofymenko
     

11 Sep, 2018

1 commit


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
     

14 Mar, 2018

2 commits

  • Refactor the code for "part start" and "part size" commands to avoid
    code duplication.

    Signed-off-by: Sam Protsenko
    Reviewed-by: Lukasz Majewski

    Sam Protsenko
     
  • Allow passing the partition name to "part start" and "part size"
    commands, so we can avoid magic numbers in the environment.

    Consider one real use-case: in include/environment/ti/boot.h we have
    commands like these:

    setenv boot_part 9
    part start mmc ${mmcdev} ${boot_part} boot_start
    part size mmc ${mmcdev} ${boot_part} boot_size
    mmc read ${loadaddr} ${boot_start} ${boot_size}

    Now suppose that we have changed the partition table and boot_part now
    is 10. We will need to fix commands above. And anyone who relies on
    these boot commands, will need to change them accordingly, too (this was
    an actual case in our lab while testing Linux boot on Android
    environment).

    By providing the option to pass partition name instead, we fix mentioned
    issue, by eliminating the necessity to use magic numbers.

    Signed-off-by: Sam Protsenko
    Reviewed-by: Lukasz Majewski

    Sam Protsenko
     

16 Aug, 2017

1 commit


28 Jan, 2017

1 commit


15 Mar, 2016

4 commits


25 Jan, 2016

1 commit

  • Now that they are in their own directory, we can remove this prefix.
    This makes it easier to find a file since the prefix does not get in the
    way.

    Signed-off-by: Simon Glass
    Reviewed-by: Bin Meng
    Reviewed-by: Heiko Schocher
    Acked-by: Stefan Roese
    Acked-by: Przemyslaw Marczak

    Simon Glass