<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/drivers/gpio, branch v4.2.8</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.2.8</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.2.8'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2015-07-18T17:27:12Z</updated>
<entry>
<title>Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip</title>
<updated>2015-07-18T17:27:12Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-07-18T17:27:12Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=59ee762156f5c6c7238ca3abe5762690aa65808b'/>
<id>urn:sha1:59ee762156f5c6c7238ca3abe5762690aa65808b</id>
<content type='text'>
Pull irq fixes from Ingo Molnar:
 "Misc irq fixes:

   - two driver fixes
   - a Xen regression fix
   - a nested irq thread crash fix"

* 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  irqchip/gicv3-its: Fix mapping of LPIs to collections
  genirq: Prevent resend to interrupts marked IRQ_NESTED_THREAD
  genirq: Revert sparse irq locking around __cpu_up() and move it to x86 for now
  gpio/davinci: Fix race in installing chained irq handler
</content>
</entry>
<entry>
<title>gpio: pca953x: fix nested irqs rescheduling</title>
<updated>2015-07-16T12:40:08Z</updated>
<author>
<name>Grygorii Strashko</name>
<email>grygorii.strashko@ti.com</email>
</author>
<published>2015-07-07T14:34:49Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=fdd50409c8b9ce4cdd757ce10bf2e39e9c172de6'/>
<id>urn:sha1:fdd50409c8b9ce4cdd757ce10bf2e39e9c172de6</id>
<content type='text'>
pca953x interrupt controller functionality is implemented using
nested threaded IRQs which require parent_irq to be configured
properly otherwise below warning can be seen if IRQ core
will try re-schedule nested IRQ:

------------[ cut here ]------------
WARNING: CPU: 1 PID: 12 at kernel/irq/manage.c:696 irq_nested_primary_handler+0x30/0x38()
Primary handler called for nested irq 301
Modules linked in: uinput ipv6 smsc95xx usbnet mii imx2_wdt etnaviv(C) matrix_keypad matrix_keymap ar1021_i2c
CPU: 1 PID: 12 Comm: ksoftirqd/1 Tainted: G        WC    4.1.1 #9
Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
Backtrace:
[&lt;c0013298&gt;] (dump_backtrace) from [&lt;c0013488&gt;] (show_stack+0x20/0x24)
[&lt;c0013468&gt;] (show_stack) from [&lt;c05743c4&gt;] (dump_stack+0x70/0xc0)
[&lt;c0574354&gt;] (dump_stack) from [&lt;c002b7b8&gt;] (warn_slowpath_common+0x88/0xc0)
[&lt;c002b730&gt;] (warn_slowpath_common) from [&lt;c002b8ac&gt;] (warn_slowpath_fmt+0x40/0x48)
[&lt;c002b870&gt;] (warn_slowpath_fmt) from [&lt;c0075798&gt;] (irq_nested_primary_handler+0x30/0x38)
[&lt;c0075768&gt;] (irq_nested_primary_handler) from [&lt;c0075200&gt;] (handle_irq_event_percpu+0x70/0x2d0)
[&lt;c0075190&gt;] (handle_irq_event_percpu) from [&lt;c00754ac&gt;] (handle_irq_event+0x4c/0x6c)
[&lt;c0075460&gt;] (handle_irq_event) from [&lt;c0078204&gt;] (handle_simple_irq+0xa4/0xc8)
[&lt;c0078160&gt;] (handle_simple_irq) from [&lt;c0077cd4&gt;] (resend_irqs+0x50/0x7c)
[&lt;c0077c84&gt;] (resend_irqs) from [&lt;c002f99c&gt;] (tasklet_action+0x94/0x140)
[&lt;c002f908&gt;] (tasklet_action) from [&lt;c002eea8&gt;] (__do_softirq+0xa0/0x3c8)
[&lt;c002ee08&gt;] (__do_softirq) from [&lt;c002f208&gt;] (run_ksoftirqd+0x38/0x54)
[&lt;c002f1d0&gt;] (run_ksoftirqd) from [&lt;c004b1e4&gt;] (smpboot_thread_fn+0x1f8/0x2f0)
[&lt;c004afec&gt;] (smpboot_thread_fn) from [&lt;c0047744&gt;] (kthread+0xe8/0x104)
[&lt;c004765c&gt;] (kthread) from [&lt;c000fac8&gt;] (ret_from_fork+0x14/0x2c)
---[ end trace 96052cda48865769 ]---

The issue was reported and described in details by Lothar WaÃŸmann and
Christian Gmeiner in https://lkml.org/lkml/2014/9/9/123.

Fix it by adding missed call of gpiochip_set_chained_irqchip()
so GPIO IRQ chip helpers will set parent_irq for nested IRQs
properly.

Reported-by: Lothar WaÃŸmann &lt;LW@KARO-electronics.de&gt;
Tested-by: Christian Gmeiner &lt;christian.gmeiner@gmail.com&gt;
Signed-off-by: Grygorii Strashko &lt;grygorii.strashko@ti.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>gpio: omap: prevent module from being unloaded while in use</title>
<updated>2015-07-16T12:26:03Z</updated>
<author>
<name>Grygorii Strashko</name>
<email>grygorii.strashko@ti.com</email>
</author>
<published>2015-06-25T15:13:33Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=c23837ce73a0cb84ab046a6c0aace30fdd1e26f0'/>
<id>urn:sha1:c23837ce73a0cb84ab046a6c0aace30fdd1e26f0</id>
<content type='text'>
OMAP GPIO driver allowed to be built as loadable module, but it
doesn't set owner field in GPIO chip structure. As result,
module_get/put() API is not working and it's possible to unload
OMAP driver while in use:

  omap_gpio 48051000.gpio: REMOVING GPIOCHIP WITH GPIOS STILL REQUESTED

Hence, add missing configuration.

Cc: Tony Lindgren &lt;tony@atomide.com&gt;
Fixes: cac089f9026e ('gpio: omap: Allow building as a loadable module')
Signed-off-by: Grygorii Strashko &lt;grygorii.strashko@ti.com&gt;
Acked-by: Alexandre Courbot &lt;acourbot@nvidia.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>gpio: max732x: Add missing dev reference to gpiochip</title>
<updated>2015-07-16T11:42:46Z</updated>
<author>
<name>Marek Vasut</name>
<email>marex@denx.de</email>
</author>
<published>2015-06-30T18:04:18Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=34ab54edbef902f31842b428dce9530f3283847c'/>
<id>urn:sha1:34ab54edbef902f31842b428dce9530f3283847c</id>
<content type='text'>
In case the gpiochip doesn't have the .dev field set, as is the case
in here, it is not possible to reference this device in DT as a GPIO
controller. A good example of this problem is that gpio-leds can not
be used when connected to this chip, the gpio-leds driver bails out
with -EPROBE_DEFER.

Fix this problem by setting the .dev field of the gpio_chip to the
parent i2c device.

Signed-off-by: Marek Vasut &lt;marex@denx.de&gt;
Cc: Alexandre Courbot &lt;gnurou@gmail.com&gt;
Cc: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Cc: Mans Rullgard &lt;mans@mansr.com&gt;
Cc: Olaf Mandel &lt;o.mandel@menlosystems.com&gt;
Cc: Semen Protsenko &lt;semen.protsenko@globallogic.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>gpio/xilinx: Use correct address when setting initial values.</title>
<updated>2015-07-16T11:28:33Z</updated>
<author>
<name>Raphaël Teysseyre</name>
<email>rteysseyre@gmail.com</email>
</author>
<published>2015-06-24T07:19:45Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=5b2c9121ef7cf9745f0c1df10544fd0ba6a6a38c'/>
<id>urn:sha1:5b2c9121ef7cf9745f0c1df10544fd0ba6a6a38c</id>
<content type='text'>
xgpio_save_regs() is used in this driver to setup the initial
values of the registers in the hardware.

The relevant registers at that time are:
0x0 -&gt; channel 0 data (32 bits, one for each GPIO on this channel).
0x4 -&gt; channel 0 tri, controls in/out status for each GPIO of this channel.
0x8 -&gt; channel 1 data
0xC -&gt; channel 1 tri

gpio-xilinx.c defines these:
XGPIO_DATA_OFFSET   (0x0)
XGPIO_TRI_OFFSET    (0x4)
XGPIO_CHANNEL_OFFSET	0x8

Before this patch, the "data" register value of channel 1 was written
at 0x4 intead of 0x8 (overwriting the channel 0 "tri" register),
and the "tri" register value for channel 1 was written at 0x8 instead of 0xC.

Signed-off-by: Raphaël Teysseyre &lt;rteysseyre@gmail.com&gt;
Reviewed-by: Michal Simek &lt;michal.simek@xilinx.com&gt;
Reviewed-by: Alexandre Courbot &lt;acourbot@nvidia.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>gpio: zynq: Fix problem with unbalanced pm_runtime_enable</title>
<updated>2015-07-16T11:00:43Z</updated>
<author>
<name>Michal Simek</name>
<email>michal.simek@xilinx.com</email>
</author>
<published>2015-06-25T08:29:19Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=6b956af0807a88c79d53e0cb2a3170a2b03e3230'/>
<id>urn:sha1:6b956af0807a88c79d53e0cb2a3170a2b03e3230</id>
<content type='text'>
Add missing pm_runtime_disabled to remove().

Error log:
root@zynqmp:~# modprobe gpio_zynq
root@zynqmp:~# lsmod
    Not tainted
gpio_zynq 7086 0 - Live 0xffffffbffc00a000
root@zynqmp:~# rmmod gpio_zynq
root@zynqmp:~# lsmod
    Not tainted
root@zynqmp:~# modprobe gpio_zynq
[  246.924438] zynq-gpio ff0a0000.gpio: Unbalanced pm_runtime_enable!
root@zynqmp:~# rmmod gpio_zynq
root@zynqmp:~# lsmod
    Not tainted

Signed-off-by: Michal Simek &lt;michal.simek@xilinx.com&gt;
Reviewed-by: Alexandre Courbot &lt;acourbot@nvidia.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>gpio: omap: add missed spin_unlock_irqrestore in omap_gpio_irq_type</title>
<updated>2015-07-16T08:35:56Z</updated>
<author>
<name>Grygorii Strashko</name>
<email>grygorii.strashko@linaro.org</email>
</author>
<published>2015-06-24T14:54:17Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=977bd8a94c40851a843e9186b9eb823bdfa5ace2'/>
<id>urn:sha1:977bd8a94c40851a843e9186b9eb823bdfa5ace2</id>
<content type='text'>
Add missed spin_unlock_irqrestore in omap_gpio_irq_type when
omap_set_gpio_triggering() is failed.

It fixes static checker warning:

	drivers/gpio/gpio-omap.c:523 omap_gpio_irq_type()
	warn: inconsistent returns 'spin_lock:&amp;bank-&gt;lock'.

This fixes commit:
1562e4618ded ('gpio: omap: fix error handling in omap_gpio_irq_type')

Reported-by: Javier Martinez Canillas &lt;javier@dowhile0.org&gt;
Signed-off-by: Grygorii Strashko &lt;grygorii.strashko@linaro.org&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>gpio: brcmstb: fix null ptr dereference in driver remove</title>
<updated>2015-07-15T22:12:24Z</updated>
<author>
<name>Gregory Fong</name>
<email>gregory.0xf0@gmail.com</email>
</author>
<published>2015-06-18T01:00:40Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=2252607d327d5219a6331b50e6ec266d56402be0'/>
<id>urn:sha1:2252607d327d5219a6331b50e6ec266d56402be0</id>
<content type='text'>
If a failure occurs during probe, brcmstb_gpio_remove() is called. In
remove, we call platform_get_drvdata(), but at the time of failure in
the probe the driver data hadn't yet been set which leads to a NULL
ptr dereference in the remove's list_for_each.  Call
platform_set_drvdata() and set up list head right after allocating the
priv struct to both avoid the null pointer dereference that could
occur today.  To guard against potential future changes, check for
null pointer in remove.

Reported-by: Tim Ross &lt;tross@broadcom.com&gt;
Signed-off-by: Gregory Fong &lt;gregory.0xf0@gmail.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>gpio/davinci: Fix race in installing chained irq handler</title>
<updated>2015-07-13T21:24:48Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2015-07-13T21:22:44Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=20483d04ae6f373858f3ca28cd7e26b66106d937'/>
<id>urn:sha1:20483d04ae6f373858f3ca28cd7e26b66106d937</id>
<content type='text'>
Fix a race where a pending interrupt could be received and the handler
called before the handler's data has been setup, by converting to
irq_set_chained_handler_and_data().
    
Search and conversion was done with coccinelle.
    
Reported-by: Russell King &lt;rmk+kernel@arm.linux.org.uk&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Julia Lawall &lt;Julia.Lawall@lip6.fr&gt;
Cc: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Cc: Alexandre Courbot &lt;gnurou@gmail.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip</title>
<updated>2015-07-01T22:19:35Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-07-01T22:19:35Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=d5fb82137b6cd39e67c4321f4f5ce9b03d4d04e6'/>
<id>urn:sha1:d5fb82137b6cd39e67c4321f4f5ce9b03d4d04e6</id>
<content type='text'>
Pull irq fixes from Thomas Gleixner:
 "This contains:

   - a series of fixes for interrupt drivers to prevent a potential race
     when installing a chained interrupt handler

   - a fix for cpumask pointer misuse

   - a fix for using the wrong interrupt number from struct irq_data

   - removal of unused code and outdated comments

   - a few new helper functions which allow us to cleanup the interrupt
     handling code further in 4.3

   I decided against doing the cleanup at the end of this merge window
   and rather do the preparatory steps for 4.3, so we can run the final
   ABI change at the end of the 4.3 merge window with less risk"

* 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (26 commits)
  ARM/LPC32xx: Use irq not hwirq for __irq_set_handler_locked()
  genirq: Implement irq_set_handler_locked()/irq_set_chip_handler_name_locked()
  genirq: Introduce helper irq_desc_get_irq()
  genirq: Remove irq_node()
  genirq: Clean up outdated comments related to include/linux/irqdesc.h
  mn10300: Fix incorrect use of irq_data-&gt;affinity
  MIPS/ralink: Fix race in installing chained IRQ handler
  MIPS/pci: Fix race in installing chained IRQ handler
  MIPS/ath25: Fix race in installing chained IRQ handler
  MIPS/ath25: Fix race in installing chained IRQ handler
  m68k/psc: Fix race in installing chained IRQ handler
  avr32/at32ap: Fix race in installing chained IRQ handler
  sh/intc: Fix race in installing chained IRQ handler
  sh/intc: Fix potential race in installing chained IRQ handler
  pinctrl/sun4i: Fix race in installing chained IRQ handler
  pinctrl/samsung: Fix race in installing chained IRQ handler
  pinctrl/samsung: Fix race in installing chained IRQ handler
  pinctrl/exynos: Fix race in installing chained IRQ handler
  pinctrl/st: Fix race in installing chained IRQ handler
  pinctrl/adi2: Fix race in installing chained IRQ handler
  ...
</content>
</entry>
</feed>
