1. 16 Sep, 2015 22 commits
  2. 15 Sep, 2015 12 commits
    • Huang Shijie's avatar
      genirq: Update the comment for generic_handle_irq_desc · 6584d84c
      Huang Shijie authored
      __do_IRQ() was removed by commit 1c77ff22 "genirq: Remove __do_IRQ",
      but the comment referring to __do_IRQ() was left.
      
      Update the comment for generic_handle_irq_desc().
      Signed-off-by: default avatarHuang Shijie <shijie.huang@arm.com>
      Cc: jiang.liu@linux.intel.com
      Cc: peterz@infradead.org
      Cc: rafael.j.wysocki@intel.com
      Cc: jason@lakedaemon.net
      Cc: marc.zyngier@arm.com
      Link: http://lkml.kernel.org/r/1441074950-3893-1-git-send-email-shijie.huang@arm.comSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      6584d84c
    • Thomas Gleixner's avatar
      genirq: Remove stale comment · 3829c664
      Thomas Gleixner authored
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      3829c664
    • Geert Uytterhoeven's avatar
      irqchip/renesas-irqc: Propagate wake-up settings to parent · 4cd7863e
      Geert Uytterhoeven authored
      The renesas-irqc interrupt controller is cascaded to the GIC, but its
      driver doesn't propagate wake-up settings to the parent interrupt
      controller.
      
      Since commit aec89ef7 ("irqchip/gic: Enable SKIP_SET_WAKE and
      MASK_ON_SUSPEND"), the GIC driver masks interrupts during suspend, and
      wake-up through gpio-keys now fails on r8a73a4/ape6evm.
      
      Fix this by propagating wake-up settings to the parent interrupt
      controller. There's no need to handle irq_set_irq_wake() failures, as
      the renesas-irqc interrupt controller is always cascaded to a GIC, and
      the GIC driver always sets SKIP_SET_WAKE since the aforementioned
      commit.
      Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Cc: Sudeep Holla <sudeep.holla@arm.com>
      Cc: Magnus Damm <magnus.damm@gmail.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Link: http://lkml.kernel.org/r/1441731636-17610-3-git-send-email-geert%2Brenesas@glider.beSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      4cd7863e
    • Geert Uytterhoeven's avatar
      irqchip/renesas-intc-irqpin: Propagate wake-up settings to parent · f4e209cd
      Geert Uytterhoeven authored
      The renesas-intc-irqpin interrupt controller is cascaded to the GIC, but
      its driver doesn't propagate wake-up settings to the parent interrupt
      controller.
      
      Since commit aec89ef7 ("irqchip/gic: Enable SKIP_SET_WAKE and
      MASK_ON_SUSPEND"), the GIC driver masks interrupts during suspend, and
      wake-up through gpio-keys now fails on r8a7740/armadillo and
      sh73a0/kzm9g.
      
      Fix this by propagating wake-up settings to the parent interrupt
      controller. There's no need to handle irq_set_irq_wake() failures, as
      the renesas-intc-irqpin interrupt controller is always cascaded to a
      GIC, and the GIC driver always sets SKIP_SET_WAKE since the
      aforementioned commit.
      Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Cc: Sudeep Holla <sudeep.holla@arm.com>
      Cc: Magnus Damm <magnus.damm@gmail.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Marc Zyngier <marc.zyngier@arm.com>
      Link: http://lkml.kernel.org/r/1441731636-17610-2-git-send-email-geert%2Brenesas@glider.beSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      f4e209cd
    • Geert Uytterhoeven's avatar
      irqchip/renesas-intc-irqpin: Use a separate lockdep class · 769b5cf7
      Geert Uytterhoeven authored
      The renesas-intc-irqpin interrupt controller is cascaded to the GIC.
      Hence when propagating wake-up settings to its parent interrupt
      controller, the following lockdep warning is printed:
      
          =============================================
          [ INFO: possible recursive locking detected ]
          4.2.0-armadillo-10725-g50fcd7643c034198 #781 Not tainted
          ---------------------------------------------
          s2ram/1179 is trying to acquire lock:
          (&irq_desc_lock_class){-.-...}, at: [<c005bb54>] __irq_get_desc_lock+0x78/0x94
      
          but task is already holding lock:
          (&irq_desc_lock_class){-.-...}, at: [<c005bb54>] __irq_get_desc_lock+0x78/0x94
      
          other info that might help us debug this:
          Possible unsafe locking scenario:
      
      	  CPU0
      	  ----
           lock(&irq_desc_lock_class);
           lock(&irq_desc_lock_class);
      
          *** DEADLOCK ***
      
          May be due to missing lock nesting notation
      
          7 locks held by s2ram/1179:
          #0:  (sb_writers#7){.+.+.+}, at: [<c00c9708>] __sb_start_write+0x64/0xb8
          #1:  (&of->mutex){+.+.+.}, at: [<c0125a00>] kernfs_fop_write+0x78/0x1a0
          #2:  (s_active#23){.+.+.+}, at: [<c0125a08>] kernfs_fop_write+0x80/0x1a0
          #3:  (autosleep_lock){+.+.+.}, at: [<c0058244>] pm_autosleep_lock+0x18/0x20
          #4:  (pm_mutex){+.+.+.}, at: [<c0057e50>] pm_suspend+0x54/0x248
          #5:  (&dev->mutex){......}, at: [<c0243a20>] __device_suspend+0xdc/0x240
          #6:  (&irq_desc_lock_class){-.-...}, at: [<c005bb54>] __irq_get_desc_lock+0x78/0x94
      
          stack backtrace:
          CPU: 0 PID: 1179 Comm: s2ram Not tainted 4.2.0-armadillo-10725-g50fcd7643c034198
      
          Hardware name: Generic R8A7740 (Flattened Device Tree)
          [<c00129f4>] (dump_backtrace) from [<c0012bec>] (show_stack+0x18/0x1c)
          [<c0012bd4>] (show_stack) from [<c03f5d94>] (dump_stack+0x20/0x28)
          [<c03f5d74>] (dump_stack) from [<c00514d4>] (__lock_acquire+0x67c/0x1b88)
          [<c0050e58>] (__lock_acquire) from [<c0052df8>] (lock_acquire+0x9c/0xbc)
          [<c0052d5c>] (lock_acquire) from [<c03fb068>] (_raw_spin_lock_irqsave+0x44/0x58)
          [<c03fb024>] (_raw_spin_lock_irqsave) from [<c005bb54>] (__irq_get_desc_lock+0x78/0x94
          [<c005badc>] (__irq_get_desc_lock) from [<c005c3d8>] (irq_set_irq_wake+0x28/0x100)
          [<c005c3b0>] (irq_set_irq_wake) from [<c01e50d0>] (intc_irqpin_irq_set_wake+0x24/0x4c)
          [<c01e50ac>] (intc_irqpin_irq_set_wake) from [<c005c17c>] (set_irq_wake_real+0x3c/0x50
          [<c005c140>] (set_irq_wake_real) from [<c005c414>] (irq_set_irq_wake+0x64/0x100)
          [<c005c3b0>] (irq_set_irq_wake) from [<c02a19b4>] (gpio_keys_suspend+0x60/0xa0)
          [<c02a1954>] (gpio_keys_suspend) from [<c023b750>] (platform_pm_suspend+0x3c/0x5c)
      
      Avoid this false positive by using a separate lockdep class for INTC
      External IRQ Pin interrupts.
      Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Cc: Grygorii Strashko <grygorii.strashko@ti.com>
      Cc: Magnus Damm <magnus.damm@gmail.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Link: http://lkml.kernel.org/r/1441798974-25716-3-git-send-email-geert%2Brenesas@glider.beSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      769b5cf7
    • Geert Uytterhoeven's avatar
      irqchip/renesas-irqc: Use a separate lockdep class · b1370658
      Geert Uytterhoeven authored
      The renesas-irqc interrupt controller is cascaded to the GIC. Hence when
      propagating wake-up settings to its parent interrupt controller, the
      following lockdep warning is printed:
      
          =============================================
          [ INFO: possible recursive locking detected ]
          4.2.0-ape6evm-10725-g50fcd7643c034198 #280 Not tainted
          ---------------------------------------------
          s2ram/1072 is trying to acquire lock:
          (&irq_desc_lock_class){-.-...}, at: [<c008d3fc>] __irq_get_desc_lock+0x58/0x98
      
          but task is already holding lock:
          (&irq_desc_lock_class){-.-...}, at: [<c008d3fc>] __irq_get_desc_lock+0x58/0x98
      
          other info that might help us debug this:
          Possible unsafe locking scenario:
      
      	  CPU0
      	  ----
           lock(&irq_desc_lock_class);
           lock(&irq_desc_lock_class);
      
          *** DEADLOCK ***
      
          May be due to missing lock nesting notation
      
          6 locks held by s2ram/1072:
          #0:  (sb_writers#7){.+.+.+}, at: [<c012eb14>] __sb_start_write+0xa0/0xa8
          #1:  (&of->mutex){+.+.+.}, at: [<c019396c>] kernfs_fop_write+0x4c/0x1bc
          #2:  (s_active#24){.+.+.+}, at: [<c0193974>] kernfs_fop_write+0x54/0x1bc
          #3:  (pm_mutex){+.+.+.}, at: [<c008213c>] pm_suspend+0x10c/0x510
          #4:  (&dev->mutex){......}, at: [<c02af3c4>] __device_suspend+0xdc/0x2cc
          #5:  (&irq_desc_lock_class){-.-...}, at: [<c008d3fc>] __irq_get_desc_lock+0x58/0x98
      
          stack backtrace:
          CPU: 0 PID: 1072 Comm: s2ram Not tainted 4.2.0-ape6evm-10725-g50fcd7643c034198 #280
          Hardware name: Generic R8A73A4 (Flattened Device Tree)
          [<c0018078>] (unwind_backtrace) from [<c00144f0>] (show_stack+0x10/0x14)
          [<c00144f0>] (show_stack) from [<c0451f14>] (dump_stack+0x88/0x98)
          [<c0451f14>] (dump_stack) from [<c007b29c>] (__lock_acquire+0x15cc/0x20e4)
          [<c007b29c>] (__lock_acquire) from [<c007c6e0>] (lock_acquire+0xac/0x12c)
          [<c007c6e0>] (lock_acquire) from [<c0457c00>] (_raw_spin_lock_irqsave+0x40/0x54)
          [<c0457c00>] (_raw_spin_lock_irqsave) from [<c008d3fc>] (__irq_get_desc_lock+0x58/0x98)
          [<c008d3fc>] (__irq_get_desc_lock) from [<c008ebbc>] (irq_set_irq_wake+0x20/0xf8)
          [<c008ebbc>] (irq_set_irq_wake) from [<c0260770>] (irqc_irq_set_wake+0x20/0x4c)
          [<c0260770>] (irqc_irq_set_wake) from [<c008ec28>] (irq_set_irq_wake+0x8c/0xf8)
          [<c008ec28>] (irq_set_irq_wake) from [<c02cb8c0>] (gpio_keys_suspend+0x74/0xc0)
          [<c02cb8c0>] (gpio_keys_suspend) from [<c02ae8cc>] (dpm_run_callback+0x54/0x124)
      
      Avoid this false positive by using a separate lockdep class for IRQC
      interrupts.
      Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Cc: Grygorii Strashko <grygorii.strashko@ti.com>
      Cc: Magnus Damm <magnus.damm@gmail.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Link: http://lkml.kernel.org/r/1441798974-25716-2-git-send-email-geert%2Brenesas@glider.beSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      b1370658
    • Pavel Fedin's avatar
      irqchip/GICv2m: Fix GICv2m build warning on 32 bits · 157add60
      Pavel Fedin authored
      After GICv2m was enabled for 32-bit ARM kernel, a warning popped up:
      
      drivers/irqchip/irq-gic-v2m.c: In function gicv2m_compose_msi_msg:
      drivers/irqchip/irq-gic-v2m.c:100:2: warning: right shift count >= width
      of type [enabled by default]
        msg->address_hi = (u32) (addr >> 32);
        ^
      
      This patch fixes it by using proper macros for splitting up the value.
      Signed-off-by: default avatarPavel Fedin <p.fedin@samsung.com>
      Reviewed-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
      Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: Stuart Yoder <stuart.yoder@freescale.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Link: http://lkml.kernel.org/r/1442142873-20213-4-git-send-email-marc.zyngier@arm.comSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      157add60
    • Marc Zyngier's avatar
      irqchip/gic-v3-its: Add missing cache flushes · 5a9a8915
      Marc Zyngier authored
      When the ITS is configured for non-cacheable transactions, make sure
      that the allocated, zeroed memory is flushed to the Point of
      Coherency, allowing the ITS to observe the zeros instead of random
      garbage (or even get its own data overwritten by zeros being evicted
      from the cache...).
      
      Fixes: 241a386c "irqchip: gicv3-its: Use non-cacheable accesses when no shareability"
      Reported-and-tested-by: default avatarStuart Yoder <stuart.yoder@freescale.com>
      Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: Pavel Fedin <p.fedin@samsung.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Link: http://lkml.kernel.org/r/1442142873-20213-3-git-send-email-marc.zyngier@arm.comSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      5a9a8915
    • Marc Zyngier's avatar
      irqchip/GIC: Add workaround for aliased GIC400 · 12e14066
      Marc Zyngier authored
      The GICv2 architecture mandates that the two 4kB GIC regions are
      contiguous, and on two separate physical pages (so that access to
      the second page can be trapped by a hypervisor). This doesn't work
      very well when PAGE_SIZE is 64kB.
      
      A relatively common hack^Wway to work around this is to alias each
      4kB region over its own 64kB page. Of course in this case, the base
      address you want to use is not really the begining of the region,
      but base + 60kB (so that you get a contiguous 8kB region over two
      distinct pages).
      
      Normally, this would be described in DT with a new property, but
      some HW is already out there, and the firmware makes sure that
      it will override whatever you put in the GIC node. Duh. And of course,
      said firmware source code is not available, despite being based
      on u-boot.
      
      The workaround is to detect the case where the CPU interface size
      is set to 128kB, and verify the aliasing by checking that the ID
      register for GIC400 (which is the only GIC wired this way so far)
      is the same at base and base + 0xF000. In this case, we update
      the GIC base address and let it roll.
      
      And if you feel slightly sick by looking at this, rest assured that
      I do too...
      Reported-by: default avatarJulien Grall <julien.grall@citrix.com>
      Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: Stuart Yoder <stuart.yoder@freescale.com>
      Cc: Pavel Fedin <p.fedin@samsung.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Link: http://lkml.kernel.org/r/1442142873-20213-2-git-send-email-marc.zyngier@arm.comSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      12e14066
    • Marc Zyngier's avatar
      platform-msi: Do not cache msi_desc in handler_data · e4084a16
      Marc Zyngier authored
      The current implementation of platform MSI caches the msi_desc
      pointer in irq_data::handler_data. This is a bit silly, as
      we also have irq_data::msi_desc, which is perfectly valid.
      
      Remove the useless assignment and simplify the whole flow.
      Reported-by: default avatarMa Jun <majun258@huawei.com>
      Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
      Reviewed-by: default avatarJiang Liu <jiang.liu@linux.intel.com>
      Link: http://lkml.kernel.org/r/1442147824-20971-1-git-send-email-marc.zyngier@arm.comSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      e4084a16
    • Thomas Gleixner's avatar
      net/mlx4_en: Use access helper irq_data_get_affinity_mask() · dc2ec62f
      Thomas Gleixner authored
      This is a preparatory patch for moving irq_data struct members. Search
      and replace was done with coccinelle
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      Cc: Julia Lawall <Julia.Lawall@lip6.fr>
      Cc: Jiang Liu <jiang.liu@linux.intel.com>
      Cc: Amir Vadai <amirv@mellanox.com>
      dc2ec62f
    • Jiang Liu's avatar
      powerpc, irq: Use access helper irq_data_get_affinity_mask() · da92b4eb
      Jiang Liu authored
      Use access helper irq_data_get_affinity_mask() so we can move the
      affinity mask to irq_common_data.
      Signed-off-by: default avatarJiang Liu <jiang.liu@linux.intel.com>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: linuxppc-dev@lists.ozlabs.org
      Link: http://lkml.kernel.org/r/1433145945-789-25-git-send-email-jiang.liu@linux.intel.comSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      da92b4eb
  3. 14 Sep, 2015 5 commits
  4. 12 Sep, 2015 1 commit