[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capabi
From: |
Shmulik Ladkani |
Subject: |
Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method |
Date: |
Wed, 2 Dec 2015 16:27:08 +0200 |
Hi,
On Wed, 2 Dec 2015 16:00:41 +0200, address@hidden wrote:
> > As I can't decide what's better, I'm following your initial suggestion
> > and submit for maintainers to review.
>
> Sure, and thanks for the patience to get to the bottom of it.
Sorry, your initial suggestion testing 'pci_bus_is_express() &&
!pci_bus_is_root()' within 'virtio_pci_dc_realize' will not do the job
as in that place pci_dev->bus is still NULL...
It's only assigned at pci_qdev_realize.
I think this is the main reason for separation.
The classes themselves describe the type of the device, which is either
pci or pcie, using k->is_express.
The class code can't tell whether the actual device instance gets
attached to a pci or pcie bus.
So yes, 'pci_is_express' really states whether device instance *can* be
an pcie device.
Thus, I'm going with my initial suggestion, plus minor naming changes.
Many thanks!
- [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Shmulik Ladkani, 2015/12/01
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Marcel Apfelbaum, 2015/12/01
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Shmulik Ladkani, 2015/12/01
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Marcel Apfelbaum, 2015/12/01
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Shmulik Ladkani, 2015/12/02
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Marcel Apfelbaum, 2015/12/02
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Shmulik Ladkani, 2015/12/02
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method, Marcel Apfelbaum, 2015/12/02
- Re: [Qemu-devel] [PATCH] virtio-pci: Set the QEMU_PCI_CAP_EXPRESS capability early in its DeviceClass realize method,
Shmulik Ladkani <=