ds1338: Add missing break statement
Without the break statement, case 5 sets month and year from the same data. This does not look correct. The missing break was reported by splint. Signed-off-by: Stefan Weil <sw@weilnetz.de> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
This commit is contained in:
parent
ee032ca146
commit
fbac6a7d35
@ -100,6 +100,7 @@ static int ds1338_send(I2CSlave *i2c, uint8_t data)
|
||||
break;
|
||||
case 5:
|
||||
s->now.tm_mon = from_bcd(data & 0x1f) - 1;
|
||||
break;
|
||||
case 6:
|
||||
s->now.tm_year = from_bcd(data) + 100;
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user