All of lore.kernel.org
 help / color / mirror / Atom feed
From: <patrice.chotard@st.com>
To: <robh+dt@kernel.org>, <mark.rutland@arm.com>,
	<linux@armlinux.org.uk>, <linux-arm-kernel@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<gregkh@linuxfoundation.org>, <jslaby@suse.com>,
	<linux-serial@vger.kernel.org>
Cc: <patrice.chotard@st.com>
Subject: [PATCH v4 1/3] tty: st-asc: Update tty alias
Date: Wed, 7 Mar 2018 18:35:32 +0100	[thread overview]
Message-ID: <1520444134-30144-2-git-send-email-patrice.chotard@st.com> (raw)
In-Reply-To: <1520444134-30144-1-git-send-email-patrice.chotard@st.com>

From: Patrice Chotard <patrice.chotard@st.com>

Since dtc v1.4.6-9-gaadd0b65c987, aliases property name
must include only lowercase and '-'.

After having updated all STi boards serial aliases from "ttyASN"
to "serialN", st-asc driver need to be updated accordingly as tty
aliases id is retrieved using of_alias_get_id().

Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Rob Herring <robh@kernel.org>
---

v4: _ add Reviewed-by
v3: _ update st-asc driver with "serial" alias prefix and keep "ttyAS" in second choice
v2: _ update st-asc driver with "serial" alias prefix

 drivers/tty/serial/st-asc.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/tty/serial/st-asc.c b/drivers/tty/serial/st-asc.c
index c763253514e9..5f9f01fac6dd 100644
--- a/drivers/tty/serial/st-asc.c
+++ b/drivers/tty/serial/st-asc.c
@@ -782,7 +782,9 @@ static struct asc_port *asc_of_get_asc_port(struct platform_device *pdev)
 	if (!np)
 		return NULL;
 
-	id = of_alias_get_id(np, ASC_SERIAL_NAME);
+	id = of_alias_get_id(np, "serial");
+	if (id < 0)
+		id = of_alias_get_id(np, ASC_SERIAL_NAME);
 
 	if (id < 0)
 		id = 0;
-- 
1.9.1


WARNING: multiple messages have this Message-ID (diff)
From: <patrice.chotard@st.com>
To: robh+dt@kernel.org, mark.rutland@arm.com, linux@armlinux.org.uk,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
	gregkh@linuxfoundation.org, jslaby@suse.com,
	linux-serial@vger.kernel.org
Cc: patrice.chotard@st.com
Subject: [PATCH v4 1/3] tty: st-asc: Update tty alias
Date: Wed, 7 Mar 2018 18:35:32 +0100	[thread overview]
Message-ID: <1520444134-30144-2-git-send-email-patrice.chotard@st.com> (raw)
In-Reply-To: <1520444134-30144-1-git-send-email-patrice.chotard@st.com>

From: Patrice Chotard <patrice.chotard@st.com>

Since dtc v1.4.6-9-gaadd0b65c987, aliases property name
must include only lowercase and '-'.

After having updated all STi boards serial aliases from "ttyASN"
to "serialN", st-asc driver need to be updated accordingly as tty
aliases id is retrieved using of_alias_get_id().

Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Rob Herring <robh@kernel.org>
---

v4: _ add Reviewed-by
v3: _ update st-asc driver with "serial" alias prefix and keep "ttyAS" in second choice
v2: _ update st-asc driver with "serial" alias prefix

 drivers/tty/serial/st-asc.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/tty/serial/st-asc.c b/drivers/tty/serial/st-asc.c
index c763253514e9..5f9f01fac6dd 100644
--- a/drivers/tty/serial/st-asc.c
+++ b/drivers/tty/serial/st-asc.c
@@ -782,7 +782,9 @@ static struct asc_port *asc_of_get_asc_port(struct platform_device *pdev)
 	if (!np)
 		return NULL;
 
-	id = of_alias_get_id(np, ASC_SERIAL_NAME);
+	id = of_alias_get_id(np, "serial");
+	if (id < 0)
+		id = of_alias_get_id(np, ASC_SERIAL_NAME);
 
 	if (id < 0)
 		id = 0;
-- 
1.9.1

WARNING: multiple messages have this Message-ID (diff)
From: patrice.chotard@st.com (patrice.chotard at st.com)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v4 1/3] tty: st-asc: Update tty alias
Date: Wed, 7 Mar 2018 18:35:32 +0100	[thread overview]
Message-ID: <1520444134-30144-2-git-send-email-patrice.chotard@st.com> (raw)
In-Reply-To: <1520444134-30144-1-git-send-email-patrice.chotard@st.com>

From: Patrice Chotard <patrice.chotard@st.com>

Since dtc v1.4.6-9-gaadd0b65c987, aliases property name
must include only lowercase and '-'.

After having updated all STi boards serial aliases from "ttyASN"
to "serialN", st-asc driver need to be updated accordingly as tty
aliases id is retrieved using of_alias_get_id().

Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Rob Herring <robh@kernel.org>
---

v4: _ add Reviewed-by
v3: _ update st-asc driver with "serial" alias prefix and keep "ttyAS" in second choice
v2: _ update st-asc driver with "serial" alias prefix

 drivers/tty/serial/st-asc.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/tty/serial/st-asc.c b/drivers/tty/serial/st-asc.c
index c763253514e9..5f9f01fac6dd 100644
--- a/drivers/tty/serial/st-asc.c
+++ b/drivers/tty/serial/st-asc.c
@@ -782,7 +782,9 @@ static struct asc_port *asc_of_get_asc_port(struct platform_device *pdev)
 	if (!np)
 		return NULL;
 
-	id = of_alias_get_id(np, ASC_SERIAL_NAME);
+	id = of_alias_get_id(np, "serial");
+	if (id < 0)
+		id = of_alias_get_id(np, ASC_SERIAL_NAME);
 
 	if (id < 0)
 		id = 0;
-- 
1.9.1

  reply	other threads:[~2018-03-07 17:36 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-07 17:35 [PATCH v4 0/3] Fix STi aliases property name patrice.chotard
2018-03-07 17:35 ` patrice.chotard at st.com
2018-03-07 17:35 ` patrice.chotard
2018-03-07 17:35 ` patrice.chotard [this message]
2018-03-07 17:35   ` [PATCH v4 1/3] tty: st-asc: Update tty alias patrice.chotard at st.com
2018-03-07 17:35   ` patrice.chotard
2018-03-07 17:35 ` [PATCH v4 2/3] ARM: dts: STi: Fix aliases property name for STi boards patrice.chotard
2018-03-07 17:35   ` patrice.chotard at st.com
2018-03-07 17:35   ` patrice.chotard
2018-03-07 17:35 ` [PATCH v4 3/3] ARM: dts: STi: Remove "console=ttyASN" from bootargs " patrice.chotard
2018-03-07 17:35   ` patrice.chotard at st.com
2018-03-07 17:35   ` patrice.chotard
2018-03-14 13:57   ` Greg KH
2018-03-14 13:57     ` Greg KH
2018-03-14 14:53     ` Patrice CHOTARD
2018-03-14 14:53       ` Patrice CHOTARD
2018-03-14 14:53       ` Patrice CHOTARD

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=1520444134-30144-2-git-send-email-patrice.chotard@st.com \
    --to=patrice.chotard@st.com \
    --cc=devicetree@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=jslaby@suse.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@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 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.