public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Jan Kiszka <jan.kiszka@web.de>, kvm <kvm@vger.kernel.org>
Cc: Joerg Roedel <joro@8bytes.org>,
	Valentine Sinitsyn <valentine.sinitsyn@gmail.com>
Subject: Re: [PATCH] KVM: nSVM: Fix IOIO bitmap evaluation
Date: Mon, 30 Jun 2014 17:08:13 +0200	[thread overview]
Message-ID: <53B17D5D.8030206@redhat.com> (raw)
In-Reply-To: <53B125B9.6050306@web.de>

Il 30/06/2014 10:54, Jan Kiszka ha scritto:
> +		SVM_IOIO_SIZE_SHIFT;
>  	gpa  = svm->nested.vmcb_iopm + (port / 8);
> -	bit  = port % 8;
> -	val  = 0;
> +	start_bit = port % 8;
> +	iopm_len = (start_bit + size > 8) ? 2 : 1;
> +	mask = (0xf >> (4 - size)) << start_bit;

These two lines are tricky. :)

The patch looks good, I'll write a test case if you don't beat me to it.

Paolo

> +	val = 0;
>


  reply	other threads:[~2014-06-30 15:08 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-30  8:54 [PATCH] KVM: nSVM: Fix IOIO bitmap evaluation Jan Kiszka
2014-06-30 15:08 ` Paolo Bonzini [this message]
2014-06-30 15:15   ` Jan Kiszka
2014-07-01 15:23 ` Joerg Roedel
2014-07-01 15:25   ` Jan Kiszka

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=53B17D5D.8030206@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=jan.kiszka@web.de \
    --cc=joro@8bytes.org \
    --cc=kvm@vger.kernel.org \
    --cc=valentine.sinitsyn@gmail.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