summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--drivers/staging/greybus/gpbridge.c2
-rw-r--r--drivers/staging/greybus/gpbridge.h34
-rw-r--r--drivers/staging/greybus/gpio.c1
-rw-r--r--drivers/staging/greybus/i2c.c1
-rw-r--r--drivers/staging/greybus/protocol.h26
-rw-r--r--drivers/staging/greybus/pwm.c1
-rw-r--r--drivers/staging/greybus/sdio.c1
-rw-r--r--drivers/staging/greybus/spi.c1
-rw-r--r--drivers/staging/greybus/uart.c1
-rw-r--r--drivers/staging/greybus/usb.c1
10 files changed, 42 insertions, 27 deletions
diff --git a/drivers/staging/greybus/gpbridge.c b/drivers/staging/greybus/gpbridge.c
index 29f0984..c82ded1 100644
--- a/drivers/staging/greybus/gpbridge.c
+++ b/drivers/staging/greybus/gpbridge.c
@@ -17,7 +17,7 @@
#include <linux/device.h>
#include "greybus.h"
-
+#include "gpbridge.h"
static int __init gpbridge_init(void)
{
diff --git a/drivers/staging/greybus/gpbridge.h b/drivers/staging/greybus/gpbridge.h
new file mode 100644
index 0000000..50ee87b
--- /dev/null
+++ b/drivers/staging/greybus/gpbridge.h
@@ -0,0 +1,34 @@
+/*
+ * Greybus GPBridge phy driver
+ *
+ * Copyright 2016 Google Inc.
+ *
+ * Released under the GPLv2 only.
+ */
+
+#ifndef __GPBRIDGE_H
+#define __GPBRIDGE_H
+
+extern int gb_gpio_protocol_init(void);
+extern void gb_gpio_protocol_exit(void);
+
+extern int gb_pwm_protocol_init(void);
+extern void gb_pwm_protocol_exit(void);
+
+extern int gb_uart_protocol_init(void);
+extern void gb_uart_protocol_exit(void);
+
+extern int gb_sdio_protocol_init(void);
+extern void gb_sdio_protocol_exit(void);
+
+extern int gb_usb_protocol_init(void);
+extern void gb_usb_protocol_exit(void);
+
+extern int gb_i2c_protocol_init(void);
+extern void gb_i2c_protocol_exit(void);
+
+extern int gb_spi_protocol_init(void);
+extern void gb_spi_protocol_exit(void);
+
+#endif /* __GPBRIDGE_H */
+
diff --git a/drivers/staging/greybus/gpio.c b/drivers/staging/greybus/gpio.c
index e7dd994..7b2cb5d 100644
--- a/drivers/staging/greybus/gpio.c
+++ b/drivers/staging/greybus/gpio.c
@@ -16,6 +16,7 @@
#include <linux/mutex.h>
#include "greybus.h"
+#include "gpbridge.h"
struct gb_gpio_line {
/* The following has to be an array of line_max entries */
diff --git a/drivers/staging/greybus/i2c.c b/drivers/staging/greybus/i2c.c
index cb68b45..4b96f69 100644
--- a/drivers/staging/greybus/i2c.c
+++ b/drivers/staging/greybus/i2c.c
@@ -13,6 +13,7 @@
#include <linux/i2c.h>
#include "greybus.h"
+#include "gpbridge.h"
struct gb_i2c_device {
struct gb_connection *connection;
diff --git a/drivers/staging/greybus/protocol.h b/drivers/staging/greybus/protocol.h
index 26c59ef..38fe14c 100644
--- a/drivers/staging/greybus/protocol.h
+++ b/drivers/staging/greybus/protocol.h
@@ -48,32 +48,6 @@ int gb_protocol_get_version(struct gb_connection *connection);
void gb_protocol_put(struct gb_protocol *protocol);
-/*
- * These are defined in their respective protocol source files.
- * Declared here for now. They could be added via modules, or maybe
- * just use initcalls (which level?).
- */
-extern int gb_gpio_protocol_init(void);
-extern void gb_gpio_protocol_exit(void);
-
-extern int gb_pwm_protocol_init(void);
-extern void gb_pwm_protocol_exit(void);
-
-extern int gb_uart_protocol_init(void);
-extern void gb_uart_protocol_exit(void);
-
-extern int gb_sdio_protocol_init(void);
-extern void gb_sdio_protocol_exit(void);
-
-extern int gb_usb_protocol_init(void);
-extern void gb_usb_protocol_exit(void);
-
-extern int gb_i2c_protocol_init(void);
-extern void gb_i2c_protocol_exit(void);
-
-extern int gb_spi_protocol_init(void);
-extern void gb_spi_protocol_exit(void);
-
/* __protocol: Pointer to struct gb_protocol */
#define gb_protocol_driver(__protocol) \
static int __init protocol_init(void) \
diff --git a/drivers/staging/greybus/pwm.c b/drivers/staging/greybus/pwm.c
index c3a3a9d..018d5c2 100644
--- a/drivers/staging/greybus/pwm.c
+++ b/drivers/staging/greybus/pwm.c
@@ -13,6 +13,7 @@
#include <linux/pwm.h>
#include "greybus.h"
+#include "gpbridge.h"
struct gb_pwm_chip {
struct gb_connection *connection;
diff --git a/drivers/staging/greybus/sdio.c b/drivers/staging/greybus/sdio.c
index da90937..9a20f0e 100644
--- a/drivers/staging/greybus/sdio.c
+++ b/drivers/staging/greybus/sdio.c
@@ -15,6 +15,7 @@
#include <linux/workqueue.h>
#include "greybus.h"
+#include "gpbridge.h"
struct gb_sdio_host {
struct gb_connection *connection;
diff --git a/drivers/staging/greybus/spi.c b/drivers/staging/greybus/spi.c
index 7689af0..3571453 100644
--- a/drivers/staging/greybus/spi.c
+++ b/drivers/staging/greybus/spi.c
@@ -14,6 +14,7 @@
#include <linux/spi/spi.h>
#include "greybus.h"
+#include "gpbridge.h"
struct gb_spi {
struct gb_connection *connection;
diff --git a/drivers/staging/greybus/uart.c b/drivers/staging/greybus/uart.c
index 0685cdc..d169c55 100644
--- a/drivers/staging/greybus/uart.c
+++ b/drivers/staging/greybus/uart.c
@@ -29,6 +29,7 @@
#include <linux/kdev_t.h>
#include "greybus.h"
+#include "gpbridge.h"
#define GB_NUM_MINORS 16 /* 16 is is more than enough */
#define GB_NAME "ttyGB"
diff --git a/drivers/staging/greybus/usb.c b/drivers/staging/greybus/usb.c
index 6647868..0cfc00f 100644
--- a/drivers/staging/greybus/usb.c
+++ b/drivers/staging/greybus/usb.c
@@ -14,6 +14,7 @@
#include <linux/usb/hcd.h>
#include "greybus.h"
+#include "gpbridge.h"
/* Version of the Greybus USB protocol we support */
#define GB_USB_VERSION_MAJOR 0x00