* [PATCH] serial/sirf: fixup for changes to pin control
@ 2012-02-16 18:43 Linus Walleij
2012-02-16 19:01 ` Stephen Warren
2012-02-22 9:14 ` Barry Song
0 siblings, 2 replies; 5+ messages in thread
From: Linus Walleij @ 2012-02-16 18:43 UTC (permalink / raw)
To: linux-kernel, linux-arm-kernel
Cc: Stephen Warren, Shawn Guo, Thomas Abraham, Dong Aisheng,
Rajendra Nayak, Haojian Zhuang, Barry Song, Tony Lindgren,
Linus Walleij, linux-serial
We changed the signature of the pin multiplexing functions to
handle any pin business, so fix up the Sirf driver to call this
new interface and rename some variables to make the semantics
understandable.
Cc: linux-serial@vger.kernel.org
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
drivers/tty/serial/sirfsoc_uart.c | 20 ++++++++++----------
drivers/tty/serial/sirfsoc_uart.h | 2 +-
2 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/drivers/tty/serial/sirfsoc_uart.c b/drivers/tty/serial/sirfsoc_uart.c
index a60523f..c1a871e 100644
--- a/drivers/tty/serial/sirfsoc_uart.c
+++ b/drivers/tty/serial/sirfsoc_uart.c
@@ -22,7 +22,7 @@
#include <linux/io.h>
#include <asm/irq.h>
#include <asm/mach/irq.h>
-#include <linux/pinctrl/pinmux.h>
+#include <linux/pinctrl/consumer.h>
#include "sirfsoc_uart.h"
@@ -673,12 +673,12 @@ int sirfsoc_uart_probe(struct platform_device *pdev)
port->irq = res->start;
if (sirfport->hw_flow_ctrl) {
- sirfport->pmx = pinmux_get(&pdev->dev, NULL);
- ret = IS_ERR(sirfport->pmx);
+ sirfport->p = pinctrl_get(&pdev->dev, NULL);
+ ret = IS_ERR(sirfport->p);
if (ret)
- goto pmx_err;
+ goto pin_err;
- pinmux_enable(sirfport->pmx);
+ pinctrl_enable(sirfport->p);
}
port->ops = &sirfsoc_uart_ops;
@@ -696,10 +696,10 @@ int sirfsoc_uart_probe(struct platform_device *pdev)
port_err:
platform_set_drvdata(pdev, NULL);
if (sirfport->hw_flow_ctrl) {
- pinmux_disable(sirfport->pmx);
- pinmux_put(sirfport->pmx);
+ pinctrl_disable(sirfport->p);
+ pinctrl_put(sirfport->p);
}
-pmx_err:
+pin_err:
irq_err:
devm_iounmap(&pdev->dev, port->membase);
err:
@@ -712,8 +712,8 @@ static int sirfsoc_uart_remove(struct platform_device *pdev)
struct uart_port *port = &sirfport->port;
platform_set_drvdata(pdev, NULL);
if (sirfport->hw_flow_ctrl) {
- pinmux_disable(sirfport->pmx);
- pinmux_put(sirfport->pmx);
+ pinctrl_disable(sirfport->p);
+ pinctrl_put(sirfport->p);
}
devm_iounmap(&pdev->dev, port->membase);
uart_remove_one_port(&sirfsoc_uart_drv, port);
diff --git a/drivers/tty/serial/sirfsoc_uart.h b/drivers/tty/serial/sirfsoc_uart.h
index fc64260..6e207fd 100644
--- a/drivers/tty/serial/sirfsoc_uart.h
+++ b/drivers/tty/serial/sirfsoc_uart.h
@@ -162,7 +162,7 @@ struct sirfsoc_uart_port {
unsigned char ms_enabled;
struct uart_port port;
- struct pinmux *pmx;
+ struct pinctrl *p;
};
/* Hardware Flow Control */
--
1.7.7.6
^ permalink raw reply related [flat|nested] 5+ messages in thread* RE: [PATCH] serial/sirf: fixup for changes to pin control
2012-02-16 18:43 [PATCH] serial/sirf: fixup for changes to pin control Linus Walleij
@ 2012-02-16 19:01 ` Stephen Warren
2012-02-16 19:39 ` Linus Walleij
2012-02-22 9:14 ` Barry Song
1 sibling, 1 reply; 5+ messages in thread
From: Stephen Warren @ 2012-02-16 19:01 UTC (permalink / raw)
To: Linus Walleij, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org
Cc: Shawn Guo, Thomas Abraham, Dong Aisheng, Rajendra Nayak,
Haojian Zhuang, Barry Song, Tony Lindgren,
linux-serial@vger.kernel.org
Linus Walleij wrote at Thursday, February 16, 2012 11:44 AM:
> We changed the signature of the pin multiplexing functions to
> handle any pin business, so fix up the Sirf driver to call this
> new interface and rename some variables to make the semantics
> understandable.
>
> Cc: linux-serial@vger.kernel.org
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Looks good to me for now.
I'll have to do another similar change when I implement the pinctrl_get
API changes we discussed at Linaro Connect (I should start implementing
that today), but I guess that's no big deal.
Should this patch be put into the pinctrl tree since that's where the
API changed, perhaps even squashed into the original commit to avoid
git bisect breakage, unless your branch needs to be stable? Otherwise,
this change will conflict with my future similar change if pulled for
the same kernel version.
--
nvpublic
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] serial/sirf: fixup for changes to pin control
2012-02-16 19:01 ` Stephen Warren
@ 2012-02-16 19:39 ` Linus Walleij
2012-02-16 19:48 ` Greg KH
0 siblings, 1 reply; 5+ messages in thread
From: Linus Walleij @ 2012-02-16 19:39 UTC (permalink / raw)
To: Stephen Warren
Cc: linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, Shawn Guo, Thomas Abraham,
Dong Aisheng, Rajendra Nayak, Haojian Zhuang, Barry Song,
Tony Lindgren, linux-serial@vger.kernel.org
On Thu, Feb 16, 2012 at 8:01 PM, Stephen Warren <swarren@nvidia.com> wrote:
> Should this patch be put into the pinctrl tree since that's where the
> API changed, perhaps even squashed into the original commit to avoid
> git bisect breakage, unless your branch needs to be stable?
Hm yeah I will for sure put it into the pinctrl tree.
The Sirf doesn't even have a defconfig so it was just my memory of
the Sirf that got me to remember it. I might squash if I don't get any
comments on this patch.
> Otherwise,
> this change will conflict with my future similar change if pulled for
> the same kernel version.
It'll be in linux-next tomorrow or so.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] serial/sirf: fixup for changes to pin control
2012-02-16 19:39 ` Linus Walleij
@ 2012-02-16 19:48 ` Greg KH
0 siblings, 0 replies; 5+ messages in thread
From: Greg KH @ 2012-02-16 19:48 UTC (permalink / raw)
To: Linus Walleij
Cc: Stephen Warren, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, Shawn Guo, Thomas Abraham,
Dong Aisheng, Rajendra Nayak, Haojian Zhuang, Barry Song,
Tony Lindgren, linux-serial@vger.kernel.org
On Thu, Feb 16, 2012 at 08:39:39PM +0100, Linus Walleij wrote:
> On Thu, Feb 16, 2012 at 8:01 PM, Stephen Warren <swarren@nvidia.com> wrote:
>
> > Should this patch be put into the pinctrl tree since that's where the
> > API changed, perhaps even squashed into the original commit to avoid
> > git bisect breakage, unless your branch needs to be stable?
>
> Hm yeah I will for sure put it into the pinctrl tree.
Great, please feel free to add:
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] serial/sirf: fixup for changes to pin control
2012-02-16 18:43 [PATCH] serial/sirf: fixup for changes to pin control Linus Walleij
2012-02-16 19:01 ` Stephen Warren
@ 2012-02-22 9:14 ` Barry Song
1 sibling, 0 replies; 5+ messages in thread
From: Barry Song @ 2012-02-22 9:14 UTC (permalink / raw)
To: Linus Walleij
Cc: linux-kernel, linux-arm-kernel, Stephen Warren, Shawn Guo,
Thomas Abraham, Dong Aisheng, Rajendra Nayak, Haojian Zhuang,
Tony Lindgren, linux-serial, DL-SHA-WorkGroupLinux
2012/2/17 Linus Walleij <linus.walleij@linaro.org>:
> We changed the signature of the pin multiplexing functions to
> handle any pin business, so fix up the Sirf driver to call this
> new interface and rename some variables to make the semantics
> understandable.
>
> Cc: linux-serial@vger.kernel.org
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Barry Song <Baohua.Song@csr.com>
> ---
> drivers/tty/serial/sirfsoc_uart.c | 20 ++++++++++----------
> drivers/tty/serial/sirfsoc_uart.h | 2 +-
> 2 files changed, 11 insertions(+), 11 deletions(-)
>
> diff --git a/drivers/tty/serial/sirfsoc_uart.c b/drivers/tty/serial/sirfsoc_uart.c
> index a60523f..c1a871e 100644
> --- a/drivers/tty/serial/sirfsoc_uart.c
> +++ b/drivers/tty/serial/sirfsoc_uart.c
> @@ -22,7 +22,7 @@
> #include <linux/io.h>
> #include <asm/irq.h>
> #include <asm/mach/irq.h>
> -#include <linux/pinctrl/pinmux.h>
> +#include <linux/pinctrl/consumer.h>
>
> #include "sirfsoc_uart.h"
>
> @@ -673,12 +673,12 @@ int sirfsoc_uart_probe(struct platform_device *pdev)
> port->irq = res->start;
>
> if (sirfport->hw_flow_ctrl) {
> - sirfport->pmx = pinmux_get(&pdev->dev, NULL);
> - ret = IS_ERR(sirfport->pmx);
> + sirfport->p = pinctrl_get(&pdev->dev, NULL);
> + ret = IS_ERR(sirfport->p);
> if (ret)
> - goto pmx_err;
> + goto pin_err;
>
> - pinmux_enable(sirfport->pmx);
> + pinctrl_enable(sirfport->p);
> }
>
> port->ops = &sirfsoc_uart_ops;
> @@ -696,10 +696,10 @@ int sirfsoc_uart_probe(struct platform_device *pdev)
> port_err:
> platform_set_drvdata(pdev, NULL);
> if (sirfport->hw_flow_ctrl) {
> - pinmux_disable(sirfport->pmx);
> - pinmux_put(sirfport->pmx);
> + pinctrl_disable(sirfport->p);
> + pinctrl_put(sirfport->p);
> }
> -pmx_err:
> +pin_err:
> irq_err:
> devm_iounmap(&pdev->dev, port->membase);
> err:
> @@ -712,8 +712,8 @@ static int sirfsoc_uart_remove(struct platform_device *pdev)
> struct uart_port *port = &sirfport->port;
> platform_set_drvdata(pdev, NULL);
> if (sirfport->hw_flow_ctrl) {
> - pinmux_disable(sirfport->pmx);
> - pinmux_put(sirfport->pmx);
> + pinctrl_disable(sirfport->p);
> + pinctrl_put(sirfport->p);
> }
> devm_iounmap(&pdev->dev, port->membase);
> uart_remove_one_port(&sirfsoc_uart_drv, port);
> diff --git a/drivers/tty/serial/sirfsoc_uart.h b/drivers/tty/serial/sirfsoc_uart.h
> index fc64260..6e207fd 100644
> --- a/drivers/tty/serial/sirfsoc_uart.h
> +++ b/drivers/tty/serial/sirfsoc_uart.h
> @@ -162,7 +162,7 @@ struct sirfsoc_uart_port {
> unsigned char ms_enabled;
>
> struct uart_port port;
> - struct pinmux *pmx;
> + struct pinctrl *p;
> };
>
> /* Hardware Flow Control */
> --
> 1.7.7.6
>
--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-02-22 9:15 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-16 18:43 [PATCH] serial/sirf: fixup for changes to pin control Linus Walleij
2012-02-16 19:01 ` Stephen Warren
2012-02-16 19:39 ` Linus Walleij
2012-02-16 19:48 ` Greg KH
2012-02-22 9:14 ` Barry Song
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox