sun4u: add a video card only when requested
PATCH 1/3 sun4u: add a video card only when requested
The sun4u machine always add a video card, even when "-vga none" is passed. Fix that by checking if it is enabled or not before instanciating it.
--- hw/sun4u.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
hw/sun4u.c +3 -1
@@ -821,7 +821,9 @@ static void sun4uv_init(MemoryRegion *address_space_mem, ivec_irqs =qemu_allocate_irqs (cpu_set_ivec_irq, env,IVEC_MAX ); pci_bus =pci_apb_init (APB_SPECIAL_BASE ,APB_MEM_BASE , ivec_irqs, &pci_bus2, &pci_bus3, &pbm_irqs); -pci_vga_init (pci_bus); +if (std_vga_enabled) { +pci_vga_init (pci_bus); + }// XXX Should be pci_bus3 isa_bus =pci_ebus_init (pci_bus,-1 , pbm_irqs);
Signature · 1 line
1.7.10.4
PATCH 2/3 g3beige: add a video card only when requested
The g3beige machine always add a video card, even when the "-vga none" is passed. Fix that by checking if it is enabled or not before instanciating it.
--- hw/ppc_oldworld.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
hw/ppc_oldworld.c +3 -1
@@ -250,7 +250,9 @@ static void ppc_heathrow_init (ram_addr_t ram_size, pci_bus =pci_grackle_init (0xfec00000 , pic,get_system_memory (),get_system_io ()); -pci_vga_init (pci_bus); +if (std_vga_enabled) { +pci_vga_init (pci_bus); + } escc_mem =escc_init (0 , pic[0x0f ], pic[0x10 ], serial_hds[0 ], serial_hds[1 ],ESCC_CLOCK ,4 );
Signature · 1 line
1.7.10.4
Re: [Qemu-devel] [PATCH 2/3] g3beige: add a video card only when requested
Quoted 15 lines · Aurelien Jarno
The g3beige machine always add a video card, even when the "-vga none" is passed. Fix that by checking if it is enabled or not before instanciating it.
Cc Alexander Graf <[email protected]>Signed-off-by Aurelien Jarno <[email protected]>---
hw/ppc_oldworld.c| 4 +++-1 file changed, 3 insertions(+), 1 deletion(-)hw/ppc_oldworld.c +0
-0
hw/ppc_oldworld.c static void ppc_heathrow_init (ram_addr_t ram_size, · line 254
Quoted 6 lines
hw/ppc_oldworld.c +2
-1@@ -250,7 +250,9 @@ static void ppc_heathrow_init (ram_addr_t ram_size, pci_bus =pci_grackle_init (0xfec00000 , pic,get_system_memory (),get_system_io ()); -pci_vga_init (pci_bus); +if (std_vga_enabled) { +pci_vga_init (pci_bus);
Shouldn't we try to have some generic function that can create any PCI VGA adapter for us? We might want to throw a cirrus or qxl one in a g3beige.
Alex
Quoted 7 lines
hw/ppc_oldworld.c +1
-0+ } escc_mem =escc_init (0 , pic[0x0f ], pic[0x10 ], serial_hds[0 ], serial_hds[1 ],ESCC_CLOCK ,4 );Signature · 1 line
1.7.10.4
Re: [Qemu-devel] [PATCH 2/3] g3beige: add a video card only when requested
Quoted 14 lines · Alexander Graf
Quoted 10 lines · Aurelien Jarno
The g3beige machine always add a video card, even when the "-vga none" is passed. Fix that by checking if it is enabled or not before instanciating it.
Cc Alexander Graf <[email protected]>Signed-off-by Aurelien Jarno <[email protected]>---
hw/ppc_oldworld.c| 4 +++-1 file changed, 3 insertions(+), 1 deletion(-)
Quoted 14 lines
hw/ppc_oldworld.c static void ppc_heathrow_init (ram_addr_t ram_size, · line 254
Quoted 11 lines
hw/ppc_oldworld.c +2
-1@@ -250,7 +250,9 @@ static void ppc_heathrow_init (ram_addr_t ram_size, pci_bus =pci_grackle_init (0xfec00000 , pic,get_system_memory (),get_system_io ()); -pci_vga_init (pci_bus); +if (std_vga_enabled) { +pci_vga_init (pci_bus);Shouldn't we try to have some generic function that can create any PCI VGA adapter for us? We might want to throw a cirrus or qxl one in a g3beige.
Other hardware supporting different videocard are using this kind of code (a bit more complicated for PC as it allow the card to be on the ISA or on the PCI bus):
| /* Optional PCI video card */
| if (cirrus_vga_enabled) {
| pci_cirrus_vga_init(pci_bus);
| } else if (vmsvga_enabled) {
| pci_vmsvga_init(pci_bus);
| } else if (std_vga_enabled) {
| pci_vga_init(pci_bus);
| }Signature · 2 lines
Aurelien Jarno GPG: 1024D/F1BCDB73 [email protected] http://www.aurel32.net
Re: [Qemu-devel] [PATCH 2/3] g3beige: add a video card only when requested
Quoted 34 lines · Aurelien Jarno
Quoted 14 lines · Alexander Graf
Quoted 10 lines · Aurelien Jarno
The g3beige machine always add a video card, even when the "-vga none" is passed. Fix that by checking if it is enabled or not before instanciating it.
Cc Alexander Graf <[email protected]>Signed-off-by Aurelien Jarno <[email protected]>---
hw/ppc_oldworld.c| 4 +++-1 file changed, 3 insertions(+), 1 deletion(-)Quoted 14 lines
hw/ppc_oldworld.c static void ppc_heathrow_init (ram_addr_t ram_size, · line 254
Quoted 11 lines
hw/ppc_oldworld.c +2
-1@@ -250,7 +250,9 @@ static void ppc_heathrow_init (ram_addr_t ram_size, pci_bus =pci_grackle_init (0xfec00000 , pic,get_system_memory (),get_system_io ()); -pci_vga_init (pci_bus); +if (std_vga_enabled) { +pci_vga_init (pci_bus);Shouldn't we try to have some generic function that can create any PCI VGA adapter for us? We might want to throw a cirrus or qxl one in a g3beige.
Other hardware supporting different videocard are using this kind of code (a bit more complicated for PC as it allow the card to be on the ISA or on the PCI bus):
Quoted 8 lines
| /* Optional PCI video card */
| if (cirrus_vga_enabled) {
| pci_cirrus_vga_init(pci_bus);
| } else if (vmsvga_enabled) {
| pci_vmsvga_init(pci_bus);
| } else if (std_vga_enabled) {
| pci_vga_init(pci_bus);
| }Yup. Can we move that to some generic pci file so that we don't have to copy it all over the place?
Alex
Re: [Qemu-devel] [PATCH 2/3] g3beige: add a video card only when requested
In reply to Aurelien JarnoQuoted 34 lines · Aurelien Jarno
Quoted 14 lines · Alexander Graf
Quoted 10 lines · Aurelien Jarno
The g3beige machine always add a video card, even when the "-vga none" is passed. Fix that by checking if it is enabled or not before instanciating it.
Cc Alexander Graf <[email protected]>Signed-off-by Aurelien Jarno <[email protected]>---
hw/ppc_oldworld.c| 4 +++-1 file changed, 3 insertions(+), 1 deletion(-)Quoted 14 lines
hw/ppc_oldworld.c static void ppc_heathrow_init (ram_addr_t ram_size, · line 254
Quoted 11 lines
hw/ppc_oldworld.c +2
-1@@ -250,7 +250,9 @@ static void ppc_heathrow_init (ram_addr_t ram_size, pci_bus =pci_grackle_init (0xfec00000 , pic,get_system_memory (),get_system_io ()); -pci_vga_init (pci_bus); +if (std_vga_enabled) { +pci_vga_init (pci_bus);Shouldn't we try to have some generic function that can create any PCI VGA adapter for us? We might want to throw a cirrus or qxl one in a g3beige.
Other hardware supporting different videocard are using this kind of code (a bit more complicated for PC as it allow the card to be on the ISA or on the PCI bus):
Quoted 8 lines
| /* Optional PCI video card */
| if (cirrus_vga_enabled) {
| pci_cirrus_vga_init(pci_bus);
| } else if (vmsvga_enabled) {
| pci_vmsvga_init(pci_bus);
| } else if (std_vga_enabled) {
| pci_vga_init(pci_bus);
| }Yup. Can we move that to some generic pci file so that we don't have to copy it all over the place?
Alex
PATCH 3/3 mac99: add a video card only when requested
In reply to Aurelien JarnoThe mac99 machine always add a video card, even when the "-vga none" is passed. Fix that by checking if it is enabled or not before instanciating it.
--- hw/ppc_newworld.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
hw/ppc_newworld.c +3 -1
@@ -330,7 +330,9 @@ static void ppc_core99_init (ram_addr_t ram_size, machine_arch =ARCH_MAC99 ; }/* init basic PC hardware */ -pci_vga_init (pci_bus); +if (std_vga_enabled) { +pci_vga_init (pci_bus); + } escc_mem =escc_init (0 , pic[0x25 ], pic[0x24 ], serial_hds[0 ], serial_hds[1 ],ESCC_CLOCK ,4 );
Signature · 1 line
1.7.10.4