All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] sc7180: Add PDC wakeup interrupt map for GPIOs
@ 2019-10-30  7:06 Maulik Shah
  2019-10-30  7:06 ` [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map Maulik Shah
  2019-10-30  7:06 ` [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM Maulik Shah
  0 siblings, 2 replies; 9+ messages in thread
From: Maulik Shah @ 2019-10-30  7:06 UTC (permalink / raw)
  To: agross, robh+dt, bjorn.andersson, linus.walleij
  Cc: linux-arm-msm, linux-kernel, linux-gpio, rnayak, ilina, lsrao,
	mka, swboyd, evgreen, dianders, Maulik Shah

GPIOs that can be configured as wakeup sources, have their interrupt
lines routed to PDC interrupt controller.

Add PDC wakeup interrupt map for sc7180 GPIOs.

This series has dependency on adding device tree support for sc7180 [1]
and support wakeup capable GPIOs [2] to merge first.

Dependencies:

[1] https://lkml.org/lkml/2019/10/23/223
[2] https://lkml.org/lkml/2019/9/13/1005

Maulik Shah (2):
  pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map
  arm64: dts: qcom: sc7180: Add wakeup parent for TLMM

 arch/arm64/boot/dts/qcom/sc7180.dtsi  |  1 +
 drivers/pinctrl/qcom/pinctrl-sc7180.c | 18 ++++++++++++++++++
 2 files changed, 19 insertions(+)

-- 
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map
  2019-10-30  7:06 [PATCH 0/2] sc7180: Add PDC wakeup interrupt map for GPIOs Maulik Shah
@ 2019-10-30  7:06 ` Maulik Shah
  2019-11-05  9:49   ` Linus Walleij
                     ` (3 more replies)
  2019-10-30  7:06 ` [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM Maulik Shah
  1 sibling, 4 replies; 9+ messages in thread
From: Maulik Shah @ 2019-10-30  7:06 UTC (permalink / raw)
  To: agross, robh+dt, bjorn.andersson, linus.walleij
  Cc: linux-arm-msm, linux-kernel, linux-gpio, rnayak, ilina, lsrao,
	mka, swboyd, evgreen, dianders, Maulik Shah

GPIOs that can be configured as wakeup sources, have their
interrupt lines routed to PDC interrupt controller.

Provide the interrupt map of the GPIO to its wakeup capable
interrupt parent.

Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
---
 drivers/pinctrl/qcom/pinctrl-sc7180.c | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/drivers/pinctrl/qcom/pinctrl-sc7180.c b/drivers/pinctrl/qcom/pinctrl-sc7180.c
index 6399c8a..8a2b97c 100644
--- a/drivers/pinctrl/qcom/pinctrl-sc7180.c
+++ b/drivers/pinctrl/qcom/pinctrl-sc7180.c
@@ -1097,6 +1097,22 @@ static const struct msm_pingroup sc7180_groups[] = {
 	[126] = SDC_QDSD_PINGROUP(sdc2_data, 0x97b000, 9, 0),
 };
 
+static const struct msm_gpio_wakeirq_map sc7180_pdc_map[] = {
+	{0, 40}, {3, 50}, {4, 42}, {5, 70}, {6, 41}, {9, 35},
+	{10, 80}, {11, 51}, {16, 20}, {21, 55}, {22, 90}, {23, 21},
+	{24, 61}, {26, 52}, {28, 36}, {30, 100}, {31, 33}, {32, 81},
+	{33, 62}, {34, 43}, {36, 91}, {37, 53}, {38, 63}, {39, 72},
+	{41, 101}, {42, 7}, {43, 34}, {45, 73}, {47, 82}, {49, 17},
+	{52, 109}, {53, 102}, {55, 92}, {56, 56}, {57, 57}, {58, 83},
+	{59, 37}, {62, 110}, {63, 111}, {64, 74}, {65, 44}, {66, 93},
+	{67, 58}, {68, 112}, {69, 32}, {70, 54}, {72, 59}, {73, 64},
+	{74, 71}, {78, 31}, {82, 30}, {85, 103}, {86, 38}, {87, 39},
+	{88, 45}, {89, 46}, {90, 47}, {91, 48}, {92, 60}, {93, 49},
+	{94, 84}, {95, 94}, {98, 65}, {101, 66}, {104, 67}, {109, 104},
+	{110, 68}, {113, 69}, {114, 113}, {115, 108}, {116, 121},
+	{117, 114}, {118, 119},
+};
+
 static const struct msm_pinctrl_soc_data sc7180_pinctrl = {
 	.pins = sc7180_pins,
 	.npins = ARRAY_SIZE(sc7180_pins),
@@ -1107,6 +1123,8 @@ static const struct msm_pinctrl_soc_data sc7180_pinctrl = {
 	.ngpios = 120,
 	.tiles = sc7180_tiles,
 	.ntiles = ARRAY_SIZE(sc7180_tiles),
+	.wakeirq_map = sc7180_pdc_map,
+	.nwakeirq_map = ARRAY_SIZE(sc7180_pdc_map),
 };
 
 static int sc7180_pinctrl_probe(struct platform_device *pdev)
-- 
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM
  2019-10-30  7:06 [PATCH 0/2] sc7180: Add PDC wakeup interrupt map for GPIOs Maulik Shah
  2019-10-30  7:06 ` [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map Maulik Shah
@ 2019-10-30  7:06 ` Maulik Shah
  2019-12-10 22:27   ` Lina Iyer
  2019-12-17 20:38   ` Doug Anderson
  1 sibling, 2 replies; 9+ messages in thread
From: Maulik Shah @ 2019-10-30  7:06 UTC (permalink / raw)
  To: agross, robh+dt, bjorn.andersson, linus.walleij
  Cc: linux-arm-msm, linux-kernel, linux-gpio, rnayak, ilina, lsrao,
	mka, swboyd, evgreen, dianders, Maulik Shah, devicetree

Specify wakeup parent irqchip for sc7180 TLMM.

Cc: devicetree@vger.kernel.org
Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
---
 arch/arm64/boot/dts/qcom/sc7180.dtsi | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm64/boot/dts/qcom/sc7180.dtsi b/arch/arm64/boot/dts/qcom/sc7180.dtsi
index 69d5e2c..9040eee 100644
--- a/arch/arm64/boot/dts/qcom/sc7180.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7180.dtsi
@@ -321,6 +321,7 @@
 			interrupt-controller;
 			#interrupt-cells = <2>;
 			gpio-ranges = <&tlmm 0 0 120>;
+			wakeup-parent = <&pdc>;
 
 			qup_uart2_default: qup-uart2-default {
 				pinmux {
-- 
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map
  2019-10-30  7:06 ` [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map Maulik Shah
@ 2019-11-05  9:49   ` Linus Walleij
  2019-12-10 22:23   ` Lina Iyer
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 9+ messages in thread
From: Linus Walleij @ 2019-11-05  9:49 UTC (permalink / raw)
  To: Maulik Shah, Lina Iyer, Bjorn Andersson
  Cc: Andy Gross, Rob Herring, MSM, linux-kernel,
	open list:GPIO SUBSYSTEM, Rajendra Nayak, lsrao,
	Matthias Kaehlcke, Stephen Boyd, Evan Green, Doug Anderson

On Wed, Oct 30, 2019 at 8:07 AM Maulik Shah <mkshah@codeaurora.org> wrote:

> GPIOs that can be configured as wakeup sources, have their
> interrupt lines routed to PDC interrupt controller.
>
> Provide the interrupt map of the GPIO to its wakeup capable
> interrupt parent.
>
> Signed-off-by: Maulik Shah <mkshah@codeaurora.org>

Looks good to me but I'd like to see Bjorns and preferably also
Lina's review on this.

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map
  2019-10-30  7:06 ` [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map Maulik Shah
  2019-11-05  9:49   ` Linus Walleij
@ 2019-12-10 22:23   ` Lina Iyer
  2019-12-11  7:09   ` Bjorn Andersson
  2019-12-16  8:19   ` Linus Walleij
  3 siblings, 0 replies; 9+ messages in thread
From: Lina Iyer @ 2019-12-10 22:23 UTC (permalink / raw)
  To: Maulik Shah
  Cc: agross, robh+dt, bjorn.andersson, linus.walleij, linux-arm-msm,
	linux-kernel, linux-gpio, rnayak, lsrao, mka, swboyd, evgreen,
	dianders

On Wed, Oct 30 2019 at 01:07 -0600, Maulik Shah wrote:
>GPIOs that can be configured as wakeup sources, have their
>interrupt lines routed to PDC interrupt controller.
>
>Provide the interrupt map of the GPIO to its wakeup capable
>interrupt parent.
>
>Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
Reviewed-by: Lina Iyer <ilina@codeaurora.org>

>---
> drivers/pinctrl/qcom/pinctrl-sc7180.c | 18 ++++++++++++++++++
> 1 file changed, 18 insertions(+)
>
>diff --git a/drivers/pinctrl/qcom/pinctrl-sc7180.c b/drivers/pinctrl/qcom/pinctrl-sc7180.c
>index 6399c8a..8a2b97c 100644
>--- a/drivers/pinctrl/qcom/pinctrl-sc7180.c
>+++ b/drivers/pinctrl/qcom/pinctrl-sc7180.c
>@@ -1097,6 +1097,22 @@ static const struct msm_pingroup sc7180_groups[] = {
> 	[126] = SDC_QDSD_PINGROUP(sdc2_data, 0x97b000, 9, 0),
> };
>
>+static const struct msm_gpio_wakeirq_map sc7180_pdc_map[] = {
>+	{0, 40}, {3, 50}, {4, 42}, {5, 70}, {6, 41}, {9, 35},
>+	{10, 80}, {11, 51}, {16, 20}, {21, 55}, {22, 90}, {23, 21},
>+	{24, 61}, {26, 52}, {28, 36}, {30, 100}, {31, 33}, {32, 81},
>+	{33, 62}, {34, 43}, {36, 91}, {37, 53}, {38, 63}, {39, 72},
>+	{41, 101}, {42, 7}, {43, 34}, {45, 73}, {47, 82}, {49, 17},
>+	{52, 109}, {53, 102}, {55, 92}, {56, 56}, {57, 57}, {58, 83},
>+	{59, 37}, {62, 110}, {63, 111}, {64, 74}, {65, 44}, {66, 93},
>+	{67, 58}, {68, 112}, {69, 32}, {70, 54}, {72, 59}, {73, 64},
>+	{74, 71}, {78, 31}, {82, 30}, {85, 103}, {86, 38}, {87, 39},
>+	{88, 45}, {89, 46}, {90, 47}, {91, 48}, {92, 60}, {93, 49},
>+	{94, 84}, {95, 94}, {98, 65}, {101, 66}, {104, 67}, {109, 104},
>+	{110, 68}, {113, 69}, {114, 113}, {115, 108}, {116, 121},
>+	{117, 114}, {118, 119},
>+};
>+
> static const struct msm_pinctrl_soc_data sc7180_pinctrl = {
> 	.pins = sc7180_pins,
> 	.npins = ARRAY_SIZE(sc7180_pins),
>@@ -1107,6 +1123,8 @@ static const struct msm_pinctrl_soc_data sc7180_pinctrl = {
> 	.ngpios = 120,
> 	.tiles = sc7180_tiles,
> 	.ntiles = ARRAY_SIZE(sc7180_tiles),
>+	.wakeirq_map = sc7180_pdc_map,
>+	.nwakeirq_map = ARRAY_SIZE(sc7180_pdc_map),
> };
>
> static int sc7180_pinctrl_probe(struct platform_device *pdev)
>-- 
>QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
>of Code Aurora Forum, hosted by The Linux Foundation
>

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM
  2019-10-30  7:06 ` [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM Maulik Shah
@ 2019-12-10 22:27   ` Lina Iyer
  2019-12-17 20:38   ` Doug Anderson
  1 sibling, 0 replies; 9+ messages in thread
From: Lina Iyer @ 2019-12-10 22:27 UTC (permalink / raw)
  To: Maulik Shah
  Cc: agross, robh+dt, bjorn.andersson, linus.walleij, linux-arm-msm,
	linux-kernel, linux-gpio, rnayak, lsrao, mka, swboyd, evgreen,
	dianders, devicetree

On Wed, Oct 30 2019 at 01:07 -0600, Maulik Shah wrote:
>Specify wakeup parent irqchip for sc7180 TLMM.
>
>Cc: devicetree@vger.kernel.org
>Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
Reviewed-by: Lina Iyer <ilina@codeaurora.org>

>---
> arch/arm64/boot/dts/qcom/sc7180.dtsi | 1 +
> 1 file changed, 1 insertion(+)
>
>diff --git a/arch/arm64/boot/dts/qcom/sc7180.dtsi b/arch/arm64/boot/dts/qcom/sc7180.dtsi
>index 69d5e2c..9040eee 100644
>--- a/arch/arm64/boot/dts/qcom/sc7180.dtsi
>+++ b/arch/arm64/boot/dts/qcom/sc7180.dtsi
>@@ -321,6 +321,7 @@
> 			interrupt-controller;
> 			#interrupt-cells = <2>;
> 			gpio-ranges = <&tlmm 0 0 120>;
>+			wakeup-parent = <&pdc>;
>
> 			qup_uart2_default: qup-uart2-default {
> 				pinmux {
>-- 
>QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
>of Code Aurora Forum, hosted by The Linux Foundation
>

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map
  2019-10-30  7:06 ` [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map Maulik Shah
  2019-11-05  9:49   ` Linus Walleij
  2019-12-10 22:23   ` Lina Iyer
@ 2019-12-11  7:09   ` Bjorn Andersson
  2019-12-16  8:19   ` Linus Walleij
  3 siblings, 0 replies; 9+ messages in thread
From: Bjorn Andersson @ 2019-12-11  7:09 UTC (permalink / raw)
  To: Maulik Shah
  Cc: agross, robh+dt, linus.walleij, linux-arm-msm, linux-kernel,
	linux-gpio, rnayak, ilina, lsrao, mka, swboyd, evgreen, dianders

On Wed 30 Oct 00:06 PDT 2019, Maulik Shah wrote:

> GPIOs that can be configured as wakeup sources, have their
> interrupt lines routed to PDC interrupt controller.
> 
> Provide the interrupt map of the GPIO to its wakeup capable
> interrupt parent.
> 
> Signed-off-by: Maulik Shah <mkshah@codeaurora.org>

Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org>

@Linus, please take this patch through your tree and I'll take patch 2
through the arm tree.

Regards,
Bjorn

> ---
>  drivers/pinctrl/qcom/pinctrl-sc7180.c | 18 ++++++++++++++++++
>  1 file changed, 18 insertions(+)
> 
> diff --git a/drivers/pinctrl/qcom/pinctrl-sc7180.c b/drivers/pinctrl/qcom/pinctrl-sc7180.c
> index 6399c8a..8a2b97c 100644
> --- a/drivers/pinctrl/qcom/pinctrl-sc7180.c
> +++ b/drivers/pinctrl/qcom/pinctrl-sc7180.c
> @@ -1097,6 +1097,22 @@ static const struct msm_pingroup sc7180_groups[] = {
>  	[126] = SDC_QDSD_PINGROUP(sdc2_data, 0x97b000, 9, 0),
>  };
>  
> +static const struct msm_gpio_wakeirq_map sc7180_pdc_map[] = {
> +	{0, 40}, {3, 50}, {4, 42}, {5, 70}, {6, 41}, {9, 35},
> +	{10, 80}, {11, 51}, {16, 20}, {21, 55}, {22, 90}, {23, 21},
> +	{24, 61}, {26, 52}, {28, 36}, {30, 100}, {31, 33}, {32, 81},
> +	{33, 62}, {34, 43}, {36, 91}, {37, 53}, {38, 63}, {39, 72},
> +	{41, 101}, {42, 7}, {43, 34}, {45, 73}, {47, 82}, {49, 17},
> +	{52, 109}, {53, 102}, {55, 92}, {56, 56}, {57, 57}, {58, 83},
> +	{59, 37}, {62, 110}, {63, 111}, {64, 74}, {65, 44}, {66, 93},
> +	{67, 58}, {68, 112}, {69, 32}, {70, 54}, {72, 59}, {73, 64},
> +	{74, 71}, {78, 31}, {82, 30}, {85, 103}, {86, 38}, {87, 39},
> +	{88, 45}, {89, 46}, {90, 47}, {91, 48}, {92, 60}, {93, 49},
> +	{94, 84}, {95, 94}, {98, 65}, {101, 66}, {104, 67}, {109, 104},
> +	{110, 68}, {113, 69}, {114, 113}, {115, 108}, {116, 121},
> +	{117, 114}, {118, 119},
> +};
> +
>  static const struct msm_pinctrl_soc_data sc7180_pinctrl = {
>  	.pins = sc7180_pins,
>  	.npins = ARRAY_SIZE(sc7180_pins),
> @@ -1107,6 +1123,8 @@ static const struct msm_pinctrl_soc_data sc7180_pinctrl = {
>  	.ngpios = 120,
>  	.tiles = sc7180_tiles,
>  	.ntiles = ARRAY_SIZE(sc7180_tiles),
> +	.wakeirq_map = sc7180_pdc_map,
> +	.nwakeirq_map = ARRAY_SIZE(sc7180_pdc_map),
>  };
>  
>  static int sc7180_pinctrl_probe(struct platform_device *pdev)
> -- 
> QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
> of Code Aurora Forum, hosted by The Linux Foundation
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map
  2019-10-30  7:06 ` [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map Maulik Shah
                     ` (2 preceding siblings ...)
  2019-12-11  7:09   ` Bjorn Andersson
@ 2019-12-16  8:19   ` Linus Walleij
  3 siblings, 0 replies; 9+ messages in thread
From: Linus Walleij @ 2019-12-16  8:19 UTC (permalink / raw)
  To: Maulik Shah
  Cc: Andy Gross, Rob Herring, Bjorn Andersson, MSM, linux-kernel,
	open list:GPIO SUBSYSTEM, Rajendra Nayak, Lina Iyer, lsrao,
	Matthias Kaehlcke, Stephen Boyd, Evan Green, Doug Anderson

On Wed, Oct 30, 2019 at 8:07 AM Maulik Shah <mkshah@codeaurora.org> wrote:

> GPIOs that can be configured as wakeup sources, have their
> interrupt lines routed to PDC interrupt controller.
>
> Provide the interrupt map of the GPIO to its wakeup capable
> interrupt parent.
>
> Signed-off-by: Maulik Shah <mkshah@codeaurora.org>

Patch applied for v5.6 with the ACKs!

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM
  2019-10-30  7:06 ` [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM Maulik Shah
  2019-12-10 22:27   ` Lina Iyer
@ 2019-12-17 20:38   ` Doug Anderson
  1 sibling, 0 replies; 9+ messages in thread
From: Doug Anderson @ 2019-12-17 20:38 UTC (permalink / raw)
  To: Maulik Shah, Bjorn Andersson, Andy Gross
  Cc: Rob Herring, LinusW, linux-arm-msm, LKML,
	open list:GPIO SUBSYSTEM, Rajendra Nayak, Lina Iyer, lsrao,
	Matthias Kaehlcke, Stephen Boyd, Evan Green,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS

Bjorn / Andy,

On Wed, Oct 30, 2019 at 12:07 AM Maulik Shah <mkshah@codeaurora.org> wrote:
>
> Specify wakeup parent irqchip for sc7180 TLMM.
>
> Cc: devicetree@vger.kernel.org
> Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
> ---
>  arch/arm64/boot/dts/qcom/sc7180.dtsi | 1 +
>  1 file changed, 1 insertion(+)

I see that Linus W. applied patch #1:

https://lore.kernel.org/r/CACRpkdY9ETQRHn7x2D2XVLZ810Uo1cPQxMBqTy5LnrORRNjTVw@mail.gmail.com

...so I think this patch is ready to go.

FWIW, feel free to add:

Reviewed-by: Douglas Anderson <dianders@chromium.org>

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2019-12-17 20:38 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-30  7:06 [PATCH 0/2] sc7180: Add PDC wakeup interrupt map for GPIOs Maulik Shah
2019-10-30  7:06 ` [PATCH 1/2] pinctrl: qcom: sc7180: Add GPIO wakeup interrupt map Maulik Shah
2019-11-05  9:49   ` Linus Walleij
2019-12-10 22:23   ` Lina Iyer
2019-12-11  7:09   ` Bjorn Andersson
2019-12-16  8:19   ` Linus Walleij
2019-10-30  7:06 ` [PATCH 2/2] arm64: dts: qcom: sc7180: Add wakeup parent for TLMM Maulik Shah
2019-12-10 22:27   ` Lina Iyer
2019-12-17 20:38   ` Doug Anderson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.