diff mbox

[v6,1/4,media] exynos-scaler: Add DT bindings for SCALER driver

Message ID 1395213196-25972-2-git-send-email-shaik.ameer@samsung.com
State Superseded, archived
Headers show

Commit Message

Shaik Ameer Basha March 19, 2014, 7:13 a.m. UTC
This patch adds the DT binding documentation for the Exynos5420/5410
based SCALER device driver.

Signed-off-by: Shaik Ameer Basha <shaik.ameer@samsung.com>
Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
---
 .../devicetree/bindings/media/exynos5-scaler.txt   |   24 ++++++++++++++++++++
 1 file changed, 24 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/media/exynos5-scaler.txt

Comments

Laurent Pinchart March 19, 2014, 11:31 a.m. UTC | #1
Hi Shaik,

Thank you for the patch.

On Wednesday 19 March 2014 12:43:13 Shaik Ameer Basha wrote:
> This patch adds the DT binding documentation for the Exynos5420/5410
> based SCALER device driver.
> 
> Signed-off-by: Shaik Ameer Basha <shaik.ameer@samsung.com>
> Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
> ---
>  .../devicetree/bindings/media/exynos5-scaler.txt   |   24 +++++++++++++++++
>  1 file changed, 24 insertions(+)
>  create mode 100644
> Documentation/devicetree/bindings/media/exynos5-scaler.txt
> 
> diff --git a/Documentation/devicetree/bindings/media/exynos5-scaler.txt
> b/Documentation/devicetree/bindings/media/exynos5-scaler.txt new file mode
> 100644
> index 0000000..e1dd465
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/media/exynos5-scaler.txt
> @@ -0,0 +1,24 @@
> +* Samsung Exynos5 SCALER device
> +
> +SCALER is used for scaling, blending, color fill and color space
> +conversion on EXYNOS[5420/5410] SoCs.
> +
> +Required properties:
> +- compatible: should be "samsung,exynos5420-scaler" or
> +			"samsung,exynos5410-scaler"
> +- reg: should contain SCALER physical address location and length
> +- interrupts: should contain SCALER interrupt specifier
> +- clocks: should contain the SCALER clock phandle and specifier pair for
> +		each clock listed in clock-names property, according to
> +		the common clock bindings
> +- clock-names: should contain exactly one entry
> +		- "scaler" - IP bus clock

I'm not too familiar with the Exynos platform, but wouldn't it make sense to 
use a common name across IP cores for interface and function clocks ?

> +Example:
> +	scaler_0: scaler@12800000 {
> +		compatible = "samsung,exynos5420-scaler";
> +		reg = <0x12800000 0x1000>;
> +		interrupts = <0 220 0>;
> +		clocks = <&clock 381>;
> +		clock-names = "scaler";
> +	};
Sylwester Nawrocki March 19, 2014, 11:55 a.m. UTC | #2
Hi,

On 19/03/14 12:31, Laurent Pinchart wrote:
>> +++ b/Documentation/devicetree/bindings/media/exynos5-scaler.txt
>> > @@ -0,0 +1,24 @@
>> > +* Samsung Exynos5 SCALER device
>> > +
>> > +SCALER is used for scaling, blending, color fill and color space
>> > +conversion on EXYNOS[5420/5410] SoCs.
>> > +
>> > +Required properties:
>> > +- compatible: should be "samsung,exynos5420-scaler" or
>> > +			"samsung,exynos5410-scaler"
>> > +- reg: should contain SCALER physical address location and length
>> > +- interrupts: should contain SCALER interrupt specifier
>> > +- clocks: should contain the SCALER clock phandle and specifier pair for
>> > +		each clock listed in clock-names property, according to
>> > +		the common clock bindings
>> > +- clock-names: should contain exactly one entry
>> > +		- "scaler" - IP bus clock
>
> I'm not too familiar with the Exynos platform, but wouldn't it make sense to 
> use a common name across IP cores for interface and function clocks ?

Certainly it would, I proposed that when the exynos clock controller
driver was posted, quite long time ago. Unfortunately it wasn't followed
up. One of serious reasons was that there are common drivers for
multiple Samsung platforms (also the ones not reworked to support dt) and
thus changing the clock names would be problematic - driver would still
need to handle multiple clock names.
But for this driver a common name like "gate" could be better IMHO.

Regards,
Sylwester
--
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
Laurent Pinchart March 19, 2014, 11:59 a.m. UTC | #3
Hi Sylwester,

On Wednesday 19 March 2014 12:55:21 Sylwester Nawrocki wrote:
> On 19/03/14 12:31, Laurent Pinchart wrote:
> >> +++ b/Documentation/devicetree/bindings/media/exynos5-scaler.txt
> >> 
> >> > @@ -0,0 +1,24 @@
> >> > +* Samsung Exynos5 SCALER device
> >> > +
> >> > +SCALER is used for scaling, blending, color fill and color space
> >> > +conversion on EXYNOS[5420/5410] SoCs.
> >> > +
> >> > +Required properties:
> >> > +- compatible: should be "samsung,exynos5420-scaler" or
> >> > +			"samsung,exynos5410-scaler"
> >> > +- reg: should contain SCALER physical address location and length
> >> > +- interrupts: should contain SCALER interrupt specifier
> >> > +- clocks: should contain the SCALER clock phandle and specifier pair
> >> > for
> >> > +		each clock listed in clock-names property, according to
> >> > +		the common clock bindings
> >> > +- clock-names: should contain exactly one entry
> >> > +		- "scaler" - IP bus clock
> > 
> > I'm not too familiar with the Exynos platform, but wouldn't it make sense
> > to use a common name across IP cores for interface and function clocks ?
> Certainly it would, I proposed that when the exynos clock controller
> driver was posted, quite long time ago. Unfortunately it wasn't followed
> up. One of serious reasons was that there are common drivers for
> multiple Samsung platforms (also the ones not reworked to support dt) and
> thus changing the clock names would be problematic - driver would still
> need to handle multiple clock names.
> But for this driver a common name like "gate" could be better IMHO.

OMAP uses "ick" for the interface clock and "fck" for the function clock. Do 
you think it would make sense to standardize on "fck" across SoC families ?
Tomasz Figa March 19, 2014, 12:02 p.m. UTC | #4
Hi Laurent,

On 19.03.2014 12:31, Laurent Pinchart wrote:
> Hi Shaik,
>
> Thank you for the patch.
>
> On Wednesday 19 March 2014 12:43:13 Shaik Ameer Basha wrote:
>> This patch adds the DT binding documentation for the Exynos5420/5410
>> based SCALER device driver.
>>
>> Signed-off-by: Shaik Ameer Basha <shaik.ameer@samsung.com>
>> Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
>> ---
>>   .../devicetree/bindings/media/exynos5-scaler.txt   |   24 +++++++++++++++++
>>   1 file changed, 24 insertions(+)
>>   create mode 100644
>> Documentation/devicetree/bindings/media/exynos5-scaler.txt
>>
>> diff --git a/Documentation/devicetree/bindings/media/exynos5-scaler.txt
>> b/Documentation/devicetree/bindings/media/exynos5-scaler.txt new file mode
>> 100644
>> index 0000000..e1dd465
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/media/exynos5-scaler.txt
>> @@ -0,0 +1,24 @@
>> +* Samsung Exynos5 SCALER device
>> +
>> +SCALER is used for scaling, blending, color fill and color space
>> +conversion on EXYNOS[5420/5410] SoCs.
>> +
>> +Required properties:
>> +- compatible: should be "samsung,exynos5420-scaler" or
>> +			"samsung,exynos5410-scaler"
>> +- reg: should contain SCALER physical address location and length
>> +- interrupts: should contain SCALER interrupt specifier
>> +- clocks: should contain the SCALER clock phandle and specifier pair for
>> +		each clock listed in clock-names property, according to
>> +		the common clock bindings
>> +- clock-names: should contain exactly one entry
>> +		- "scaler" - IP bus clock
>
> I'm not too familiar with the Exynos platform, but wouldn't it make sense to
> use a common name across IP cores for interface and function clocks ?

Yes, it would definitely make sense, provided we are starting from 
scratch, but due to the lack of listed IP clock inputs in documentation, 
we ended with a custom of naming the inputs after SoC clocks of first 
SoC used with such driver. This showed up long before adoption of DT and 
common clocks on Samsung platform and I'd say it would be hard to get 
rid of it now.

Anyway, as long as clock names are well specified in binding 
documentation, it should be fine. So, from me it's a

Reviewed-by: Tomasz Figa <t.figa@samsung.com>

Best regards,
Tomasz
--
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
Sylwester Nawrocki March 19, 2014, 12:33 p.m. UTC | #5
Hi Laurent,

On 19/03/14 12:59, Laurent Pinchart wrote:
> On Wednesday 19 March 2014 12:55:21 Sylwester Nawrocki wrote:
>> > On 19/03/14 12:31, Laurent Pinchart wrote:
>>>> > >> +++ b/Documentation/devicetree/bindings/media/exynos5-scaler.txt
>>>> > >> 
>>>>> > >> > @@ -0,0 +1,24 @@
>>>>> > >> > +* Samsung Exynos5 SCALER device
>>>>> > >> > +
>>>>> > >> > +SCALER is used for scaling, blending, color fill and color space
>>>>> > >> > +conversion on EXYNOS[5420/5410] SoCs.
>>>>> > >> > +
>>>>> > >> > +Required properties:
>>>>> > >> > +- compatible: should be "samsung,exynos5420-scaler" or
>>>>> > >> > +			"samsung,exynos5410-scaler"
>>>>> > >> > +- reg: should contain SCALER physical address location and length
>>>>> > >> > +- interrupts: should contain SCALER interrupt specifier
>>>>> > >> > +- clocks: should contain the SCALER clock phandle and specifier pair
>>>>> > >> > for
>>>>> > >> > +		each clock listed in clock-names property, according to
>>>>> > >> > +		the common clock bindings
>>>>> > >> > +- clock-names: should contain exactly one entry
>>>>> > >> > +		- "scaler" - IP bus clock
>>> > > 
>>> > > I'm not too familiar with the Exynos platform, but wouldn't it make sense
>>> > > to use a common name across IP cores for interface and function clocks ?
>> > Certainly it would, I proposed that when the exynos clock controller
>> > driver was posted, quite long time ago. Unfortunately it wasn't followed
>> > up. One of serious reasons was that there are common drivers for
>> > multiple Samsung platforms (also the ones not reworked to support dt) and
>> > thus changing the clock names would be problematic - driver would still
>> > need to handle multiple clock names.
>> > But for this driver a common name like "gate" could be better IMHO.
>
> OMAP uses "ick" for the interface clock and "fck" for the function clock. Do 
> you think it would make sense to standardize on "fck" across SoC families ?

Not sure if it could be future proof, I guess where it isn't bound to other
issues and the names could be chosen freely - we could try to use standard
names. OTOH it could obfuscate things a bit. As far as Samsung platforms 
are concerned, the function clock names are usually in form of SCLK_[IP_NAME],
"sclk" seems to be an abbreviation of "special clock".
It is also not always clear which clock is the interface clock and which is
the function clock. The "special clocks" are generally referred to as the IP 
block clocks.

--
Regards,
Sylwester
--
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/media/exynos5-scaler.txt b/Documentation/devicetree/bindings/media/exynos5-scaler.txt
new file mode 100644
index 0000000..e1dd465
--- /dev/null
+++ b/Documentation/devicetree/bindings/media/exynos5-scaler.txt
@@ -0,0 +1,24 @@ 
+* Samsung Exynos5 SCALER device
+
+SCALER is used for scaling, blending, color fill and color space
+conversion on EXYNOS[5420/5410] SoCs.
+
+Required properties:
+- compatible: should be "samsung,exynos5420-scaler" or
+			"samsung,exynos5410-scaler"
+- reg: should contain SCALER physical address location and length
+- interrupts: should contain SCALER interrupt specifier
+- clocks: should contain the SCALER clock phandle and specifier pair for
+		each clock listed in clock-names property, according to
+		the common clock bindings
+- clock-names: should contain exactly one entry
+		- "scaler" - IP bus clock
+
+Example:
+	scaler_0: scaler@12800000 {
+		compatible = "samsung,exynos5420-scaler";
+		reg = <0x12800000 0x1000>;
+		interrupts = <0 220 0>;
+		clocks = <&clock 381>;
+		clock-names = "scaler";
+	};