summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2008-05-16 19:37:09 +0200
committerGrant Likely <grant.likely@secretlab.ca>2008-07-26 04:34:40 +0200
commit284b01897340974000bcc84de87a4e1becc8a83d (patch)
tree9d2f38c9d2d39601d615f738c337c5af14a6b344 /include
parentspi: split up spi_new_device() to allow two stage registration. (diff)
downloadlinux-284b01897340974000bcc84de87a4e1becc8a83d.tar.xz
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')
-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 */