Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 5468
b: refs/heads/master
c: d91e169
h: refs/heads/master
v: v3
  • Loading branch information
Ladislav Michl authored and Linus Torvalds committed Jul 29, 2005
1 parent f7690d1 commit ed3073e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: cb14c3a13cb1e78acf54a9ddc9e5f3e2f023523e
refs/heads/master: d91e16943fdaf02bf3459059abca1032589c0663
6 changes: 3 additions & 3 deletions trunk/drivers/i2c/chips/ds1337.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ static int ds1337_set_datetime(struct i2c_client *client, struct rtc_time *dt)
buf[0] = 0; /* reg offset */
buf[1] = BIN2BCD(dt->tm_sec);
buf[2] = BIN2BCD(dt->tm_min);
buf[3] = BIN2BCD(dt->tm_hour) | (1 << 6);
buf[3] = BIN2BCD(dt->tm_hour);
buf[4] = BIN2BCD(dt->tm_wday) + 1;
buf[5] = BIN2BCD(dt->tm_mday);
buf[6] = BIN2BCD(dt->tm_mon) + 1;
Expand Down Expand Up @@ -344,9 +344,9 @@ static void ds1337_init_client(struct i2c_client *client)

/* Ensure that device is set in 24-hour mode */
val = i2c_smbus_read_byte_data(client, DS1337_REG_HOUR);
if ((val >= 0) && (val & (1 << 6)) == 0)
if ((val >= 0) && (val & (1 << 6)))
i2c_smbus_write_byte_data(client, DS1337_REG_HOUR,
val | (1 << 6));
val & 0x3f);
}

static int ds1337_detach_client(struct i2c_client *client)
Expand Down

0 comments on commit ed3073e

Please sign in to comment.