summaryrefslogtreecommitdiff
path: root/packages/linux/linux-2.6.18/spi-set-kset-of-master-class-dev-explicitly.patch
diff options
context:
space:
mode:
authorKoen Kooi <koen@openembedded.org>2007-09-14 07:43:03 +0000
committerKoen Kooi <koen@openembedded.org>2007-09-14 07:43:03 +0000
commit2019b37bac10cff32469452eb3061e6e8e8aaad4 (patch)
tree79aa76f03f001988977386a9c13e59cebfe7c57b /packages/linux/linux-2.6.18/spi-set-kset-of-master-class-dev-explicitly.patch
parent7a5c873a58cdc4130eb4a14c5af0960f8ec6d81a (diff)
parenta50f3c05fc84d7d914e6a8287c82581462302bbe (diff)
propagate from branch 'org.openembedded.dev' (head bbdff51149f19a443ea4c897e2b4eb81eec6283a)
to branch 'org.openembedded.dev.avr32' (head ef59785d9aa6d25f6cf33266a65b61426e620f71)
Diffstat (limited to 'packages/linux/linux-2.6.18/spi-set-kset-of-master-class-dev-explicitly.patch')
-rw-r--r--packages/linux/linux-2.6.18/spi-set-kset-of-master-class-dev-explicitly.patch34
1 files changed, 34 insertions, 0 deletions
diff --git a/packages/linux/linux-2.6.18/spi-set-kset-of-master-class-dev-explicitly.patch b/packages/linux/linux-2.6.18/spi-set-kset-of-master-class-dev-explicitly.patch
new file mode 100644
index 0000000000..4a6ed65d8b
--- /dev/null
+++ b/packages/linux/linux-2.6.18/spi-set-kset-of-master-class-dev-explicitly.patch
@@ -0,0 +1,34 @@
+From 3bd0f6943520e459659d10f3282285e43d3990f1 Mon Sep 17 00:00:00 2001
+From: Hans-Christian Egtvedt <hcegtvedt@atmel.com>
+Date: Wed, 6 Dec 2006 20:36:19 -0800
+Subject: [PATCH] [PATCH] spi: set kset of master class dev explicitly
+
+<quote Imre Deak from Thu, 12 Jan 2006 21:18:54 +0200>
+ In order for spi_busnum_to_master to work spi master devices must be linked
+ into the spi_master_class.subsys.kset list. At the moment the default
+ class_obj_subsys.kset is used and we can't enumerate the master devices.
+</quote>
+
+Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel.com>
+Cc: David Brownell <david-b@pacbell.net>
+Signed-off-by: Andrew Morton <akpm@osdl.org>
+Signed-off-by: Linus Torvalds <torvalds@osdl.org>
+---
+ drivers/spi/spi.c | 1 +
+ 1 files changed, 1 insertions(+), 0 deletions(-)
+
+diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c
+index 7d215ea..270e621 100644
+--- a/drivers/spi/spi.c
++++ b/drivers/spi/spi.c
+@@ -366,6 +366,7 @@ spi_alloc_master(struct device *dev, unsigned size)
+
+ class_device_initialize(&master->cdev);
+ master->cdev.class = &spi_master_class;
++ kobj_set_kset_s(&master->cdev, spi_master_class.subsys);
+ master->cdev.dev = get_device(dev);
+ spi_master_set_devdata(master, &master[1]);
+
+--
+1.4.4.1
+