summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/common.h10
-rw-r--r--include/hab.h1
-rw-r--r--include/libbb.h1
-rw-r--r--include/linux/clk.h30
-rw-r--r--include/linux/nvmem-consumer.h4
-rw-r--r--include/net.h8
-rw-r--r--include/of_device.h2
-rw-r--r--include/platform_data/eth-davinci-emac.h10
-rw-r--r--include/printk.h21
9 files changed, 51 insertions, 36 deletions
diff --git a/include/common.h b/include/common.h
index f52c7e430c..11d26cb3db 100644
--- a/include/common.h
+++ b/include/common.h
@@ -112,16 +112,6 @@ void shutdown_barebox(void);
#define PAGE_ALIGN(s) ALIGN(s, PAGE_SIZE)
#define PAGE_ALIGN_DOWN(x) ALIGN_DOWN(x, PAGE_SIZE)
-int memory_display(const void *addr, loff_t offs, unsigned nbytes, int size, int swab);
-
-#define DUMP_PREFIX_OFFSET 0
-static inline void print_hex_dump(const char *level, const char *prefix_str,
- int prefix_type, int rowsize, int groupsize,
- const void *buf, size_t len, bool ascii)
-{
- memory_display(buf, 0, len, 4, 0);
-}
-
int mem_parse_options(int argc, char *argv[], char *optstr, int *mode,
char **sourcefile, char **destfile, int *swab);
#define RW_BUF_SIZE (unsigned)4096
diff --git a/include/hab.h b/include/hab.h
index 78c2b865ba..abfce18736 100644
--- a/include/hab.h
+++ b/include/hab.h
@@ -21,6 +21,7 @@
#include <errno.h>
#ifdef CONFIG_HABV4
+extern bool habv4_need_rng_software_self_test;
int imx28_hab_get_status(void);
int imx6_hab_get_status(void);
#else
diff --git a/include/libbb.h b/include/libbb.h
index a362bd32d8..1f6afaa27a 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -17,6 +17,7 @@ enum {
ACTION_FOLLOWLINKS = (1 << 1),
ACTION_DEPTHFIRST = (1 << 2),
/*ACTION_REVERSE = (1 << 3), - unused */
+ ACTION_SORT = (1 << 4),
};
int recursive_action(const char *fileName, unsigned flags,
diff --git a/include/linux/clk.h b/include/linux/clk.h
index c6465b1c90..26da1114e8 100644
--- a/include/linux/clk.h
+++ b/include/linux/clk.h
@@ -325,6 +325,11 @@ struct device_node;
struct of_phandle_args;
struct of_device_id;
+struct clk_onecell_data {
+ struct clk **clks;
+ unsigned int clk_num;
+};
+
#if defined(CONFIG_COMMON_CLK_OF_PROVIDER)
#define CLK_OF_DECLARE(name, compat, fn) \
@@ -336,10 +341,6 @@ void of_clk_del_provider(struct device_node *np);
typedef int (*of_clk_init_cb_t)(struct device_node *);
-struct clk_onecell_data {
- struct clk **clks;
- unsigned int clk_num;
-};
struct clk *of_clk_src_onecell_get(struct of_phandle_args *clkspec, void *data);
struct clk *of_clk_src_simple_get(struct of_phandle_args *clkspec, void *data);
@@ -350,6 +351,10 @@ unsigned int of_clk_get_parent_count(struct device_node *np);
int of_clk_parent_fill(struct device_node *np, const char **parents,
unsigned int size);
int of_clk_init(struct device_node *root, const struct of_device_id *matches);
+int of_clk_add_provider(struct device_node *np,
+ struct clk *(*clk_src_get)(struct of_phandle_args *args,
+ void *data),
+ void *data);
#else
@@ -362,12 +367,16 @@ static const struct of_device_id __clk_of_table_##name \
__attribute__ ((unused)) = { .data = fn }
+static inline struct clk *of_clk_src_onecell_get(struct of_phandle_args *clkspec,
+ void *data)
+{
+ return ERR_PTR(-ENOENT);
+}
static inline struct clk *
of_clk_src_simple_get(struct of_phandle_args *clkspec, void *data)
{
return ERR_PTR(-ENOENT);
}
-
static inline struct clk *of_clk_get(struct device_node *np, int index)
{
return ERR_PTR(-ENOENT);
@@ -382,16 +391,19 @@ static inline int of_clk_init(struct device_node *root,
{
return 0;
}
+static inline int of_clk_add_provider(struct device_node *np,
+ struct clk *(*clk_src_get)(struct of_phandle_args *args,
+ void *data),
+ void *data)
+{
+ return 0;
+}
#endif
struct string_list;
int clk_name_complete(struct string_list *sl, char *instr);
-int of_clk_add_provider(struct device_node *np,
- struct clk *(*clk_src_get)(struct of_phandle_args *args,
- void *data),
- void *data);
char *of_clk_get_parent_name(struct device_node *np, unsigned int index);
#endif
diff --git a/include/linux/nvmem-consumer.h b/include/linux/nvmem-consumer.h
index 0ec2f05b97..32ea46e3bf 100644
--- a/include/linux/nvmem-consumer.h
+++ b/include/linux/nvmem-consumer.h
@@ -40,6 +40,10 @@ int nvmem_cell_write(struct nvmem_cell *cell, void *buf, size_t len);
/* direct nvmem device read/write interface */
struct nvmem_device *nvmem_device_get(struct device_d *dev, const char *name);
void nvmem_device_put(struct nvmem_device *nvmem);
+ssize_t nvmem_device_cell_read(struct nvmem_device *nvmem,
+ struct nvmem_cell_info *info, void *buf);
+int nvmem_device_cell_write(struct nvmem_device *nvmem,
+ struct nvmem_cell_info *info, void *buf);
#else
diff --git a/include/net.h b/include/net.h
index a09cb155a8..6912a557b5 100644
--- a/include/net.h
+++ b/include/net.h
@@ -330,13 +330,11 @@ int string_to_ethaddr(const char *str, u8 enetaddr[6]);
void ethaddr_to_string(const u8 enetaddr[6], char *str);
#ifdef CONFIG_NET_RESOLV
-IPaddr_t resolv(const char *host);
+int resolv(const char *host, IPaddr_t *ip);
#else
-static inline IPaddr_t resolv(const char *host)
+static inline int resolv(const char *host, IPaddr_t *ip)
{
- IPaddr_t ip = 0;
- string_to_ip(host, &ip);
- return ip;
+ return string_to_ip(host, ip);
}
#endif
diff --git a/include/of_device.h b/include/of_device.h
index e84fc9c377..44c1c0f545 100644
--- a/include/of_device.h
+++ b/include/of_device.h
@@ -41,7 +41,7 @@ static inline const struct of_device_id *__of_match_device(
return NULL;
}
#define of_match_device(matches, dev) \
- __of_match_device(of_match_ptr(matches), (dev))
+ __of_match_device(matches, (dev))
#endif /* CONFIG_OF */
diff --git a/include/platform_data/eth-davinci-emac.h b/include/platform_data/eth-davinci-emac.h
deleted file mode 100644
index caead1fecf..0000000000
--- a/include/platform_data/eth-davinci-emac.h
+++ /dev/null
@@ -1,10 +0,0 @@
-#ifndef __NET_DAVINCI_EMAC_H__
-#define __NET_DAVINCI_EMAC_H__
-
-struct davinci_emac_platform_data {
- int phy_addr;
- bool force_link;
- bool interface_rmii;
-};
-
-#endif /* __NET_DAVINCI_EMAC_H__ */
diff --git a/include/printk.h b/include/printk.h
index 4384fb85ea..aaad07552e 100644
--- a/include/printk.h
+++ b/include/printk.h
@@ -91,7 +91,7 @@ static inline int pr_print(int level, const char *format, ...)
#define pr_debug(fmt, arg...) __pr_printk(7, pr_fmt(fmt), ##arg)
#define debug(fmt, arg...) __pr_printk(7, pr_fmt(fmt), ##arg)
#define pr_vdebug(fmt, arg...) __pr_printk(8, pr_fmt(fmt), ##arg)
-#define pr_cont(fmt, arg...) __pr_printk(0, fmt, ##arg)
+#define pr_cont(fmt, arg...) __pr_printk(-1, fmt, ##arg)
#define printk_once(fmt, ...) \
({ \
@@ -103,6 +103,25 @@ static inline int pr_print(int level, const char *format, ...)
} \
})
+int memory_display(const void *addr, loff_t offs, unsigned nbytes, int size,
+ int swab);
+int __pr_memory_display(int level, const void *addr, loff_t offs, unsigned nbytes,
+ int size, int swab, const char *format, ...);
+
+#define pr_memory_display(level, addr, offs, nbytes, size, swab) \
+ ({ \
+ (level) <= LOGLEVEL ? __pr_memory_display((level), (addr), \
+ (offs), (nbytes), (size), (swab), pr_fmt("")) : 0; \
+ })
+
+#define DUMP_PREFIX_OFFSET 0
+static inline void print_hex_dump(const char *level, const char *prefix_str,
+ int prefix_type, int rowsize, int groupsize,
+ const void *buf, size_t len, bool ascii)
+{
+ memory_display(buf, 0, len, 4, 0);
+}
+
struct log_entry {
struct list_head list;
char *msg;