aboutsummaryrefslogtreecommitdiff
path: root/drivers/w1/w1_smem.c
diff options
context:
space:
mode:
authorEvgeniy Polyakov <johnpol@2ka.mipt.ru>2005-05-20 22:33:25 +0400
committerGreg Kroah-Hartman <gregkh@suse.de>2005-06-21 21:43:09 -0700
commit7785925dd8e0d2f389d4a9168f1683c6b249a552 (patch)
tree5772979184dc9e2b811503fab6ed1119f5c9f93a /drivers/w1/w1_smem.c
parent85e941cc9f10316080a16b121d24d329e5c2a65d (diff)
[PATCH] w1: cleanups.
- white space changes. - list_for_each_entry/list_for_each_entry_safe and reverse changes. - small coding style changes. - removed redundant NULL checks. - use attribute group and macros instead of direct device attributes. Patch is havily based on work from Adrian Bunk and Dmitry Torokhov, thanks guys. Signed-off-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/w1/w1_smem.c')
-rw-r--r--drivers/w1/w1_smem.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/w1/w1_smem.c b/drivers/w1/w1_smem.c
index 4a335f1a2ae..285eb8f8457 100644
--- a/drivers/w1/w1_smem.c
+++ b/drivers/w1/w1_smem.c
@@ -1,8 +1,8 @@
/*
- * w1_smem.c
+ * w1_smem.c
*
* Copyright (c) 2004 Evgeniy Polyakov <johnpol@2ka.mipt.ru>
- *
+ *
*
* This program is free software; you can redistribute it and/or modify
* it under the smems of the GNU General Public License as published by
@@ -70,7 +70,7 @@ static ssize_t w1_smem_read_val(struct device *dev, struct device_attribute *att
static ssize_t w1_smem_read_bin(struct kobject *kobj, char *buf, loff_t off, size_t count)
{
struct w1_slave *sl = container_of(container_of(kobj, struct device, kobj),
- struct w1_slave, dev);
+ struct w1_slave, dev);
int i;
atomic_inc(&sl->refcnt);
@@ -90,7 +90,7 @@ static ssize_t w1_smem_read_bin(struct kobject *kobj, char *buf, loff_t off, siz
for (i = 0; i < 8; ++i)
count += sprintf(buf + count, "%02x ", ((u8 *)&sl->reg_num)[i]);
count += sprintf(buf + count, "\n");
-
+
out:
up(&sl->master->mutex);
out_dec: