<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/drivers/pinctrl, branch linux-4.2.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.</subtitle>
<id>https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-4.2.y</id>
<link rel='self' href='https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-4.2.y'/>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/'/>
<updated>2015-11-09T22:37:40Z</updated>
<entry>
<title>pinctrl: baytrail: Use raw_spinlock for locking</title>
<updated>2015-11-09T22:37:40Z</updated>
<author>
<name>Mika Westerberg</name>
<email>mika.westerberg@linux.intel.com</email>
</author>
<published>2015-08-17T13:03:17Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=4f2b300b74c6a9c99c7e8cf9f2d46bc3cab67e0e'/>
<id>urn:sha1:4f2b300b74c6a9c99c7e8cf9f2d46bc3cab67e0e</id>
<content type='text'>
commit 78e1c896932df5b8bcdff7bf5417d8e72a4d0d6b upstream.

The Intel Baytrail pinctrl driver implements irqchip callbacks which are
called with desc-&gt;lock raw_spinlock held. In mainline this is fine because
spinlock resolves to raw_spinlock. However, running the same code in -rt we
get:

 BUG: sleeping function called from invalid context at kernel/locking/rtmutex.c:917
 in_atomic(): 1, irqs_disabled(): 1, pid: 0, name: swapper/0
 Preemption disabled at:[&lt;ffffffff81092e9f&gt;] cpu_startup_entry+0x17f/0x480

 CPU: 0 PID: 0 Comm: swapper/0 Not tainted 4.1.5-rt5 #13
  ...
 Call Trace:
  &lt;IRQ&gt;  [&lt;ffffffff816283c6&gt;] dump_stack+0x4a/0x61
  [&lt;ffffffff81077e17&gt;] ___might_sleep+0xe7/0x170
  [&lt;ffffffff8162d6cf&gt;] rt_spin_lock+0x1f/0x50
  [&lt;ffffffff812e3b88&gt;] byt_gpio_clear_triggering+0x38/0x60
  [&lt;ffffffff812e3bc1&gt;] byt_irq_mask+0x11/0x20
  [&lt;ffffffff810a7013&gt;] handle_level_irq+0x83/0x150
  [&lt;ffffffff810a3457&gt;] generic_handle_irq+0x27/0x40
  [&lt;ffffffff812e3a5f&gt;] byt_gpio_irq_handler+0x7f/0xc0
  [&lt;ffffffff810050aa&gt;] handle_irq+0xaa/0x190
  ...

This is because in -rt spinlocks are preemptible so taking the driver
private spinlock in irqchip callbacks causes might_sleep() to trigger.

In order to keep -rt happy but at the same time make sure that register
accesses get serialized, convert the driver to use raw_spinlock instead.

Also shorten the critical section a bit in few places.

Suggested-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Signed-off-by: Mika Westerberg &lt;mika.westerberg@linux.intel.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Cc: Lucas De Marchi &lt;lucas.de.marchi@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>pinctrl: baytrail: Serialize all register access</title>
<updated>2015-11-09T22:37:40Z</updated>
<author>
<name>Mika Westerberg</name>
<email>mika.westerberg@linux.intel.com</email>
</author>
<published>2015-08-04T12:03:14Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=fd35a6831470f2a238b51f8c940a17c9f9b25fc4'/>
<id>urn:sha1:fd35a6831470f2a238b51f8c940a17c9f9b25fc4</id>
<content type='text'>
commit 39ce8150a079e3ae6ed9abf26d7918a558ef7c19 upstream.

There is a hardware issue in Intel Baytrail where concurrent GPIO register
access might result reads of 0xffffffff and writes might get dropped
completely.

Prevent this from happening by taking the serializing lock in all places
where it is possible that more than one thread might be accessing the
hardware concurrently.

Signed-off-by: Mika Westerberg &lt;mika.westerberg@linux.intel.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Cc: Lucas De Marchi &lt;lucas.de.marchi@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>pinctrl: imx25: ensure that a pin with id i is at position i in the info array</title>
<updated>2015-10-27T00:53:43Z</updated>
<author>
<name>Uwe Kleine-König</name>
<email>u.kleine-koenig@pengutronix.de</email>
</author>
<published>2015-09-23T14:35:09Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=ff78a95c11ec3dc9c0bfec8aa37d2c9953b77c25'/>
<id>urn:sha1:ff78a95c11ec3dc9c0bfec8aa37d2c9953b77c25</id>
<content type='text'>
commit 9911a2d5e9d14e39692b751929a92cb5a1d9d0e0 upstream.

The code in pinctrl-imx.c only works correctly if in the
imx_pinctrl_soc_info passed to imx_pinctrl_probe we have:

	info-&gt;pins[i].number = i
	conf_reg(info-&gt;pins[i]) = 4 * i

(which conf_reg(pin) being the offset of the pin's configuration
register).

When the imx25 specific part was introduced in b4a87c9b966f ("pinctrl:
pinctrl-imx: add imx25 pinctrl driver") we had:

	info-&gt;pins[i].number = i + 1
	conf_reg(info-&gt;pins[i]) = 4 * i

. Commit 34027ca2bbc6 ("pinctrl: imx25: fix numbering for pins") tried
to fix that but made the situation:

	info-&gt;pins[i-1].number = i
	conf_reg(info-&gt;pins[i-1]) = 4 * i

which is hardly better but fixed the error seen back then.

So insert another reserved entry in the array to finally yield:

	info-&gt;pins[i].number = i
	conf_reg(info-&gt;pins[i]) = 4 * i

Fixes: 34027ca2bbc6 ("pinctrl: imx25: fix numbering for pins")
Signed-off-by: Uwe Kleine-König &lt;u.kleine-koenig@pengutronix.de&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>pinctrl: at91: fix null pointer dereference</title>
<updated>2015-09-29T17:33:23Z</updated>
<author>
<name>David Dueck</name>
<email>davidcdueck@googlemail.com</email>
</author>
<published>2015-07-28T07:48:16Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=d0ee7702ddd162d6433d0f9c93a7476935b08930'/>
<id>urn:sha1:d0ee7702ddd162d6433d0f9c93a7476935b08930</id>
<content type='text'>
commit 1ab36387ea4face01aac3560b396b1e2ce07c4ff upstream.

Not all gpio banks are necessarily enabled, in the current code this can
lead to null pointer dereferences.

[   51.130000] Unable to handle kernel NULL pointer dereference at virtual address 00000058
[   51.130000] pgd = dee04000
[   51.130000] [00000058] *pgd=3f66d831, *pte=00000000, *ppte=00000000
[   51.140000] Internal error: Oops: 17 [#1] ARM
[   51.140000] Modules linked in:
[   51.140000] CPU: 0 PID: 1664 Comm: cat Not tainted 4.1.1+ #6
[   51.140000] Hardware name: Atmel SAMA5
[   51.140000] task: df6dd880 ti: dec60000 task.ti: dec60000
[   51.140000] PC is at at91_pinconf_get+0xb4/0x200
[   51.140000] LR is at at91_pinconf_get+0xb4/0x200
[   51.140000] pc : [&lt;c01e71a0&gt;]    lr : [&lt;c01e71a0&gt;]    psr: 600f0013
sp : dec61e48  ip : 600f0013  fp : df522538
[   51.140000] r10: df52250c  r9 : 00000058  r8 : 00000068
[   51.140000] r7 : 00000000  r6 : df53c910  r5 : 00000000  r4 : dec61e7c
[   51.140000] r3 : 00000000  r2 : c06746d4  r1 : 00000000  r0 : 00000003
[   51.140000] Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment user
[   51.140000] Control: 10c53c7d  Table: 3ee04059  DAC: 00000015
[   51.140000] Process cat (pid: 1664, stack limit = 0xdec60208)
[   51.140000] Stack: (0xdec61e48 to 0xdec62000)
[   51.140000] 1e40:                   00000358 00000000 df522500 ded15f80 c05a9d08 ded15f80
[   51.140000] 1e60: 0000048c 00000061 df522500 ded15f80 c05a9d08 c01e7304 ded15f80 00000000
[   51.140000] 1e80: c01e6008 00000060 0000048c c01e6034 c01e5f6c ded15f80 dec61ec0 00000000
[   51.140000] 1ea0: 00020000 ded6f280 dec61f80 00000001 00000001 c00ae0b8 b6e80000 ded15fb0
[   51.140000] 1ec0: 00000000 00000000 df4bc974 00000055 00000800 ded6f280 b6e80000 ded6f280
[   51.140000] 1ee0: ded6f280 00020000 b6e80000 00000000 00020000 c0090dec c0671e1c dec61fb0
[   51.140000] 1f00: b6f8b510 00000001 00004201 c000924c 00000000 00000003 00000003 00000000
[   51.140000] 1f20: df4bc940 00022000 00000022 c066e188 b6e7f000 c00836f4 000b6e7f ded6f280
[   51.140000] 1f40: ded6f280 b6e80000 dec61f80 ded6f280 00020000 c0091508 00000000 00000003
[   51.140000] 1f60: 00022000 00000000 00000000 ded6f280 ded6f280 00020000 b6e80000 c0091d9c
[   51.140000] 1f80: 00000000 00000000 ffffffff 00020000 00020000 b6e80000 00000003 c000f124
[   51.140000] 1fa0: dec60000 c000efa0 00020000 00020000 00000003 b6e80000 00020000 000271c4
[   51.140000] 1fc0: 00020000 00020000 b6e80000 00000003 7fffe000 00000000 00000000 00020000
[   51.140000] 1fe0: 00000000 bef50b64 00013835 b6f29c76 400f0030 00000003 00000000 00000000
[   51.140000] [&lt;c01e71a0&gt;] (at91_pinconf_get) from [&lt;c01e7304&gt;] (at91_pinconf_dbg_show+0x18/0x2c0)
[   51.140000] [&lt;c01e7304&gt;] (at91_pinconf_dbg_show) from [&lt;c01e6034&gt;] (pinconf_pins_show+0xc8/0xf8)
[   51.140000] [&lt;c01e6034&gt;] (pinconf_pins_show) from [&lt;c00ae0b8&gt;] (seq_read+0x1a0/0x464)
[   51.140000] [&lt;c00ae0b8&gt;] (seq_read) from [&lt;c0090dec&gt;] (__vfs_read+0x20/0xd0)
[   51.140000] [&lt;c0090dec&gt;] (__vfs_read) from [&lt;c0091508&gt;] (vfs_read+0x7c/0x108)
[   51.140000] [&lt;c0091508&gt;] (vfs_read) from [&lt;c0091d9c&gt;] (SyS_read+0x40/0x94)
[   51.140000] [&lt;c0091d9c&gt;] (SyS_read) from [&lt;c000efa0&gt;] (ret_fast_syscall+0x0/0x3c)
[   51.140000] Code: eb010ec2 e30a0d08 e34c005a eb0ae5a7 (e5993000)
[   51.150000] ---[ end trace fb3c370da3ea4794 ]---

Fixes: a0b957f306fa ("pinctrl: at91: allow to have disabled gpio bank")
Signed-off-by: David Dueck &lt;davidcdueck@googlemail.com&gt;
Acked-by: Ludovic Desroches &lt;ludovic.desroches@atmel.com&gt;
Acked-by: Alexandre Belloni &lt;alexandre.belloni@free-electrons.com&gt;
Acked-by: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Cc: Boris Brezillon &lt;boris.brezillon@free-electrons.com&gt;
Cc: Jean-Christophe PLAGNIOL-VILLARD &lt;plagnioj@jcrosoft.com&gt;
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>pinctrl: mediatek: Fix multiple registration issue.</title>
<updated>2015-09-29T17:33:22Z</updated>
<author>
<name>Hongzhou Yang</name>
<email>hongzhou.yang@mediatek.com</email>
</author>
<published>2015-08-26T00:32:45Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=3771834bb9422446dffe0169b78a843b0da5fd01'/>
<id>urn:sha1:3771834bb9422446dffe0169b78a843b0da5fd01</id>
<content type='text'>
commit d48c2c02645392483f2b88b050d21ce1db6997b3 upstream.

Since our common driver need support main chip and PMU
at the same time, that means it will register two
pinctrl device, and the pinctrl_desc structure should
be used two times.

But pinctrl_desc use global static definition, then
the latest registered pinctrl device will overwrite
the old one's, all members in pinctrl_desc will set to
the new one's, such as name, pins and pins numbers, etc.
This is a bug.

Move pinctrl_desc into mtk_pinctrl, assign new value for
each pinctrl device to fix it.

Signed-off-by: Hongzhou Yang &lt;hongzhou.yang@mediatek.com&gt;
Reviewed-by: Axel Lin &lt;axel.lin@ingics.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>Merge tag 'pinctrl-v4.2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl</title>
<updated>2015-07-21T22:27:27Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-07-21T22:27:27Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=71ebd1af094db1c72d69505a27dfecea99c2cb0b'/>
<id>urn:sha1:71ebd1af094db1c72d69505a27dfecea99c2cb0b</id>
<content type='text'>
Pull pin control fixes from Linus Walleij:
 "Here are some overly ripe pin control fixes for the v4.2 series.

  They got delayed because of various crap commits and having to clean
  and rinse the patch stack a few times.  Now they are however looking
  good.

   - some dead defines dropped from the Samsung driver, was targeted for
     -rc2 but got delayed
   - drop the strict mode from abx500, this was too strict
   - fix the R-Car sparse IRQs code to work as intended
   - fix the IRQ code for the pinctrl-single GPIO backend to not enforce
     threaded IRQs
   - clear the latched events/IRQs for the Broadcom BCM2835 driver
   - fix up debugfs for the Freescale imx1 driver
   - fix a typo bug in the Schmitt Trigger setup in the LPC18xx driver"

* tag 'pinctrl-v4.2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl:
  pinctrl: lpc18xx: fix schmitt trigger setup
  Subject: pinctrl: imx1-core: Fix debug output in .pin_config_set callback
  pinctrl: bcm2835: Clear the event latch register when disabling interrupts
  pinctrl: single: ensure pcs irq will not be forced threaded
  sh-pfc: fix sparse GPIOs for R-Car SoCs
  pinctrl: abx500: remove strict mode
  pinctrl: samsung: Remove old unused defines
</content>
</entry>
<entry>
<title>pinctrl: lpc18xx: fix schmitt trigger setup</title>
<updated>2015-07-20T09:01:53Z</updated>
<author>
<name>Joachim Eastwood</name>
<email>manabian@gmail.com</email>
</author>
<published>2015-07-14T22:25:26Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=681ccdcc756f17f847beba5ac4cd3d03e0949489'/>
<id>urn:sha1:681ccdcc756f17f847beba5ac4cd3d03e0949489</id>
<content type='text'>
The param_val variable is what determines if schmitt
trigger is enabled on a pin or not. A typo here mean
that schmitt trigger was always enabled for standard
and i2c pins.

Signed-off-by: Joachim Eastwood &lt;manabian@gmail.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>Subject: pinctrl: imx1-core: Fix debug output in .pin_config_set callback</title>
<updated>2015-07-20T09:01:53Z</updated>
<author>
<name>Uwe Kleine-König</name>
<email>u.kleine-koenig@pengutronix.de</email>
</author>
<published>2015-07-17T07:38:43Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=9571b25df1dbf4db17191b54f59734e8b77fd591'/>
<id>urn:sha1:9571b25df1dbf4db17191b54f59734e8b77fd591</id>
<content type='text'>
imx1_pinconf_set assumes that the array of pins in struct
imx1_pinctrl_soc_info can be indexed by pin id to get the
pinctrl_pin_desc for a pin. This used to be correct up to commit
607af165c047 which removed some entries from the array and so made it
wrong to access the array by pin id.

The result of this bug is a wrong pin name in the output for small pin
ids and an oops for the bigger ones.

This patch is the result of a discussion that includes patches by Markus
Pargmann and Chris Ruehl.

Fixes: 607af165c047 ("pinctrl: i.MX27: Remove nonexistent pad definitions")
Cc: stable@vger.kernel.org
Reported-by: Chris Ruehl &lt;chris.ruehl@gtsys.com.hk&gt;
Signed-off-by: Uwe Kleine-König &lt;u.kleine-koenig@pengutronix.de&gt;
Reviewed-by: Markus Pargmann &lt;mpa@pengutronix.de&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: bcm2835: Clear the event latch register when disabling interrupts</title>
<updated>2015-07-20T09:01:52Z</updated>
<author>
<name>Jonathan Bell</name>
<email>jonathan@raspberrypi.org</email>
</author>
<published>2015-06-30T11:35:39Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=714b1dd8f72e39ef4bc0f38f7f341bb1d57d98bf'/>
<id>urn:sha1:714b1dd8f72e39ef4bc0f38f7f341bb1d57d98bf</id>
<content type='text'>
It's possible to hit a race condition if interrupts are generated on a GPIO
pin when the IRQ line in question is being disabled.

If the interrupt is freed, bcm2835_gpio_irq_disable() is called which
disables the event generation sources (edge, level). If an event occurred
between the last disabling of hard IRQs and the write to the event
source registers, a bit would be set in the GPIO event detect register
(GPEDSn) which goes unacknowledged by bcm2835_gpio_irq_handler()
so Linux complains loudly.

There is no per-GPIO mask register, so when disabling GPIO interrupts
write 1 to the relevant bit in GPEDSn to clear out any stale events.

Signed-off-by: Jonathan Bell &lt;jonathan@raspberrypi.org&gt;
Acked-by: Stephen Warren &lt;swarren@wwwdotorg.org&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: single: ensure pcs irq will not be forced threaded</title>
<updated>2015-07-20T09:01:52Z</updated>
<author>
<name>Grygorii Strashko</name>
<email>grygorii.strashko@ti.com</email>
</author>
<published>2015-07-06T15:13:37Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=c10372e615b8f790d30cbfcf59e43908ca42bf1a'/>
<id>urn:sha1:c10372e615b8f790d30cbfcf59e43908ca42bf1a</id>
<content type='text'>
The PSC IRQ is requested using request_irq() API and as result it can
be forced to be threaded IRQ in RT-Kernel if PCS_QUIRK_HAS_SHARED_IRQ
is enabled for pinctrl domain.

As result, following 'possible irq lock inversion dependency' report
can be seen:
=========================================================
[ INFO: possible irq lock inversion dependency detected ]
3.14.43-rt42-00360-g96ff499-dirty #24 Not tainted
---------------------------------------------------------
irq/369-pinctrl/927 just changed the state of lock:
 (&amp;pcs-&gt;lock){+.....}, at: [&lt;c0375b54&gt;] pcs_irq_handle+0x48/0x9c
but this lock was taken by another, HARDIRQ-safe lock in the past:
 (&amp;irq_desc_lock_class){-.....}

and interrupts could create inverse lock ordering between them.

other info that might help us debug this:
 Possible interrupt unsafe locking scenario:

       CPU0                    CPU1
       ----                    ----
  lock(&amp;pcs-&gt;lock);
                               local_irq_disable();
                               lock(&amp;irq_desc_lock_class);
                               lock(&amp;pcs-&gt;lock);
  &lt;Interrupt&gt;
    lock(&amp;irq_desc_lock_class);

 *** DEADLOCK ***

no locks held by irq/369-pinctrl/927.

the shortest dependencies between 2nd lock and 1st lock:
  -&gt; (&amp;irq_desc_lock_class){-.....} ops: 58724 {
     IN-HARDIRQ-W at:
                       [&lt;c0090040&gt;] lock_acquire+0x9c/0x158
                       [&lt;c07065c8&gt;] _raw_spin_lock+0x48/0x58
                       [&lt;c009edac&gt;] handle_fasteoi_irq+0x24/0x15c
                       [&lt;c009abb0&gt;] generic_handle_irq+0x3c/0x4c
                       [&lt;c000f83c&gt;] handle_IRQ+0x50/0xa0
                       [&lt;c0008674&gt;] gic_handle_irq+0x3c/0x6c
                       [&lt;c0707a04&gt;] __irq_svc+0x44/0x8c
                       [&lt;c000fc44&gt;] arch_cpu_idle+0x40/0x4c
                       [&lt;c009aadc&gt;] cpu_startup_entry+0x270/0x2e0
                       [&lt;c06fcbf8&gt;] rest_init+0xd4/0xe4
                       [&lt;c0a44bfc&gt;] start_kernel+0x3d0/0x3dc
                       [&lt;80008084&gt;] 0x80008084
     INITIAL USE at:
                      [&lt;c0090040&gt;] lock_acquire+0x9c/0x158
                      [&lt;c070674c&gt;] _raw_spin_lock_irqsave+0x54/0x68
                      [&lt;c009aff8&gt;] __irq_get_desc_lock+0x64/0xa4
                      [&lt;c009e38c&gt;] irq_set_chip+0x30/0x78
                      [&lt;c009ec30&gt;] irq_set_chip_and_handler_name+0x24/0x3c
                      [&lt;c036ca10&gt;] gic_irq_domain_map+0x48/0xb4
                      [&lt;c00a0a80&gt;] irq_domain_associate+0x84/0x1d4
                      [&lt;c00a1154&gt;] irq_create_mapping+0x80/0x11c
                      [&lt;c00a1270&gt;] irq_create_of_mapping+0x80/0x120
                      [&lt;c05cdaa8&gt;] irq_of_parse_and_map+0x34/0x3c
                      [&lt;c0a4ea24&gt;] omap_dm_timer_init_one+0x90/0x30c
                      [&lt;c0a4eef0&gt;] omap5_realtime_timer_init+0x8c/0x48c
                      [&lt;c0a486b0&gt;] time_init+0x28/0x38
                      [&lt;c0a44a6c&gt;] start_kernel+0x240/0x3dc
                      [&lt;80008084&gt;] 0x80008084
   }
   ... key      at: [&lt;c1049ce0&gt;] irq_desc_lock_class+0x0/0x8
   ... acquired at:
   [&lt;c07065c8&gt;] _raw_spin_lock+0x48/0x58
   [&lt;c0375a90&gt;] pcs_irq_unmask+0x58/0xa0
   [&lt;c009ea48&gt;] irq_enable+0x38/0x48
   [&lt;c009ead0&gt;] irq_startup+0x78/0x7c
   [&lt;c009d440&gt;] __setup_irq+0x4a8/0x4f4
   [&lt;c009d5dc&gt;] request_threaded_irq+0xb8/0x138
   [&lt;c0415a5c&gt;] omap_8250_startup+0x4c/0x148
   [&lt;c041276c&gt;] serial8250_startup+0x24/0x30
   [&lt;c040d0ec&gt;] uart_startup.part.9+0x5c/0x1b4
   [&lt;c040dbcc&gt;] uart_open+0xf4/0x16c
   [&lt;c03f0540&gt;] tty_open+0x170/0x61c
   [&lt;c0157028&gt;] chrdev_open+0xbc/0x1b4
   [&lt;c0150494&gt;] do_dentry_open+0x1e8/0x2bc
   [&lt;c0150a84&gt;] finish_open+0x44/0x5c
   [&lt;c0160d50&gt;] do_last.isra.47+0x710/0xca0
   [&lt;c01613a4&gt;] path_openat+0xc4/0x640
   [&lt;c0162904&gt;] do_filp_open+0x3c/0x98
   [&lt;c0151bdc&gt;] do_sys_open+0x114/0x1d8
   [&lt;c0151cc8&gt;] SyS_open+0x28/0x2c
   [&lt;c0a44d70&gt;] kernel_init_freeable+0x168/0x1e4
   [&lt;c06fcc24&gt;] kernel_init+0x1c/0xf8
   [&lt;c000eee8&gt;] ret_from_fork+0x14/0x20

-&gt; (&amp;pcs-&gt;lock){+.....} ops: 65 {
   HARDIRQ-ON-W at:
                    [&lt;c0090040&gt;] lock_acquire+0x9c/0x158
                    [&lt;c07065c8&gt;] _raw_spin_lock+0x48/0x58
                    [&lt;c0375b54&gt;] pcs_irq_handle+0x48/0x9c
                    [&lt;c0375c5c&gt;] pcs_irq_handler+0x1c/0x28
                    [&lt;c009c458&gt;] irq_forced_thread_fn+0x30/0x74
                    [&lt;c009c784&gt;] irq_thread+0x158/0x1c4
                    [&lt;c0063fc4&gt;] kthread+0xd4/0xe8
                    [&lt;c000eee8&gt;] ret_from_fork+0x14/0x20
   INITIAL USE at:
                   [&lt;c0090040&gt;] lock_acquire+0x9c/0x158
                   [&lt;c070674c&gt;] _raw_spin_lock_irqsave+0x54/0x68
                   [&lt;c0375344&gt;] pcs_enable+0x7c/0xe8
                   [&lt;c0372a44&gt;] pinmux_enable_setting+0x178/0x220
                   [&lt;c036fecc&gt;] pinctrl_select_state+0x110/0x194
                   [&lt;c04732dc&gt;] pinctrl_bind_pins+0x7c/0x108
                   [&lt;c045853c&gt;] driver_probe_device+0x70/0x254
                   [&lt;c0458810&gt;] __driver_attach+0x9c/0xa0
                   [&lt;c045674c&gt;] bus_for_each_dev+0x78/0xac
                   [&lt;c0458030&gt;] driver_attach+0x2c/0x30
                   [&lt;c0457c78&gt;] bus_add_driver+0x15c/0x204
                   [&lt;c0458ee0&gt;] driver_register+0x88/0x108
                   [&lt;c045a168&gt;] __platform_driver_register+0x64/0x6c
                   [&lt;c0a8170c&gt;] omap_hsmmc_driver_init+0x1c/0x20
                   [&lt;c0008a94&gt;] do_one_initcall+0x110/0x170
                   [&lt;c0a44d48&gt;] kernel_init_freeable+0x140/0x1e4
                   [&lt;c06fcc24&gt;] kernel_init+0x1c/0xf8
                   [&lt;c000eee8&gt;] ret_from_fork+0x14/0x20
 }
 ... key      at: [&lt;c1088a8c&gt;] __key.18572+0x0/0x8
 ... acquired at:
   [&lt;c008cdd4&gt;] mark_lock+0x388/0x76c
   [&lt;c008df40&gt;] __lock_acquire+0x6d0/0x1f98
   [&lt;c0090040&gt;] lock_acquire+0x9c/0x158
   [&lt;c07065c8&gt;] _raw_spin_lock+0x48/0x58
   [&lt;c0375b54&gt;] pcs_irq_handle+0x48/0x9c
   [&lt;c0375c5c&gt;] pcs_irq_handler+0x1c/0x28
   [&lt;c009c458&gt;] irq_forced_thread_fn+0x30/0x74
   [&lt;c009c784&gt;] irq_thread+0x158/0x1c4
   [&lt;c0063fc4&gt;] kthread+0xd4/0xe8
   [&lt;c000eee8&gt;] ret_from_fork+0x14/0x20

stack backtrace:
CPU: 1 PID: 927 Comm: irq/369-pinctrl Not tainted 3.14.43-rt42-00360-g96ff499-dirty #24
[&lt;c00177e0&gt;] (unwind_backtrace) from [&lt;c00130b0&gt;] (show_stack+0x20/0x24)
[&lt;c00130b0&gt;] (show_stack) from [&lt;c0702958&gt;] (dump_stack+0x84/0xd0)
[&lt;c0702958&gt;] (dump_stack) from [&lt;c008bcfc&gt;] (print_irq_inversion_bug+0x1d0/0x21c)
[&lt;c008bcfc&gt;] (print_irq_inversion_bug) from [&lt;c008bf18&gt;] (check_usage_backwards+0xb4/0x11c)
[&lt;c008bf18&gt;] (check_usage_backwards) from [&lt;c008cdd4&gt;] (mark_lock+0x388/0x76c)
[&lt;c008cdd4&gt;] (mark_lock) from [&lt;c008df40&gt;] (__lock_acquire+0x6d0/0x1f98)
[&lt;c008df40&gt;] (__lock_acquire) from [&lt;c0090040&gt;] (lock_acquire+0x9c/0x158)
[&lt;c0090040&gt;] (lock_acquire) from [&lt;c07065c8&gt;] (_raw_spin_lock+0x48/0x58)
[&lt;c07065c8&gt;] (_raw_spin_lock) from [&lt;c0375b54&gt;] (pcs_irq_handle+0x48/0x9c)
[&lt;c0375b54&gt;] (pcs_irq_handle) from [&lt;c0375c5c&gt;] (pcs_irq_handler+0x1c/0x28)
[&lt;c0375c5c&gt;] (pcs_irq_handler) from [&lt;c009c458&gt;] (irq_forced_thread_fn+0x30/0x74)
[&lt;c009c458&gt;] (irq_forced_thread_fn) from [&lt;c009c784&gt;] (irq_thread+0x158/0x1c4)
[&lt;c009c784&gt;] (irq_thread) from [&lt;c0063fc4&gt;] (kthread+0xd4/0xe8)
[&lt;c0063fc4&gt;] (kthread) from [&lt;c000eee8&gt;] (ret_from_fork+0x14/0x20)

To fix it use IRQF_NO_THREAD to ensure that pcs irq will not be forced threaded.

Cc: Tony Lindgren &lt;tony@atomide.com&gt;
Cc: Sebastian Andrzej Siewior &lt;bigeasy@linutronix.de&gt;
Signed-off-by: Grygorii Strashko &lt;grygorii.strashko@ti.com&gt;
Acked-by: Tony Lindgren &lt;tony@atomide.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
</feed>
