1. 23 3月, 2018 1 次提交
    • M
      MIPS: Use the entry point from the ELF file header · 27c524d1
      Maciej W. Rozycki 提交于
      In order to fetch the correct entry point with the ISA bit included, for
      use by non-ELF boot loaders, parse the output of `objdump -f' for the
      start address recorded in the kernel executable itself, rather than
      using `nm' to get the value of the `kernel_entry' symbol.
      
      Sign-extend the address retrieved if 32-bit, so that execution is
      correctly started on 64-bit processors as well.  The tool always prints
      the entry point using either 8 or 16 hexadecimal digits, matching the
      address width (aka class) of the ELF file, even in the presence of
      leading zeros.
      Signed-off-by: NMaciej W. Rozycki <macro@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Paul Burton <paul.burton@mips.com>
      Cc: linux-mips@linux-mips.org
      Patchwork: https://patchwork.linux-mips.org/patch/18912/Signed-off-by: NJames Hogan <jhogan@kernel.org>
      27c524d1
  2. 22 3月, 2018 3 次提交
  3. 14 3月, 2018 2 次提交
  4. 09 3月, 2018 6 次提交
  5. 06 3月, 2018 3 次提交
  6. 05 3月, 2018 1 次提交
    • J
      MIPS: Expand help text to list generic defconfigs · cccd0b9a
      James Hogan 提交于
      Expand the MIPS Makefile help text to list generic board names, generic
      defconfigs, and legacy defconfigs which have been converted to generic
      and are still usable.
      
      Here's a snippet of the new "make ARCH=mips help" output:
        ...
        If you are targeting a system supported by generic kernels you may
        configure the kernel for a given architecture target like so:
      
        {micro32,32,64}{r1,r2,r6}{el,}_defconfig <BOARDS="list of boards">
      
        Where BOARDS is some subset of the following:
          boston
          ni169445
          ranchu
          sead-3
          xilfpga
      
        Specifically the following generic default configurations are
        supported:
      
        32r1_defconfig           - Build generic kernel for MIPS32 r1
        32r1el_defconfig         - Build generic kernel for MIPS32 r1 little endian
        32r2_defconfig           - Build generic kernel for MIPS32 r2
        32r2el_defconfig         - Build generic kernel for MIPS32 r2 little endian
        32r6_defconfig           - Build generic kernel for MIPS32 r6
        32r6el_defconfig         - Build generic kernel for MIPS32 r6 little endian
        64r1_defconfig           - Build generic kernel for MIPS64 r1
        64r1el_defconfig         - Build generic kernel for MIPS64 r1 little endian
        64r2_defconfig           - Build generic kernel for MIPS64 r2
        64r2el_defconfig         - Build generic kernel for MIPS64 r2 little endian
        64r6_defconfig           - Build generic kernel for MIPS64 r6
        64r6el_defconfig         - Build generic kernel for MIPS64 r6 little endian
        micro32r2_defconfig      - Build generic kernel for microMIPS32 r2
        micro32r2el_defconfig    - Build generic kernel for microMIPS32 r2 little endian
      
        The following legacy default configurations have been converted to
        generic and can still be used:
      
        sead3_defconfig          - Build 32r2el_defconfig BOARDS=sead-3
        sead3micro_defconfig     - Build micro32r2el_defconfig BOARDS=sead-3
        xilfpga_defconfig        - Build 32r2el_defconfig BOARDS=xilfpga
        ...
      Signed-off-by: NJames Hogan <jhogan@kernel.org>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Paul Burton <paul.burton@mips.com>
      Cc: Matt Redfearn <matt.redfearn@mips.com>
      Cc: linux-mips@linux-mips.org
      Cc: linux-kbuild@vger.kernel.org
      Patchwork: https://patchwork.linux-mips.org/patch/18598/
      cccd0b9a
  7. 20 2月, 2018 4 次提交
  8. 19 2月, 2018 10 次提交
  9. 17 2月, 2018 3 次提交
  10. 16 2月, 2018 5 次提交
  11. 15 2月, 2018 2 次提交
    • I
      x86/entry/64: Fix CR3 restore in paranoid_exit() · e4865757
      Ingo Molnar 提交于
      Josh Poimboeuf noticed the following bug:
      
       "The paranoid exit code only restores the saved CR3 when it switches back
        to the user GS.  However, even in the kernel GS case, it's possible that
        it needs to restore a user CR3, if for example, the paranoid exception
        occurred in the syscall exit path between SWITCH_TO_USER_CR3_STACK and
        SWAPGS."
      
      Josh also confirmed via targeted testing that it's possible to hit this bug.
      
      Fix the bug by also restoring CR3 in the paranoid_exit_no_swapgs branch.
      
      The reason we haven't seen this bug reported by users yet is probably because
      "paranoid" entry points are limited to the following cases:
      
       idtentry double_fault       do_double_fault  has_error_code=1  paranoid=2
       idtentry debug              do_debug         has_error_code=0  paranoid=1 shift_ist=DEBUG_STACK
       idtentry int3               do_int3          has_error_code=0  paranoid=1 shift_ist=DEBUG_STACK
       idtentry machine_check      do_mce           has_error_code=0  paranoid=1
      
      Amongst those entry points only machine_check is one that will interrupt an
      IRQS-off critical section asynchronously - and machine check events are rare.
      
      The other main asynchronous entries are NMI entries, which can be very high-freq
      with perf profiling, but they are special: they don't use the 'idtentry' macro but
      are open coded and restore user CR3 unconditionally so don't have this bug.
      Reported-and-tested-by: NJosh Poimboeuf <jpoimboe@redhat.com>
      Reviewed-by: NAndy Lutomirski <luto@kernel.org>
      Acked-by: NThomas Gleixner <tglx@linutronix.de>
      Cc: Arjan van de Ven <arjan@linux.intel.com>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Dan Williams <dan.j.williams@intel.com>
      Cc: Dave Hansen <dave.hansen@linux.intel.com>
      Cc: David Woodhouse <dwmw2@infradead.org>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Link: http://lkml.kernel.org/r/20180214073910.boevmg65upbk3vqb@gmail.comSigned-off-by: NIngo Molnar <mingo@kernel.org>
      e4865757
    • G
      x86/cpu: Change type of x86_cache_size variable to unsigned int · 24dbc600
      Gustavo A. R. Silva 提交于
      Currently, x86_cache_size is of type int, which makes no sense as we
      will never have a valid cache size equal or less than 0. So instead of
      initializing this variable to -1, it can perfectly be initialized to 0
      and use it as an unsigned variable instead.
      Suggested-by: NThomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NGustavo A. R. Silva <garsilva@embeddedor.com>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Addresses-Coverity-ID: 1464429
      Link: http://lkml.kernel.org/r/20180213192208.GA26414@embeddedor.comSigned-off-by: NIngo Molnar <mingo@kernel.org>
      24dbc600