1. 03 9月, 2015 1 次提交
  2. 13 4月, 2015 1 次提交
  3. 01 4月, 2015 1 次提交
  4. 17 2月, 2015 1 次提交
    • M
      MIPS: Make use of the ERETNC instruction on MIPS R6 · 7c151d3d
      Markos Chandras 提交于
      The ERETNC instruction, introduced in MIPS R5, is similar to the ERET
      one, except it does not clear the LLB bit in the LLADDR register.
      This feature is necessary to safely emulate R2 LL/SC instructions.
      However, on context switches, we need to clear the LLAddr/LLB bit
      in order to make sure that an SC instruction from the new thread
      will never succeed if it happens to interrupt an LL operation on the
      same address from the previous thread.
      Signed-off-by: NMarkos Chandras <markos.chandras@imgtec.com>
      7c151d3d
  5. 13 2月, 2015 1 次提交
    • A
      all arches, signal: move restart_block to struct task_struct · f56141e3
      Andy Lutomirski 提交于
      If an attacker can cause a controlled kernel stack overflow, overwriting
      the restart block is a very juicy exploit target.  This is because the
      restart_block is held in the same memory allocation as the kernel stack.
      
      Moving the restart block to struct task_struct prevents this exploit by
      making the restart_block harder to locate.
      
      Note that there are other fields in thread_info that are also easy
      targets, at least on some architectures.
      
      It's also a decent simplification, since the restart code is more or less
      identical on all architectures.
      
      [james.hogan@imgtec.com: metag: align thread_info::supervisor_stack]
      Signed-off-by: NAndy Lutomirski <luto@amacapital.net>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Kees Cook <keescook@chromium.org>
      Cc: David Miller <davem@davemloft.net>
      Acked-by: NRichard Weinberger <richard@nod.at>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Matt Turner <mattst88@gmail.com>
      Cc: Vineet Gupta <vgupta@synopsys.com>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
      Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
      Cc: Steven Miao <realmz6@gmail.com>
      Cc: Mark Salter <msalter@redhat.com>
      Cc: Aurelien Jacquiot <a-jacquiot@ti.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: Jesper Nilsson <jesper.nilsson@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Richard Kuo <rkuo@codeaurora.org>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
      Cc: Helge Deller <deller@gmx.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Acked-by: Michael Ellerman <mpe@ellerman.id.au> (powerpc)
      Tested-by: Michael Ellerman <mpe@ellerman.id.au> (powerpc)
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Chen Liqin <liqin.linux@gmail.com>
      Cc: Lennox Wu <lennox.wu@gmail.com>
      Cc: Chris Metcalf <cmetcalf@ezchip.com>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: Max Filippov <jcmvbkbc@gmail.com>
      Cc: Oleg Nesterov <oleg@redhat.com>
      Cc: Guenter Roeck <linux@roeck-us.net>
      Signed-off-by: NJames Hogan <james.hogan@imgtec.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      f56141e3
  6. 04 2月, 2015 1 次提交
  7. 24 11月, 2014 1 次提交
    • P
      MIPS: Support for hybrid FPRs · 4227a2d4
      Paul Burton 提交于
      Hybrid FPRs is a scheme where scalar FP registers are 64b wide, but
      accesses to odd indexed single registers use bits 63:32 of the
      preceeding even indexed 64b register. In this mode all FP code
      except that built for the plain FP64 ABI can execute correctly. Most
      notably a combination of FP64A & FP32 code can execute correctly,
      allowing for existing FP32 binaries to be linked with new FP64A binaries
      that can make use of 64 bit FP & MSA.
      
      Hybrid FPRs are implemented by setting both the FR & FRE bits, trapping
      & emulating single precision FP instructions (via Reserved Instruction
      exceptions) whilst allowing others to execute natively. It therefore has
      a penalty in terms of execution speed, and should only be used when no
      fully native mode can be. As more binaries are recompiled to use either
      the FPXX or FP64(A) ABIs, the need for hybrid FPRs should diminish.
      However in the short to mid term it allows for a gradual transition
      towards that world, rather than a complete ABI break which is not
      feasible for some users & not desirable for many.
      
      A task will be executed using the hybrid FPR scheme when its
      TIF_HYBRID_FPREGS flag is set & TIF_32BIT_FPREGS is clear. A further
      patch will set the flags as necessary, this patch simply adds the
      infrastructure necessary for the hybrid FPR mode to work.
      Signed-off-by: NPaul Burton <paul.burton@imgtec.com>
      Cc: linux-mips@linux-mips.org
      Cc: Alexander Viro <viro@zeniv.linux.org.uk>
      Cc: linux-fsdevel@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Patchwork: https://patchwork.linux-mips.org/patch/7683/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      4227a2d4
  8. 24 5月, 2014 1 次提交
    • R
      MIPS: MT: Remove SMTC support · b633648c
      Ralf Baechle 提交于
      Nobody is maintaining SMTC anymore and there also seems to be no userbase.
      Which is a pity - the SMTC technology primarily developed by Kevin D.
      Kissell <kevink@paralogos.com> is an ingenious demonstration for the MT
      ASE's power and elegance.
      
      Based on Markos Chandras <Markos.Chandras@imgtec.com> patch
      https://patchwork.linux-mips.org/patch/6719/ which while very similar did
      no longer apply cleanly when I tried to merge it plus some additional
      post-SMTC cleanup - SMTC was a feature as tricky to remove as it was to
      merge once upon a time.
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      b633648c
  9. 27 3月, 2014 2 次提交
  10. 14 1月, 2014 1 次提交
    • P
      MIPS: Support for 64-bit FP with O32 binaries · 597ce172
      Paul Burton 提交于
      CPUs implementing MIPS32 R2 may include a 64-bit FPU, just as MIPS64 CPUs
      do. In order to preserve backwards compatibility a 64-bit FPU will act
      like a 32-bit FPU (by accessing doubles from the least significant 32
      bits of an even-odd pair of FP registers) when the Status.FR bit is
      zero, again just like a mips64 CPU. The standard O32 ABI is defined
      expecting a 32-bit FPU, however recent toolchains support use of a
      64-bit FPU from an O32 MIPS32 executable. When an ELF executable is
      built to use a 64-bit FPU a new flag (EF_MIPS_FP64) is set in the ELF
      header.
      
      With this patch the kernel will check the EF_MIPS_FP64 flag when
      executing an O32 binary, and set Status.FR accordingly. The addition
      of O32 64-bit FP support lessens the opportunity for optimisation in
      the FPU emulator, so a CONFIG_MIPS_O32_FP64_SUPPORT Kconfig option is
      introduced to allow this support to be disabled for those that don't
      require it.
      
      Inspired by an earlier patch by Leonid Yegoshin, but implemented more
      cleanly & correctly.
      Signed-off-by: NPaul Burton <paul.burton@imgtec.com>
      Cc: linux-mips@linux-mips.org
      Cc: Paul Burton <paul.burton@imgtec.com>
      Patchwork: https://patchwork.linux-mips.org/patch/6154/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      597ce172
  11. 14 11月, 2013 1 次提交
  12. 30 10月, 2013 2 次提交
  13. 11 6月, 2013 2 次提交
  14. 11 4月, 2013 1 次提交
    • R
      MIPS: Use inline function to access current thread pointer. · ad04c2e9
      Ralf Baechle 提交于
      With LTE this fixes this issue:
      
        LDFINAL vmlinux.o
      arch/mips/built-in.o (symbol from plugin): In function `sgimc_init':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      kernel/built-in.o (symbol from plugin): In function `get_task_mm':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      mm/built-in.o (symbol from plugin): In function `iov_iter_single_seg_count':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      fs/built-in.o (symbol from plugin): In function `finish_no_open':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      ipc/built-in.o (symbol from plugin): In function `ipc_init_ids':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      security/built-in.o (symbol from plugin): In function `key_schedule_gc':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      crypto/built-in.o (symbol from plugin): In function `crypto_find_alg':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      block/built-in.o (symbol from plugin): In function `elv_rb_find':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      argv_split.o (symbol from plugin): In function `argv_free':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      dec_and_lock.o (symbol from plugin): In function `_atomic_dec_and_lock':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      extable.o (symbol from plugin): In function `sort_extable':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      flex_proportions.o (symbol from plugin): In function `fprop_global_init':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      idr.o (symbol from plugin): In function `idr_for_each':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      is_single_threaded.o (symbol from plugin): In function `current_is_single_threaded':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      kobject.o (symbol from plugin): In function `kobject_get':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      kobject_uevent.o (symbol from plugin): In function `add_uevent_var':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      plist.o (symbol from plugin): In function `plist_add':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      radix-tree.o (symbol from plugin): In function `radix_tree_lookup_slot':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      ratelimit.o (symbol from plugin): In function `___ratelimit':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      rwsem-spinlock.o (symbol from plugin): In function `__init_rwsem':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      show_mem.o (symbol from plugin): In function `show_mem':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      timerqueue.o (symbol from plugin): In function `timerqueue_iterate_next':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      vsprintf.o (symbol from plugin): In function `simple_strtoull':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      delay.o (symbol from plugin): In function `__delay':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      mips-atomic.o (symbol from plugin): In function `arch_local_irq_disable':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      uncached.o (symbol from plugin): In function `run_uncached':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      lib/built-in.o (symbol from plugin): In function `_bcd2bin':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      arch/mips/lib/built-in.o (symbol from plugin): In function `ioread8':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      drivers/built-in.o (symbol from plugin): In function `fb_notifier_call_chain':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      net/built-in.o (symbol from plugin): In function `sock_from_file':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      klist.o (symbol from plugin): In function `klist_init':
      (.text+0x0): multiple definition of `$28'
      init/built-in.o (symbol from plugin):(.text+0x0): first defined here
      
      It also makes the code a little more readable, so let's merge it.
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      ad04c2e9
  15. 01 2月, 2013 1 次提交
  16. 27 12月, 2012 1 次提交
  17. 09 11月, 2012 2 次提交
  18. 01 10月, 2012 4 次提交
  19. 22 9月, 2012 2 次提交
  20. 19 7月, 2012 1 次提交
  21. 08 5月, 2012 1 次提交
  22. 22 11月, 2011 1 次提交
  23. 19 5月, 2011 1 次提交
  24. 23 3月, 2011 1 次提交
  25. 30 10月, 2010 1 次提交
  26. 05 10月, 2010 1 次提交
    • R
      MIPS: Audit: Fix hang in entry.S. · 24459946
      Ralf Baechle 提交于
      _TIF_WORK_MASK false had _TIF_SYSCALL_AUDIT set.  If a thread's
      _TIF_SYSCALL_AUDIT is ever set this will lead to an endless loop on the
      way out from a syscall.
      
      Currently this is only a theoretic bug as init/Kconfig doesn't allow
      AUDIT_SYSCALL to be enabled for MIPS.
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      24459946
  27. 14 5月, 2010 1 次提交
  28. 02 11月, 2009 1 次提交
  29. 02 9月, 2009 1 次提交
  30. 11 7月, 2009 1 次提交
  31. 14 5月, 2009 1 次提交
  32. 14 3月, 2009 1 次提交