summaryrefslogtreecommitdiffstats
path: root/include/linux/of_spi.h
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2008-05-16 11:37:09 -0600
committerGrant Likely <grant.likely@secretlab.ca>2008-07-25 22:34:40 -0400
commit284b01897340974000bcc84de87a4e1becc8a83d (patch)
tree9d2f38c9d2d39601d615f738c337c5af14a6b344 /include/linux/of_spi.h
parentdc87c98e8f635a718f1abb2c3e15fc77c0001651 (diff)
downloadtalos-obmc-linux-284b01897340974000bcc84de87a4e1becc8a83d.tar.gz
talos-obmc-linux-284b01897340974000bcc84de87a4e1becc8a83d.zip
spi: Add OF binding support for SPI busses
This patch adds support for populating an SPI bus based on data in the OF device tree. This is useful for powerpc platforms which use the device tree instead of discrete code for describing platform layout. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'include/linux/of_spi.h')
-rw-r--r--include/linux/of_spi.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/include/linux/of_spi.h b/include/linux/of_spi.h
new file mode 100644
index 000000000000..5f71ee8c0868
--- /dev/null
+++ b/include/linux/of_spi.h
@@ -0,0 +1,18 @@
+/*
+ * OpenFirmware SPI support routines
+ * Copyright (C) 2008 Secret Lab Technologies Ltd.
+ *
+ * Support routines for deriving SPI device attachments from the device
+ * tree.
+ */
+
+#ifndef __LINUX_OF_SPI_H
+#define __LINUX_OF_SPI_H
+
+#include <linux/of.h>
+#include <linux/spi/spi.h>
+
+extern void of_register_spi_devices(struct spi_master *master,
+ struct device_node *np);
+
+#endif /* __LINUX_OF_SPI */
OpenPOWER on IntegriCloud