1. 01 9月, 2019 2 次提交
    • T
      MIPS: PCI: refactor ioc3 special handling · 813cafc4
      Thomas Bogendoerfer 提交于
      Refactored code to only have one ioc3 special handling for read
      access and one for write access.
      Signed-off-by: NThomas Bogendoerfer <tbogendoerfer@suse.de>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Cc: Alexandre Belloni <alexandre.belloni@bootlin.com>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Jiri Slaby <jslaby@suse.com>
      Cc: Evgeniy Polyakov <zbr@ioremap.net>
      Cc: linux-doc@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-input@vger.kernel.org
      Cc: netdev@vger.kernel.org
      Cc: linux-rtc@vger.kernel.org
      Cc: linux-serial@vger.kernel.org
      813cafc4
    • C
      mips: remove ioremap_cachable · 60af0d94
      Christoph Hellwig 提交于
      Just define ioremap_cache directly.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Guo Ren <guoren@kernel.org>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Greentime Hu <green.hu@gmail.com>
      Cc: Vincent Chen <deanbo422@gmail.com>
      Cc: Guan Xuetao <gxt@pku.edu.cn>
      Cc: linux-mips@vger.kernel.org
      Cc: linux-arch@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      60af0d94
  2. 31 8月, 2019 3 次提交
    • P
      mips/atomic: Fix smp_mb__{before,after}_atomic() · 42344113
      Peter Zijlstra 提交于
      Recent probing at the Linux Kernel Memory Model uncovered a
      'surprise'. Strongly ordered architectures where the atomic RmW
      primitive implies full memory ordering and
      smp_mb__{before,after}_atomic() are a simple barrier() (such as MIPS
      without WEAK_REORDERING_BEYOND_LLSC) fail for:
      
      	*x = 1;
      	atomic_inc(u);
      	smp_mb__after_atomic();
      	r0 = *y;
      
      Because, while the atomic_inc() implies memory order, it
      (surprisingly) does not provide a compiler barrier. This then allows
      the compiler to re-order like so:
      
      	atomic_inc(u);
      	*x = 1;
      	smp_mb__after_atomic();
      	r0 = *y;
      
      Which the CPU is then allowed to re-order (under TSO rules) like:
      
      	atomic_inc(u);
      	r0 = *y;
      	*x = 1;
      
      And this very much was not intended. Therefore strengthen the atomic
      RmW ops to include a compiler barrier.
      Reported-by: NAndrea Parri <andrea.parri@amarulasolutions.com>
      Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      42344113
    • P
      mips/atomic: Fix loongson_llsc_mb() wreckage · 1c6c1ca3
      Peter Zijlstra 提交于
      The comment describing the loongson_llsc_mb() reorder case doesn't
      make any sense what so ever. Instruction re-ordering is not an SMP
      artifact, but rather a CPU local phenomenon. Clarify the comment by
      explaining that these issue cause a coherence fail.
      
      For the branch speculation case; if futex_atomic_cmpxchg_inatomic()
      needs one at the bne branch target, then surely the normal
      __cmpxch_asm() implementation does too. We cannot rely on the
      barriers from cmpxchg() because cmpxchg_local() is implemented with
      the same macro, and branch prediction and speculation are, too, CPU
      local.
      
      Fixes: e02e07e3 ("MIPS: Loongson: Introduce and use loongson_llsc_mb()")
      Cc: Huacai Chen <chenhc@lemote.com>
      Cc: Huang Pei <huangpei@loongson.cn>
      Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      1c6c1ca3
    • P
      mips/atomic: Fix cmpxchg64 barriers · dfc8d8de
      Peter Zijlstra 提交于
      There were no memory barriers on the 32bit implementation of
      cmpxchg64(). Fix this.
      Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      dfc8d8de
  3. 27 8月, 2019 1 次提交
  4. 26 8月, 2019 4 次提交
    • F
      firmware: bcm47xx_nvram: Allow COMPILE_TEST · 5699ad0a
      Florian Fainelli 提交于
      Allow building building the BCM47xx NVRAM and SPROM drivers using
      COMPILE_TEST.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: linux-mips@linux-mips.org
      Cc: joe@perches.com
      Cc: Rafał Miłecki <zajec5@gmail.com>
      Cc: linux-mips@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      5699ad0a
    • F
      firmware: bcm47xx_nvram: Correct size_t printf format · feb4eb06
      Florian Fainelli 提交于
      When building on a 64-bit host, we will get warnings like those:
      
      drivers/firmware/broadcom/bcm47xx_nvram.c:103:3: note: in expansion of macro 'pr_err'
         pr_err("nvram on flash (%i bytes) is bigger than the reserved space in memory, will just copy the first %i bytes\n",
         ^~~~~~
      drivers/firmware/broadcom/bcm47xx_nvram.c:103:28: note: format string is defined here
         pr_err("nvram on flash (%i bytes) is bigger than the reserved space in memory, will just copy the first %i bytes\n",
                                 ~^
                                 %li
      
      Use %zu instead for that purpose.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Reviewed-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: linux-mips@linux-mips.org
      Cc: joe@perches.com
      Cc: Rafał Miłecki <zajec5@gmail.com>
      Cc: linux-mips@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      feb4eb06
    • J
      MIPS: Treat Loongson Extensions as ASEs · d2f96554
      Jiaxun Yang 提交于
      Recently, binutils had split Loongson-3 Extensions into four ASEs:
      MMI, CAM, EXT, EXT2. This patch do the samething in kernel and expose
      them in cpuinfo so applications can probe supported ASEs at runtime.
      Signed-off-by: NJiaxun Yang <jiaxun.yang@flygoat.com>
      Cc: Huacai Chen <chenhc@lemote.com>
      Cc: Yunqiang Su <ysu@wavecomp.com>
      Cc: stable@vger.kernel.org # v4.14+
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: linux-mips@vger.kernel.org
      d2f96554
    • S
      MIPS: Remove dev_err() usage after platform_get_irq() · 322e577b
      Stephen Boyd 提交于
      We don't need dev_err() messages when platform_get_irq() fails now that
      platform_get_irq() prints an error message itself when something goes
      wrong. Let's remove these prints with a simple semantic patch.
      
      // <smpl>
      @@
      expression ret;
      struct platform_device *E;
      @@
      
      ret =
      (
      platform_get_irq(E, ...)
      |
      platform_get_irq_byname(E, ...)
      );
      
      if ( \( ret < 0 \| ret <= 0 \) )
      {
      (
      -if (ret != -EPROBE_DEFER)
      -{ ...
      -dev_err(...);
      -... }
      |
      ...
      -dev_err(...);
      )
      ...
      }
      // </smpl>
      
      While we're here, remove braces on if statements that only have one
      statement (manually).
      
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Paul Burton <paul.burton@mips.com>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: linux-mips@vger.kernel.org
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Signed-off-by: NStephen Boyd <swboyd@chromium.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: linux-kernel@vger.kernel.org
      322e577b
  5. 24 8月, 2019 6 次提交
  6. 23 8月, 2019 8 次提交
  7. 20 8月, 2019 2 次提交
  8. 12 8月, 2019 3 次提交
    • N
      MIPS: tlbex: Explicitly cast _PAGE_NO_EXEC to a boolean · c59ae0a1
      Nathan Chancellor 提交于
      clang warns:
      
      arch/mips/mm/tlbex.c:634:19: error: use of logical '&&' with constant
      operand [-Werror,-Wconstant-logical-operand]
              if (cpu_has_rixi && _PAGE_NO_EXEC) {
                               ^  ~~~~~~~~~~~~~
      arch/mips/mm/tlbex.c:634:19: note: use '&' for a bitwise operation
              if (cpu_has_rixi && _PAGE_NO_EXEC) {
                               ^~
                               &
      arch/mips/mm/tlbex.c:634:19: note: remove constant to silence this
      warning
              if (cpu_has_rixi && _PAGE_NO_EXEC) {
                              ~^~~~~~~~~~~~~~~~
      1 error generated.
      
      Explicitly cast this value to a boolean so that clang understands we
      intend for this to be a non-zero value.
      
      Fixes: 00bf1c69 ("MIPS: tlbex: Avoid placing software PTE bits in Entry* PFN fields")
      Link: https://github.com/ClangBuiltLinux/linux/issues/609Signed-off-by: NNathan Chancellor <natechancellor@gmail.com>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Nick Desaulniers <ndesaulniers@google.com>
      Cc: linux-mips@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: clang-built-linux@googlegroups.com
      c59ae0a1
    • N
      MIPS/ptrace: Update mips_get_syscall_arg's return type · 077ff3be
      Nathan Chancellor 提交于
      clang warns:
      
      arch/mips/include/asm/syscall.h:136:3: error: variable 'ret' is
      uninitialized when used here [-Werror,-Wuninitialized]
                      ret |= mips_get_syscall_arg(args++, task, regs, i++);
                      ^~~
      arch/mips/include/asm/syscall.h:129:9: note: initialize the variable
      'ret' to silence this warning
              int ret;
                     ^
                      = 0
      1 error generated.
      
      It's not wrong; however, it's not an issue in practice because ret is
      only assigned to, not read from. ret could just be initialized to zero
      but looking into it further, ret has been unused since it was first
      added in 2012 so just get rid of it and update mips_get_syscall_arg's
      return type since none of the return values are ever checked. If it is
      ever needed again, this commit can be reverted and ret can be properly
      initialized.
      
      Fixes: c0ff3c53 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.")
      Link: https://github.com/ClangBuiltLinux/linux/issues/604Signed-off-by: NNathan Chancellor <natechancellor@gmail.com>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Nick Desaulniers <ndesaulniers@google.com>
      Cc: linux-mips@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: clang-built-linux@googlegroups.com
      077ff3be
    • N
      MIPS: Don't use bc_false uninitialized in __mm_isBranchInstr · c2869aaf
      Nathan Chancellor 提交于
      clang warns:
      
      arch/mips/kernel/branch.c:148:8: error: variable 'bc_false' is used
      uninitialized whenever switch case is taken
      [-Werror,-Wsometimes-uninitialized]
                      case mm_bc2t_op:
                           ^~~~~~~~~~
      arch/mips/kernel/branch.c:157:8: note: uninitialized use occurs here
                              if (bc_false)
                                  ^~~~~~~~
      arch/mips/kernel/branch.c:149:8: error: variable 'bc_false' is used
      uninitialized whenever switch case is taken
      [-Werror,-Wsometimes-uninitialized]
                      case mm_bc1t_op:
                           ^~~~~~~~~~
      arch/mips/kernel/branch.c:157:8: note: uninitialized use occurs here
                              if (bc_false)
                                  ^~~~~~~~
      arch/mips/kernel/branch.c:142:4: note: variable 'bc_false' is declared
      here
                              int bc_false = 0;
                              ^
      2 errors generated.
      
      When mm_bc1t_op and mm_bc2t_op are taken, the bc_false initialization
      does not happen, which leads to a garbage value upon use, as illustrated
      below with a small sample program.
      
      $ mipsel-linux-gnu-gcc --version | head -n1
      mipsel-linux-gnu-gcc (Debian 8.3.0-2) 8.3.0
      
      $ clang --version | head -n1
      ClangBuiltLinux clang version 9.0.0 (git://github.com/llvm/llvm-project
      544315b4197034a3be8acd12cba56a75fb1f08dc) (based on LLVM 9.0.0svn)
      
      $ cat test.c
       #include <stdio.h>
      
       static void switch_scoped(int opcode)
       {
      	 switch (opcode) {
      	 case 1:
      	 case 2: {
      		 int bc_false = 0;
      
      		 bc_false = 4;
      	 case 3:
      	 case 4:
      		 printf("\t* switch scoped bc_false = %d\n", bc_false);
      	 }
      	 }
       }
      
       static void function_scoped(int opcode)
       {
      	 int bc_false = 0;
      
      	 switch (opcode) {
      	 case 1:
      	 case 2: {
      		 bc_false = 4;
      	 case 3:
      	 case 4:
      		 printf("\t* function scoped bc_false = %d\n", bc_false);
      	 }
      	 }
       }
      
       int main(void)
       {
      	 int opcode;
      
      	 for (opcode = 1; opcode < 5; opcode++) {
      		 printf("opcode = %d:\n", opcode);
      		 switch_scoped(opcode);
      		 function_scoped(opcode);
      		 printf("\n");
      	 }
      
      	 return 0;
       }
      
      $ mipsel-linux-gnu-gcc -std=gnu89 -static test.c && \
        qemu-mipsel a.out
      opcode = 1:
              * switch scoped bc_false = 4
              * function scoped bc_false = 4
      
      opcode = 2:
              * switch scoped bc_false = 4
              * function scoped bc_false = 4
      
      opcode = 3:
              * switch scoped bc_false = 2147483004
              * function scoped bc_false = 0
      
      opcode = 4:
              * switch scoped bc_false = 2147483004
              * function scoped bc_false = 0
      
      $ clang -std=gnu89 --target=mipsel-linux-gnu -m32 -static test.c && \
        qemu-mipsel a.out
      opcode = 1:
              * switch scoped bc_false = 4
              * function scoped bc_false = 4
      
      opcode = 2:
              * switch scoped bc_false = 4
              * function scoped bc_false = 4
      
      opcode = 3:
              * switch scoped bc_false = 2147483004
              * function scoped bc_false = 0
      
      opcode = 4:
              * switch scoped bc_false = 2147483004
              * function scoped bc_false = 0
      
      Move the definition up so that we get the right behavior and mark it
      __maybe_unused as it will not be used when CONFIG_MIPS_FP_SUPPORT
      isn't enabled.
      
      Fixes: 6a1cc218 ("MIPS: branch: Remove FP branch handling when CONFIG_MIPS_FP_SUPPORT=n")
      Link: https://github.com/ClangBuiltLinux/linux/issues/603Signed-off-by: NNathan Chancellor <natechancellor@gmail.com>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Nick Desaulniers <ndesaulniers@google.com>
      Cc: linux-mips@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: clang-built-linux@googlegroups.com
      c2869aaf
  9. 09 8月, 2019 11 次提交
    • P
      Merge branch 'ingenic-tcu-v5.4' into mips-next · 75b7329a
      Paul Burton 提交于
      Merge the Ingenic TCU patchset from the ingenic-tcu-v5.4 branch which
      was created to enable follow-on changes in other subsystems.
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      75b7329a
    • P
      MIPS: jz4740: Drop obsolete code · abc55228
      Paul Cercueil 提交于
      The old clocksource/timer platform code is now obsoleted by the newly
      introduced TCU drivers.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      abc55228
    • P
      MIPS: GCW0: Reduce system timer and clocksource to 750 kHz · 967a7100
      Paul Cercueil 提交于
      The default clock (12 MHz) is too fast for the system timer.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      967a7100
    • P
      MIPS: CI20: Reduce system timer and clocksource to 3 MHz · 157c887a
      Paul Cercueil 提交于
      The default clock (48 MHz) is too fast for the system timer.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      157c887a
    • P
      MIPS: qi_lb60: Reduce system timer and clocksource to 750 kHz · a68d3b05
      Paul Cercueil 提交于
      The default clock (12 MHz) is too fast for the system timer, which fails
      to report time accurately.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      a68d3b05
    • P
      MIPS: jz4740: Add DTS nodes for the TCU drivers · 36aafdbd
      Paul Cercueil 提交于
      Add DTS nodes for the JZ4780, JZ4770 and JZ4740 devicetree files.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      36aafdbd
    • P
      clk: jz4740: Add TCU clock · 73dd11dc
      Paul Cercueil 提交于
      Add the missing TCU clock to the list of clocks supplied by the CGU for
      the JZ4740 SoC.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Acked-by: NStephen Boyd <sboyd@kernel.org>
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      73dd11dc
    • P
      clocksource: Add a new timer-ingenic driver · 34e93683
      Paul Cercueil 提交于
      This driver handles the TCU (Timer Counter Unit) present on the Ingenic
      JZ47xx SoCs, and provides the kernel with a system timer, a clocksource
      and a sched_clock.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Reviewed-by: NThomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      34e93683
    • P
      irqchip: Add irq-ingenic-tcu driver · 9536eba0
      Paul Cercueil 提交于
      This driver handles the interrupt controller built in the Timer/Counter
      Unit (TCU) of the JZ47xx SoCs from Ingenic.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Reviewed-by: NThomas Gleixner <tglx@linutronix.de>
      Acked-by: NMarc Zyngier <maz@kernel.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      9536eba0
    • P
      clk: ingenic: Add driver for the TCU clocks · 4f89e4b8
      Paul Cercueil 提交于
      Add driver to support the clocks provided by the Timer/Counter Unit
      (TCU) of the JZ47xx SoCs from Ingenic.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NMathieu Malaterre <malat@debian.org>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Acked-by: NStephen Boyd <sboyd@kernel.org>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      4f89e4b8
    • P
      mfd/syscon: Add device_node_to_regmap() · 39233b7c
      Paul Cercueil 提交于
      device_node_to_regmap() is exactly like syscon_node_to_regmap(), but it
      does not check that the node is compatible with "syscon", and won't
      attach the first clock it finds to the regmap.
      
      The rationale behind this, is that one device node with a standard
      compatible string "foo,bar" can be covered by multiple drivers sharing a
      regmap, or by a single driver doing all the job without a regmap, but
      these are implementation details which shouldn't reflect on the
      devicetree.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Acked-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NPaul Burton <paul.burton@mips.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: James Hogan <jhogan@kernel.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Lee Jones <lee.jones@linaro.org>
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Michael Turquette <mturquette@baylibre.com>
      Cc: Stephen Boyd <sboyd@kernel.org>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: devicetree@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Cc: linux-mips@vger.kernel.org
      Cc: linux-clk@vger.kernel.org
      Cc: od@zcrc.me
      Cc: Mathieu Malaterre <malat@debian.org>
      39233b7c