aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2005-06-22 00:01:59 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2005-06-22 00:43:10 -0400
commitc7b2b2a723174d22a743180d5367f0028226031b (patch)
tree9f4261361e660b64c71da0022304e23875c3561e
parentca775c629a366ded01aae69da8410f70aaf85de1 (diff)
[PATCH] w1: fix build issues
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/w1/w1_smem.c16
1 files changed, 0 insertions, 16 deletions
diff --git a/drivers/w1/w1_smem.c b/drivers/w1/w1_smem.c
index 285eb8f84574..70d2d469963c 100644
--- a/drivers/w1/w1_smem.c
+++ b/drivers/w1/w1_smem.c
@@ -37,14 +37,11 @@ MODULE_AUTHOR("Evgeniy Polyakov <johnpol@2ka.mipt.ru>");
37MODULE_DESCRIPTION("Driver for 1-wire Dallas network protocol, 64bit memory family."); 37MODULE_DESCRIPTION("Driver for 1-wire Dallas network protocol, 64bit memory family.");
38 38
39static ssize_t w1_smem_read_name(struct device *, struct device_attribute *attr, char *); 39static ssize_t w1_smem_read_name(struct device *, struct device_attribute *attr, char *);
40static ssize_t w1_smem_read_val(struct device *, struct device_attribute *attr, char *);
41static ssize_t w1_smem_read_bin(struct kobject *, char *, loff_t, size_t); 40static ssize_t w1_smem_read_bin(struct kobject *, char *, loff_t, size_t);
42 41
43static struct w1_family_ops w1_smem_fops = { 42static struct w1_family_ops w1_smem_fops = {
44 .rname = &w1_smem_read_name, 43 .rname = &w1_smem_read_name,
45 .rbin = &w1_smem_read_bin, 44 .rbin = &w1_smem_read_bin,
46 .rval = &w1_smem_read_val,
47 .rvalname = "id",
48}; 45};
49 46
50static ssize_t w1_smem_read_name(struct device *dev, struct device_attribute *attr, char *buf) 47static ssize_t w1_smem_read_name(struct device *dev, struct device_attribute *attr, char *buf)
@@ -54,19 +51,6 @@ static ssize_t w1_smem_read_name(struct device *dev, struct device_attribute *at
54 return sprintf(buf, "%s\n", sl->name); 51 return sprintf(buf, "%s\n", sl->name);
55} 52}
56 53
57static ssize_t w1_smem_read_val(struct device *dev, struct device_attribute *attr, char *buf)
58{
59 struct w1_slave *sl = container_of(dev, struct w1_slave, dev);
60 int i;
61 ssize_t count = 0;
62
63 for (i = 0; i < 8; ++i)
64 count += sprintf(buf + count, "%02x ", ((u8 *)&sl->reg_num)[i]);
65 count += sprintf(buf + count, "\n");
66
67 return count;
68}
69
70static ssize_t w1_smem_read_bin(struct kobject *kobj, char *buf, loff_t off, size_t count) 54static ssize_t w1_smem_read_bin(struct kobject *kobj, char *buf, loff_t off, size_t count)
71{ 55{
72 struct w1_slave *sl = container_of(container_of(kobj, struct device, kobj), 56 struct w1_slave *sl = container_of(container_of(kobj, struct device, kobj),