]> git.dujemihanovic.xyz Git - u-boot.git/commit
pxe: Refactor sysboot to have one helper
authorSimon Glass <sjg@chromium.org>
Thu, 14 Oct 2021 18:48:09 +0000 (12:48 -0600)
committerTom Rini <trini@konsulko.com>
Fri, 12 Nov 2021 00:02:39 +0000 (19:02 -0500)
commit81a2f8d34b4ef38f8a4dbb9013ab65476644603a
treea78e807aa921ebbc5259ed38edf59298fa9ce44b
parent4d79e884adf6842beb94566bf5249c07a84a5b51
pxe: Refactor sysboot to have one helper

The only difference between the three helpers is the filesystem type.
Factor this out and call the filesystem functions directly, instead of
through the command-line interpreter. This allows the file size to be
obtained directly, instead of via an environment variable.

We cannot do the same thing with PXE's tftpboot since there is no API
at present to obtain information about the file that was read. So there
is no point in changing pxe_getfile_func to use a ulong for the address,
for example.

This is as far as the refactoring can go for the present.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Artem Lapkin <email2tema@gmail.com>
Tested-by: Artem Lapkin <email2tema@gmail.com>
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
cmd/sysboot.c