pc: Fix RTC CMOS info on RAM for ram_size < 1MiB
commite89001f72edde37fb36fa7c964daa1bbeb2eca26
authorMarkus Armbruster <armbru@redhat.com>
Wed, 15 Aug 2012 11:12:20 +0000 (15 13:12 +0200)
committerBlue Swirl <blauwirbel@gmail.com>
Sat, 18 Aug 2012 16:54:23 +0000 (18 16:54 +0000)
tree16f7686100516d64117a63fe4926a147f8085e3c
parentff961015529437f4b83fca0a92069aebcf533c9c
pc: Fix RTC CMOS info on RAM for ram_size < 1MiB

pc_cmos_init() always claims 640KiB base memory, and ram_size - 1MiB
extended memory.  The latter can underflow to "lots of extended
memory".  Fix both, and clean up some.

Note: SeaBIOS currently requires 1MiB of RAM, and doesn't check
whether it got enough.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
hw/pc.c