Patchwork rtc: ds1307: change sysfs function pointer assignment

login
register
mail settings
Submitter Steffen Trumtrar
Date Feb. 13, 2013, 11:57 a.m.
Message ID <1360756675-30845-1-git-send-email-s.trumtrar@pengutronix.de>
Download mbox | patch
Permalink /patch/220125/
State New
Headers show

Comments

Steffen Trumtrar - Feb. 13, 2013, 11:57 a.m.
The current usage of commas instead of semicolons is not wrong, but affects the
readability of the code.

Also, the code would break, iff someone would put something between those two
assignments.

Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
---
 drivers/rtc/rtc-ds1307.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Patch

diff --git a/drivers/rtc/rtc-ds1307.c b/drivers/rtc/rtc-ds1307.c
index a65621c..35f8671 100644
--- a/drivers/rtc/rtc-ds1307.c
+++ b/drivers/rtc/rtc-ds1307.c
@@ -960,8 +960,8 @@  read_rtc:
 		ds1307->nvram->attr.name = "nvram";
 		ds1307->nvram->attr.mode = S_IRUGO | S_IWUSR;
 		sysfs_bin_attr_init(ds1307->nvram);
-		ds1307->nvram->read = ds1307_nvram_read,
-		ds1307->nvram->write = ds1307_nvram_write,
+		ds1307->nvram->read = ds1307_nvram_read;
+		ds1307->nvram->write = ds1307_nvram_write;
 		ds1307->nvram->size = chip->nvram_size;
 		ds1307->nvram_offset = chip->nvram_offset;
 		err = sysfs_create_bin_file(&client->dev.kobj, ds1307->nvram);