summaryrefslogtreecommitdiffstats
path: root/hw/sparc64/sun4u.c
diff options
context:
space:
mode:
authorPeter Maydell2019-02-07 17:49:30 +0100
committerPeter Maydell2019-02-07 17:49:30 +0100
commitd55451dcdee0704f6a756d4ec95be31515751235 (patch)
tree9ba72140bcf645ace7f8b308a96f254b332ba3de /hw/sparc64/sun4u.c
parentMerge remote-tracking branch 'remotes/vivier2/tags/trivial-patches-pull-reque... (diff)
parentsun4m: pass initrd size to OpenBIOS via fw_cfg interface (diff)
downloadqemu-d55451dcdee0704f6a756d4ec95be31515751235.tar.gz
qemu-d55451dcdee0704f6a756d4ec95be31515751235.tar.xz
qemu-d55451dcdee0704f6a756d4ec95be31515751235.zip
Merge remote-tracking branch 'remotes/mcayland/tags/qemu-sparc-20190206' into staging
qemu-sparc queue # gpg: Signature made Wed 06 Feb 2019 21:25:18 GMT # gpg: using RSA key CC621AB98E82200D915CC9C45BC2C56FAE0F321F # gpg: issuer "mark.cave-ayland@ilande.co.uk" # gpg: Good signature from "Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>" [full] # Primary key fingerprint: CC62 1AB9 8E82 200D 915C C9C4 5BC2 C56F AE0F 321F * remotes/mcayland/tags/qemu-sparc-20190206: sun4m: pass initrd size to OpenBIOS via fw_cfg interface sun4u: add power_mem_read routine hw/sparc64: Create VGA device only if it has really been requested Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/sparc64/sun4u.c')
-rw-r--r--hw/sparc64/sun4u.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c
index 3d310f1d76..ff24d9b350 100644
--- a/hw/sparc64/sun4u.c
+++ b/hw/sparc64/sun4u.c
@@ -213,6 +213,11 @@ typedef struct PowerDevice {
} PowerDevice;
/* Power */
+static uint64_t power_mem_read(void *opaque, hwaddr addr, unsigned size)
+{
+ return 0;
+}
+
static void power_mem_write(void *opaque, hwaddr addr,
uint64_t val, unsigned size)
{
@@ -223,6 +228,7 @@ static void power_mem_write(void *opaque, hwaddr addr,
}
static const MemoryRegionOps power_mem_ops = {
+ .read = power_mem_read,
.write = power_mem_write,
.endianness = DEVICE_NATIVE_ENDIAN,
.valid = {
@@ -595,7 +601,15 @@ static void sun4uv_init(MemoryRegion *address_space_mem,
qdev_connect_gpio_out_named(DEVICE(ebus), "isa-irq", 4,
qdev_get_gpio_in_named(DEVICE(sabre), "pbm-irq", OBIO_SER_IRQ));
- pci_dev = pci_create_simple(pci_busA, PCI_DEVFN(2, 0), "VGA");
+ switch (vga_interface_type) {
+ case VGA_STD:
+ pci_create_simple(pci_busA, PCI_DEVFN(2, 0), "VGA");
+ break;
+ case VGA_NONE:
+ break;
+ default:
+ abort(); /* Should not happen - types are checked in vl.c already */
+ }
memset(&macaddr, 0, sizeof(MACAddr));
onboard_nic = false;