summaryrefslogtreecommitdiff
path: root/recipes/linux/gumstix-kernel-2.6.21/one-wire.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/linux/gumstix-kernel-2.6.21/one-wire.patch')
-rw-r--r--recipes/linux/gumstix-kernel-2.6.21/one-wire.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/recipes/linux/gumstix-kernel-2.6.21/one-wire.patch b/recipes/linux/gumstix-kernel-2.6.21/one-wire.patch
new file mode 100644
index 0000000000..b4994c3e61
--- /dev/null
+++ b/recipes/linux/gumstix-kernel-2.6.21/one-wire.patch
@@ -0,0 +1,35 @@
+--- linux-2.6.21/drivers/w1/w1.c
++++ linux-2.6.21/drivers/w1/w1.c
+@@ -675,7 +675,6 @@ static void w1_slave_found(void *data, u64 rn)
+ struct w1_slave *sl;
+ struct list_head *ent;
+ struct w1_reg_num *tmp;
+- int family_found = 0;
+ struct w1_master *dev;
+ u64 rn_le = cpu_to_le64(rn);
+
+@@ -698,9 +697,6 @@ static void w1_slave_found(void *data, u64 rn)
+ sl->reg_num.crc == tmp->crc) {
+ set_bit(W1_SLAVE_ACTIVE, (long *)&sl->flags);
+ break;
+- } else if (sl->reg_num.family == tmp->family) {
+- family_found = 1;
+- break;
+ }
+
+ slave_count++;
+@@ -874,11 +874,9 @@ void w1_search_process(struct w1_master *dev, u8 search_type)
+ w1_search_devices(dev, search_type, w1_slave_found);
+
+ list_for_each_entry_safe(sl, sln, &dev->slist, w1_slave_entry) {
+- if (!test_bit(W1_SLAVE_ACTIVE, (unsigned long *)&sl->flags) && !--sl->ttl) {
++ if (!test_bit(W1_SLAVE_ACTIVE, (unsigned long *)&sl->flags) && !--sl->ttl)
+ w1_slave_detach(sl);
+-
+- dev->slave_count--;
+- } else if (test_bit(W1_SLAVE_ACTIVE, (unsigned long *)&sl->flags))
++ else if (test_bit(W1_SLAVE_ACTIVE, (unsigned long *)&sl->flags))
+ sl->ttl = dev->slave_ttl;
+ }
+
+