summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/spl/spl.c3
-rw-r--r--common/spl/spl_usb.c3
2 files changed, 2 insertions, 4 deletions
diff --git a/common/spl/spl.c b/common/spl/spl.c
index 84ae003..d2e23bf 100644
--- a/common/spl/spl.c
+++ b/common/spl/spl.c
@@ -400,9 +400,6 @@ static int spl_load_image(u32 boot_device)
bootdev.boot_device_name = "usb_ether";
return spl_net_load_image(&bootdev);
#endif
-#ifdef CONFIG_SPL_USB_SUPPORT
- case BOOT_DEVICE_USB:
- return spl_usb_load_image(&bootdev);
#endif
#ifdef CONFIG_SPL_SATA_SUPPORT
case BOOT_DEVICE_SATA:
diff --git a/common/spl/spl_usb.c b/common/spl/spl_usb.c
index f990336..2bc321a 100644
--- a/common/spl/spl_usb.c
+++ b/common/spl/spl_usb.c
@@ -22,7 +22,7 @@ DECLARE_GLOBAL_DATA_PTR;
static int usb_stor_curr_dev = -1; /* current device */
#endif
-int spl_usb_load_image(struct spl_boot_device *bootdev)
+static int spl_usb_load_image(struct spl_boot_device *bootdev)
{
int err;
struct blk_desc *stor_dev;
@@ -61,3 +61,4 @@ int spl_usb_load_image(struct spl_boot_device *bootdev)
return 0;
}
+SPL_LOAD_IMAGE_METHOD(0, BOOT_DEVICE_USB, spl_usb_load_image);