+/**
+ * struct spl_boot_device - Describes a boot device used by SPL
+ *
+ * @boot_device: A number indicating the BOOT_DEVICE type. There are various
+ * BOOT_DEVICE... #defines and enums in U-Boot and they are not consistently
+ * numbered.
+ * @boot_device_name: Named boot device, or NULL if none.
+ *
+ * Note: Additional fields can be added here, bearing in mind that SPL is
+ * size-sensitive and common fields will be present on all boards. This
+ * struct can also be used to return additional information about the load
+ * process if that becomes useful.
+ */
+struct spl_boot_device {
+ uint boot_device;
+ const char *boot_device_name;
+};
+
+/**
+ * Holds information about a way of loading an SPL image
+ *
+ * @name: User-friendly name for this method (e.g. "MMC")
+ * @boot_device: Boot device that this loader supports
+ * @load_image: Function to call to load image
+ */
+struct spl_image_loader {
+#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT
+ const char *name;
+#endif
+ uint boot_device;
+ /**
+ * load_image() - Load an SPL image
+ *
+ * @spl_image: place to put image information
+ * @bootdev: describes the boot device to load from
+ */
+ int (*load_image)(struct spl_image_info *spl_image,
+ struct spl_boot_device *bootdev);
+};