1. 25 1月, 2017 1 次提交
  2. 27 7月, 2016 1 次提交
  3. 18 3月, 2016 1 次提交
  4. 20 10月, 2015 1 次提交
  5. 19 5月, 2015 1 次提交
    • D
      mm/fault, arch: Use pagefault_disable() to check for disabled pagefaults in the handler · 70ffdb93
      David Hildenbrand 提交于
      Introduce faulthandler_disabled() and use it to check for irq context and
      disabled pagefaults (via pagefault_disable()) in the pagefault handlers.
      
      Please note that we keep the in_atomic() checks in place - to detect
      whether in irq context (in which case preemption is always properly
      disabled).
      
      In contrast, preempt_disable() should never be used to disable pagefaults.
      With !CONFIG_PREEMPT_COUNT, preempt_disable() doesn't modify the preempt
      counter, and therefore the result of in_atomic() differs.
      We validate that condition by using might_fault() checks when calling
      might_sleep().
      
      Therefore, add a comment to faulthandler_disabled(), describing why this
      is needed.
      
      faulthandler_disabled() and pagefault_disable() are defined in
      linux/uaccess.h, so let's properly add that include to all relevant files.
      
      This patch is based on a patch from Thomas Gleixner.
      Reviewed-and-tested-by: NThomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NDavid Hildenbrand <dahi@linux.vnet.ibm.com>
      Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
      Cc: David.Laight@ACULAB.COM
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: airlied@linux.ie
      Cc: akpm@linux-foundation.org
      Cc: benh@kernel.crashing.org
      Cc: bigeasy@linutronix.de
      Cc: borntraeger@de.ibm.com
      Cc: daniel.vetter@intel.com
      Cc: heiko.carstens@de.ibm.com
      Cc: herbert@gondor.apana.org.au
      Cc: hocko@suse.cz
      Cc: hughd@google.com
      Cc: mst@redhat.com
      Cc: paulus@samba.org
      Cc: ralf@linux-mips.org
      Cc: schwidefsky@de.ibm.com
      Cc: yang.shi@windriver.com
      Link: http://lkml.kernel.org/r/1431359540-32227-7-git-send-email-dahi@linux.vnet.ibm.comSigned-off-by: NIngo Molnar <mingo@kernel.org>
      70ffdb93
  6. 11 3月, 2015 1 次提交
  7. 21 11月, 2014 1 次提交
  8. 13 9月, 2013 2 次提交
  9. 29 6月, 2013 1 次提交
  10. 09 10月, 2012 1 次提交
  11. 16 5月, 2012 1 次提交
  12. 05 5月, 2012 1 次提交
  13. 10 4月, 2012 1 次提交
  14. 29 3月, 2012 1 次提交
  15. 24 3月, 2012 1 次提交
  16. 08 12月, 2011 2 次提交
  17. 06 12月, 2011 1 次提交
  18. 17 10月, 2011 1 次提交
  19. 19 7月, 2011 1 次提交
  20. 02 7月, 2011 1 次提交
  21. 01 7月, 2011 1 次提交
    • P
      perf: Remove the nmi parameter from the swevent and overflow interface · a8b0ca17
      Peter Zijlstra 提交于
      The nmi parameter indicated if we could do wakeups from the current
      context, if not, we would set some state and self-IPI and let the
      resulting interrupt do the wakeup.
      
      For the various event classes:
      
        - hardware: nmi=0; PMI is in fact an NMI or we run irq_work_run from
          the PMI-tail (ARM etc.)
        - tracepoint: nmi=0; since tracepoint could be from NMI context.
        - software: nmi=[0,1]; some, like the schedule thing cannot
          perform wakeups, and hence need 0.
      
      As one can see, there is very little nmi=1 usage, and the down-side of
      not using it is that on some platforms some software events can have a
      jiffy delay in wakeup (when arch_irq_work_raise isn't implemented).
      
      The up-side however is that we can remove the nmi parameter and save a
      bunch of conditionals in fast paths.
      Signed-off-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Michael Cree <mcree@orcon.net.nz>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Deng-Cheng Zhu <dengcheng.zhu@gmail.com>
      Cc: Anton Blanchard <anton@samba.org>
      Cc: Eric B Munson <emunson@mgebm.net>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jason Wessel <jason.wessel@windriver.com>
      Cc: Don Zickus <dzickus@redhat.com>
      Link: http://lkml.kernel.org/n/tip-agjev8eu666tvknpb3iaj0fg@git.kernel.orgSigned-off-by: NIngo Molnar <mingo@elte.hu>
      a8b0ca17
  22. 22 2月, 2011 1 次提交
  23. 15 2月, 2011 1 次提交
  24. 22 12月, 2010 1 次提交
    • R
      ARM: pgtable: switch order of Linux vs hardware page tables · d30e45ee
      Russell King 提交于
      This switches the ordering of the Linux vs hardware page tables in
      each page, thereby eliminating some of the arithmetic in the page
      table walks.  As we now place the Linux page table at the beginning
      of the page, we can deal with the offset in the pgt by simply masking
      it away, along with the other control bits.
      
      This also makes the arithmetic all be positive, rather than a mixture.
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      d30e45ee
  25. 08 9月, 2010 1 次提交
  26. 27 7月, 2010 5 次提交
  27. 09 6月, 2010 1 次提交
  28. 15 5月, 2010 1 次提交
  29. 13 2月, 2010 1 次提交
  30. 06 10月, 2009 1 次提交
    • I
      ARM: 5742/1: ARM: add debug check for invalid kernel page faults · 1d212712
      Imre Deak 提交于
      According to the following in arch/arm/mm/fault.c page faults from
      kernel mode are invalid if mmap_sem is already held and there is
      no exception handler defined for the faulting instruction:
      
      /*
       * As per x86, we may deadlock here.  However, since the kernel only
       * validly references user space from well defined areas of the code,
       * we can bug out early if this is from code which shouldn't.
       */
      if (!down_read_trylock(&mm->mmap_sem)) {
      	if (!user_mode(regs) && !search_exception_tables(regs->ARM_pc))
      		goto no_context;
      
      Since mmap_sem can be held at arbitrary times by another thread this
      also means that any page faults from kernel mode are invalid if no
      exception handler is defined for them, regardless whether mmap_sem is
      held at the time of fault.
      
      To easier detect code that can trigger the above error, add a check
      also for the case where mmap_sem is acquired. As this has an overhead
      make it a VM debug check.
      Signed-off-by: NImre Deak <imre.deak@nokia.com>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      1d212712
  31. 03 10月, 2009 2 次提交
  32. 20 9月, 2009 2 次提交