[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/2] pci: add check for pcie root ports and down
From: |
Gonglei (Arei) |
Subject: |
Re: [Qemu-devel] [PATCH 2/2] pci: add check for pcie root ports and downstream ports |
Date: |
Wed, 20 Aug 2014 03:10:42 +0000 |
> -----Original Message-----
> From: Paolo Bonzini [mailto:address@hidden
> Sent: Tuesday, August 19, 2014 11:09 PM
> To: Marcel Apfelbaum; Gonglei (Arei)
> Cc: address@hidden; address@hidden; Huangweidong (C);
> address@hidden; address@hidden; address@hidden;
> Huangpeng (Peter); address@hidden; Luonengjun
> Subject: Re: [PATCH 2/2] pci: add check for pcie root ports and downstream
> ports
>
> Il 19/08/2014 16:37, Marcel Apfelbaum ha scritto:
> >> > +static int pci_check_pcie_port(PCIBus *bus, PCIDevice *dev)
> >> > +{
> >> > + Object *obj = OBJECT(bus);
> >> > +
> >> > + if (!strcmp(object_get_typename(obj), TYPE_PCIE_BUS)) {
> > Maybe there is another way to check that this is a PCIe bus?
> >
>
> It's object_dynamic_cast.
>
> Paolo
Great! Thanks. :)
Best regards,
-Gonglei
Re: [Qemu-devel] [PATCH 0/2] add check for PCIe root ports and downstream ports, Michael S. Tsirkin, 2014/08/19