qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: "Li, Liang Z" <liang.z.li@intel.com>,
	"Tian, Kevin" <kevin.tian@intel.com>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	"mst@redhat.com" <mst@redhat.com>,
	"mtosatti@redhat.com" <mtosatti@redhat.com>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	"aliguori@amazon.com" <aliguori@amazon.com>,
	"Zhang, Yang Z" <yang.z.zhang@intel.com>,
	"Hu, Robert" <robert.hu@intel.com>,
	"rth@twiddle.net" <rth@twiddle.net>
Subject: Re: [Qemu-devel] [Xen-devel] [PATCH] xen-pt: Fix PCI devices re-attach failed
Date: Mon, 12 Jan 2015 15:49:28 +0100	[thread overview]
Message-ID: <54B3DEF8.5020400@redhat.com> (raw)
In-Reply-To: <F2CBF3009FA73547804AE4C663CAB28E45B6A5@shsmsx102.ccr.corp.intel.com>



On 12/01/2015 14:35, Li, Liang Z wrote:
> 
> diff --git a/hw/xen/xen_pt.c b/hw/xen/xen_pt.c index c1bf357..f2893b2 100644
> --- a/hw/xen/xen_pt.c
> +++ b/hw/xen/xen_pt.c
> @@ -736,7 +736,7 @@ static int xen_pt_initfn(PCIDevice *d)
>      }
>  
>  out:
> -    memory_listener_register(&s->memory_listener, &address_space_memory);
> +    memory_listener_register(&s->memory_listener, 
> + &s->dev.bus_master_as);
>      memory_listener_register(&s->io_listener, &address_space_io);
>      XEN_PT_LOG(d,
>                 "Real physical device %02x:%02x.%d registered successfully!\n",
> 
> By further debugging, I found when using 'address_space_memory',  'xen_pt_region_del' 
> won't be called when the memory region's name is not  ' xen-pci-pt-*', when using
>  ' s->dev.bus_master_as ', there is no such issue.
> 
> I think use the device related address space here is more reasonable, but I am not sure.
>  Could you give some suggestion?

Yes, this patch makes sense.  The listener will be called every time the
command register is written.

Paolo

  reply	other threads:[~2015-01-12 14:49 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-24  8:56 [Qemu-devel] [PATCH] xen-pt: Fix PCI devices re-attach failed Liang Li
2015-01-12 11:36 ` Stefano Stabellini
2015-01-12 12:02   ` [Qemu-devel] [Xen-devel] " Tian, Kevin
2015-01-12 13:35     ` Li, Liang Z
2015-01-12 14:49       ` Paolo Bonzini [this message]
2015-01-12 15:46         ` Stefano Stabellini

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=54B3DEF8.5020400@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=aliguori@amazon.com \
    --cc=kevin.tian@intel.com \
    --cc=liang.z.li@intel.com \
    --cc=mst@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=robert.hu@intel.com \
    --cc=rth@twiddle.net \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    --cc=yang.z.zhang@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).