mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
rtc: rs5c372: fix buffer size
Match the buffer size to the amount of initialized values. Before, it was one too big and thus destroyed the neighbouring register causing the clock to run at false speeds. Reported-by: Andre van Rooyen <[email protected]> Signed-off-by: Wolfram Sang <[email protected]> Cc: Alessandro Zummo <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
6900609612
commit
118364948f
1 changed files with 1 additions and 1 deletions
|
|
@ -207,7 +207,7 @@ static int rs5c372_get_datetime(struct i2c_client *client, struct rtc_time *tm)
|
|||
static int rs5c372_set_datetime(struct i2c_client *client, struct rtc_time *tm)
|
||||
{
|
||||
struct rs5c372 *rs5c = i2c_get_clientdata(client);
|
||||
unsigned char buf[8];
|
||||
unsigned char buf[7];
|
||||
int addr;
|
||||
|
||||
dev_dbg(&client->dev, "%s: tm is secs=%d, mins=%d, hours=%d "
|
||||
|
|
|
|||
Loading…
Reference in a new issue