Patchwork [PATCHv5-repost,1/2] qemu: make cirrus init value pci spec compliant

login
register
mail settings
Submitter Michael S. Tsirkin
Date Nov. 30, 2009, 7:02 p.m.
Message ID <20091130190226.GB457@redhat.com>
Download mbox | patch
Permalink /patch/39854/
State New
Headers show

Comments

Michael S. Tsirkin - Nov. 30, 2009, 7:02 p.m.
PCI memory should be disabled at reset, otherwise
we might claim transactions at address 0.
I/O should also be disabled, although for cirrus
it is harmless to enable it as we do not
have I/O bar.

Note: bios fix needed for this patch to work
was already applied:
previously bios incorrently assumed that it does not
need to enable i/o unless device has i/o bar.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Juan Quintela <quintela@redhat.com>
---
 hw/cirrus_vga.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)
Avi Kivity - Dec. 2, 2009, 12:52 p.m.
On 11/30/2009 09:02 PM, Michael S. Tsirkin wrote:
> PCI memory should be disabled at reset, otherwise
> we might claim transactions at address 0.
> I/O should also be disabled, although for cirrus
> it is harmless to enable it as we do not
> have I/O bar.
>
> Note: bios fix needed for this patch to work
> was already applied:
> previously bios incorrently assumed that it does not
> need to enable i/o unless device has i/o bar.
>    

Is this for qemu-kvm.git or qemu.git?
Michael S. Tsirkin - Dec. 2, 2009, 1:33 p.m.
On Wed, Dec 02, 2009 at 02:52:33PM +0200, Avi Kivity wrote:
> On 11/30/2009 09:02 PM, Michael S. Tsirkin wrote:
>> PCI memory should be disabled at reset, otherwise
>> we might claim transactions at address 0.
>> I/O should also be disabled, although for cirrus
>> it is harmless to enable it as we do not
>> have I/O bar.
>>
>> Note: bios fix needed for this patch to work
>> was already applied:
>> previously bios incorrently assumed that it does not
>> need to enable i/o unless device has i/o bar.
>>    
>
> Is this for qemu-kvm.git or qemu.git?
>
> -- 
> error compiling committee.c: too many arguments to function

This for qemu.git
Avi Kivity - Dec. 2, 2009, 1:43 p.m.
On 12/02/2009 03:33 PM, Michael S. Tsirkin wrote:
> This for qemu.git
>    

Please set the To: header correctly to avoid confusion.

Patch

diff --git a/hw/cirrus_vga.c b/hw/cirrus_vga.c
index d76e5bb..e16026f 100644
--- a/hw/cirrus_vga.c
+++ b/hw/cirrus_vga.c
@@ -3231,7 +3231,6 @@  static int pci_cirrus_vga_initfn(PCIDevice *dev)
      /* setup PCI */
      pci_config_set_vendor_id(pci_conf, PCI_VENDOR_ID_CIRRUS);
      pci_config_set_device_id(pci_conf, device_id);
-     pci_conf[0x04] = PCI_COMMAND_IOACCESS | PCI_COMMAND_MEMACCESS;
      pci_config_set_class(pci_conf, PCI_CLASS_DISPLAY_VGA);
      pci_conf[PCI_HEADER_TYPE] = PCI_HEADER_TYPE_NORMAL;