linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: linus.walleij@linaro.org, linux-sh@vger.kernel.org,
	laurent.pinchart@ideasonboard.com, linux-gpio@vger.kernel.org
Subject: [PATCH v3 1/3] sh-pfc: fix sparse GPIOs for R-Car SoCs
Date: Fri, 26 Jun 2015 01:40:56 +0300	[thread overview]
Message-ID: <2925145.E3lLFJfWJW@wasted.cogentembedded.com> (raw)
In-Reply-To: <1460630.GxHT4lRd7u@wasted.cogentembedded.com>

The PFC driver causes the kernel to hang on the R-Car gen2 SoC based  boards
when the CPU_ALL_PORT() macro is fixed to reflect the reality, i.e. when the
GPIO space becomes actually sparse.  This happens because the _GP_GPIO() macro
includes  an indexed initializer which causes the "holes" (array entries filled
with all 0s) between the groups  of the existing GPIOs; and the driver can't
cope with that.  There seems to  be no reason to use the indexed initializer,
so we can remove the index specifier and so avoid the "holes".

Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>

---
Changes in version 3:
- new patch.

 drivers/pinctrl/sh-pfc/sh_pfc.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-pinctrl/drivers/pinctrl/sh-pfc/sh_pfc.h
===================================================================
--- linux-pinctrl.orig/drivers/pinctrl/sh-pfc/sh_pfc.h
+++ linux-pinctrl/drivers/pinctrl/sh-pfc/sh_pfc.h
@@ -224,7 +224,7 @@ struct sh_pfc_soc_info {
 
 /* PINMUX_GPIO_GP_ALL - Expand to a list of sh_pfc_pin entries */
 #define _GP_GPIO(bank, _pin, _name, sfx)				\
-	[(bank * 32) + _pin] = {					\
+	{								\
 		.pin = (bank * 32) + _pin,				\
 		.name = __stringify(_name),				\
 		.enum_id = _name##_DATA,				\


  reply	other threads:[~2015-06-25 22:41 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-25 22:39 [PATCH v3 0/3] Remove non-existing GPIO pins for R8A7790/1 Sergei Shtylyov
2015-06-25 22:40 ` Sergei Shtylyov [this message]
2015-07-07 17:39   ` [PATCH v3 1/3] sh-pfc: fix sparse GPIOs for R-Car SoCs Laurent Pinchart
2015-07-08  7:37     ` Geert Uytterhoeven
2015-07-13 20:29   ` Linus Walleij
2015-06-25 22:42 ` [PATCH v3 2/3] sh-pfc: r8a7790: remove non-existing GPIO pins Sergei Shtylyov
2015-07-13 20:30   ` Linus Walleij
2015-06-25 22:43 ` [PATCH v3 3/3] sh-pfc: r8a7791: " Sergei Shtylyov
2015-07-08  7:38   ` Geert Uytterhoeven
2015-07-13 20:32   ` Linus Walleij
2015-06-26 20:51 ` [PATCH v3 0/3] Remove non-existing GPIO pins for R8A7790/1 Sergei Shtylyov
2015-06-29 10:43   ` Linus Walleij
2015-07-03 23:29     ` Laurent Pinchart
2015-07-07 20:58     ` Laurent Pinchart

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2925145.E3lLFJfWJW@wasted.cogentembedded.com \
    --to=sergei.shtylyov@cogentembedded.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-sh@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).