linux-arch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Martin Schwidefsky <schwidefsky@de.ibm.com>
To: linux-arch@vger.kernel.org, linux-mm@kvack.org,
	Zachary Amsden <zach@vmware.com>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Paul Mackerras <paulus@samba.org>,
	Chris Metcalf <cmetcalf@tilera.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Subject: [RFC][PATCH 0/2] fun with tlb flushing on s390
Date: Thu, 26 Jul 2012 17:47:12 +0200	[thread overview]
Message-ID: <1343317634-13197-1-git-send-email-schwidefsky@de.ibm.com> (raw)

A code review revealed another potential race in regard to TLB flushing
on s390. See patch #2 for the ugly details. To fix this I would like
to use the arch_enter_lazy_mmu_mode/arch_leave_lazy_mmu_mode but to do
that the pointer to the mm in question needs to be added to the functions.
To keep things symmetrical arch_flush_lazy_mmu_mode should grow an mm
argument as well.

powerpc and x86 have a non-empty implementation for the lazy mmu flush
primitives and tile calls the generic definition in the architecture
files (which is a bit strange because the generic definition is empty).
Comments?

Martin Schwidefsky (2):
  add mm argument to lazy mmu mode hooks
  s390/tlb: race of lazy TLB flush vs. recreation of TLB entries

 arch/powerpc/include/asm/tlbflush.h |    6 ++---
 arch/powerpc/mm/subpage-prot.c      |    4 ++--
 arch/powerpc/mm/tlb_hash64.c        |    4 ++--
 arch/s390/include/asm/hugetlb.h     |   24 ++++++++-----------
 arch/s390/include/asm/mmu_context.h |   13 ++++++++---
 arch/s390/include/asm/pgtable.h     |   43 ++++++++++++++++++++++-------------
 arch/s390/include/asm/tlb.h         |    3 ++-
 arch/s390/include/asm/tlbflush.h    |    8 +++----
 arch/s390/mm/pgtable.c              |    6 ++---
 arch/tile/mm/fault.c                |    2 +-
 arch/tile/mm/highmem.c              |    4 ++--
 arch/x86/include/asm/paravirt.h     |    6 ++---
 arch/x86/kernel/paravirt.c          |   10 ++++----
 arch/x86/mm/highmem_32.c            |    4 ++--
 arch/x86/mm/iomap_32.c              |    2 +-
 include/asm-generic/pgtable.h       |    6 ++---
 mm/memory.c                         |   16 ++++++-------
 mm/mprotect.c                       |    4 ++--
 mm/mremap.c                         |    4 ++--
 19 files changed, 91 insertions(+), 78 deletions(-)

-- 
1.7.10.4

             reply	other threads:[~2012-07-26 15:48 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-26 15:47 Martin Schwidefsky [this message]
2012-07-26 15:47 ` [PATCH 1/2] add mm argument to lazy mmu mode hooks Martin Schwidefsky
2012-07-27 16:57   ` Konrad Rzeszutek Wilk
2012-07-27 16:57     ` Konrad Rzeszutek Wilk
2012-07-30  8:15     ` Martin Schwidefsky
2012-07-26 15:47 ` [PATCH 2/2] s390/tlb: race of lazy TLB flush vs. recreation of TLB entries Martin Schwidefsky
2012-07-26 15:47   ` Martin Schwidefsky
2012-07-26 19:42 ` [RFC][PATCH 0/2] fun with tlb flushing on s390 Peter Zijlstra
2012-07-26 19:42   ` Peter Zijlstra
2012-07-27  6:57   ` Martin Schwidefsky
2012-07-27  8:01     ` Peter Zijlstra
2012-07-27  8:01       ` Peter Zijlstra

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=1343317634-13197-1-git-send-email-schwidefsky@de.ibm.com \
    --to=schwidefsky@de.ibm.com \
    --cc=benh@kernel.crashing.org \
    --cc=cmetcalf@tilera.com \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mingo@redhat.com \
    --cc=paulus@samba.org \
    --cc=peterz@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=zach@vmware.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).