All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC] spi-gpio on Odroid-C2 board
@ 2017-01-29 10:33 Slawomir Stepien
  2017-01-30  8:44 ` Neil Armstrong
  0 siblings, 1 reply; 2+ messages in thread
From: Slawomir Stepien @ 2017-01-29 10:33 UTC (permalink / raw)
  To: linus-amlogic

Hi

Are there any issues regarding using spi-gpio on Odroid-C2 board dts file?
I would like to use it but from what I can see dts still doesn't have it?

I tested something like this and is seems to works:

diff --git a/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts b/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts
index 5d28e1cdc998..62104dcd48a6 100644
--- a/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts
+++ b/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts
@@ -135,6 +135,18 @@
                compatible = "mmc-pwrseq-emmc";
                reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>;
        };
+
+       spi-gpio {
+               compatible = "spi-gpio";
+               #address-cells = <1>;
+               #size-cells = <0>;
+               gpio-sck  = <&gpio GPIOX_2 GPIO_ACTIVE_HIGH>;
+               gpio-miso = <&gpio GPIOX_4 GPIO_ACTIVE_HIGH>;
+               gpio-mosi = <&gpio GPIOX_7 GPIO_ACTIVE_HIGH>;
+               cs-gpios  = <&gpio GPIOX_1 GPIO_ACTIVE_HIGH
+                            &gpio GPIOY_14 GPIO_ACTIVE_HIGH>;
+               num-chipselects = <2>;
+       };
 };
 
 &scpi_clocks {

-- 
Slawomir Stepien

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

* [RFC] spi-gpio on Odroid-C2 board
  2017-01-29 10:33 [RFC] spi-gpio on Odroid-C2 board Slawomir Stepien
@ 2017-01-30  8:44 ` Neil Armstrong
  0 siblings, 0 replies; 2+ messages in thread
From: Neil Armstrong @ 2017-01-30  8:44 UTC (permalink / raw)
  To: linus-amlogic

On 01/29/2017 11:33 AM, Slawomir Stepien wrote:
> Hi
> 
> Are there any issues regarding using spi-gpio on Odroid-C2 board dts file?
> I would like to use it but from what I can see dts still doesn't have it?
> 
> I tested something like this and is seems to works:
> 
> diff --git a/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts b/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts
> index 5d28e1cdc998..62104dcd48a6 100644
> --- a/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts
> +++ b/arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts
> @@ -135,6 +135,18 @@
>                 compatible = "mmc-pwrseq-emmc";
>                 reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>;
>         };
> +
> +       spi-gpio {
> +               compatible = "spi-gpio";
> +               #address-cells = <1>;
> +               #size-cells = <0>;
> +               gpio-sck  = <&gpio GPIOX_2 GPIO_ACTIVE_HIGH>;
> +               gpio-miso = <&gpio GPIOX_4 GPIO_ACTIVE_HIGH>;
> +               gpio-mosi = <&gpio GPIOX_7 GPIO_ACTIVE_HIGH>;
> +               cs-gpios  = <&gpio GPIOX_1 GPIO_ACTIVE_HIGH
> +                            &gpio GPIOY_14 GPIO_ACTIVE_HIGH>;
> +               num-chipselects = <2>;
> +       };
>  };
>  
>  &scpi_clocks {
> 

Hi Slawomir,

Thanks for testing the spi-gpio interface, but since these pins are not explicitely used
as SPI, there is no real need to have them in the upstream Odroid-C2 dts file.

Such entries should added locally for each local projects.

Neil

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

end of thread, other threads:[~2017-01-30  8:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-29 10:33 [RFC] spi-gpio on Odroid-C2 board Slawomir Stepien
2017-01-30  8:44 ` Neil Armstrong

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.