All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: James Hogan <james.hogan@imgtec.com>
Cc: "Jiri Slaby" <jslaby@suse.cz>,
	stable@vger.kernel.org, "Paolo Bonzini" <pbonzini@redhat.com>,
	"Radim Krčmář" <rkrcmar@redhat.com>,
	"Ralf Baechle" <ralf@linux-mips.org>,
	linux-mips@linux-mips.org, kvm@vger.kernel.org
Subject: Re: [BACKPORT PATCH 3.10..3.16] KVM: MIPS: Drop other CPU ASIDs on guest MMU changes
Date: Thu, 10 Nov 2016 07:08:43 +0100	[thread overview]
Message-ID: <20161110060843.GA28639@kroah.com> (raw)
In-Reply-To: <20161109220043.GA7075@jhogan-linux.le.imgtec.org>

On Wed, Nov 09, 2016 at 10:00:43PM +0000, James Hogan wrote:
> On Wed, Nov 09, 2016 at 10:22:01PM +0100, Jiri Slaby wrote:
> > On 11/09/2016, 03:46 PM, James Hogan wrote:
> > > commit 91e4f1b6073dd680d86cdb7e42d7cccca9db39d8 upstream.
> > > 
> > > When a guest TLB entry is replaced by TLBWI or TLBWR, we only invalidate
> > > TLB entries on the local CPU. This doesn't work correctly on an SMP host
> > > when the guest is migrated to a different physical CPU, as it could pick
> > > up stale TLB mappings from the last time the vCPU ran on that physical
> > > CPU.
> > > 
> > > Therefore invalidate both user and kernel host ASIDs on other CPUs,
> > > which will cause new ASIDs to be generated when it next runs on those
> > > CPUs.
> > > 
> > > We're careful only to do this if the TLB entry was already valid, and
> > > only for the kernel ASID where the virtual address it mapped is outside
> > > of the guest user address range.
> > > 
> > > Signed-off-by: James Hogan <james.hogan@imgtec.com>
> > > Cc: Paolo Bonzini <pbonzini@redhat.com>
> > > Cc: "Radim Krčmář" <rkrcmar@redhat.com>
> > > Cc: Ralf Baechle <ralf@linux-mips.org>
> > > Cc: linux-mips@linux-mips.org
> > > Cc: kvm@vger.kernel.org
> > > Cc: <stable@vger.kernel.org> # 3.10.x-
> > > Cc: Jiri Slaby <jslaby@suse.cz>
> > > [james.hogan@imgtec.com: Backport to 3.10..3.16]
> > > Signed-off-by: James Hogan <james.hogan@imgtec.com>
> > > ---
> > > Unfortunately the original commit went in to v3.12.65 as commit
> > > 168e5ebbd63e, without fixing up the references to tlb_lo[0/1] to
> > > tlb_lo0/1 which broke the MIPS KVM build, and I didn't twig that I
> > > already had a correct backport outstanding (sorry!). That commit should
> > > be reverted before applying this backport to 3.12.
> > 
> > Thanks, reverted and applied. I wonder the builders didn't break given 4
> > mips configurations are tested. I indeed could reproduce locally.
> 
> I'm guessing malta_kvm_defconfig isn't one of those defconfigs (and the
> imgtec buildbots don't yet test stable branches). Which builders do you
> use?

I use 0-day for these types of things, and it is not showing up any
errors for the 4.4-stable kernel.  Can you get these configurations
added to it so that we can ensure it doesn't regress?

thanks,

greg k-h

  reply	other threads:[~2016-11-10 11:33 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-09 14:46 [BACKPORT PATCH 3.10..3.16] KVM: MIPS: Drop other CPU ASIDs on guest MMU changes James Hogan
2016-11-09 14:46 ` James Hogan
2016-11-09 17:34 ` Willy Tarreau
2016-11-09 21:22 ` Jiri Slaby
2016-11-09 22:00   ` James Hogan
2016-11-10  6:08     ` Greg KH [this message]
2016-11-10 17:37       ` James Hogan
2016-11-10 17:37         ` James Hogan
2016-11-11  2:56         ` Fengguang Wu
2016-11-11  8:42           ` Jiri Slaby
2016-11-11  8:58           ` Paul Burton
2016-11-11 23:11             ` Fengguang Wu
2016-11-12  3:08 ` Ben Hutchings

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=20161110060843.GA28639@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=james.hogan@imgtec.com \
    --cc=jslaby@suse.cz \
    --cc=kvm@vger.kernel.org \
    --cc=linux-mips@linux-mips.org \
    --cc=pbonzini@redhat.com \
    --cc=ralf@linux-mips.org \
    --cc=rkrcmar@redhat.com \
    --cc=stable@vger.kernel.org \
    /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.