mirror of
https://github.com/u-boot/u-boot.git
synced 2025-04-26 23:41:50 +00:00
boot: set correct block device name in set_efi_bootdev()
For SATA devices the class name is 'ahci' but the block device name is 'sata'. Use function blk_get_uclass_name() to retrieve the correct string. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
751e5bfdb5
commit
ed3ce65958
1 changed files with 3 additions and 4 deletions
|
@ -100,11 +100,10 @@ static void set_efi_bootdev(struct blk_desc *desc, struct bootflow *bflow)
|
||||||
if (last_slash)
|
if (last_slash)
|
||||||
*last_slash = '\0';
|
*last_slash = '\0';
|
||||||
|
|
||||||
log_debug("setting bootdev %s, %s, %s, %p, %x\n",
|
|
||||||
dev_get_uclass_name(media_dev), devnum_str, bflow->fname,
|
|
||||||
bflow->buf, size);
|
|
||||||
dev_name = device_get_uclass_id(media_dev) == UCLASS_MASS_STORAGE ?
|
dev_name = device_get_uclass_id(media_dev) == UCLASS_MASS_STORAGE ?
|
||||||
"usb" : dev_get_uclass_name(media_dev);
|
"usb" : blk_get_uclass_name(device_get_uclass_id(media_dev));
|
||||||
|
log_debug("setting bootdev %s, %s, %s, %p, %x\n",
|
||||||
|
dev_name, devnum_str, bflow->fname, bflow->buf, size);
|
||||||
efi_set_bootdev(dev_name, devnum_str, bflow->fname, bflow->buf, size);
|
efi_set_bootdev(dev_name, devnum_str, bflow->fname, bflow->buf, size);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue