summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2013-12-06 08:23:27 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2013-12-06 08:23:27 +0100
commited039cd72bfe7cf897fc195dd9cfec0bfa359222 (patch)
treeff64b841e6245817d987be35c488fbf747560d95 /include
parent6d7fae1e97d67b635a972b0f1f5c6a140c596e95 (diff)
parent03d601d58f4d6228bcb67e6035d4ede7b1d99ae3 (diff)
downloadbarebox-ed039cd72bfe7cf897fc195dd9cfec0bfa359222.tar.gz
barebox-ed039cd72bfe7cf897fc195dd9cfec0bfa359222.tar.xz
Merge branch 'for-next/omap-drivers'
Diffstat (limited to 'include')
-rw-r--r--include/driver.h9
-rw-r--r--include/pinctrl.h12
-rw-r--r--include/string.h2
-rw-r--r--include/xfuncs.h1
4 files changed, 24 insertions, 0 deletions
diff --git a/include/driver.h b/include/driver.h
index 7f0532e1a6..bbe789b51e 100644
--- a/include/driver.h
+++ b/include/driver.h
@@ -229,6 +229,15 @@ void *dev_get_mem_region(struct device_d *dev, int num);
*/
void __iomem *dev_request_mem_region(struct device_d *dev, int num);
+struct device_d *device_alloc(const char *devname, int id);
+
+int device_add_resources(struct device_d *dev, const struct resource *res, int num);
+
+int device_add_resource(struct device_d *dev, const char *resname,
+ resource_size_t start, resource_size_t size, unsigned int flags);
+
+int device_add_data(struct device_d *dev, void *data, size_t size);
+
/*
* register a generic device
* with only one resource
diff --git a/include/pinctrl.h b/include/pinctrl.h
index 7323f8b2f2..0f03b10bec 100644
--- a/include/pinctrl.h
+++ b/include/pinctrl.h
@@ -20,6 +20,8 @@ void pinctrl_unregister(struct pinctrl_device *pdev);
#ifdef CONFIG_PINCTRL
int pinctrl_select_state(struct device_d *dev, const char *state);
int pinctrl_select_state_default(struct device_d *dev);
+int of_pinctrl_select_state(struct device_node *np, const char *state);
+int of_pinctrl_select_state_default(struct device_node *np);
#else
static inline int pinctrl_select_state(struct device_d *dev, const char *state)
{
@@ -30,6 +32,16 @@ static inline int pinctrl_select_state_default(struct device_d *dev)
{
return -ENODEV;
}
+
+static inline int of_pinctrl_select_state(struct device_node *np, const char *state)
+{
+ return -ENODEV;
+}
+
+static inline int of_pinctrl_select_state_default(struct device_node *np)
+{
+ return -ENODEV;
+}
#endif
#endif /* PINCTRL_H */
diff --git a/include/string.h b/include/string.h
index b906e1504e..a833da131b 100644
--- a/include/string.h
+++ b/include/string.h
@@ -3,4 +3,6 @@
#include <linux/string.h>
+void *memdup(const void *, size_t);
+
#endif /* __STRING_H */
diff --git a/include/xfuncs.h b/include/xfuncs.h
index 261aaa5c14..8efc99dbc4 100644
--- a/include/xfuncs.h
+++ b/include/xfuncs.h
@@ -8,5 +8,6 @@ void *xrealloc(void *ptr, size_t size);
void *xzalloc(size_t size);
char *xstrdup(const char *s);
void* xmemalign(size_t alignment, size_t bytes);
+void* xmemdup(const void *orig, size_t size);
#endif /* __XFUNCS_H */