net: Improve documentation for string_to_ip()
[oweals/u-boot.git] / include / spl.h
index c7cc2b0767cfcb18a76a49b5bd65eabedf2ef155..08ffddac29f27a5495881dbfc58258e220df3ed7 100644 (file)
@@ -200,6 +200,18 @@ int spl_load_simple_fit(struct spl_image_info *spl_image,
 #define SPL_COPY_PAYLOAD_ONLY  1
 #define SPL_FIT_FOUND          2
 
+/**
+ * spl_load_imx_container() - Loads a imx container image from a device.
+ * @spl_image: Image description to set up
+ * @info:      Structure containing the information required to load data.
+ * @sector:    Sector number where container image is located in the device
+ *
+ * Reads the container image @sector in the device. Loads u-boot image to
+ * specified load address.
+ */
+int spl_load_imx_container(struct spl_image_info *spl_image,
+                          struct spl_load_info *info, ulong sector);
+
 /* SPL common functions */
 void preloader_console_init(void);
 u32 spl_boot_device(void);
@@ -320,14 +332,14 @@ struct spl_image_loader {
  */
 #ifdef CONFIG_SPL_LIBCOMMON_SUPPORT
 #define SPL_LOAD_IMAGE_METHOD(_name, _priority, _boot_device, _method) \
-       SPL_LOAD_IMAGE(_method ## _priority ## _boot_device) = { \
+       SPL_LOAD_IMAGE(_boot_device ## _priority ## _method) = { \
                .name = _name, \
                .boot_device = _boot_device, \
                .load_image = _method, \
        }
 #else
 #define SPL_LOAD_IMAGE_METHOD(_name, _priority, _boot_device, _method) \
-       SPL_LOAD_IMAGE(_method ## _priority ## _boot_device) = { \
+       SPL_LOAD_IMAGE(_boot_device ## _priority ## _method) = { \
                .boot_device = _boot_device, \
                .load_image = _method, \
        }
@@ -422,6 +434,9 @@ int spl_mmc_load(struct spl_image_info *spl_image,
                 int raw_part,
                 unsigned long raw_sect);
 
+int spl_ymodem_load_image(struct spl_image_info *spl_image,
+                         struct spl_boot_device *bootdev);
+
 /**
  * spl_invoke_atf - boot using an ARM trusted firmware image
  */
@@ -453,7 +468,8 @@ void spl_invoke_opensbi(struct spl_image_info *spl_image);
  * stage wants to return to the ROM code to continue booting, boards
  * can implement 'board_return_to_bootrom'.
  */
-void board_return_to_bootrom(void);
+int board_return_to_bootrom(struct spl_image_info *spl_image,
+                           struct spl_boot_device *bootdev);
 
 /**
  * board_spl_fit_post_load - allow process images after loading finished