[PATCH v2 1/1] sandbox: fix return type of os_filesize()

Simon Glass sjg at chromium.org
Sat Apr 22 18:51:27 CEST 2023


On Wed, 5 Apr 2023 at 21:34, Heinrich Schuchardt
<heinrich.schuchardt at canonical.com> wrote:
>
> Given a file ../img of size 4294967296 with GPT partition table and
> partitions:
>
> => host bind 0 ../img
> => part list host 0
> Disk host-0.blk not ready
>
> The cause is os_filesize() returning int. File sizes must use off_t.
>
> Correct all uses of os_filesize() too.
>
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt at canonical.com>
> ---
> v2:
>         avoid different signedness when comparing numbers
> ---
>  arch/sandbox/cpu/os.c    | 8 ++++++--
>  drivers/block/host_dev.c | 3 ++-
>  include/os.h             | 2 +-
>  3 files changed, 9 insertions(+), 4 deletions(-)

Reviewed-by: Simon Glass <sjg at chromium.org>

Applied to u-boot-dm, thanks!


More information about the U-Boot mailing list