linux/arch/avr32/mach-at32ap
Linus Walleij 58383c7842 gpio: change member .dev to .parent
The name .dev in a struct is normally reserved for a struct device
that is let us say a superclass to the thing described by the struct.
struct gpio_chip stands out by confusingly using a struct device *dev
to point to the parent device (such as a platform_device) that
represents the hardware. As we want to give gpio_chip:s real devices,
this is not working. We need to rename this member to parent.

This was done by two coccinelle scripts, I guess it is possible to
combine them into one, but I don't know such stuff. They look like
this:

@@
struct gpio_chip *var;
@@
-var->dev
+var->parent

and:

@@
struct gpio_chip var;
@@
-var.dev
+var.parent

and:

@@
struct bgpio_chip *var;
@@
-var->gc.dev
+var->gc.parent

Plus a few instances of bgpio that I couldn't figure out how
to teach Coccinelle to rewrite.

This patch hits all over the place, but I *strongly* prefer this
solution to any piecemal approaches that just exercise patch
mechanics all over the place. It mainly hits drivers/gpio and
drivers/pinctrl which is my own backyard anyway.

Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
Cc: Rafał Miłecki <zajec5@gmail.com>
Cc: Richard Purdie <rpurdie@rpsys.net>
Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Cc: Alek Du <alek.du@intel.com>
Cc: Jaroslav Kysela <perex@perex.cz>
Cc: Takashi Iwai <tiwai@suse.com>
Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Acked-by: Jiri Kosina <jkosina@suse.cz>
Acked-by: Hans-Christian Egtvedt <egtvedt@samfundet.no>
Acked-by: Jacek Anaszewski <j.anaszewski@samsung.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2015-11-19 09:24:35 +01:00
..
include/mach avr32: remove fake at91 cpu identification 2015-02-09 15:27:45 +01:00
at32ap700x.c avr32: use dw_dmac autoconfiguration 2015-09-30 13:43:09 +05:30
clock.c avr32: handle NULL as a valid clock object 2015-07-27 09:14:07 +02:00
clock.h avr32: Hammerhead board support 2009-01-05 15:52:04 +01:00
extint.c genirq: Remove irq argument from irq flow handlers 2015-09-16 15:47:51 +02:00
hmatrix.c avr32: Clean up HMATRIX code 2008-08-08 12:44:01 +02:00
hsmc.c treewide: Convert uses of struct resource to resource_size(ptr) 2011-06-10 14:55:36 +02:00
hsmc.h [PATCH] AVR32: Use __raw MMIO access for internal peripherals 2006-10-25 20:26:33 -07:00
intc.c avr32: add export.h to arch/avr32 for EXPORT_SYMBOL/THIS_MODULE 2011-10-31 19:30:59 -04:00
intc.h [PATCH] AVR32: Use __raw MMIO access for internal peripherals 2006-10-25 20:26:33 -07:00
Kconfig [AVR32] Add support for AT32AP7001 and AT32AP7002 2008-01-25 08:31:41 +01:00
Makefile cpufreq: AVR32: move cpufreq driver to drivers/cpufreq 2013-04-10 13:19:25 +02:00
pdc.c avr32: Use platform_driver_probe for pdc platform driver 2008-09-22 09:51:03 +02:00
pio.c gpio: change member .dev to .parent 2015-11-19 09:24:35 +01:00
pio.h avr32: Fix typo of IFSR in a comment in the PIO header file 2008-07-04 09:48:05 +02:00
pm-at32ap700x.S avr32: Use generic idle loop 2013-04-08 17:39:24 +02:00
pm.c avr32: pm: Fix section mismatch 2013-12-10 08:46:38 +01:00
pm.h avr32: Add MMIO address definitions for certain controllers 2008-08-08 12:42:14 +02:00
sdramc.h avr32: Power Management support ("standby" and "mem" modes) 2008-07-02 11:05:01 +02:00