From: Paolo Bonzini <pbonzini@redhat.com>
To: Marcel Apfelbaum <marcel.a@redhat.com>, arei.gonglei@huawei.com
Cc: peter.crosthwaite@xilinx.com, weidong.huang@huawei.com,
mst@redhat.com, armbru@redhat.com, luonengjun@huawei.com,
qemu-devel@nongnu.org, peter.huangpeng@huawei.com,
imammedo@redhat.com, afaerber@suse.de
Subject: Re: [Qemu-devel] [PATCH 2/2] pci: add check for pcie root ports and downstream ports
Date: Tue, 19 Aug 2014 17:09:22 +0200 [thread overview]
Message-ID: <53F368A2.1030409@redhat.com> (raw)
In-Reply-To: <1408459079.13594.29.camel@localhost.localdomain>
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
next prev parent reply other threads:[~2014-08-19 15:10 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-19 13:08 [Qemu-devel] [PATCH 0/2] add check for PCIe root ports and downstream ports arei.gonglei
2014-08-19 13:08 ` [Qemu-devel] [PATCH 1/2] qdev: Introduce a function to get qbus's parent arei.gonglei
2014-08-19 13:08 ` [Qemu-devel] [PATCH 2/2] pci: add check for pcie root ports and downstream ports arei.gonglei
2014-08-19 14:37 ` Marcel Apfelbaum
2014-08-19 15:09 ` Paolo Bonzini [this message]
2014-08-20 3:10 ` Gonglei (Arei)
2014-08-20 3:20 ` Gonglei (Arei)
2014-08-20 8:47 ` Marcel Apfelbaum
2014-08-20 9:06 ` Gonglei (Arei)
2014-08-19 21:23 ` [Qemu-devel] [PATCH 0/2] add check for PCIe " Michael S. Tsirkin
2014-08-20 3:03 ` Gonglei (Arei)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53F368A2.1030409@redhat.com \
--to=pbonzini@redhat.com \
--cc=afaerber@suse.de \
--cc=arei.gonglei@huawei.com \
--cc=armbru@redhat.com \
--cc=imammedo@redhat.com \
--cc=luonengjun@huawei.com \
--cc=marcel.a@redhat.com \
--cc=mst@redhat.com \
--cc=peter.crosthwaite@xilinx.com \
--cc=peter.huangpeng@huawei.com \
--cc=qemu-devel@nongnu.org \
--cc=weidong.huang@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.