diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/common.h | 10 | ||||
-rw-r--r-- | include/linux/clk.h | 10 | ||||
-rw-r--r-- | include/linux/nvmem-consumer.h | 2 | ||||
-rw-r--r-- | include/linux/pstore.h | 6 | ||||
-rw-r--r-- | include/mfd/syscon.h | 9 | ||||
-rw-r--r-- | include/of_device.h | 4 |
6 files changed, 36 insertions, 5 deletions
diff --git a/include/common.h b/include/common.h index a947406e1b..8cc8e14fb7 100644 --- a/include/common.h +++ b/include/common.h @@ -93,6 +93,16 @@ unsigned long long strtoull_suffix(const char *str, char **endp, int base); */ extern int (*barebox_main)(void); +enum autoboot_state { + AUTOBOOT_UNKNOWN, + AUTOBOOT_ABORT, + AUTOBOOT_MENU, + AUTOBOOT_BOOT, +}; + +void set_autoboot_state(enum autoboot_state autoboot); +enum autoboot_state do_autoboot_countdown(void); + void __noreturn start_barebox(void); void shutdown_barebox(void); diff --git a/include/linux/clk.h b/include/linux/clk.h index b9c5e0ab04..c3aeea80dd 100644 --- a/include/linux/clk.h +++ b/include/linux/clk.h @@ -340,6 +340,8 @@ struct clk_divider { int table_size; }; +#define clk_div_mask(width) ((1 << (width)) - 1) + #define CLK_DIVIDER_POWER_OF_TWO (1 << 1) #define CLK_DIVIDER_HIWORD_MASK (1 << 3) #define CLK_DIVIDER_READ_ONLY (1 << 5) @@ -354,6 +356,14 @@ unsigned long divider_recalc_rate(struct clk *clk, unsigned long parent_rate, const struct clk_div_table *table, unsigned long flags, unsigned long width); +long divider_round_rate(struct clk *clk, unsigned long rate, + unsigned long *prate, const struct clk_div_table *table, + u8 width, unsigned long flags); + +int divider_get_val(unsigned long rate, unsigned long parent_rate, + const struct clk_div_table *table, u8 width, + unsigned long flags); + struct clk *clk_divider_alloc(const char *name, const char *parent, unsigned clk_flags, void __iomem *reg, u8 shift, u8 width, unsigned div_flags); diff --git a/include/linux/nvmem-consumer.h b/include/linux/nvmem-consumer.h index 32ea46e3bf..9e0fd4265e 100644 --- a/include/linux/nvmem-consumer.h +++ b/include/linux/nvmem-consumer.h @@ -103,6 +103,6 @@ static inline struct nvmem_device *of_nvmem_device_get(struct device_node *np, { return ERR_PTR(-ENOSYS); } -#endif /* CONFIG_NVMEM && CONFIG_OF */ +#endif /* CONFIG_NVMEM && CONFIG_OFTREE */ #endif /* ifndef _LINUX_NVMEM_CONSUMER_H */ diff --git a/include/linux/pstore.h b/include/linux/pstore.h index 15e1e3d6fa..f598f31a54 100644 --- a/include/linux/pstore.h +++ b/include/linux/pstore.h @@ -64,8 +64,6 @@ struct pstore_record { struct pstore_info { struct module *owner; char *name; - char *buf; - size_t bufsize; int flags; int (*open)(struct pstore_info *psi); int (*close)(struct pstore_info *psi); @@ -85,6 +83,7 @@ struct pstore_info { #ifdef CONFIG_FS_PSTORE extern int pstore_register(struct pstore_info *); extern bool pstore_cannot_block_path(enum kmsg_dump_reason reason); +extern void pstore_log(const char *msg); #else static inline int pstore_register(struct pstore_info *psi) @@ -96,6 +95,9 @@ pstore_cannot_block_path(enum kmsg_dump_reason reason) { return false; } +static inline void pstore_log(const char *msg) +{ +} #endif #endif /*_LINUX_PSTORE_H*/ diff --git a/include/mfd/syscon.h b/include/mfd/syscon.h index 902f9fa2f3..ac33f2d347 100644 --- a/include/mfd/syscon.h +++ b/include/mfd/syscon.h @@ -22,6 +22,9 @@ void __iomem *syscon_base_lookup_by_phandle (struct device_node *np, const char *property); struct regmap *syscon_node_to_regmap(struct device_node *np); struct regmap *syscon_regmap_lookup_by_compatible(const char *s); +extern struct regmap *syscon_regmap_lookup_by_phandle( + struct device_node *np, + const char *property); #else static inline void __iomem *syscon_base_lookup_by_pdevname(const char *s) { @@ -42,6 +45,12 @@ static inline struct regmap *syscon_regmap_lookup_by_compatible(const char *s) { return ERR_PTR(-ENOSYS); } +static inline struct regmap *syscon_regmap_lookup_by_phandle( + struct device_node *np, + const char *property) +{ + return ERR_PTR(-ENOSYS); +} #endif #endif diff --git a/include/of_device.h b/include/of_device.h index 44c1c0f545..54410ad12f 100644 --- a/include/of_device.h +++ b/include/of_device.h @@ -22,7 +22,7 @@ static inline int of_driver_match_device(struct device_d *dev, extern const void *of_device_get_match_data(const struct device_d *dev); -#else /* CONFIG_OF */ +#else /* CONFIG_OFTREE */ static inline int of_driver_match_device(struct device_d *dev, const struct device_d *drv) @@ -43,6 +43,6 @@ static inline const struct of_device_id *__of_match_device( #define of_match_device(matches, dev) \ __of_match_device(matches, (dev)) -#endif /* CONFIG_OF */ +#endif /* CONFIG_OFTREE */ #endif /* _LINUX_OF_DEVICE_H */ |