Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1357695 > unrolled thread

[PATCH] gpio: 74x164: add dt support for nxp's 74x594

Started byNicolas Saenz Julienne <nicolassaenzj@gmail.com>
First post2016-03-15 00:40 +0100
Last post2016-03-15 16:30 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] gpio: 74x164: add dt support for nxp's 74x594 Nicolas Saenz Julienne <nicolassaenzj@gmail.com> - 2016-03-15 00:40 +0100
    Re: [PATCH] gpio: 74x164: add dt support for nxp's 74x594 Geert Uytterhoeven <geert@linux-m68k.org> - 2016-03-15 16:30 +0100

#1357695 — [PATCH] gpio: 74x164: add dt support for nxp's 74x594

FromNicolas Saenz Julienne <nicolassaenzj@gmail.com>
Date2016-03-15 00:40 +0100
Subject[PATCH] gpio: 74x164: add dt support for nxp's 74x594
Message-ID<rcKfD-2br-7@gated-at.bofh.it>
The chip is also an 8 bit shift register which works out of the box as a GPO
expander with this patch

Signed-off-by: Nicolas Saenz Julienne <nicolassaenzj@gmail.com>
---
 Documentation/devicetree/bindings/gpio/gpio-74x164.txt | 4 +++-
 drivers/gpio/gpio-74x164.c                             | 1 +
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/gpio/gpio-74x164.txt b/Documentation/devicetree/bindings/gpio/gpio-74x164.txt
index cc26080..ce1b223 100644
--- a/Documentation/devicetree/bindings/gpio/gpio-74x164.txt
+++ b/Documentation/devicetree/bindings/gpio/gpio-74x164.txt
@@ -1,7 +1,9 @@
 * Generic 8-bits shift register GPIO driver
 
 Required properties:
-- compatible : Should be "fairchild,74hc595"
+- compatible: Should contain one of the following:
+    "fairchild,74hc595"
+    "nxp,74lvc594"
 - reg : chip select number
 - gpio-controller : Marks the device node as a gpio controller.
 - #gpio-cells : Should be two.  The first cell is the pin number and
diff --git a/drivers/gpio/gpio-74x164.c b/drivers/gpio/gpio-74x164.c
index c81224f..ebd0d1a 100644
--- a/drivers/gpio/gpio-74x164.c
+++ b/drivers/gpio/gpio-74x164.c
@@ -153,6 +153,7 @@ static int gen_74x164_remove(struct spi_device *spi)
 
 static const struct of_device_id gen_74x164_dt_ids[] = {
 	{ .compatible = "fairchild,74hc595" },
+	{ .compatible = "nxp,74lvc594" },
 	{},
 };
 MODULE_DEVICE_TABLE(of, gen_74x164_dt_ids);
-- 
2.5.0

[toc] | [next] | [standalone]


#1358102

FromGeert Uytterhoeven <geert@linux-m68k.org>
Date2016-03-15 16:30 +0100
Message-ID<rcZ50-3S4-15@gated-at.bofh.it>
In reply to#1357695
On Tue, Mar 15, 2016 at 12:32 AM, Nicolas Saenz Julienne
<nicolassaenzj@gmail.com> wrote:
> The chip is also an 8 bit shift register which works out of the box as a GPO
> expander with this patch
>
> Signed-off-by: Nicolas Saenz Julienne <nicolassaenzj@gmail.com>
> ---
>  Documentation/devicetree/bindings/gpio/gpio-74x164.txt | 4 +++-
>  drivers/gpio/gpio-74x164.c                             | 1 +
>  2 files changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/gpio/gpio-74x164.txt b/Documentation/devicetree/bindings/gpio/gpio-74x164.txt
> index cc26080..ce1b223 100644
> --- a/Documentation/devicetree/bindings/gpio/gpio-74x164.txt
> +++ b/Documentation/devicetree/bindings/gpio/gpio-74x164.txt
> @@ -1,7 +1,9 @@
>  * Generic 8-bits shift register GPIO driver
>
>  Required properties:
> -- compatible : Should be "fairchild,74hc595"
> +- compatible: Should contain one of the following:
> +    "fairchild,74hc595"
> +    "nxp,74lvc594"

Why did you choose the "lvc" variant?

Ideally, you want to put the oldest "manuf,74x594" variant here.
I once read it was Motorola who invented the 7459x parts, to interface with
SPI.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web