History | View | Annotate | Download (4.9 kB)
hw/ds1338: Fix mishandling of register pointer
Correct several deficiencies in the handling of the register pointer: * it should wrap around after 0x3f, not 0xff * guard against the caller handing us an out of range pointer (on h/w this can never happen, because only a 7 bit value is...
hw/ds1338: Recapture current time when register pointer wraps around
The DS1338 datasheet documents that the current time is captured intothe secondary registers when the register pointer wraps round to zeroas well as at a START condition. Implement this....
hw/ds1338: Remove 'now' field from state struct
The 'struct tm now' field in the state structure is in fact onlyever used as a temporary (the actual RTC state is held in 'offset').Remove it from the state structure in favour of using local variablesto avoid confusion about whether it needs to be saved on migration....
hw/ds1338: Implement state save/restore
Implement state save/restore for the DS1338. This requiresthe usual minor adjustment of types in the state struct toget fixed-width ones with vmstate macros.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
ds1338: Add missing break statement
Without the break statement, case 5 sets month and year from the samedata. 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>...
qom: Unify type registration
Replace device_init() with generalized type_init().
While at it, unify naming convention: type_init([$prefix_]register_types)Also, type_init() is a function, so add preceding blank line wherenecessary and don't put a semicolon after the closing brace....
qdev: register all types natively through QEMU Object Model
This was done in a mostly automated fashion. I did it in three steps and thenrebased it into a single step which avoids repeatedly touching every file inthe tree.
The first step was a sed-based addition of the parent type to the subclass...
i2c: rename i2c_slave -> I2CSlave
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
i2c: smbus: convert to QEMU Object Model
This converts two types because smbus is implemented as a subclass of i2c. It'sextremely difficult to convert these two independently.
prepare for future GPLv2+ relicensing
All files under GPLv2 will get GPLv2+ changes starting tomorrow.event_notifier.c and exec-obsolete.h were only ever touched by Red Hatemployees and can be relicensed now.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>...
Correct spelling of licensed
Correct typos of "licenced" to "licensed".
Reviewed-by: Stefan Weil <weil@mail.berlios.de>Reviewed-by: Andreas F=E4rber <andreas.faerber@web.de>Signed-off-by: Matthew Fernandez <matthew.fernandez@gmail.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
DS1338 RTC
Implement MAXIM SD1338 RTC+NVRAM.
Signed-off-by: Paul Brook <paul@codesourcery.com>