Add an isa device for SGA

This patch adds a dummy legacy ISA device whose responsibility is to
deploy sgabios, an option rom for a serial graphics adapter.
The proposal is that this device is always-on when -nographics,
but can otherwise be enable in any setup when -device sga is used.

[v2: suggestions on qdev by Markus ]
[v3: cleanups and documentation, per list suggestions ]

Signed-off-by: Glauber Costa <glommer@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
Glauber Costa 2011-05-16 15:45:08 -03:00 committed by Anthony Liguori
parent c1990ebfa1
commit a90d469007
3 changed files with 66 additions and 1 deletions

View file

@ -1070,6 +1070,15 @@ void pc_vga_init(PCIBus *pci_bus)
isa_vga_init();
}
}
/*
* sga does not suppress normal vga output. So a machine can have both a
* vga card and sga manually enabled. Output will be seen on both.
* For nographic case, sga is enabled at all times
*/
if (display_type == DT_NOGRAPHIC) {
isa_create_simple("sga");
}
}
static void cpu_request_exit(void *opaque, int irq, int level)