Revision 7267c094 hw/ppc405_boards.c
b/hw/ppc405_boards.c | ||
---|---|---|
162 | 162 |
ref405ep_fpga_t *fpga; |
163 | 163 |
int fpga_memory; |
164 | 164 |
|
165 |
fpga = qemu_mallocz(sizeof(ref405ep_fpga_t));
|
|
165 |
fpga = g_malloc0(sizeof(ref405ep_fpga_t));
|
|
166 | 166 |
fpga_memory = cpu_register_io_memory(ref405ep_fpga_read, |
167 | 167 |
ref405ep_fpga_write, fpga, |
168 | 168 |
DEVICE_NATIVE_ENDIAN); |
... | ... | |
246 | 246 |
filename = qemu_find_file(QEMU_FILE_TYPE_BIOS, bios_name); |
247 | 247 |
if (filename) { |
248 | 248 |
bios_size = load_image(filename, qemu_get_ram_ptr(bios_offset)); |
249 |
qemu_free(filename);
|
|
249 |
g_free(filename);
|
|
250 | 250 |
} else { |
251 | 251 |
bios_size = -1; |
252 | 252 |
} |
... | ... | |
487 | 487 |
taihu_cpld_t *cpld; |
488 | 488 |
int cpld_memory; |
489 | 489 |
|
490 |
cpld = qemu_mallocz(sizeof(taihu_cpld_t));
|
|
490 |
cpld = g_malloc0(sizeof(taihu_cpld_t));
|
|
491 | 491 |
cpld_memory = cpu_register_io_memory(taihu_cpld_read, |
492 | 492 |
taihu_cpld_write, cpld, |
493 | 493 |
DEVICE_NATIVE_ENDIAN); |
... | ... | |
560 | 560 |
filename = qemu_find_file(QEMU_FILE_TYPE_BIOS, bios_name); |
561 | 561 |
if (filename) { |
562 | 562 |
bios_size = load_image(filename, qemu_get_ram_ptr(bios_offset)); |
563 |
qemu_free(filename);
|
|
563 |
g_free(filename);
|
|
564 | 564 |
} else { |
565 | 565 |
bios_size = -1; |
566 | 566 |
} |
Also available in: Unified diff