From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hans-Christian Noren Egtvedt Subject: Re: [PATCH] gpio: change member .dev to .parent Date: Wed, 4 Nov 2015 10:54:48 +0100 Message-ID: <20151104095448.GA20076@samfundet.no> References: <1446629475-31754-1-git-send-email-linus.walleij@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: Received: from cassarossa.samfundet.no ([193.35.52.29]:45024 "EHLO cassarossa.samfundet.no" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754672AbbKDJzB (ORCPT ); Wed, 4 Nov 2015 04:55:01 -0500 Content-Disposition: inline In-Reply-To: <1446629475-31754-1-git-send-email-linus.walleij@linaro.org> Sender: linux-gpio-owner@vger.kernel.org List-Id: linux-gpio@vger.kernel.org To: Linus Walleij Cc: linux-gpio@vger.kernel.org, Alexandre Courbot , Haavard Skinnemoen , =?utf-8?B?UmFmYcWCIE1pxYJlY2tp?= , Jiri Kosina , Dmitry Torokhov , Richard Purdie , Jacek Anaszewski , Mauro Carvalho Chehab , Lee Jones , Alek Du , Greg Kroah-Hartman , Jaroslav Kysela , Takashi Iwai Around Wed 04 Nov 2015 10:31:15 +0100 or thereabout, Linus Walleij wrot= e: > 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. >=20 > 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: >=20 > @@ > struct gpio_chip *var; > @@ > -var->dev > +var->parent >=20 > and: >=20 > @@ > struct gpio_chip var; > @@ > -var.dev > +var.parent >=20 > 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. >=20 > Cc: Haavard Skinnemoen > Cc: Hans-Christian Egtvedt > Cc: Rafa=C5=82 Mi=C5=82ecki > Cc: Jiri Kosina > Cc: Dmitry Torokhov > Cc: Richard Purdie > Cc: Jacek Anaszewski > Cc: Mauro Carvalho Chehab > Cc: Lee Jones > Cc: Alek Du > Cc: Greg Kroah-Hartman > Cc: Jaroslav Kysela > Cc: Takashi Iwai > Signed-off-by: Linus Walleij > --- > Other subsystem maintainers: please ACK this. I want to merge this > big patch in the beginning of -rc1. I can create an immutable branch > or tag if you think it will cause you problems, so you can pull it > in. > --- > arch/avr32/mach-at32ap/pio.c | 2 +- =46or the tiny AVR32 bits Acked-by: Hans-Christian Egtvedt --=20 Best regards, Hans-Christian Egtvedt -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" i= n the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html