[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 13/32] smbios: Don't allocate smbus eeprom buffer
smbus_eeprom_device_init() has been disabled since 2007. The #define turns the actual function call into a comma expression with no effect. Removing the leaked allocation also makes Valgrind happier. Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Coverity-ID: 1090387 --- hw/pc.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/hw/pc.c b/hw/pc.c index 3e33694..7359338 100644 --- a/hw/pc.c +++ b/hw/pc.c @@ -79,7 +79,6 @@ static void xen_relocator_hook(target_phys_addr_t *prot_addr_upd, uint16_t protocol, const uint8_t header[], int kernel_size, target_phys_addr_t real_addr, int real_size); -#define smbus_eeprom_device_init (void) static void ioport80_write(void *opaque, uint32_t addr, uint32_t data) { @@ -1135,17 +1134,8 @@ vga_bios_error: } if (pci_enabled && acpi_enabled) { - uint8_t *eeprom_buf = qemu_mallocz(8 * 256); /* XXX: make this persistent */ - i2c_bus *smbus; - /* TODO: Populate SPD eeprom data. */ - smbus = piix4_pm_init(pci_bus, piix3_devfn + 3, 0xb100, i8259[9]); - - if (smbus) { - for (i = 0; i < 8; i++) { - smbus_eeprom_device_init(smbus, 0x50 + i, eeprom_buf + (i * 256)); - } - } + piix4_pm_init(pci_bus, piix3_devfn + 3, 0xb100, i8259[9]); } if (i440fx_state) { -- 1.7.10.4 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |