1. 04 Aug, 2016 1 commit
    • Masahiro Yamada's avatar
      tree-wide: replace config_enabled() with IS_ENABLED() · 97f2645f
      Masahiro Yamada authored
      The use of config_enabled() against config options is ambiguous.  In
      practical terms, config_enabled() is equivalent to IS_BUILTIN(), but the
      author might have used it for the meaning of IS_ENABLED().  Using
      IS_ENABLED(), IS_BUILTIN(), IS_MODULE() etc.  makes the intention
      clearer.
      
      This commit replaces config_enabled() with IS_ENABLED() where possible.
      This commit is only touching bool config options.
      
      I noticed two cases where config_enabled() is used against a tristate
      option:
      
       - config_enabled(CONFIG_HWMON)
        [ drivers/net/wireless/ath/ath10k/thermal.c ]
      
       - config_enabled(CONFIG_BACKLIGHT_CLASS_DEVICE)
        [ drivers/gpu/drm/gma500/opregion.c ]
      
      I did not touch them because they should be converted to IS_BUILTIN()
      in order to keep the logic, but I was not sure it was the authors'
      intention.
      
      Link: http://lkml.kernel.org/r/1465215656-20569-1-git-send-email-yamada.masahiro@socionext.comSigned-off-by: Masahiro Yamada's avatarMasahiro Yamada <yamada.masahiro@socionext.com>
      Acked-by: default avatarKees Cook <keescook@chromium.org>
      Cc: Stas Sergeev <stsp@list.ru>
      Cc: Matt Redfearn <matt.redfearn@imgtec.com>
      Cc: Joshua Kinard <kumba@gentoo.org>
      Cc: Jiri Slaby <jslaby@suse.com>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Borislav Petkov <bp@suse.de>
      Cc: Markos Chandras <markos.chandras@imgtec.com>
      Cc: "Dmitry V. Levin" <ldv@altlinux.org>
      Cc: yu-cheng yu <yu-cheng.yu@intel.com>
      Cc: James Hogan <james.hogan@imgtec.com>
      Cc: Brian Gerst <brgerst@gmail.com>
      Cc: Johannes Berg <johannes@sipsolutions.net>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: Will Drewry <wad@chromium.org>
      Cc: Nikolay Martynov <mar.kolya@gmail.com>
      Cc: Huacai Chen <chenhc@lemote.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Daniel Borkmann <daniel@iogearbox.net>
      Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com>
      Cc: Rafal Milecki <zajec5@gmail.com>
      Cc: James Cowgill <James.Cowgill@imgtec.com>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Alex Smith <alex.smith@imgtec.com>
      Cc: Adam Buchbinder <adam.buchbinder@gmail.com>
      Cc: Qais Yousef <qais.yousef@imgtec.com>
      Cc: Jiang Liu <jiang.liu@linux.intel.com>
      Cc: Mikko Rapeli <mikko.rapeli@iki.fi>
      Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
      Cc: Denys Vlasenko <dvlasenk@redhat.com>
      Cc: Brian Norris <computersforpeace@gmail.com>
      Cc: Hidehiro Kawai <hidehiro.kawai.ez@hitachi.com>
      Cc: "Luis R. Rodriguez" <mcgrof@do-not-panic.com>
      Cc: Andy Lutomirski <luto@amacapital.net>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Dave Hansen <dave.hansen@linux.intel.com>
      Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
      Cc: Roland McGrath <roland@hack.frob.com>
      Cc: Paul Burton <paul.burton@imgtec.com>
      Cc: Kalle Valo <kvalo@qca.qualcomm.com>
      Cc: Viresh Kumar <viresh.kumar@linaro.org>
      Cc: Tony Wu <tung7970@gmail.com>
      Cc: Huaitong Han <huaitong.han@intel.com>
      Cc: Sumit Semwal <sumit.semwal@linaro.org>
      Cc: Alexei Starovoitov <ast@kernel.org>
      Cc: Juergen Gross <jgross@suse.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Oleg Nesterov <oleg@redhat.com>
      Cc: Andrea Gelmini <andrea.gelmini@gelma.net>
      Cc: David Woodhouse <dwmw2@infradead.org>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rabin Vincent <rabin@rab.in>
      Cc: "Maciej W. Rozycki" <macro@imgtec.com>
      Cc: David Daney <david.daney@cavium.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      97f2645f
  2. 28 May, 2016 2 commits
  3. 09 May, 2016 1 commit
  4. 03 Apr, 2016 1 commit
    • Maciej W. Rozycki's avatar
      MIPS: traps: Correct the SIGTRAP debug ABI in `do_watch' and `do_trap_or_bp' · 3b143cca
      Maciej W. Rozycki authored
      Follow our own rules set in <asm/siginfo.h> for SIGTRAP signals issued
      from `do_watch' and `do_trap_or_bp' by setting the signal code to
      TRAP_HWBKPT and TRAP_BRKPT respectively, for Watch exceptions and for
      those Breakpoint exceptions whose originating BREAK instruction's code
      does not have a special meaning.  Keep Trap exceptions unaffected as
      these are not debug events.
      
      No existing user software is expected to examine signal codes for these
      signals as SI_KERNEL has been always used here.  This change makes the
      MIPS port more like other Linux ports, which reduces the complexity and
      provides for performance improvement in GDB.
      Signed-off-by: default avatarMaciej W. Rozycki <macro@imgtec.com>
      Cc: Pedro Alves <palves@redhat.com>
      Cc: Luis Machado <lgustavo@codesourcery.com>
      Cc: linux-mips@linux-mips.org
      Cc: gdb@sourceware.org
      Patchwork: https://patchwork.linux-mips.org/patch/12758/Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
      3b143cca
  5. 26 Oct, 2015 1 commit
    • Paul Burton's avatar
      MIPS: Declare mips_debugfs_dir in a header · 75dcfc1d
      Paul Burton authored
      We have many extern declarations of mips_debugfs_dir through arch/mips/
      in various C files. Unify them by declaring mips_debugfs_dir in a
      header, including it in each affected C file & removing the duplicate
      declarations.
      Signed-off-by: default avatarPaul Burton <paul.burton@imgtec.com>
      Cc: linux-mips@linux-mips.org
      Cc: Steven J. Hill <Steven.Hill@imgtec.com>
      Cc: Alexander Sverdlin <alexander.sverdlin@nokia.com>
      Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
      Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com>
      Cc: Maciej W. Rozycki <macro@linux-mips.org>
      Cc: linux-kernel@vger.kernel.org
      Cc: Joe Perches <joe@perches.com>
      Cc: Jaedon Shin <jaedon.shin@gmail.com>
      Cc: James Hogan <james.hogan@imgtec.com>
      Cc: David Daney <david.daney@cavium.com>
      Cc: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com>
      Cc: Markos Chandras <markos.chandras@imgtec.com>
      Cc: James Cowgill <James.Cowgill@imgtec.com>
      Patchwork: https://patchwork.linux-mips.org/patch/11181/Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
      75dcfc1d
  6. 07 Apr, 2015 3 commits
  7. 17 Feb, 2015 1 commit
    • Leonid Yegoshin's avatar
      MIPS: kernel: mips-r2-to-r6-emul: Add R2 emulator for MIPS R6 · b0a668fb
      Leonid Yegoshin authored
      MIPS R6 removed quite a few R2 instructions. However, there
      is plenty of <R6 userland code so we add an in-kernel emulator
      so we can still be able to execute all R2 userland out there.
      
      The emulator comes with a handy debugfs under /mips/ directory
      (r2-emul-stats) to provide some basic statistics of the
      instructions that are being emulated.
      
      Below are some statistics from booting a minimal buildroot image:
      
      Instruction     Total   BDslot
      ------------------------------
      movs            236969  0
      hilo            56686   0
      muls            55279   0
      divs            10941   0
      dsps            0       0
      bops            1       0
      traps           0       0
      fpus            0       0
      loads           214981  17
      stores          103364  0
      llsc            56898   0
      dsemul          150418  0
      jr              370158
      bltzl           43
      bgezl           1594
      bltzll          0
      bgezll          0
      bltzal          39
      bgezal          39
      beql            14503
      bnel            138741
      blezl           0
      bgtzl           3988
      Signed-off-by: default avatarLeonid Yegoshin <Leonid.Yegoshin@imgtec.com>
      Signed-off-by: default avatarMarkos Chandras <markos.chandras@imgtec.com>
      b0a668fb