Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-11 Thread Jason Chien
This bug was also in 8.0. Jason On Fri, Aug 11, 2023 at 10:07 PM Peter Maydell wrote: > On Fri, 11 Aug 2023 at 10:55, Peter Maydell > wrote: > > > > On Thu, 10 Aug 2023 at 18:51, Michael S. Tsirkin wrote: > > > > > > On Wed, Aug 09, 2023 at 10:22:50AM +, Jason Chien wrote: > > > > In pcie

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-11 Thread Peter Maydell
On Fri, 11 Aug 2023 at 10:55, Peter Maydell wrote: > > On Thu, 10 Aug 2023 at 18:51, Michael S. Tsirkin wrote: > > > > On Wed, Aug 09, 2023 at 10:22:50AM +, Jason Chien wrote: > > > In pcie_bus_realize(), a root bus is realized as a PCIe bus and a non-root > > > bus is realized as a PCIe bus

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-11 Thread Peter Maydell
On Thu, 10 Aug 2023 at 18:51, Michael S. Tsirkin wrote: > > On Wed, Aug 09, 2023 at 10:22:50AM +, Jason Chien wrote: > > In pcie_bus_realize(), a root bus is realized as a PCIe bus and a non-root > > bus is realized as a PCIe bus if its parent bus is a PCIe bus. However, > > the child bus "dw-

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-10 Thread Frank Chang
Reviewed-by: Frank Chang On Wed, Aug 9, 2023 at 6:23 PM Jason Chien wrote: > In pcie_bus_realize(), a root bus is realized as a PCIe bus and a non-root > bus is realized as a PCIe bus if its parent bus is a PCIe bus. However, > the child bus "dw-pcie" is realized before the parent bus "pcie" wh

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-10 Thread Michael S. Tsirkin
On Wed, Aug 09, 2023 at 10:22:50AM +, Jason Chien wrote: > In pcie_bus_realize(), a root bus is realized as a PCIe bus and a non-root > bus is realized as a PCIe bus if its parent bus is a PCIe bus. However, > the child bus "dw-pcie" is realized before the parent bus "pcie" which is > the root

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-10 Thread Jason Chien
the patch link: https://lists.gnu.org/archive/html/qemu-devel/2021-11/msg02162.html On Fri, Aug 11, 2023 at 1:44 AM Michael S. Tsirkin wrote: > On Fri, Aug 11, 2023 at 01:22:08AM +0800, Jason Chien wrote: > > As far as I know,

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-10 Thread Michael S. Tsirkin
On Fri, Aug 11, 2023 at 01:22:08AM +0800, Jason Chien wrote: > As far as I know, the order issue is caused by nested device realization. In > this case, realizing TYPE_DESIGNWARE_PCIE_HOST will also > realize TYPE_DESIGNWARE_PCIE_ROOT(see designware_pcie_host_realize()). > device_set_realized() is

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-10 Thread Jason Chien
As far as I know, the order issue is caused by nested device realization. In this case, realizing TYPE_DESIGNWARE_PCIE_HOST will also realize TYPE_DESIGNWARE_PCIE_ROOT(see designware_pcie_host_realize()). device_set_realized() is the function that realizing a device must go through, and this functi

Re: [PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-09 Thread Michael S. Tsirkin
On Wed, Aug 09, 2023 at 10:22:50AM +, Jason Chien wrote: > In pcie_bus_realize(), a root bus is realized as a PCIe bus and a non-root > bus is realized as a PCIe bus if its parent bus is a PCIe bus. However, > the child bus "dw-pcie" is realized before the parent bus "pcie" which is > the root

[PATCH] hw/pci-host: Allow extended config space access for Designware PCIe host

2023-08-09 Thread Jason Chien
In pcie_bus_realize(), a root bus is realized as a PCIe bus and a non-root bus is realized as a PCIe bus if its parent bus is a PCIe bus. However, the child bus "dw-pcie" is realized before the parent bus "pcie" which is the root PCIe bus. Thus, the extended configuration space is not accessible on