From: "Jan Beulich" Subject: Re: [PATCH v4 09/17] x86/hvm: unify stdvga mmio intercept with standard mmio intercept Date: Wed, 24 Jun 2015 15:30:07 +0100 Message-ID: <558ADB0F0200007800088FDB@mail.emea.novell.com> References: <1435145089-21999-1-git-send-email-paul.durrant@citrix.com> <1435145089-21999-10-git-send-email-paul.durrant@citrix.com> <558AD3CE0200007800088F89@mail.emea.novell.com> <9AAE0902D5BC7E449B7C8E4E778ABCD02596CC4F@AMSPEX01CL02.citrite.net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1Z7lgs-0001hk-FB for xen-devel@lists.xenproject.org; Wed, 24 Jun 2015 14:30:14 +0000 In-Reply-To: <9AAE0902D5BC7E449B7C8E4E778ABCD02596CC4F@AMSPEX01CL02.citrite.net> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Paul Durrant Cc: Andrew Cooper , "Keir(Xen.org)" , "xen-devel@lists.xenproject.org" List-Id: xen-devel@lists.xenproject.org >>> On 24.06.15 at 16:12, wrote: >> From: Jan Beulich [mailto:JBeulich@suse.com] >> Sent: 24 June 2015 14:59 >> >>> On 24.06.15 at 13:24, wrote: >> > - if ( s->stdvga && s->cache ) >> > - { >> > - switch ( p->type ) >> > - { >> > - case IOREQ_TYPE_COPY: >> > - buf = mmio_move(s, p); >> > - if ( !buf ) >> > - s->cache = 0; >> > - break; >> > - default: >> > - gdprintk(XENLOG_WARNING, "unsupported mmio request type:%d >> " >> > - "addr:0x%04x data:0x%04x size:%d count:%d state:%d " >> > - "isptr:%d dir:%d df:%d\n", >> > - p->type, (int)p->addr, (int)p->data, (int)p->size, >> > - (int)p->count, p->state, >> > - p->data_is_ptr, p->dir, p->df); >> > - s->cache = 0; >> > - } >> >> I can't see where these cases of clearing s->cache move to. >> > > There's only one case AFAICT, which is if the domain goes through a > save/restore then s->cache is cleared. There are two cases visible in the context above, which afaict have nothing to do with save/restore. Jan