Skip to content
Snippets Groups Projects
Commit cc413a39 authored by Aurelien Jarno's avatar Aurelien Jarno
Browse files

mips_malta: do not raise exceptions when accessing invalid memory


Since commit c658b94f, MIPS raises
exceptions when accessing invalid memory. This is not the correct
behaviour for MIPS Malta Core LV, as the GT-64120A system controller
just ignore undecoded access. This feature is used by the Linux kernel
to probe for some devices.

Emulate the correct behaviour in QEMU by adding an empty slot covering
the entire memory space decoded by the GT-64120A.

Tested-by: default avatarStefan Weil <sw@weilnetz.de>
Signed-off-by: default avatarAurelien Jarno <aurelien@aurel32.net>
parent 8b7a5415
No related branches found
No related tags found
No related merge requests found
......@@ -34,3 +34,4 @@ CONFIG_JAZZ_LED=y
CONFIG_MC146818RTC=y
CONFIG_VT82C686=y
CONFIG_ISA_TESTDEV=y
CONFIG_EMPTY_SLOT=y
......@@ -34,3 +34,4 @@ CONFIG_JAZZ_LED=y
CONFIG_MC146818RTC=y
CONFIG_VT82C686=y
CONFIG_ISA_TESTDEV=y
CONFIG_EMPTY_SLOT=y
......@@ -36,3 +36,4 @@ CONFIG_JAZZ_LED=y
CONFIG_MC146818RTC=y
CONFIG_VT82C686=y
CONFIG_ISA_TESTDEV=y
CONFIG_EMPTY_SLOT=y
......@@ -34,3 +34,4 @@ CONFIG_JAZZ_LED=y
CONFIG_MC146818RTC=y
CONFIG_VT82C686=y
CONFIG_ISA_TESTDEV=y
CONFIG_EMPTY_SLOT=y
......@@ -50,6 +50,7 @@
#include "qemu/host-utils.h"
#include "sysemu/qtest.h"
#include "qemu/error-report.h"
#include "hw/empty_slot.h"
//#define DEBUG_BOARD_INIT
......@@ -908,6 +909,11 @@ void mips_malta_init(QEMUMachineInitArgs *args)
DeviceState *dev = qdev_create(NULL, TYPE_MIPS_MALTA);
MaltaState *s = MIPS_MALTA(dev);
/* The whole address space decoded by the GT-64120A doesn't generate
exception when accessing invalid memory. Create an empty slot to
emulate this feature. */
empty_slot_init(0, 0x20000000);
qdev_init_nofail(dev);
/* Make sure the first 3 serial ports are associated with a device. */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment