diff options
-rw-r--r-- | drivers/w1/w1.c | 6 | ||||
-rw-r--r-- | drivers/w1/w1.h | 10 | ||||
-rw-r--r-- | drivers/w1/w1_family.c | 2 | ||||
-rw-r--r-- | drivers/w1/w1_int.c | 13 | ||||
-rw-r--r-- | drivers/w1/w1_io.c | 2 |
5 files changed, 18 insertions, 15 deletions
diff --git a/drivers/w1/w1.c b/drivers/w1/w1.c index f0b47fe4ed25..5def7fb903ac 100644 --- a/drivers/w1/w1.c +++ b/drivers/w1/w1.c | |||
@@ -164,11 +164,12 @@ struct device w1_master_device = { | |||
164 | .release = &w1_master_release | 164 | .release = &w1_master_release |
165 | }; | 165 | }; |
166 | 166 | ||
167 | struct device_driver w1_slave_driver = { | 167 | static struct device_driver w1_slave_driver = { |
168 | .name = "w1_slave_driver", | 168 | .name = "w1_slave_driver", |
169 | .bus = &w1_bus_type, | 169 | .bus = &w1_bus_type, |
170 | }; | 170 | }; |
171 | 171 | ||
172 | #if 0 | ||
172 | struct device w1_slave_device = { | 173 | struct device w1_slave_device = { |
173 | .parent = NULL, | 174 | .parent = NULL, |
174 | .bus = &w1_bus_type, | 175 | .bus = &w1_bus_type, |
@@ -176,6 +177,7 @@ struct device w1_slave_device = { | |||
176 | .driver = &w1_slave_driver, | 177 | .driver = &w1_slave_driver, |
177 | .release = &w1_slave_release | 178 | .release = &w1_slave_release |
178 | }; | 179 | }; |
180 | #endif /* 0 */ | ||
179 | 181 | ||
180 | static ssize_t w1_master_attribute_show_name(struct device *dev, struct device_attribute *attr, char *buf) | 182 | static ssize_t w1_master_attribute_show_name(struct device *dev, struct device_attribute *attr, char *buf) |
181 | { | 183 | { |
@@ -355,7 +357,7 @@ int w1_create_master_attributes(struct w1_master *master) | |||
355 | return sysfs_create_group(&master->dev.kobj, &w1_master_defattr_group); | 357 | return sysfs_create_group(&master->dev.kobj, &w1_master_defattr_group); |
356 | } | 358 | } |
357 | 359 | ||
358 | void w1_destroy_master_attributes(struct w1_master *master) | 360 | static void w1_destroy_master_attributes(struct w1_master *master) |
359 | { | 361 | { |
360 | sysfs_remove_group(&master->dev.kobj, &w1_master_defattr_group); | 362 | sysfs_remove_group(&master->dev.kobj, &w1_master_defattr_group); |
361 | } | 363 | } |
diff --git a/drivers/w1/w1.h b/drivers/w1/w1.h index b62e771e5709..5f09213512bf 100644 --- a/drivers/w1/w1.h +++ b/drivers/w1/w1.h | |||
@@ -203,6 +203,16 @@ static inline struct w1_master* dev_to_w1_master(struct device *dev) | |||
203 | return container_of(dev, struct w1_master, dev); | 203 | return container_of(dev, struct w1_master, dev); |
204 | } | 204 | } |
205 | 205 | ||
206 | extern int w1_max_slave_count; | ||
207 | extern int w1_max_slave_ttl; | ||
208 | extern spinlock_t w1_mlock; | ||
209 | extern struct list_head w1_masters; | ||
210 | extern struct device_driver w1_master_driver; | ||
211 | extern struct device w1_master_device; | ||
212 | |||
213 | int w1_process(void *data); | ||
214 | void w1_reconnect_slaves(struct w1_family *f); | ||
215 | |||
206 | #endif /* __KERNEL__ */ | 216 | #endif /* __KERNEL__ */ |
207 | 217 | ||
208 | #endif /* __W1_H */ | 218 | #endif /* __W1_H */ |
diff --git a/drivers/w1/w1_family.c b/drivers/w1/w1_family.c index 9e293e139a0e..0e32c114f906 100644 --- a/drivers/w1/w1_family.c +++ b/drivers/w1/w1_family.c | |||
@@ -25,10 +25,10 @@ | |||
25 | #include <linux/delay.h> | 25 | #include <linux/delay.h> |
26 | 26 | ||
27 | #include "w1_family.h" | 27 | #include "w1_family.h" |
28 | #include "w1.h" | ||
28 | 29 | ||
29 | DEFINE_SPINLOCK(w1_flock); | 30 | DEFINE_SPINLOCK(w1_flock); |
30 | static LIST_HEAD(w1_families); | 31 | static LIST_HEAD(w1_families); |
31 | extern void w1_reconnect_slaves(struct w1_family *f); | ||
32 | 32 | ||
33 | int w1_register_family(struct w1_family *newf) | 33 | int w1_register_family(struct w1_family *newf) |
34 | { | 34 | { |
diff --git a/drivers/w1/w1_int.c b/drivers/w1/w1_int.c index c3f67eafc7ec..4724693ad51d 100644 --- a/drivers/w1/w1_int.c +++ b/drivers/w1/w1_int.c | |||
@@ -26,19 +26,10 @@ | |||
26 | #include "w1.h" | 26 | #include "w1.h" |
27 | #include "w1_log.h" | 27 | #include "w1_log.h" |
28 | #include "w1_netlink.h" | 28 | #include "w1_netlink.h" |
29 | #include "w1_int.h" | ||
29 | 30 | ||
30 | static u32 w1_ids = 1; | 31 | static u32 w1_ids = 1; |
31 | 32 | ||
32 | extern struct device_driver w1_master_driver; | ||
33 | extern struct bus_type w1_bus_type; | ||
34 | extern struct device w1_master_device; | ||
35 | extern int w1_max_slave_count; | ||
36 | extern int w1_max_slave_ttl; | ||
37 | extern struct list_head w1_masters; | ||
38 | extern spinlock_t w1_mlock; | ||
39 | |||
40 | extern int w1_process(void *); | ||
41 | |||
42 | static struct w1_master * w1_alloc_dev(u32 id, int slave_count, int slave_ttl, | 33 | static struct w1_master * w1_alloc_dev(u32 id, int slave_count, int slave_ttl, |
43 | struct device_driver *driver, | 34 | struct device_driver *driver, |
44 | struct device *device) | 35 | struct device *device) |
@@ -103,7 +94,7 @@ static struct w1_master * w1_alloc_dev(u32 id, int slave_count, int slave_ttl, | |||
103 | return dev; | 94 | return dev; |
104 | } | 95 | } |
105 | 96 | ||
106 | void w1_free_dev(struct w1_master *dev) | 97 | static void w1_free_dev(struct w1_master *dev) |
107 | { | 98 | { |
108 | device_unregister(&dev->dev); | 99 | device_unregister(&dev->dev); |
109 | } | 100 | } |
diff --git a/drivers/w1/w1_io.c b/drivers/w1/w1_io.c index e2a043354ddf..f7f7e8bec30e 100644 --- a/drivers/w1/w1_io.c +++ b/drivers/w1/w1_io.c | |||
@@ -28,7 +28,7 @@ | |||
28 | #include "w1_log.h" | 28 | #include "w1_log.h" |
29 | #include "w1_io.h" | 29 | #include "w1_io.h" |
30 | 30 | ||
31 | int w1_delay_parm = 1; | 31 | static int w1_delay_parm = 1; |
32 | module_param_named(delay_coef, w1_delay_parm, int, 0); | 32 | module_param_named(delay_coef, w1_delay_parm, int, 0); |
33 | 33 | ||
34 | static u8 w1_crc8_table[] = { | 34 | static u8 w1_crc8_table[] = { |