diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2014-02-03 09:52:34 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2014-02-03 09:52:34 +0100 |
commit | ca10989374ffb6f08fde864a95c623fc7557b8e8 (patch) | |
tree | f87522919e6b55c7f7dcab5bc4e9e4e37eaa2a49 /include | |
parent | fd6fe68e95bb418456973cfa4b1760d9060ba4df (diff) | |
parent | 0c66005aeaeb85e247e715bd18ac3b621481e425 (diff) | |
download | barebox-ca10989374ffb6f08fde864a95c623fc7557b8e8.tar.gz barebox-ca10989374ffb6f08fde864a95c623fc7557b8e8.tar.xz |
Merge branch 'for-next/bootm'
Diffstat (limited to 'include')
-rw-r--r-- | include/boot.h | 5 | ||||
-rw-r--r-- | include/linux/list.h | 11 |
2 files changed, 16 insertions, 0 deletions
diff --git a/include/boot.h b/include/boot.h index 56f6c359b9..bdd5477d35 100644 --- a/include/boot.h +++ b/include/boot.h @@ -61,6 +61,7 @@ struct image_data { struct device_node *of_root_node; struct fdt_header *oftree; + struct resource *oftree_res; int verify; int verbose; @@ -108,6 +109,10 @@ static inline int linux_bootargs_overwrite(const char *bootargs) } #endif +int bootm_load_os(struct image_data *data, unsigned long load_address); +int bootm_load_initrd(struct image_data *data, unsigned long load_address); +int bootm_load_devicetree(struct image_data *data, unsigned long load_address); + #define UIMAGE_SOME_ADDRESS (UIMAGE_INVALID_ADDRESS - 1) #endif /* __BOOT_H */ diff --git a/include/linux/list.h b/include/linux/list.h index 5ae90b43a3..bc63ece95d 100644 --- a/include/linux/list.h +++ b/include/linux/list.h @@ -292,6 +292,17 @@ static inline void list_splice_init(struct list_head *list, list_entry((head)->prev, type, member) /** + * list_first_entry_or_null - get the first element from a list + * @ptr: the list head to take the element from. + * @type: the type of the struct this is embedded in. + * @member: the name of the list_struct within the struct. + * + * Note that if the list is empty, it returns NULL. + */ +#define list_first_entry_or_null(ptr, type, member) \ + (!list_empty(ptr) ? list_first_entry(ptr, type, member) : NULL) + +/** * list_for_each - iterate over a list * @pos: the &struct list_head to use as a loop cursor. * @head: the head for your list. |