smbios: make qemu generate smbios tables.
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 18 lines · Gerd Hoffmann
Hi,
This patch series makes qemu generate smbios tables for 2.1 & newer machine types. Most patches are created by Gabriel L. Somlo. For the new machine type I've picked mst's patch though, so git should have an easier job sorting things in case the same thing comes in through another branch.
please pull,
GerdThe following changes since commit
e2da502c003b9a91b4aea7684959192bd07c1f1d:Merge remote-tracking branch 'remotes/otubo/seccomp' into staging (2014-04-28 14:14:35 +0100)
are available in the git repository at:
Quoted 8 lines
git://git.kraxel.org/qemutags/pull-smbios-1for you to fetch changes up to
3b17c3b4b58b4528e9097ac5d40b7b70060a1016:SMBIOS: Build aggregate smbios tables and entry point (2014-04-29 13:48:48 +0200)
----------------------------------------------------------------
smbios: make qemu generate smbios tables.
I'm afraid this doesn't compile:
CC i386-softmmu/hw/i386/smbios.o/root/qemu/hw/i386/smbios.c: In function ‘smbios_get_tables’:/root/qemu/hw/i386/smbios.c:834:71: error: division by zero [-Werror=div-by-zero]/root/qemu/hw/i386/smbios.c:834:142: error: division by zero [-Werror=div-by-zero]/root/qemu/hw/i386/smbios.c:839:105: error: division by zero [-Werror=div-by-zero]/root/qemu/hw/i386/smbios.c:844:13: error: passing argument 3 of ‘e820_get_entry’ from incompatible pointer type [-Werror] In file included from /root/qemu/hw/i386/smbios.c:22:0:/root/qemu/include/hw/i386/pc.h:243:7: note: expected ‘uint64_t *’ but argument is of type ‘ram_addr_t *’ /root/qemu/hw/i386/smbios.c:844:13: error: passing argument 4 of ‘e820_get_entry’ from incompatible pointer type [-Werror] In file included from /root/qemu/hw/i386/smbios.c:22:0:/root/qemu/include/hw/i386/pc.h:243:7: note: expected ‘uint64_t *’ but argument is of type ‘ram_addr_t *’
cc1: all warnings being treated as errors
make[1]: *** [hw/i386/smbios.o] Error 1
You can't assume ram_addr_t is 64 bits.
The division by zero issues are also caused by this:
you define
#define ONE_GB ((ram_addr_t)1 << 30)
and later
#define MAX_DIMM_SZ (16 * ONE_GB)
but this will overflow if ram_addr_t is 32 bits and you end up with MAX_DIMM_SZ being zero.
thanks
-- PMM
Hi,
Quoted 1 line
I'm afraid this doesn't compile:
/me goes add a -m32 build to the test matrix.
Hmm, looks like "make check" has issues on 32bit:
CC tests/test-cutils.o/home/kraxel/projects/qemu/tests/test-cutils.c: In function ‘test_parse_uint_llong_max’:/home/kraxel/projects/qemu/tests/test-cutils.c:168:5: error: overflow in implicit constant conversion [-Werror=overflow]
g_assert_cmpint(i, ==, (unsigned long long)LLONG_MAX + 1);
^/home/kraxel/projects/qemu/tests/test-cutils.c: In function ‘test_parse_uint_overflow’:/home/kraxel/projects/qemu/tests/test-cutils.c:185:5: error: overflow in implicit constant conversion [-Werror=overflow]
g_assert_cmpint(i, ==, ULLONG_MAX);
^cc1: all warnings being treated as errors
make: *** [tests/test-cutils.o] Error 1
test failure
cheers,
Gerd