[Qemu-devel] Re: [kvm-devel] PIIX/IDE: ports disabled in PCI config space?
Luca wrote: Good point. I'm looking at bochs right now: the BIOS doesn't touch that bits. The 2 ports are enabled/disabled - using values from the config file - by the reset function of the emulated controller (iodev/pci_ide.cc), so they're doing the same thing I've done for QEMU. I'd rather not touch the BIOS, it's a bit obscure ;-) No kidding :-) Maybe if you post your findings to bochs-devel they'd make the change. -- error compiling committee.c: too many arguments to function
[Qemu-devel] Re: [kvm-devel] PIIX/IDE: ports disabled in PCI config space?
On 6/5/07, Avi Kivity <[EMAIL PROTECTED]> wrote: Luca Tettamanti wrote: > Hello, > I'm testing the new Fedora7 under KVM. As you may know Fedora has > migrated to the new libata drivers. > > ata_piix is unhappy with the PIIX IDE controller provided by QEmu/KVM: > > > [...] > The following patch fixes the problem (i.e. ata_piix finds both the HD > and the cdrom): > > --- a/hw/ide.c2007-06-04 19:34:25.0 +0200 > +++ b/hw/ide.c2007-06-04 21:45:28.0 +0200 > @@ -2586,6 +2586,8 @@ static void piix3_reset(PCIIDEState *d) > pci_conf[0x06] = 0x80; /* FBC */ > pci_conf[0x07] = 0x02; // PCI_status_devsel_medium > pci_conf[0x20] = 0x01; /* BMIBA: 20-23h */ > +pci_conf[0x41] = 0x80; // enable port 0 > +pci_conf[0x43] = 0x80; // enable port 1 > } > > void pci_piix_ide_init(PCIBus *bus, BlockDriverState **hd_table, int devfn) > I imagine the reset state in the spec is disabled? Yes, you are right. Btw, this is the doc: http://www.intel.com/design/intarch/datashts/290550.htm If so, then the long-term fix is to enable these bits in the bios. Good point. I'm looking at bochs right now: the BIOS doesn't touch that bits. The 2 ports are enabled/disabled - using values from the config file - by the reset function of the emulated controller (iodev/pci_ide.cc), so they're doing the same thing I've done for QEMU. I'd rather not touch the BIOS, it's a bit obscure ;-) Luca
[Qemu-devel] Re: [kvm-devel] PIIX/IDE: ports disabled in PCI config space?
Luca Tettamanti wrote: Hello, I'm testing the new Fedora7 under KVM. As you may know Fedora has migrated to the new libata drivers. ata_piix is unhappy with the PIIX IDE controller provided by QEmu/KVM: [...] The following patch fixes the problem (i.e. ata_piix finds both the HD and the cdrom): --- a/hw/ide.c 2007-06-04 19:34:25.0 +0200 +++ b/hw/ide.c 2007-06-04 21:45:28.0 +0200 @@ -2586,6 +2586,8 @@ static void piix3_reset(PCIIDEState *d) pci_conf[0x06] = 0x80; /* FBC */ pci_conf[0x07] = 0x02; // PCI_status_devsel_medium pci_conf[0x20] = 0x01; /* BMIBA: 20-23h */ +pci_conf[0x41] = 0x80; // enable port 0 +pci_conf[0x43] = 0x80; // enable port 1 } void pci_piix_ide_init(PCIBus *bus, BlockDriverState **hd_table, int devfn) I imagine the reset state in the spec is disabled? If so, then the long-term fix is to enable these bits in the bios. In any case, I applied this to the kvm repo. Thanks. -- error compiling committee.c: too many arguments to function