diff mbox

[V3,3/4] dt-bindings: serial: add a new compatible string for SC9860

Message ID 1488435730-6711-4-git-send-email-chunyan.zhang@spreadtrum.com
State Changes Requested, archived
Headers show

Commit Message

Chunyan Zhang March 2, 2017, 6:22 a.m. UTC
SC9860 use the same serial device, so added a new compatible string to
support SC9860 as well, also added an example of how to describe this
serial device in DT.

Signed-off-by: Chunyan Zhang <chunyan.zhang@spreadtrum.com>
---
 Documentation/devicetree/bindings/serial/sprd-uart.txt | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

Comments

Rob Herring (Arm) March 3, 2017, 6:21 a.m. UTC | #1
On Thu, Mar 02, 2017 at 02:22:09PM +0800, Chunyan Zhang wrote:
> SC9860 use the same serial device, so added a new compatible string to
> support SC9860 as well, also added an example of how to describe this
> serial device in DT.
> 
> Signed-off-by: Chunyan Zhang <chunyan.zhang@spreadtrum.com>
> ---
>  Documentation/devicetree/bindings/serial/sprd-uart.txt | 15 ++++++++++++++-
>  1 file changed, 14 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/serial/sprd-uart.txt b/Documentation/devicetree/bindings/serial/sprd-uart.txt
> index 2aff0f2..8bd8144 100644
> --- a/Documentation/devicetree/bindings/serial/sprd-uart.txt
> +++ b/Documentation/devicetree/bindings/serial/sprd-uart.txt
> @@ -1,7 +1,20 @@
>  * Spreadtrum serial UART
>  
>  Required properties:
> -- compatible: must be "sprd,sc9836-uart"
> +- compatible must contain:
> +  * "sprd,sc9836-uart" for SC9836 and all Spreadtrum SoCs
> +  This also can be specific with:
> +  * "sprd,sc9860-uart" for SC9860

Just say:

- compatible: must be one of:
	"sprd,sc9836-uart"
	"sprd,sc9860-uart", "sprd,sc9836-uart"

> +
>  - reg: offset and length of the register set for the device
>  - interrupts: exactly one interrupt specifier
>  - clocks: phandles to input clocks.
> +
> +Example:
> +	uart0: serial@70000000 {
> +		compatible = "sprd,sc9860-uart",
> +			     "sprd,sc9836-uart";
> +		reg = <0x000000 0x100>;

unit address doesn't match the reg property.

> +		interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
> +		clocks = <&ext_26m>;
> +	};
> -- 
> 2.7.4
> 
--
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
Chunyan Zhang March 3, 2017, 10:48 a.m. UTC | #2
On 3 March 2017 at 14:21, Rob Herring <robh@kernel.org> wrote:
> On Thu, Mar 02, 2017 at 02:22:09PM +0800, Chunyan Zhang wrote:
>> SC9860 use the same serial device, so added a new compatible string to
>> support SC9860 as well, also added an example of how to describe this
>> serial device in DT.
>>
>> Signed-off-by: Chunyan Zhang <chunyan.zhang@spreadtrum.com>
>> ---
>>  Documentation/devicetree/bindings/serial/sprd-uart.txt | 15 ++++++++++++++-
>>  1 file changed, 14 insertions(+), 1 deletion(-)
>>
>> diff --git a/Documentation/devicetree/bindings/serial/sprd-uart.txt b/Documentation/devicetree/bindings/serial/sprd-uart.txt
>> index 2aff0f2..8bd8144 100644
>> --- a/Documentation/devicetree/bindings/serial/sprd-uart.txt
>> +++ b/Documentation/devicetree/bindings/serial/sprd-uart.txt
>> @@ -1,7 +1,20 @@
>>  * Spreadtrum serial UART
>>
>>  Required properties:
>> -- compatible: must be "sprd,sc9836-uart"
>> +- compatible must contain:
>> +  * "sprd,sc9836-uart" for SC9836 and all Spreadtrum SoCs
>> +  This also can be specific with:
>> +  * "sprd,sc9860-uart" for SC9860
>
> Just say:
>
> - compatible: must be one of:
>         "sprd,sc9836-uart"
>         "sprd,sc9860-uart", "sprd,sc9836-uart"
>
>> +
>>  - reg: offset and length of the register set for the device
>>  - interrupts: exactly one interrupt specifier
>>  - clocks: phandles to input clocks.
>> +
>> +Example:
>> +     uart0: serial@70000000 {
>> +             compatible = "sprd,sc9860-uart",
>> +                          "sprd,sc9836-uart";
>> +             reg = <0x000000 0x100>;
>
> unit address doesn't match the reg property.

OK, I will revise dts file accordingly.

Thanks,
Chunyan

>
>> +             interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
>> +             clocks = <&ext_26m>;
>> +     };
>> --
>> 2.7.4
>>
--
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/serial/sprd-uart.txt b/Documentation/devicetree/bindings/serial/sprd-uart.txt
index 2aff0f2..8bd8144 100644
--- a/Documentation/devicetree/bindings/serial/sprd-uart.txt
+++ b/Documentation/devicetree/bindings/serial/sprd-uart.txt
@@ -1,7 +1,20 @@ 
 * Spreadtrum serial UART
 
 Required properties:
-- compatible: must be "sprd,sc9836-uart"
+- compatible must contain:
+  * "sprd,sc9836-uart" for SC9836 and all Spreadtrum SoCs
+  This also can be specific with:
+  * "sprd,sc9860-uart" for SC9860
+
 - reg: offset and length of the register set for the device
 - interrupts: exactly one interrupt specifier
 - clocks: phandles to input clocks.
+
+Example:
+	uart0: serial@70000000 {
+		compatible = "sprd,sc9860-uart",
+			     "sprd,sc9836-uart";
+		reg = <0x000000 0x100>;
+		interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&ext_26m>;
+	};