diff mbox

[2/3] dt-bindings: spi: document bcm63xx HS SPI devicetree bindings

Message ID 20170222131940.31085-2-jonas.gorski@gmail.com
State Not Applicable, archived
Headers show

Commit Message

Jonas Gorski Feb. 22, 2017, 1:19 p.m. UTC
Add documentation for the bindings of the high speed SPI controller found
on newer bcm63xx SoCs.

Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
---
 .../devicetree/bindings/spi/spi-bcm63xx-hsspi.txt  | 35 ++++++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt

Comments

Rob Herring Feb. 27, 2017, 10:41 p.m. UTC | #1
On Wed, Feb 22, 2017 at 02:19:39PM +0100, Jonas Gorski wrote:
> Add documentation for the bindings of the high speed SPI controller found
> on newer bcm63xx SoCs.
> 
> Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
> ---
>  .../devicetree/bindings/spi/spi-bcm63xx-hsspi.txt  | 35 ++++++++++++++++++++++
>  1 file changed, 35 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt

Acked-by: Rob Herring <robh@kernel.org>
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Florian Fainelli Feb. 27, 2017, 10:49 p.m. UTC | #2
On 02/22/2017 05:19 AM, Jonas Gorski wrote:
> Add documentation for the bindings of the high speed SPI controller found
> on newer bcm63xx SoCs.
> 
> Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
> ---
>  .../devicetree/bindings/spi/spi-bcm63xx-hsspi.txt  | 35 ++++++++++++++++++++++
>  1 file changed, 35 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
> 
> diff --git a/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt b/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
> new file mode 100644
> index 000000000000..3b0a2220b896
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
> @@ -0,0 +1,35 @@
> +Binding for Broadcom BCM6328 SPI controller
> +
> +Required properties:
> +- compatible: must contain of "brcm,bcm6328-hsspi".
> +- reg: Base address and size of the controllers memory area.
> +- interrupts: Interrupt for the SPI block.
> +- clocks: phandle of the SPI clock.
> +- clock-names: must be "hsspi".
> +- #address-cells: <1>, as required by generic SPI binding.
> +- #size-cells: <0>, also as required by generic SPI binding.
> +
> +Optional properties:
> +- num-cs: some controllers have less than 8 cs signals. Defaults to 8
> +  if absent.
> +- clocks: a second handle for the PLL clock.
> +- clock-names: must be named "pll", if present.

I have not found chips where the PLL may be optional, but there may be
ways to have the same PLL and UBUS clocks feeding into the HSSPI block.

Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Jonas Gorski Feb. 28, 2017, 1:11 p.m. UTC | #3
Hi,

On 27 February 2017 at 23:49, Florian Fainelli <f.fainelli@gmail.com> wrote:
> On 02/22/2017 05:19 AM, Jonas Gorski wrote:
>> Add documentation for the bindings of the high speed SPI controller found
>> on newer bcm63xx SoCs.
>>
>> Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
>> ---
>>  .../devicetree/bindings/spi/spi-bcm63xx-hsspi.txt  | 35 ++++++++++++++++++++++
>>  1 file changed, 35 insertions(+)
>>  create mode 100644 Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
>>
>> diff --git a/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt b/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
>> new file mode 100644
>> index 000000000000..3b0a2220b896
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
>> @@ -0,0 +1,35 @@
>> +Binding for Broadcom BCM6328 SPI controller

I missed a "High Speed" here.

>> +
>> +Required properties:
>> +- compatible: must contain of "brcm,bcm6328-hsspi".
>> +- reg: Base address and size of the controllers memory area.
>> +- interrupts: Interrupt for the SPI block.
>> +- clocks: phandle of the SPI clock.
>> +- clock-names: must be "hsspi".
>> +- #address-cells: <1>, as required by generic SPI binding.
>> +- #size-cells: <0>, also as required by generic SPI binding.
>> +
>> +Optional properties:
>> +- num-cs: some controllers have less than 8 cs signals. Defaults to 8
>> +  if absent.
>> +- clocks: a second handle for the PLL clock.
>> +- clock-names: must be named "pll", if present.
>
> I have not found chips where the PLL may be optional, but there may be
> ways to have the same PLL and UBUS clocks feeding into the HSSPI block.

Indeed, I guess I make it just non-optional. Having it as an optional
clock was (not intentionally) more describing the driver, not the
hardware. If there is ever only one clock, one could just pass it
twice. I'll update and send a V2.


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

Patch

diff --git a/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt b/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
new file mode 100644
index 000000000000..3b0a2220b896
--- /dev/null
+++ b/Documentation/devicetree/bindings/spi/spi-bcm63xx-hsspi.txt
@@ -0,0 +1,35 @@ 
+Binding for Broadcom BCM6328 SPI controller
+
+Required properties:
+- compatible: must contain of "brcm,bcm6328-hsspi".
+- reg: Base address and size of the controllers memory area.
+- interrupts: Interrupt for the SPI block.
+- clocks: phandle of the SPI clock.
+- clock-names: must be "hsspi".
+- #address-cells: <1>, as required by generic SPI binding.
+- #size-cells: <0>, also as required by generic SPI binding.
+
+Optional properties:
+- num-cs: some controllers have less than 8 cs signals. Defaults to 8
+  if absent.
+- clocks: a second handle for the PLL clock.
+- clock-names: must be named "pll", if present.
+
+Child nodes as per the generic SPI binding.
+
+Example:
+
+	spi@10001000 {
+		compatible = "brcm,bcm6328-hsspi";
+		reg = <0x10001000 0x600>;
+
+		interrupts = <29>;
+
+		clocks = <&clkctl 9>, <&hsspi_pll>;
+		clock-names = "hsspi", "pll";
+
+		num-cs = <2>;
+
+		#address-cells = <1>;
+		#size-cells = <0>;
+	};