diff options
author | Juergen Lock <nox@FreeBSD.org> | 2009-12-06 19:37:46 +0000 |
---|---|---|
committer | Juergen Lock <nox@FreeBSD.org> | 2009-12-06 19:37:46 +0000 |
commit | b987bd37c9ef735647d3a4ba66db5c7b88c2a993 (patch) | |
tree | 8929f0c86b3c65495580a6b839d41d2acf5a3ad9 /emulators/qemu/files/patch-vl.c | |
parent | Update to 1.2, remove dead patch incorporated upstream, fix descr (diff) |
- Update to 0.11.1 - from the official announcement:
- fix I2C slave addressing (Juha Riihimaki)
- Revert "vga: do not resize the screen on hw_invalidate" (Aurelien Jarno)
- slirp: fix use-after-free (Mark McLoughlin)
- Fix sparc.ld (Blue Swirl)
- ELF codedump build failures (Laurent Desnogues)
- kvm: Move KVM mp_state accessors to i386-specific code (Hollis Blanchard)
- fix configure script with armv4l cpu (Laurent Desnogues)
- net: disable draining tap queue in one go (Mark McLoughlin)
- pcnet: Restart poll timer on pcnet_start (Jan Kiszka)
- Sparc32: Fix lance (Blue Swirl)
- mac99: fix segmentation fault on startup (Aurelien Jarno)
- usb-linux.c: fix buffer overflow (Jim Paris)
- ARM host: fix generated blocks linking (Laurent Desnogues)
- qemu serial: lost tx irqs (affecting FreeBSD's new uart(4) driver)
(Juergen Lock)
- exec-all.h: increase MAX_OP_PER_INSTR to 96 from 64 (Aurelien Jarno)
- Added a cherry picked commit from stable branch that fixes qcow2.
Notes
Notes:
svn path=/head/; revision=245296
Diffstat (limited to 'emulators/qemu/files/patch-vl.c')
-rw-r--r-- | emulators/qemu/files/patch-vl.c | 78 |
1 files changed, 66 insertions, 12 deletions
diff --git a/emulators/qemu/files/patch-vl.c b/emulators/qemu/files/patch-vl.c index 44684c7ce36b..b979a0373046 100644 --- a/emulators/qemu/files/patch-vl.c +++ b/emulators/qemu/files/patch-vl.c @@ -1,28 +1,82 @@ Index: qemu/vl.c -@@ -75,6 +75,7 @@ +@@ -57,6 +57,7 @@ #include <sys/stat.h> - #ifdef __FreeBSD__ + #if defined(__FreeBSD__) || defined(__DragonFly__) #include <libutil.h> +#include <sys/param.h> #else #include <util.h> #endif -@@ -9850,15 +9850,15 @@ - phys_ram_size += ram_size; - } +@@ -4782,6 +4783,10 @@ + + #endif + ++#if !defined(CONFIG_USER_ONLY) ++void io_mem_init(void); ++#endif ++ + int main(int argc, char **argv, char **envp) + { + #ifdef CONFIG_GDBSTUB +@@ -5621,6 +5626,10 @@ + #ifdef CONFIG_KQEMU + if (smp_cpus > 1) + kqemu_allowed = 0; ++ if (kqemu_allowed && ram_size > (1536 << 20)) { ++ fprintf(stderr, "qemu: at most 1536 MB RAM can be simulated with kqemu\n"); ++ exit(1); ++ } + #endif + if (qemu_init_main_loop()) { + fprintf(stderr, "qemu_init_main_loop failed\n"); +@@ -5715,6 +5724,9 @@ + if (ram_size == 0) + ram_size = DEFAULT_RAM_SIZE * 1024 * 1024; + /* init the dynamic translator */ + cpu_exec_init_all(tb_size * 1024 * 1024); + - phys_ram_base = qemu_vmalloc(phys_ram_size); - if (!phys_ram_base) { - fprintf(stderr, "Could not allocate physical memory\n"); - exit(1); + #ifdef CONFIG_KQEMU + /* FIXME: This is a nasty hack because kqemu can't cope with dynamic + guest ram allocation. It needs to go away. */ +@@ -5727,9 +5739,9 @@ + } } - + #endif +- - /* init the dynamic translator */ - cpu_exec_init_all(tb_size * 1024 * 1024); -- ++#if !defined(CONFIG_USER_ONLY) ++ io_mem_init(); ++#endif + bdrv_init(); + dma_helper_init(); +Index: qemu/exec.c +@@ -179,7 +179,7 @@ + static PhysPageDesc **l1_phys_map; + + #if !defined(CONFIG_USER_ONLY) +-static void io_mem_init(void); ++void io_mem_init(void); + + /* io memory support */ + CPUWriteMemoryFunc *io_mem_write[IO_MEM_NB_ENTRIES][4]; +@@ -503,7 +503,7 @@ + code_gen_alloc(tb_size); + code_gen_ptr = code_gen_buffer; + page_init(); +-#if !defined(CONFIG_USER_ONLY) ++#if 0 && !defined(CONFIG_USER_ONLY) + io_mem_init(); + #endif + } +@@ -2993,7 +2993,7 @@ + return -1; + } + +-static void io_mem_init(void) ++void io_mem_init(void) + { + int i; - /* we always create the cdrom drive, even if no disk is there */ |