From mboxrd@z Thu Jan 1 00:00:00 1970 From: George Dunlap Subject: Re: [PATCH v15 14/19] pvh: Use PV handlers for PIO Date: Tue, 12 Nov 2013 16:54:11 +0000 Message-ID: <52825D33.7040801@eu.citrix.com> References: <1384181841-22739-1-git-send-email-george.dunlap@eu.citrix.com> <1384181841-22739-15-git-send-email-george.dunlap@eu.citrix.com> <52824A5802000078001026C8@nat28.tlf.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1VgHEI-0004TX-KQ for xen-devel@lists.xenproject.org; Tue, 12 Nov 2013 16:54:18 +0000 In-Reply-To: <52824A5802000078001026C8@nat28.tlf.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Jan Beulich Cc: Keir Fraser , Tim Deegan , Eddie Dong , Jun Nakajima , xen-devel List-Id: xen-devel@lists.xenproject.org On 11/12/2013 02:33 PM, Jan Beulich wrote: >>>> On 11.11.13 at 15:57, George Dunlap wrote: >> @@ -566,7 +581,10 @@ int hvm_domain_initialise(struct domain *d) >> d->arch.hvm_domain.io_handler->num_slot = 0; >> >> if ( is_pvh_domain(d) ) >> + { >> + register_portio_handler(d, 0, 0xffffffff, handle_pvh_io); > > Nice idea, but I'm afraid it'll need a little more than this long term > (i.e. I'm fine for this to go is as is, with the second paragraph below > address in some way): hvm_io_intercept() first tries > dpci_ioport_intercept(), and without device model I think that's not > correct. If indeed it isn't, a simple solution might be to just disallow > the registration of translated I/O port ranges for PVH guests. > > The other thing here is the use of 0xffffffff: The parameter is a > size one, not an end of range. And considering that we're talking > about I/O ports, 0x10000 would seem to be the right value (or, > if taking the potential wrapping into account, 0x10003). Oh, right -- I was looking at a trace of the guest, but confusing the values written with the address. Do you just want to change it to 0x10000? (Or 0x10003?) -George