devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] ARM: dts: rockchip: pull up cts lines
@ 2015-09-02 23:27 Alexandru M Stan
  2015-09-02 23:27 ` [PATCH v2 1/2] ARM: dts: rockchip: pull up cts lines on rk3288 Alexandru M Stan
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Alexandru M Stan @ 2015-09-02 23:27 UTC (permalink / raw)
  To: Heiko Stuebner
  Cc: Romain Perier, FUKAUMI Naoki, Neil Hendin, Douglas Anderson,
	Jeffy Chen, Caesar Wang, devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	Alexandru M Stan

The flow control lines from a user accessible UART are optional,
the user might not have anything connected to those pins.
In order to prevent random interrupts happening and noise affecting
the cts pin should be pulled up.

The only boards affected (that care about uart*_cts ) are the veyron
chromeos devices and the firefly. Veyron already has something like that,
which I now have to remove in the second patch. Firefly uses uart0_cts
for the wifi chip communications, same thing as veyron, so it should be
fine having it.

Changes in v2:
- Restrict changes only to cts pin, leave rts alone
- CC people with the firefly board
- New patch removing redundant pullup code from veyron
- cover letter

Alexandru M Stan (2):
  ARM: dts: rockchip: pull up cts lines on rk3288
  ARM: dts: rockchip: Remove specific cts pullup from veyron

 arch/arm/boot/dts/rk3288-veyron.dtsi | 12 ------------
 arch/arm/boot/dts/rk3288.dtsi        |  8 ++++----
 2 files changed, 4 insertions(+), 16 deletions(-)

-- 
2.5.0.457.gab17608

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH v2 1/2] ARM: dts: rockchip: pull up cts lines on rk3288
  2015-09-02 23:27 [PATCH v2 0/2] ARM: dts: rockchip: pull up cts lines Alexandru M Stan
@ 2015-09-02 23:27 ` Alexandru M Stan
  2015-09-02 23:34   ` Doug Anderson
  2015-09-02 23:27 ` [PATCH v2 2/2] ARM: dts: rockchip: Remove specific cts pullup from veyron Alexandru M Stan
       [not found] ` <1441236479-4941-1-git-send-email-amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
  2 siblings, 1 reply; 6+ messages in thread
From: Alexandru M Stan @ 2015-09-02 23:27 UTC (permalink / raw)
  To: Heiko Stuebner
  Cc: Romain Perier, FUKAUMI Naoki, Neil Hendin, Douglas Anderson,
	Jeffy Chen, Caesar Wang, devicetree, linux-kernel, linux-rockchip,
	linux-arm-kernel, Alexandru M Stan

The flow control lines from a user accessible UART are optional,
the user might not have anything connected to those pins.
In order to prevent random interrupts happening and noise affecting
the cts pin should be pulled up.

Note that the default state for that pin on the rk3288 is pulled up,
so this patch merely restores them.

This is similar to what we're already doing with the RX pin,
so it should be safe. At worst it might be a slightly higher power usage
(through ~50 kohms) when the cts is low.

Suggested-by: Neil Hendin <nhendin@chromium.org>
Signed-off-by: Alexandru M Stan <amstan@chromium.org>
---
Changes in v2: None

 arch/arm/boot/dts/rk3288.dtsi | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/arm/boot/dts/rk3288.dtsi b/arch/arm/boot/dts/rk3288.dtsi
index 906e938..0e8fd53 100644
--- a/arch/arm/boot/dts/rk3288.dtsi
+++ b/arch/arm/boot/dts/rk3288.dtsi
@@ -1211,7 +1211,7 @@
 			};
 
 			uart0_cts: uart0-cts {
-				rockchip,pins = <4 18 RK_FUNC_1 &pcfg_pull_none>;
+				rockchip,pins = <4 18 RK_FUNC_1 &pcfg_pull_up>;
 			};
 
 			uart0_rts: uart0-rts {
@@ -1226,7 +1226,7 @@
 			};
 
 			uart1_cts: uart1-cts {
-				rockchip,pins = <5 10 RK_FUNC_1 &pcfg_pull_none>;
+				rockchip,pins = <5 10 RK_FUNC_1 &pcfg_pull_up>;
 			};
 
 			uart1_rts: uart1-rts {
@@ -1249,7 +1249,7 @@
 			};
 
 			uart3_cts: uart3-cts {
-				rockchip,pins = <7 9 RK_FUNC_1 &pcfg_pull_none>;
+				rockchip,pins = <7 9 RK_FUNC_1 &pcfg_pull_up>;
 			};
 
 			uart3_rts: uart3-rts {
@@ -1264,7 +1264,7 @@
 			};
 
 			uart4_cts: uart4-cts {
-				rockchip,pins = <5 14 3 &pcfg_pull_none>;
+				rockchip,pins = <5 14 3 &pcfg_pull_up>;
 			};
 
 			uart4_rts: uart4-rts {
-- 
2.5.0.457.gab17608

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

* [PATCH v2 2/2] ARM: dts: rockchip: Remove specific cts pullup from veyron
  2015-09-02 23:27 [PATCH v2 0/2] ARM: dts: rockchip: pull up cts lines Alexandru M Stan
  2015-09-02 23:27 ` [PATCH v2 1/2] ARM: dts: rockchip: pull up cts lines on rk3288 Alexandru M Stan
@ 2015-09-02 23:27 ` Alexandru M Stan
       [not found]   ` <1441236479-4941-3-git-send-email-amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
       [not found] ` <1441236479-4941-1-git-send-email-amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
  2 siblings, 1 reply; 6+ messages in thread
From: Alexandru M Stan @ 2015-09-02 23:27 UTC (permalink / raw)
  To: Heiko Stuebner
  Cc: Romain Perier, FUKAUMI Naoki, Neil Hendin, Douglas Anderson,
	Jeffy Chen, Caesar Wang, devicetree, linux-kernel, linux-rockchip,
	linux-arm-kernel, Alexandru M Stan

With the previous patch ("rk3288: pull up cts lines") this is redundant,
I sent that patch for the same reason this existed here, so the lines don't
wiggle randomly when disconnected.

Signed-off-by: Alexandru M Stan <amstan@chromium.org>
---
Changes in v2:
- Restrict changes only to cts pin, leave rts alone
- CC people with the firefly board
- New patch removing redundant pullup code from veyron
- cover letter

 arch/arm/boot/dts/rk3288-veyron.dtsi | 12 ------------
 1 file changed, 12 deletions(-)

diff --git a/arch/arm/boot/dts/rk3288-veyron.dtsi b/arch/arm/boot/dts/rk3288-veyron.dtsi
index 2fa7a0d..2b5d2e2 100644
--- a/arch/arm/boot/dts/rk3288-veyron.dtsi
+++ b/arch/arm/boot/dts/rk3288-veyron.dtsi
@@ -543,18 +543,6 @@
 		};
 	};
 
-	/*
-	 * On Marvell-based hardware this is a no-connect.  Make sure we enable
-	 * the pullup so that the line doesn't float.  The pullup shouldn't
-	 * hurt on Broadcom-based hardware since the other side is actively
-	 * driving this signal.  As proof: we've already got a pullup on RX.
-	 */
-	uart0 {
-		uart0_cts: uart0-cts {
-			rockchip,pins = <4 18 RK_FUNC_1 &pcfg_pull_up>;
-		};
-	};
-
 	write-protect {
 		fw_wp_ap: fw-wp-ap {
 			rockchip,pins = <7 6 RK_FUNC_GPIO &pcfg_pull_none>;
-- 
2.5.0.457.gab17608

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

* Re: [PATCH v2 1/2] ARM: dts: rockchip: pull up cts lines on rk3288
  2015-09-02 23:27 ` [PATCH v2 1/2] ARM: dts: rockchip: pull up cts lines on rk3288 Alexandru M Stan
@ 2015-09-02 23:34   ` Doug Anderson
  0 siblings, 0 replies; 6+ messages in thread
From: Doug Anderson @ 2015-09-02 23:34 UTC (permalink / raw)
  To: Alexandru M Stan
  Cc: Heiko Stuebner, Romain Perier, FUKAUMI Naoki, Neil Hendin,
	Jeffy Chen, Caesar Wang, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, open list:ARM/Rockchip SoC...,
	linux-arm-kernel@lists.infradead.org

Alex,

On Wed, Sep 2, 2015 at 4:27 PM, Alexandru M Stan <amstan@chromium.org> wrote:
> The flow control lines from a user accessible UART are optional,
> the user might not have anything connected to those pins.
> In order to prevent random interrupts happening and noise affecting
> the cts pin should be pulled up.
>
> Note that the default state for that pin on the rk3288 is pulled up,
> so this patch merely restores them.
>
> This is similar to what we're already doing with the RX pin,
> so it should be safe. At worst it might be a slightly higher power usage
> (through ~50 kohms) when the cts is low.
>
> Suggested-by: Neil Hendin <nhendin@chromium.org>
> Signed-off-by: Alexandru M Stan <amstan@chromium.org>
> ---
> Changes in v2: None

Probably not entirely true.  ;)

>  arch/arm/boot/dts/rk3288.dtsi | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)

Looks good to me.

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

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

* Re: [PATCH v2 2/2] ARM: dts: rockchip: Remove specific cts pullup from veyron
       [not found]   ` <1441236479-4941-3-git-send-email-amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
@ 2015-09-02 23:35     ` Doug Anderson
  0 siblings, 0 replies; 6+ messages in thread
From: Doug Anderson @ 2015-09-02 23:35 UTC (permalink / raw)
  To: Alexandru M Stan
  Cc: Heiko Stuebner, Romain Perier, FUKAUMI Naoki, Neil Hendin,
	Jeffy Chen, Caesar Wang,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	open list:ARM/Rockchip SoC...,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org

Alex,

On Wed, Sep 2, 2015 at 4:27 PM, Alexandru M Stan <amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org> wrote:
> With the previous patch ("rk3288: pull up cts lines") this is redundant,
> I sent that patch for the same reason this existed here, so the lines don't
> wiggle randomly when disconnected.
>
> Signed-off-by: Alexandru M Stan <amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
> ---
> Changes in v2:
> - Restrict changes only to cts pin, leave rts alone
> - CC people with the firefly board
> - New patch removing redundant pullup code from veyron
> - cover letter
>
>  arch/arm/boot/dts/rk3288-veyron.dtsi | 12 ------------
>  1 file changed, 12 deletions(-)

Reviewed-by: Douglas Anderson <dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH v2 0/2] ARM: dts: rockchip: pull up cts lines
       [not found] ` <1441236479-4941-1-git-send-email-amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
@ 2015-09-03 19:03   ` Heiko Stuebner
  0 siblings, 0 replies; 6+ messages in thread
From: Heiko Stuebner @ 2015-09-03 19:03 UTC (permalink / raw)
  To: Alexandru M Stan
  Cc: Romain Perier, FUKAUMI Naoki, Neil Hendin, Douglas Anderson,
	Jeffy Chen, Caesar Wang, devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Hi Alex,

Am Mittwoch, 2. September 2015, 16:27:57 schrieb Alexandru M Stan:
> The flow control lines from a user accessible UART are optional,
> the user might not have anything connected to those pins.
> In order to prevent random interrupts happening and noise affecting
> the cts pin should be pulled up.
> 
> The only boards affected (that care about uart*_cts ) are the veyron
> chromeos devices and the firefly. Veyron already has something like that,
> which I now have to remove in the second patch. Firefly uses uart0_cts
> for the wifi chip communications, same thing as veyron, so it should be
> fine having it.

applied both to my dts branch for 4.4 with Doug's Review-tag
(Currently only on github and becomes really public after 4.3-rc1)


Heiko
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

end of thread, other threads:[~2015-09-03 19:03 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-02 23:27 [PATCH v2 0/2] ARM: dts: rockchip: pull up cts lines Alexandru M Stan
2015-09-02 23:27 ` [PATCH v2 1/2] ARM: dts: rockchip: pull up cts lines on rk3288 Alexandru M Stan
2015-09-02 23:34   ` Doug Anderson
2015-09-02 23:27 ` [PATCH v2 2/2] ARM: dts: rockchip: Remove specific cts pullup from veyron Alexandru M Stan
     [not found]   ` <1441236479-4941-3-git-send-email-amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-09-02 23:35     ` Doug Anderson
     [not found] ` <1441236479-4941-1-git-send-email-amstan-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-09-03 19:03   ` [PATCH v2 0/2] ARM: dts: rockchip: pull up cts lines Heiko Stuebner

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).