[PATCH v2 2/4] drm/lima: Reduce the amount of logs on deferred probe

2019-06-21 Thread Krzysztof Kozlowski
There is no point to print deferred probe (and its failures to get
resources) as an error.  For example getting a regulator causes three
unneeded error messages:

lima 1300.gpu: failed to get regulator: -517
lima 1300.gpu: regulator init fail -517
lima 1300.gpu: Fatal error during GPU init

Also do not print clock rates before the initialization finishes
because they will be duplicated after deferral.  Each probe step already
prints error so remove the final error message "Fatal error during GPU
init".

In case of multiple probe tries this would pollute the dmesg.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. None
---
 drivers/gpu/drm/lima/lima_device.c | 17 ++---
 drivers/gpu/drm/lima/lima_drv.c|  4 +---
 2 files changed, 7 insertions(+), 14 deletions(-)

diff --git a/drivers/gpu/drm/lima/lima_device.c 
b/drivers/gpu/drm/lima/lima_device.c
index 570d0e93f9a9..bb2eaa4f370e 100644
--- a/drivers/gpu/drm/lima/lima_device.c
+++ b/drivers/gpu/drm/lima/lima_device.c
@@ -80,7 +80,6 @@ const char *lima_ip_name(struct lima_ip *ip)
 static int lima_clk_init(struct lima_device *dev)
 {
int err;
-   unsigned long bus_rate, gpu_rate;
 
dev->clk_bus = devm_clk_get(dev->dev, "bus");
if (IS_ERR(dev->clk_bus)) {
@@ -94,12 +93,6 @@ static int lima_clk_init(struct lima_device *dev)
return PTR_ERR(dev->clk_gpu);
}
 
-   bus_rate = clk_get_rate(dev->clk_bus);
-   dev_info(dev->dev, "bus rate = %lu\n", bus_rate);
-
-   gpu_rate = clk_get_rate(dev->clk_gpu);
-   dev_info(dev->dev, "mod rate = %lu", gpu_rate);
-
err = clk_prepare_enable(dev->clk_bus);
if (err)
return err;
@@ -145,7 +138,8 @@ static int lima_regulator_init(struct lima_device *dev)
dev->regulator = NULL;
if (ret == -ENODEV)
return 0;
-   dev_err(dev->dev, "failed to get regulator: %d\n", ret);
+   if (ret != -EPROBE_DEFER)
+   dev_err(dev->dev, "failed to get regulator: %d\n", ret);
return ret;
}
 
@@ -297,10 +291,8 @@ int lima_device_init(struct lima_device *ldev)
}
 
err = lima_regulator_init(ldev);
-   if (err) {
-   dev_err(ldev->dev, "regulator init fail %d\n", err);
+   if (err)
goto err_out0;
-   }
 
ldev->empty_vm = lima_vm_create(ldev);
if (!ldev->empty_vm) {
@@ -343,6 +335,9 @@ int lima_device_init(struct lima_device *ldev)
if (err)
goto err_out5;
 
+   dev_info(ldev->dev, "bus rate = %lu\n", clk_get_rate(ldev->clk_bus));
+   dev_info(ldev->dev, "mod rate = %lu", clk_get_rate(ldev->clk_gpu));
+
return 0;
 
 err_out5:
diff --git a/drivers/gpu/drm/lima/lima_drv.c b/drivers/gpu/drm/lima/lima_drv.c
index b29c26cd13b2..cebc44592e47 100644
--- a/drivers/gpu/drm/lima/lima_drv.c
+++ b/drivers/gpu/drm/lima/lima_drv.c
@@ -307,10 +307,8 @@ static int lima_pdev_probe(struct platform_device *pdev)
ldev->ddev = ddev;
 
err = lima_device_init(ldev);
-   if (err) {
-   dev_err(>dev, "Fatal error during GPU init\n");
+   if (err)
goto err_out1;
-   }
 
/*
 * Register the DRM device with the core and the connectors with
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v3 0/1] drm/exynos: drop use of drmP.h

2019-06-21 Thread Krzysztof Kozlowski
On Fri, 21 Jun 2019 at 20:49, Sam Ravnborg  wrote:
>
> Build tested using allyesconfig, allmodconfig for various
> architectures.

Hi,

Thanks for fixes. Just for the record, allyesconfig/allmodconfig are
not a proper way for build test specific drivers. They are nice but
since all dependencies are in, they might miss a lot. You should build
mentioned platform (exynos_defconfig on ARMv7, defconfig on ARMv8) and
multi configs (multi_v7 on ARMv7). Such rule is also valid for other
drivers, not specific to Exynos.

Best regards,
Krzysztof

>
> v2:
> - add missing people to recipient list of mail
> - no change in actual patch
>
> v3:
> - fix build breakage (Inki Dae)
>
> The testing I had done with allyesconfig, allmodconfig
> did not trigger a configuration where exynos_drm_g2d.c
> was built.  So a build error had slipped through.
>
> Verified that all 23 .c files are built now.
>
> Sam
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v3 0/1] drm/exynos: drop use of drmP.h

2019-06-22 Thread Krzysztof Kozlowski
On Sat, 22 Jun 2019 at 09:31, Sam Ravnborg  wrote:
>
> Hi Krzysztof.
>
> > > Build tested using allyesconfig, allmodconfig for various
> > > architectures.
> >
> > Hi,
> >
> > Thanks for fixes. Just for the record, allyesconfig/allmodconfig are
> > not a proper way for build test specific drivers. They are nice but
> > since all dependencies are in, they might miss a lot. You should build
> > mentioned platform (exynos_defconfig on ARMv7, defconfig on ARMv8) and
> > multi configs (multi_v7 on ARMv7). Such rule is also valid for other
> > drivers, not specific to Exynos.
>
> Thanks for the feedback. I have added exynos_defconfig,
> multi_v7_defconfig to my growing list of configs that I try when doing
> cross driver changes.
> They include defconfig + allnoconfig for the supported archs too.
>
> None of these configs would have triggered a build of exynos_drm_g2d.c
> so to do that some manual twaeks of the confg was necessary.
>
> Adding a COMPILE_TEST dependency will enable the build
> for the allyesconfig, allmodconfig.
> Thats worths to consider to avoid future mistakes.
>
> Sam
>
> Something like this:
>
> From 9b29b85f25f4cc485f36efb8d658766fa9a252d9 Mon Sep 17 00:00:00 2001
> From: Sam Ravnborg 
> Date: Sat, 22 Jun 2019 09:24:06 +0200
> Subject: [PATCH v1] drm/exynos: trigger build of all modules
>
> Add COMPILE_TEST dependency to a few options to trigger that the modules
> get built using allyesconfig, allmodconfig.
> This allows a non-exynos developer to catch build issues
> in files that is usually not built.
>
> Signed-off-by: Sam Ravnborg 
> Cc: Inki Dae 
> Cc: Joonyoung Shim 
> Cc: Seung-Woo Kim 
> Cc: Kyungmin Park 
> Cc: David Airlie 
> Cc: Daniel Vetter 
> Cc: Kukjin Kim 
> Cc: Krzysztof Kozlowski 
> Cc: Jingoo Han 
> ---
>  drivers/gpu/drm/exynos/Kconfig | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/exynos/Kconfig b/drivers/gpu/drm/exynos/Kconfig
> index cbe58d307d1c..eadea2daf1ab 100644
> --- a/drivers/gpu/drm/exynos/Kconfig
> +++ b/drivers/gpu/drm/exynos/Kconfig
> @@ -86,7 +86,7 @@ comment "Sub-drivers"
>
>  config DRM_EXYNOS_G2D
> bool "G2D"
> -   depends on VIDEO_SAMSUNG_S5P_G2D=n
> +   depends on VIDEO_SAMSUNG_S5P_G2D=n || COMPILE_TEST

Oh yes, that definitely makes sense (assuming it compiles on all
archs). Maybe you can send a follow up adding these?

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v2 2/2] arm: dts: add ARM Mali GPU node for Odroid XU3

2019-06-18 Thread Krzysztof Kozlowski
On Sat, 15 Jun 2019 at 01:57, Joseph Kogut  wrote:
>
> Add device tree node for mali gpu on Odroid XU3 SoCs.
>
> Signed-off-by: Joseph Kogut 
> ---
>
> Changes v1 -> v2:
> - Use interrupt name ordering from binding doc
> - Specify a single clock for GPU node
> - Add gpu opp table
> - Fix warnings from IRQ_TYPE_NONE
>
>  .../boot/dts/exynos5422-odroidxu3-common.dtsi | 26 +++
>  1 file changed, 26 insertions(+)
>
> diff --git a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi 
> b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
> index 93a48f2dda49..b8a4246e3b37 100644
> --- a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
> +++ b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
> @@ -48,6 +48,32 @@
> cooling-levels = <0 130 170 230>;
> };
>
> +   gpu: gpu@1180 {
> +   compatible = "samsung,exynos-mali", "arm,mali-t628";
> +   reg = <0x1180 0x5000>;
> +   interrupts = ,
> +,
> +;
> +   interrupt-names = "job", "mmu", "gpu";
> +   clocks = < CLK_G3D>;
> +   mali-supply = <_reg>;
> +   operating-points-v2 = <_opp_table>;
> +   };
> +
> +   gpu_opp_table: gpu-opp-table {

One more thing - use "opp_table" as node name (generic class of node,
matches style with other tables).

Best regards,
Krzysztof

> +   compatible = "operating-points-v2";
> +
> +   opp-17700 {
> +   opp-hz = /bits/ 64 <11700>;
> +   opp-microvolt = <812500>;
> +   };
> +
> +   opp-6 {
> +   opp-hz = /bits/ 64 <6>;
> +   opp-microvolt = <115>;
> +   };
> +   };
> +
> thermal-zones {
> cpu0_thermal: cpu0-thermal {
> thermal-sensors = <_cpu0 0>;
> --
> 2.22.0
>
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH] ARM: dts: exynos: Increase minimal ACLK400_DISP1 frequency on Exynos542x

2019-04-24 Thread Krzysztof Kozlowski
On Tue, Mar 19, 2019 at 02:26:01PM +0100, Marek Szyprowski wrote:
> ACLK400_DISP1 bus feeds some internal buses of the display subsystem, some
> of which are also related to TV/Mixer hardware modules. When that bus
> is set to 120MHz, Exynos Mixer is not able to properly handle two XRGB
> display planes at FullHD-60MHz. DMA underrun happens, which in turn might
> result in reading data out of the configured buffer, what causes IOMMU
> page fault and kernel panic.
> 
> This change fixes the following IOMMU fault, observed, when 2 Mixer planes
> were enabled:
> 
> exynos-sysmmu 1465.sysmmu: 1445.mixer: PAGE FAULT occurred at 
> 0x20fe9000
> [ cut here ]
> kernel BUG at ../drivers/iommu/exynos-iommu.c:450!
> Internal error: Oops - BUG: 0 [#1] PREEMPT SMP ARM
> Modules linked in:
> CPU: 5 PID: 0 Comm: swapper/5 Not tainted 5.0.0-3-g1b03088168ea #149
> Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
> PC is at exynos_sysmmu_irq+0x1c0/0x264
> LR is at lock_is_held_type+0x44/0x64
> ...
> 
> Reported-by: Marian Mihailescu 
> Fixes: 5d99cc59a3c6 ("ARM: dts: exynos: Move Exynos5250 and Exynos5420 nodes 
> under soc")
> Fixes: b04a62d3ade3 ("ARM: dts: exynos: Add bus nodes using VDD_INT for 
> Exynos542x SoC")
> Signed-off-by: Marek Szyprowski 
> ---
>  arch/arm/boot/dts/exynos5420.dtsi | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/exynos5420.dtsi 
> b/arch/arm/boot/dts/exynos5420.dtsi
> index aaff15880761..250f4d7182e0 100644
> --- a/arch/arm/boot/dts/exynos5420.dtsi
> +++ b/arch/arm/boot/dts/exynos5420.dtsi
> @@ -1294,7 +1294,7 @@
>   compatible = "operating-points-v2";
>  
>   opp00 {
> - opp-hz = /bits/ 64 <12000>;
> + opp-hz = /bits/ 64 <15000>;

Some time ago we talked about all these changes on IRC. I understand
that implementing proper QoS (or fix devfreq/PPMU events to properly
indicate busy mixer) might be a big task so let's go with this
workaround. However how about adding a TODO comment about reason of
bumping the frequency?

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v2] dt-bindings: gpu: Convert Samsung Image Rotator to dt-schema

2019-09-13 Thread Krzysztof Kozlowski
On Fri, 13 Sep 2019 at 11:15, Marek Szyprowski  wrote:
>
> Hi Krzysztof,
>
> On 9/13/19 8:29 AM, Krzysztof Kozlowski wrote:
> > On Thu, Sep 12, 2019 at 06:15:38PM +0200, Maciej Falkowski wrote:
> >> Convert Samsung Image Rotator to newer dt-schema format.
> >>
> >> Signed-off-by: Maciej Falkowski 
> >> Signed-off-by: Marek Szyprowski 
> > Just to make it clear, Marek's signed-off should appear for one of
> > conditions:
> >   - he contributed some source code to your patch,
> >   - he took your patch, rebased, send by himself (not a case here, I
> > think),
> >   - he contributed significant ideas, although for this there is a
> > "Co-developed-by" tag.
> >
> > If someone made just review - add Reviewed-by. If someone suggested the
> > patch - add Suggested-by.
>
> My signed-off here was added to mark that this patch is allowed to be
> submitted to the public mailing list, as I have required company
> permissions for such activity. It is not that uncommon that a given
> patch has more than one signed-off and still the main author has the
> first signed-off tag.

Thanks for explanations. If I understand correctly, your SoB appears
because some internal Samsung rules. That is not what SoB is meant
for:
https://elixir.bootlin.com/linux/v5.3-rc8/source/Documentation/process/submitting-patches.rst#L431
If you do not contributed to the patch, did not touch it (e.g.
rebasing) and you are not sending it, then your SoB should not be
there. It looks like the same madness with Kyungmin Park long time
ago:
https://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux.git/commit/?h=for-next=6c6cf64b16438eac6da9a90412a82316ad196e7c
Every patch was marked with SoB even though he was not involved at all
in the process.

That's not what kernel's SoB is for.

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v2] dt-bindings: gpu: Convert Samsung Image Rotator to dt-schema

2019-09-13 Thread Krzysztof Kozlowski
On Fri, 13 Sep 2019 at 11:29, Krzysztof Kozlowski  wrote:
>
> On Fri, 13 Sep 2019 at 11:15, Marek Szyprowski  
> wrote:
> >
> > Hi Krzysztof,
> >
> > On 9/13/19 8:29 AM, Krzysztof Kozlowski wrote:
> > > On Thu, Sep 12, 2019 at 06:15:38PM +0200, Maciej Falkowski wrote:
> > >> Convert Samsung Image Rotator to newer dt-schema format.
> > >>
> > >> Signed-off-by: Maciej Falkowski 
> > >> Signed-off-by: Marek Szyprowski 
> > > Just to make it clear, Marek's signed-off should appear for one of
> > > conditions:
> > >   - he contributed some source code to your patch,
> > >   - he took your patch, rebased, send by himself (not a case here, I
> > > think),
> > >   - he contributed significant ideas, although for this there is a
> > > "Co-developed-by" tag.
> > >
> > > If someone made just review - add Reviewed-by. If someone suggested the
> > > patch - add Suggested-by.
> >
> > My signed-off here was added to mark that this patch is allowed to be
> > submitted to the public mailing list, as I have required company
> > permissions for such activity. It is not that uncommon that a given
> > patch has more than one signed-off and still the main author has the
> > first signed-off tag.
>
> Thanks for explanations. If I understand correctly, your SoB appears
> because some internal Samsung rules. That is not what SoB is meant
> for:
> https://elixir.bootlin.com/linux/v5.3-rc8/source/Documentation/process/submitting-patches.rst#L431
> If you do not contributed to the patch, did not touch it (e.g.
> rebasing) and you are not sending it, then your SoB should not be
> there. It looks like the same madness with Kyungmin Park long time
> ago:
> https://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux.git/commit/?h=for-next=6c6cf64b16438eac6da9a90412a82316ad196e7c
> Every patch was marked with SoB even though he was not involved at all
> in the process.
>
> That's not what kernel's SoB is for.

Ah, and if you meant that Maciej does not have the permissions to send
the patches, then your SoB along with patch going through your account
makes sense. Otherwise, adding your SoB and sending by Maciej, is a
joke of company regulations. It means absolutely nothing and then
strip it out.

Best regards,
Krzysztof


[RESEND PATCH] drm/panfrost: Reduce the amount of logs on deferred probe

2019-09-09 Thread Krzysztof Kozlowski
There is no point to print deferred probe (and its failures to get
resources) as an error.

In case of multiple probe tries this would pollute the dmesg.

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/panfrost/panfrost_device.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/panfrost/panfrost_device.c 
b/drivers/gpu/drm/panfrost/panfrost_device.c
index 46b0b02e4289..2252147bc285 100644
--- a/drivers/gpu/drm/panfrost/panfrost_device.c
+++ b/drivers/gpu/drm/panfrost/panfrost_device.c
@@ -95,7 +95,9 @@ static int panfrost_regulator_init(struct panfrost_device 
*pfdev)
pfdev->regulator = NULL;
if (ret == -ENODEV)
return 0;
-   dev_err(pfdev->dev, "failed to get regulator: %d\n", ret);
+   if (ret != -EPROBE_DEFER)
+   dev_err(pfdev->dev, "failed to get regulator: %d\n",
+   ret);
return ret;
}
 
-- 
2.17.1



Re: [PATCH] dt-bindings: gpu: Convert Samsung Image Scaler to dt-schema

2019-09-18 Thread Krzysztof Kozlowski
On Fri, 13 Sep 2019 at 11:41, Maciej Falkowski  wrote:
>
> Convert Samsung Image Scaler to newer dt-schema format.
>
> Signed-off-by: Maciej Falkowski 
> Signed-off-by: Marek Szyprowski 
> ---
>  .../bindings/gpu/samsung-scaler.txt   | 27 -
>  .../bindings/gpu/samsung-scaler.yaml  | 57 +++
>  2 files changed, 57 insertions(+), 27 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.txt
>  create mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
>
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt 
> b/Documentation/devicetree/bindings/gpu/samsung-scaler.txt
> deleted file mode 100644
> index 9c3d98105dfd..
> --- a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt
> +++ /dev/null
> @@ -1,27 +0,0 @@
> -* Samsung Exynos Image Scaler
> -
> -Required properties:
> -  - compatible : value should be one of the following:
> -   (a) "samsung,exynos5420-scaler" for Scaler IP in Exynos5420
> -   (b) "samsung,exynos5433-scaler" for Scaler IP in Exynos5433
> -
> -  - reg : Physical base address of the IP registers and length of memory
> - mapped region.
> -
> -  - interrupts : Interrupt specifier for scaler interrupt, according to 
> format
> -specific to interrupt parent.
> -
> -  - clocks : Clock specifier for scaler clock, according to generic clock
> -bindings. (See 
> Documentation/devicetree/bindings/clock/exynos*.txt)
> -
> -  - clock-names : Names of clocks. For exynos scaler, it should be "mscl"
> - on 5420 and "pclk", "aclk" and "aclk_xiu" on 5433.
> -
> -Example:
> -   scaler@1280 {
> -   compatible = "samsung,exynos5420-scaler";
> -   reg = <0x1280 0x1294>;
> -   interrupts = <0 220 IRQ_TYPE_LEVEL_HIGH>;
> -   clocks = < CLK_MSCL0>;
> -   clock-names = "mscl";
> -   };
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml 
> b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
> new file mode 100644
> index ..ee2caab22977
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
> @@ -0,0 +1,57 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpu/samsung-scaler.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Samsung Exynos SoC Image Scaler
> +
> +maintainers:
> +  - Inki Dae 
> +
> +properties:
> +  compatible:
> +enum:
> +  - "samsung,exynos5420-scaler"
> +  - "samsung,exynos5433-scaler"
> +
> +  reg:
> +maxItems: 1
> +
> +  interrupts:
> +maxItems: 1
> +
> +  clocks:
> +minItems: 1
> +maxItems: 3
> +
> +  clock-names:
> +oneOf:
> +  - items:
> +  - const: mscl
> +  - items:
> +  - const: pclk
> +  - const: aclk
> +  - const: aclk_xiu
> +description: |
> +  For exynos scaler it should be:
> +  - "mscl" on Exynos5420
> +  - "pclk", "aclk", "aclk_xiu" on Exynos5433

Hi,

This should be customized with proper if in allOf section.

Best regards,
Krzysztof

> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - clock-names
> +
> +examples:
> +  - |
> +scaler@1280 {
> +compatible = "samsung,exynos5420-scaler";
> +reg = <0x1280 0x1294>;
> +interrupts = <0 220 4>; // IRQ_TYPE_LEVEL_HIGH
> +clocks = < 0>; // CLK_MSCL0
> +clock-names = "mscl";
> +};
> +
> --
> 2.17.1
>


[PATCH v2 2/8] dt-bindings: sram: Convert SRAM bindings to json-schema

2019-09-18 Thread Krzysztof Kozlowski
Convert generic mmio-sram bindings to DT schema format using
json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Indent example with four spaces (more readable).
---
 .../devicetree/bindings/sram/sram.txt |  80 --
 .../devicetree/bindings/sram/sram.yaml| 138 ++
 2 files changed, 138 insertions(+), 80 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/sram/sram.txt
 create mode 100644 Documentation/devicetree/bindings/sram/sram.yaml

diff --git a/Documentation/devicetree/bindings/sram/sram.txt 
b/Documentation/devicetree/bindings/sram/sram.txt
deleted file mode 100644
index e98908bd4227..
--- a/Documentation/devicetree/bindings/sram/sram.txt
+++ /dev/null
@@ -1,80 +0,0 @@
-Generic on-chip SRAM
-
-Simple IO memory regions to be managed by the genalloc API.
-
-Required properties:
-
-- compatible : mmio-sram or atmel,sama5d2-securam
-
-- reg : SRAM iomem address range
-
-Reserving sram areas:
--
-
-Each child of the sram node specifies a region of reserved memory. Each
-child node should use a 'reg' property to specify a specific range of
-reserved memory.
-
-Following the generic-names recommended practice, node names should
-reflect the purpose of the node. Unit address (@) should be
-appended to the name.
-
-Required properties in the sram node:
-
-- #address-cells, #size-cells : should use the same values as the root node
-- ranges : standard definition, should translate from local addresses
-   within the sram to bus addresses
-
-Optional properties in the sram node:
-
-- no-memory-wc : the flag indicating, that SRAM memory region has not to
- be remapped as write combining. WC is used by default.
-
-Required properties in the area nodes:
-
-- reg : iomem address range, relative to the SRAM range
-
-Optional properties in the area nodes:
-
-- compatible : standard definition, should contain a vendor specific string
-   in the form ,[-]
-- pool : indicates that the particular reserved SRAM area is addressable
- and in use by another device or devices
-- export : indicates that the reserved SRAM area may be accessed outside
-   of the kernel, e.g. by bootloader or userspace
-- protect-exec : Same as 'pool' above but with the additional
-constraint that code wil be run from the region and
-that the memory is maintained as read-only, executable
-during code execution. NOTE: This region must be page
-aligned on start and end in order to properly allow
-manipulation of the page attributes.
-- label : the name for the reserved partition, if omitted, the label
-  is taken from the node name excluding the unit address.
-- clocks : a list of phandle and clock specifier pair that controls the
-  single SRAM clock.
-
-Example:
-
-sram: sram@5c00 {
-   compatible = "mmio-sram";
-   reg = <0x5c00 0x4>; /* 256 KiB SRAM at address 0x5c00 */
-
-   #address-cells = <1>;
-   #size-cells = <1>;
-   ranges = <0 0x5c00 0x4>;
-
-   smp-sram@100 {
-   compatible = "socvendor,smp-sram";
-   reg = <0x100 0x50>;
-   };
-
-   device-sram@1000 {
-   reg = <0x1000 0x1000>;
-   pool;
-   };
-
-   exported@2 {
-   reg = <0x2 0x2>;
-   export;
-   };
-};
diff --git a/Documentation/devicetree/bindings/sram/sram.yaml 
b/Documentation/devicetree/bindings/sram/sram.yaml
new file mode 100644
index ..8d9d6ce494b2
--- /dev/null
+++ b/Documentation/devicetree/bindings/sram/sram.yaml
@@ -0,0 +1,138 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/sram/sram.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Generic on-chip SRAM
+
+maintainers:
+  - FIXME 
+
+description: |+
+  Simple IO memory regions to be managed by the genalloc API.
+
+  Each child of the sram node specifies a region of reserved memory. Each
+  child node should use a 'reg' property to specify a specific range of
+  reserved memory.
+
+  Following the generic-names recommended practice, node names should
+  reflect the purpose of the node. Unit address (@) should be
+  appended to the name.
+
+properties:
+  $nodename:
+pattern: "^sram(@.*)?"
+
+  compatible:
+items:
+  - enum:
+  - mmio-sram
+  - atmel,sama5d2-securam
+
+  reg:
+maxItems: 1
+
+  "#address-cells":
+description: Should use the same values as the root node.
+
+  "#size-cells":
+description: Should use the same values as the root node.
+
+  ranges:
+description:
+  Should translate from local addresses within the sram to bus addresses.
+
+  no-memory-wc:
+description:
+  The flag indi

[PATCH v2 1/8] dt-bindings: rng: exynos4-rng: Convert Exynos PRNG bindings to json-schema

2019-09-18 Thread Krzysztof Kozlowski
Convert Samsung Exynos Pseudo Random Number Generator bindings to DT
schema format using json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Indent example with four spaces (more readable).
---
 .../bindings/rng/samsung,exynos4-rng.txt  | 19 -
 .../bindings/rng/samsung,exynos4-rng.yaml | 41 +++
 MAINTAINERS   |  2 +-
 3 files changed, 42 insertions(+), 20 deletions(-)
 delete mode 100644 
Documentation/devicetree/bindings/rng/samsung,exynos4-rng.txt
 create mode 100644 
Documentation/devicetree/bindings/rng/samsung,exynos4-rng.yaml

diff --git a/Documentation/devicetree/bindings/rng/samsung,exynos4-rng.txt 
b/Documentation/devicetree/bindings/rng/samsung,exynos4-rng.txt
deleted file mode 100644
index a13fbdb4bd88..
--- a/Documentation/devicetree/bindings/rng/samsung,exynos4-rng.txt
+++ /dev/null
@@ -1,19 +0,0 @@
-Exynos Pseudo Random Number Generator
-
-Required properties:
-
-- compatible  : One of:
-- "samsung,exynos4-rng" for Exynos4210 and Exynos4412
-- "samsung,exynos5250-prng" for Exynos5250+
-- reg : Specifies base physical address and size of the registers map.
-- clocks  : Phandle to clock-controller plus clock-specifier pair.
-- clock-names : "secss" as a clock name.
-
-Example:
-
-   rng@10830400 {
-   compatible = "samsung,exynos4-rng";
-   reg = <0x10830400 0x200>;
-   clocks = < CLK_SSS>;
-   clock-names = "secss";
-   };
diff --git a/Documentation/devicetree/bindings/rng/samsung,exynos4-rng.yaml 
b/Documentation/devicetree/bindings/rng/samsung,exynos4-rng.yaml
new file mode 100644
index ..2d075d6c87b6
--- /dev/null
+++ b/Documentation/devicetree/bindings/rng/samsung,exynos4-rng.yaml
@@ -0,0 +1,41 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/rng/samsung,exynos4-rng.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung Exynos SoC Pseudo Random Number Generator
+
+maintainers:
+  - Krzysztof Kozlowski 
+
+properties:
+  compatible:
+enum:
+  - samsung,exynos4-rng   # for Exynos4210 and Exynos4412
+  - samsung,exynos5250-prng   # for Exynos5250+
+
+  reg:
+maxItems: 1
+
+  clocks:
+maxItems: 1
+
+  clock-names:
+items:
+  - const: secss
+
+required:
+  - compatible
+  - reg
+  - clock-names
+  - clocks
+
+examples:
+  - |
+rng@10830400 {
+compatible = "samsung,exynos4-rng";
+reg = <0x10830400 0x200>;
+clocks = < 255>; // CLK_SSS
+clock-names = "secss";
+};
diff --git a/MAINTAINERS b/MAINTAINERS
index 00969a90f94c..9cec4494b9a8 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -14181,7 +14181,7 @@ L:  linux-cry...@vger.kernel.org
 L: linux-samsung-...@vger.kernel.org
 S: Maintained
 F: drivers/crypto/exynos-rng.c
-F: Documentation/devicetree/bindings/rng/samsung,exynos4-rng.txt
+F: Documentation/devicetree/bindings/rng/samsung,exynos4-rng.yaml
 
 SAMSUNG EXYNOS TRUE RANDOM NUMBER GENERATOR (TRNG) DRIVER
 M: Łukasz Stelmach 
-- 
2.17.1



[PATCH v2 7/8] dt-bindings: pwm: Convert PWM bindings to json-schema

2019-09-18 Thread Krzysztof Kozlowski
Convert generic PWM bindings to DT schema format using json-schema.  The
consumer bindings are split to separate file.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Indent example with four spaces (more readable),
2. Change pattern for pwm nodes,
3. Remove $ref from #cells.
---
 .../devicetree/bindings/clock/pwm-clock.txt   |  2 +-
 .../bindings/display/bridge/ti,sn65dsi86.txt  |  2 +-
 .../devicetree/bindings/display/ssd1307fb.txt |  2 +-
 .../bindings/leds/backlight/pwm-backlight.txt |  2 +-
 .../devicetree/bindings/leds/leds-pwm.txt |  2 +-
 .../devicetree/bindings/mfd/max77693.txt  |  2 +-
 .../bindings/pwm/atmel-hlcdc-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/atmel-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/atmel-tcb-pwm.txt |  2 +-
 .../bindings/pwm/brcm,bcm7038-pwm.txt |  2 +-
 .../bindings/pwm/brcm,iproc-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/brcm,kona-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/img-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/imx-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/imx-tpm-pwm.txt   |  2 +-
 .../bindings/pwm/lpc1850-sct-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/mxs-pwm.txt   |  2 +-
 .../bindings/pwm/nvidia,tegra20-pwm.txt   |  2 +-
 .../bindings/pwm/nxp,pca9685-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-bcm2835.txt   |  2 +-
 .../devicetree/bindings/pwm/pwm-berlin.txt|  2 +-
 .../bindings/pwm/pwm-consumers.yaml   | 76 +++
 .../devicetree/bindings/pwm/pwm-fsl-ftm.txt   |  2 +-
 .../devicetree/bindings/pwm/pwm-hibvt.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-lp3943.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-mediatek.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-meson.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-mtk-disp.txt  |  2 +-
 .../bindings/pwm/pwm-omap-dmtimer.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-rockchip.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-sifive.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-stm32-lp.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-stm32.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-tiecap.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-tiehrpwm.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-zx.txt|  2 +-
 Documentation/devicetree/bindings/pwm/pwm.txt | 69 -
 .../devicetree/bindings/pwm/pwm.yaml  | 29 +++
 .../bindings/pwm/renesas,pwm-rcar.txt |  2 +-
 .../bindings/pwm/renesas,tpu-pwm.txt  |  4 +-
 .../devicetree/bindings/pwm/spear-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/st,stmpe-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/ti,twl-pwm.txt|  2 +-
 .../devicetree/bindings/pwm/ti,twl-pwmled.txt |  2 +-
 .../devicetree/bindings/pwm/vt8500-pwm.txt|  2 +-
 .../bindings/regulator/pwm-regulator.txt  |  2 +-
 .../devicetree/bindings/timer/ingenic,tcu.txt |  2 +-
 47 files changed, 150 insertions(+), 114 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm-consumers.yaml
 delete mode 100644 Documentation/devicetree/bindings/pwm/pwm.txt
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm.yaml

diff --git a/Documentation/devicetree/bindings/clock/pwm-clock.txt 
b/Documentation/devicetree/bindings/clock/pwm-clock.txt
index 83db876b3b90..8a791b6d76a9 100644
--- a/Documentation/devicetree/bindings/clock/pwm-clock.txt
+++ b/Documentation/devicetree/bindings/clock/pwm-clock.txt
@@ -3,7 +3,7 @@ Binding for an external clock signal driven by a PWM pin.
 This binding uses the common clock binding[1] and the common PWM binding[2].
 
 [1] Documentation/devicetree/bindings/clock/clock-bindings.txt
-[2] Documentation/devicetree/bindings/pwm/pwm.txt
+[2] Documentation/devicetree/bindings/pwm/pwm-consumers.yaml
 
 Required properties:
 - compatible : shall be "pwm-clock".
diff --git a/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt 
b/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
index 0a3fbb53a16e..8ec4a7f2623a 100644
--- a/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
+++ b/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
@@ -21,7 +21,7 @@ Optional properties:
 - #gpio-cells: Should be two. The first cell is the pin number and
the second cell is used to specify flags.
See ../../gpio/gpio.txt for more information.
-- #pwm-cells : Should be one. See ../../pwm/pwm.txt for description of
+- #pwm-cells : Should be one. See ../../pwm/pwm.yaml for description of
the cell formats.
 
 - clock-names: should be "refclk"
diff --git a/Documentation/devicetree/bindings/display/ssd1307fb.txt 
b/Documentation/devicetree/bindings/display/ssd1307fb.txt
index 27333b9551b3..da9b28153a3c 100644
--- a/Documentation/devicetree/bindings/display/ssd1307fb.txt
+++ b/Documentation/devicetree/bindings/display/ssd1307fb.txt
@@ -37,7 +37,7 @@ Optional propertie

[PATCH v2 5/8] dt-bindings: watchdog: Convert Samsung SoC watchdog bindings to json-schema

2019-09-18 Thread Krzysztof Kozlowski
Convert Samsung S3C/S5P/Exynos watchdog bindings to DT schema format
using json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Indent example with four spaces (more readable),
2. Remove unneeded timeout-sec description.
---
 .../bindings/watchdog/samsung-wdt.txt | 35 --
 .../bindings/watchdog/samsung-wdt.yaml| 67 +++
 2 files changed, 67 insertions(+), 35 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/watchdog/samsung-wdt.txt
 create mode 100644 Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml

diff --git a/Documentation/devicetree/bindings/watchdog/samsung-wdt.txt 
b/Documentation/devicetree/bindings/watchdog/samsung-wdt.txt
deleted file mode 100644
index 46dcb48e75b4..
--- a/Documentation/devicetree/bindings/watchdog/samsung-wdt.txt
+++ /dev/null
@@ -1,35 +0,0 @@
-* Samsung's Watchdog Timer Controller
-
-The Samsung's Watchdog controller is used for resuming system operation
-after a preset amount of time during which the WDT reset event has not
-occurred.
-
-Required properties:
-- compatible : should be one among the following
-   - "samsung,s3c2410-wdt" for S3C2410
-   - "samsung,s3c6410-wdt" for S3C6410, S5PV210 and Exynos4
-   - "samsung,exynos5250-wdt" for Exynos5250
-   - "samsung,exynos5420-wdt" for Exynos5420
-   - "samsung,exynos7-wdt" for Exynos7
-
-- reg : base physical address of the controller and length of memory mapped
-   region.
-- interrupts : interrupt number to the cpu.
-- samsung,syscon-phandle : reference to syscon node (This property required 
only
-   in case of compatible being "samsung,exynos5250-wdt" or 
"samsung,exynos5420-wdt".
-   In case of Exynos5250 and 5420 this property points to syscon node 
holding the PMU
-   base address)
-
-Optional properties:
-- timeout-sec : contains the watchdog timeout in seconds.
-
-Example:
-
-watchdog@101d {
-   compatible = "samsung,exynos5250-wdt";
-   reg = <0x101D 0x100>;
-   interrupts = <0 42 0>;
-   clocks = < 336>;
-   clock-names = "watchdog";
-   samsung,syscon-phandle = <_syscon>;
-};
diff --git a/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml 
b/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml
new file mode 100644
index ..3ea3c9fe8390
--- /dev/null
+++ b/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml
@@ -0,0 +1,67 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/watchdog/samsung-wdt.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung SoC Watchdog Timer Controller
+
+maintainers:
+  - Krzysztof Kozlowski 
+
+description: |+
+  The Samsung's Watchdog controller is used for resuming system operation
+  after a preset amount of time during which the WDT reset event has not
+  occurred.
+
+properties:
+  compatible:
+enum:
+  - samsung,s3c2410-wdt   # for S3C2410
+  - samsung,s3c6410-wdt   # for S3C6410, S5PV210 and 
Exynos4
+  - samsung,exynos5250-wdt# for Exynos5250
+  - samsung,exynos5420-wdt# for Exynos5420
+  - samsung,exynos7-wdt   # for Exynos7
+
+  reg:
+maxItems: 1
+
+  interrupts:
+maxItems: 1
+
+  samsung,syscon-phandle:
+$ref: /schemas/types.yaml#/definitions/phandle
+description:
+  Phandle to the PMU system controller node (in case of Exynos5250
+  and Exynos5420).
+
+  timeout-sec:
+$ref: /schemas/types.yaml#/definitions/uint32
+
+required:
+  - compatible
+  - interrupts
+  - reg
+
+allOf:
+  - if:
+  properties:
+compatible:
+  contains:
+enum:
+  - samsung,exynos5250-wdt
+  - samsung,exynos5420-wdt
+then:
+  required:
+- samsung,syscon-phandle
+
+examples:
+  - |
+watchdog@101d {
+compatible = "samsung,exynos5250-wdt";
+reg = <0x101D 0x100>;
+interrupts = <0 42 0>;
+clocks = < 336>;
+clock-names = "watchdog";
+samsung,syscon-phandle = <_syscon>;
+};
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH v2 4/8] dt-bindings: memory-controllers: Convert Samsung Exynos SROM bindings to json-schema

2019-09-18 Thread Krzysztof Kozlowski
Convert Samsung Exynos SROM controller bindings to DT schema format
using json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Indent example with four spaces (more readable),
2. Split examples into two,
3. Fix pattern for subnode name,
4. Remove checks for #address-cells-ranges-#size-cells,
5. Add "additionalProperties" so the wrongly named subnodes would be
   matched.
---
 .../memory-controllers/exynos-srom.txt|  79 ---
 .../memory-controllers/exynos-srom.yaml   | 128 ++
 2 files changed, 128 insertions(+), 79 deletions(-)
 delete mode 100644 
Documentation/devicetree/bindings/memory-controllers/exynos-srom.txt
 create mode 100644 
Documentation/devicetree/bindings/memory-controllers/exynos-srom.yaml

diff --git 
a/Documentation/devicetree/bindings/memory-controllers/exynos-srom.txt 
b/Documentation/devicetree/bindings/memory-controllers/exynos-srom.txt
deleted file mode 100644
index f633b5d0f8ca..
--- a/Documentation/devicetree/bindings/memory-controllers/exynos-srom.txt
+++ /dev/null
@@ -1,79 +0,0 @@
-SAMSUNG Exynos SoCs SROM Controller driver.
-
-Required properties:
-- compatible : Should contain "samsung,exynos4210-srom".
-
-- reg: offset and length of the register set
-
-Optional properties:
-The SROM controller can be used to attach external peripherals. In this case
-extra properties, describing the bus behind it, should be specified as below:
-
-- #address-cells: Must be set to 2 to allow device address translation.
- Address is specified as (bank#, offset).
-
-- #size-cells: Must be set to 1 to allow device size passing
-
-- ranges: Must be set up to reflect the memory layout with four integer values
- per bank:
-0  
-
-Sub-nodes:
-The actual device nodes should be added as subnodes to the SROMc node. These
-subnodes, in addition to regular device specification, should contain the 
following
-properties, describing configuration of the relevant SROM bank:
-
-Required properties:
-- reg: bank number, base address (relative to start of the bank) and size of
-   the memory mapped for the device. Note that base address will be
-   typically 0 as this is the start of the bank.
-
-- samsung,srom-timing : array of 6 integers, specifying bank timings in the
-following order: Tacp, Tcah, Tcoh, Tacc, Tcos, Tacs.
-Each value is specified in cycles and has the following
-meaning and valid range:
-Tacp : Page mode access cycle at Page mode (0 - 15)
-Tcah : Address holding time after CSn (0 - 15)
-Tcoh : Chip selection hold on OEn (0 - 15)
-Tacc : Access cycle (0 - 31, the actual time is N + 1)
-Tcos : Chip selection set-up before OEn (0 - 15)
-Tacs : Address set-up before CSn (0 - 15)
-
-Optional properties:
-- reg-io-width : data width in bytes (1 or 2). If omitted, default of 1 is 
used.
-
-- samsung,srom-page-mode : if page mode is set, 4 data page mode will be 
configured,
-  else normal (1 data) page mode will be set.
-
-Example: basic definition, no banks are configured
-   memory-controller@1257 {
-   compatible = "samsung,exynos4210-srom";
-   reg = <0x1257 0x14>;
-   };
-
-Example: SROMc with SMSC911x ethernet chip on bank 3
-   memory-controller@1257 {
-   #address-cells = <2>;
-   #size-cells = <1>;
-   ranges = <0 0 0x0400 0x2   // Bank0
- 1 0 0x0500 0x2   // Bank1
- 2 0 0x0600 0x2   // Bank2
- 3 0 0x0700 0x2>; // Bank3
-
-   compatible = "samsung,exynos4210-srom";
-   reg = <0x1257 0x14>;
-
-   ethernet@3,0 {
-   compatible = "smsc,lan9115";
-   reg = <3 0 0x1>;   // Bank 3, offset = 0
-   phy-mode = "mii";
-   interrupt-parent = <>;
-   interrupts = <5 8>;
-   reg-io-width = <2>;
-   smsc,irq-push-pull;
-   smsc,force-internal-phy;
-
-   samsung,srom-page-mode;
-   samsung,srom-timing = <9 12 1 9 1 1>;
-   };
-   };
diff --git 
a/Documentation/devicetree/bindings/memory-controllers/exynos-srom.yaml 
b/Documentation/devicetree/bindings/memory-controllers/exynos-srom.yaml
new file mode 100644
index ..cdfe3f7f0ea9
--- /dev/null
+++ b/Documentation/devicetree/bindings/memory-controllers/exynos-srom.yaml
@@ -0,0 +1,128 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+-

[PATCH v2 8/8] dt-bindings: pwm: Convert Samsung PWM bindings to json-schema

2019-09-18 Thread Krzysztof Kozlowski
Convert Samsung PWM (S3C, S5P and Exynos SoCs) bindings to DT schema
format using json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Indent example with four spaces (more readable),
2. Fix samsung,pwm-outputs after review,
3. Remove double-quotes from clock names.
---
 .../devicetree/bindings/pwm/pwm-samsung.txt   |  51 -
 .../devicetree/bindings/pwm/pwm-samsung.yaml  | 107 ++
 2 files changed, 107 insertions(+), 51 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/pwm/pwm-samsung.txt
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm-samsung.yaml

diff --git a/Documentation/devicetree/bindings/pwm/pwm-samsung.txt 
b/Documentation/devicetree/bindings/pwm/pwm-samsung.txt
deleted file mode 100644
index 5538de9c2007..
--- a/Documentation/devicetree/bindings/pwm/pwm-samsung.txt
+++ /dev/null
@@ -1,51 +0,0 @@
-* Samsung PWM timers
-
-Samsung SoCs contain PWM timer blocks which can be used for system clock source
-and clock event timers, as well as to drive SoC outputs with PWM signal. Each
-PWM timer block provides 5 PWM channels (not all of them can drive physical
-outputs - see SoC and board manual).
-
-Be aware that the clocksource driver supports only uniprocessor systems.
-
-Required properties:
-- compatible : should be one of following:
-samsung,s3c2410-pwm - for 16-bit timers present on S3C24xx SoCs
-samsung,s3c6400-pwm - for 32-bit timers present on S3C64xx SoCs
-samsung,s5p6440-pwm - for 32-bit timers present on S5P64x0 SoCs
-samsung,s5pc100-pwm - for 32-bit timers present on S5PC100, S5PV210,
- Exynos4210 rev0 SoCs
-samsung,exynos4210-pwm - for 32-bit timers present on Exynos4210,
-  Exynos4x12, Exynos5250 and Exynos5420 SoCs
-- reg: base address and size of register area
-- interrupts: list of timer interrupts (one interrupt per timer, starting at
-  timer 0)
-- clock-names: should contain all following required clock names:
-- "timers" - PWM base clock used to generate PWM signals,
-  and any subset of following optional clock names:
-- "pwm-tclk0" - first external PWM clock source,
-- "pwm-tclk1" - second external PWM clock source.
-  Note that not all IP variants allow using all external clock sources.
-  Refer to SoC documentation to learn which clock source configurations
-  are available.
-- clocks: should contain clock specifiers of all clocks, which input names
-  have been specified in clock-names property, in same order.
-- #pwm-cells: should be 3. See pwm.txt in this directory for a description of
-  the cells format. The only third cell flag supported by this binding is
-  PWM_POLARITY_INVERTED.
-
-Optional properties:
-- samsung,pwm-outputs: list of PWM channels used as PWM outputs on particular
-platform - an array of up to 5 elements being indices of PWM channels
-(from 0 to 4), the order does not matter.
-
-Example:
-   pwm@7f006000 {
-   compatible = "samsung,s3c6400-pwm";
-   reg = <0x7f006000 0x1000>;
-   interrupt-parent = <>;
-   interrupts = <23>, <24>, <25>, <27>, <28>;
-   clocks = < 67>;
-   clock-names = "timers";
-   samsung,pwm-outputs = <0>, <1>;
-   #pwm-cells = <3>;
-   }
diff --git a/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml 
b/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml
new file mode 100644
index ..06d11faabff6
--- /dev/null
+++ b/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml
@@ -0,0 +1,107 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/pwm/pwm-samsung.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung SoC PWM timers
+
+maintainers:
+  - Thierry Reding 
+  - Krzysztof Kozlowski 
+
+description: |+
+  Samsung SoCs contain PWM timer blocks which can be used for system clock 
source
+  and clock event timers, as well as to drive SoC outputs with PWM signal. Each
+  PWM timer block provides 5 PWM channels (not all of them can drive physical
+  outputs - see SoC and board manual).
+
+  Be aware that the clocksource driver supports only uniprocessor systems.
+
+allOf:
+  - $ref: pwm.yaml#
+
+properties:
+  compatible:
+enum:
+  - samsung,s3c2410-pwm # 16-bit, S3C24xx
+  - samsung,s3c6400-pwm # 32-bit, S3C64xx
+  - samsung,s5p6440-pwm # 32-bit, S5P64x0
+  - samsung,s5pc100-pwm # 32-bit, S5PC100, S5PV210, Exynos4210 
rev0 SoCs
+  - samsung,exynos4210-pwm  # 32-bit, Exynos
+
+  reg:
+maxItems: 1
+
+  clocks:
+minItems: 1
+maxItems: 3
+
+  clock-names:
+description: |
+  Should contain all following required clock names:
+  - "timers" - PWM base clock us

[PATCH v2 3/8] dt-bindings: sram: Convert Samsung Exynos SYSRAM bindings to json-schema

2019-09-18 Thread Krzysztof Kozlowski
Convert Samsung Exynos SYSRAM bindings to DT schema format using
json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

TODO:
The node naming should be probably fixed (sysram->sram)

Changes since v1:
1. Indent example with four spaces (more readable).
---
 .../devicetree/bindings/sram/samsung-sram.txt | 38 
 .../bindings/sram/samsung-sram.yaml   | 58 +++
 MAINTAINERS   |  2 +-
 3 files changed, 59 insertions(+), 39 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/sram/samsung-sram.txt
 create mode 100644 Documentation/devicetree/bindings/sram/samsung-sram.yaml

diff --git a/Documentation/devicetree/bindings/sram/samsung-sram.txt 
b/Documentation/devicetree/bindings/sram/samsung-sram.txt
deleted file mode 100644
index 61a9bbed303d..
--- a/Documentation/devicetree/bindings/sram/samsung-sram.txt
+++ /dev/null
@@ -1,38 +0,0 @@
-Samsung Exynos SYSRAM for SMP bringup:
-
-
-Samsung SMP-capable Exynos SoCs use part of the SYSRAM for the bringup
-of the secondary cores. Once the core gets powered up it executes the
-code that is residing at some specific location of the SYSRAM.
-
-Therefore reserved section sub-nodes have to be added to the mmio-sram
-declaration. These nodes are of two types depending upon secure or
-non-secure execution environment.
-
-Required sub-node properties:
-- compatible : depending upon boot mode, should be
-   "samsung,exynos4210-sysram" : for Secure SYSRAM
-   "samsung,exynos4210-sysram-ns" : for Non-secure SYSRAM
-
-The rest of the properties should follow the generic mmio-sram discription
-found in Documentation/devicetree/bindings/sram/sram.txt
-
-Example:
-
-   sysram@202 {
-   compatible = "mmio-sram";
-   reg = <0x0202 0x54000>;
-   #address-cells = <1>;
-   #size-cells = <1>;
-   ranges = <0 0x0202 0x54000>;
-
-   smp-sysram@0 {
-   compatible = "samsung,exynos4210-sysram";
-   reg = <0x0 0x1000>;
-   };
-
-   smp-sysram@53000 {
-   compatible = "samsung,exynos4210-sysram-ns";
-   reg = <0x53000 0x1000>;
-   };
-   };
diff --git a/Documentation/devicetree/bindings/sram/samsung-sram.yaml 
b/Documentation/devicetree/bindings/sram/samsung-sram.yaml
new file mode 100644
index ..f49b3b58eb5c
--- /dev/null
+++ b/Documentation/devicetree/bindings/sram/samsung-sram.yaml
@@ -0,0 +1,58 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/sram/samsung-sram.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung Exynos SoC SYSRAM for SMP bringup
+
+maintainers:
+  - Krzysztof Kozlowski 
+
+description: |+
+  Samsung SMP-capable Exynos SoCs use part of the SYSRAM for the bringup
+  of the secondary cores. Once the core gets powered up it executes the
+  code that is residing at some specific location of the SYSRAM.
+
+  Therefore reserved section sub-nodes have to be added to the mmio-sram
+  declaration. These nodes are of two types depending upon secure or
+  non-secure execution environment.
+
+allOf:
+  - $ref: "sram.yaml#"
+
+properties:
+  $nodename:
+pattern: "^sysram(@.*)?"
+
+patternProperties:
+  "^([a-z]*-)?sysram@[a-f0-9]$":
+type: object
+
+properties:
+  compatible:
+description:
+  Depending upon boot mode
+enum:
+  - samsung,exynos4210-sysram # for Secure SYSRAM
+  - samsung,exynos4210-sysram-ns  # for Non-secure SYSRAM
+
+examples:
+  - |
+sysram@202 {
+compatible = "mmio-sram";
+reg = <0x0202 0x54000>;
+#address-cells = <1>;
+#size-cells = <1>;
+ranges = <0 0x0202 0x54000>;
+
+smp-sysram@0 {
+compatible = "samsung,exynos4210-sysram";
+reg = <0x0 0x1000>;
+};
+
+smp-sysram@53000 {
+compatible = "samsung,exynos4210-sysram-ns";
+reg = <0x53000 0x1000>;
+};
+};
diff --git a/MAINTAINERS b/MAINTAINERS
index 9cec4494b9a8..c49d35dce088 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2225,7 +2225,7 @@ F:drivers/soc/samsung/
 F: include/linux/soc/samsung/
 F: Documentation/arm/samsung/
 F: Documentation/devicetree/bindings/arm/samsung/
-F: Documentation/devicetree/bindings/sram/samsung-sram.txt
+F: Documentation/devicetree/bindings/sram/samsung-sram.yaml
 F: Documentation/devicetree/bindings/power/pd-samsung.txt
 N: exynos
 
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH v2 6/8] dt-bindings: watchdog: Add missing clocks requirement in Samsung SoC watchdog

2019-09-18 Thread Krzysztof Kozlowski
The Samsung SoC watchdog driver always required providing a clock
(either through platform data or from DT).  However when bindings were
added in commit 9487a9cc7140 ("watchdog: s3c2410: Add support for device
tree based probe"), they missed the requirement of clock.

Signed-off-by: Krzysztof Kozlowski 
Reviewed-by: Rob Herring 

---

Changes since v1:
1. Indent example with four spaces (more readable),
2. Add also missing required entries for clocks.
---
 .../devicetree/bindings/watchdog/samsung-wdt.yaml| 9 +
 1 file changed, 9 insertions(+)

diff --git a/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml 
b/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml
index 3ea3c9fe8390..311f9dc83fdb 100644
--- a/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml
+++ b/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml
@@ -26,6 +26,13 @@ properties:
   reg:
 maxItems: 1
 
+  clocks:
+maxItems: 1
+
+  clock-names:
+items:
+  - const: watchdog
+
   interrupts:
 maxItems: 1
 
@@ -40,6 +47,8 @@ properties:
 
 required:
   - compatible
+  - clocks
+  - clock-names
   - interrupts
   - reg
 
-- 
2.17.1



Re: [PATCH v2] dt-bindings: gpu: Convert Samsung Image Rotator to dt-schema

2019-09-13 Thread Krzysztof Kozlowski
On Thu, Sep 12, 2019 at 06:15:38PM +0200, Maciej Falkowski wrote:
> Convert Samsung Image Rotator to newer dt-schema format.
> 
> Signed-off-by: Maciej Falkowski 
> Signed-off-by: Marek Szyprowski 

Just to make it clear, Marek's signed-off should appear for one of
conditions:
 - he contributed some source code to your patch,
 - he took your patch, rebased, send by himself (not a case here, I
   think),
 - he contributed significant ideas, although for this there is a
   "Co-developed-by" tag.

If someone made just review - add Reviewed-by. If someone suggested the
patch - add Suggested-by.

> ---
> v2:
> - add required properties
> - add proper commit recipients
> ---
>  .../bindings/gpu/samsung-rotator.txt  | 28 --
>  .../bindings/gpu/samsung-rotator.yaml | 52 +++
>  2 files changed, 52 insertions(+), 28 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-rotator.txt
>  create mode 100644 Documentation/devicetree/bindings/gpu/samsung-rotator.yaml
> 
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-rotator.txt 
> b/Documentation/devicetree/bindings/gpu/samsung-rotator.txt
> deleted file mode 100644
> index 3aca2578da0b..
> --- a/Documentation/devicetree/bindings/gpu/samsung-rotator.txt
> +++ /dev/null
> @@ -1,28 +0,0 @@
> -* Samsung Image Rotator
> -
> -Required properties:
> -  - compatible : value should be one of the following:
> - * "samsung,s5pv210-rotator" for Rotator IP in S5PV210
> - * "samsung,exynos4210-rotator" for Rotator IP in Exynos4210
> - * "samsung,exynos4212-rotator" for Rotator IP in Exynos4212/4412
> - * "samsung,exynos5250-rotator" for Rotator IP in Exynos5250
> -
> -  - reg : Physical base address of the IP registers and length of memory
> -   mapped region.
> -
> -  - interrupts : Interrupt specifier for rotator interrupt, according to 
> format
> -  specific to interrupt parent.
> -
> -  - clocks : Clock specifier for rotator clock, according to generic clock
> -  bindings. (See Documentation/devicetree/bindings/clock/exynos*.txt)
> -
> -  - clock-names : Names of clocks. For exynos rotator, it should be 
> "rotator".
> -
> -Example:
> - rotator@1281 {
> - compatible = "samsung,exynos4210-rotator";
> - reg = <0x1281 0x1000>;
> - interrupts = <0 83 0>;
> - clocks = < 278>;
> - clock-names = "rotator";
> - };
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-rotator.yaml 
> b/Documentation/devicetree/bindings/gpu/samsung-rotator.yaml
> new file mode 100644
> index ..96afafe98388
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpu/samsung-rotator.yaml
> @@ -0,0 +1,52 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpu/samsung-rotator.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Samsung Image Rotator

Thanks Maciej for working on this.

I am trying to make the names more consistent:
1. For Exynos bindings:
Samsung Exynos SoC xxx yyy zzz

2. For multiple SoCs (S3C, S5P, Exynos etc):
Samsung SoC xxx yyy zzz

Currently the names are mixture of legacy and new names. It is a
nit-pick but makes all bindings look like a part of bigger effort, not
bunch of patches done by random people. :)

If there are no objections, maybe you could change it to:
Samsung SoC Image Rotator

> +
> +maintainers:
> +  - Inki Dae 
> +
> +properties:
> +  compatible:
> +enum:
> +  - "samsung,s5pv210-rotator"# for Rotator IP in S5PV210
> +  - "samsung,exynos4210-rotator" # for Rotator IP in Exynos4210
> +  - "samsung,exynos4212-rotator" # for Rotator IP in Exynos4212/4412
> +  - "samsung,exynos5250-rotator" # for Rotator IP in Exynos5250

The comments are duplicating the compatible, so skip them.

> +  reg:
> +maxItems: 1
> +
> +  interrupts:
> +maxItems: 1
> +
> +  clocks:
> +description: |
> +  Clock specifier for rotator clock according to generic clock
> +  bindings. (See Documentation/devicetree/bindings/clock/exynos*.txt)

Skip the description. Clocks property is a well-known binding.

> +maxItems: 1
> +
> +  clock-names:
> +items:
> +- const: rotator
> +maxItems: 1

I think there is no need to maxItems since all possible items are fixed.

Best regards,
Krzysztof


> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - clock-names
> +
> +examples:
> +  - |
> +rotator@1281 {
> +compatible = "samsung,exynos4210-rotator";
> +reg = <0x1281 0x1000>;
> +interrupts = <0 83 0>;
> +clocks = < 278>;
> +clock-names = "rotator";
> +};
> +
> -- 
> 2.17.1
> 
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [RFC PATCH 01/11] devfreq: exynos-bus: Extract exynos_bus_profile_init()

2019-08-05 Thread Krzysztof Kozlowski
On Wed, 31 Jul 2019 at 15:00, Artur Świgoń  wrote:
>
> Hi,
>
> On Wed, 2019-07-24 at 21:07 +0200, Krzysztof Kozlowski wrote:
> > On Tue, Jul 23, 2019 at 02:20:06PM +0200, Artur Świgoń wrote:
> > > This patch adds a new static function, exynos_bus_profile_init(), 
> > > extracted
> > > from exynos_bus_probe().
> > >
> > > Signed-off-by: Artur Świgoń 
> > > ---
> > >  drivers/devfreq/exynos-bus.c | 106 ---
> > >  1 file changed, 60 insertions(+), 46 deletions(-)
> > >
> > > diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq/exynos-bus.c
> > > index d9f377912c10..d8f1efaf2d49 100644
> > > --- a/drivers/devfreq/exynos-bus.c
> > > +++ b/drivers/devfreq/exynos-bus.c
> > > @@ -372,12 +372,69 @@ static int exynos_bus_parse_of(struct device_node 
> > > *np,
> > > return ret;
> > >  }
> > >
> > > +static int exynos_bus_profile_init(struct exynos_bus *bus,
> > > +  struct devfreq_dev_profile *profile)
> > > +{
> > > +   struct device *dev = bus->dev;
> > > +   struct devfreq_simple_ondemand_data *ondemand_data;
> > > +   int ret;
> > > +
> > > +   /* Initialize the struct profile and governor data for parent device 
> > > */
> > > +   profile->polling_ms = 50;
> > > +   profile->target = exynos_bus_target;
> > > +   profile->get_dev_status = exynos_bus_get_dev_status;
> > > +   profile->exit = exynos_bus_exit;
> > > +
> > > +   ondemand_data = devm_kzalloc(dev, sizeof(*ondemand_data), GFP_KERNEL);
> > > +   if (!ondemand_data) {
> > > +   ret = -ENOMEM;
> > > +   goto err;
> >
> > Just return proper error code. Less lines, obvious code since you do not
> > have any cleanup in error path.
>
> I was advised to avoid modifying code being moved (in one patch). I do make
> changes in these places in patch 04/11, i.e. change the original label 'err' 
> to
> 'out'. What's your opinion on making the proposed changes to patches 01 and 02
> (s/goto err/return ret/) in patch 04 instead?

Yes, you're right. I also prefer not to touch moved code.

Best regards,
Krzysztof


Re: [RFC PATCH 04/11] devfreq: exynos-bus: Clean up code

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:09PM +0200, Artur Świgoń wrote:
> This patch adds minor improvements to the exynos-bus driver.
> 
> Signed-off-by: Artur Świgoń 
> ---
>  drivers/devfreq/exynos-bus.c | 49 
>  1 file changed, 22 insertions(+), 27 deletions(-)

Reviewed-by: Krzysztof Kozlowski 

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [RFC PATCH 08/11] arm: dts: exynos: Add parents and #interconnect-cells to Exynos4412

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:13PM +0200, Artur Świgoń wrote:
> This patch adds two fields tp the Exynos4412 DTS:

tp->to

>   - parent: to declare connections between nodes that are not in a
> parent-child relation in devfreq;

Is it a standard property?
The explanation needs some improvement... why are you adding parent to a
devices which are not child-parent?

Best regards,
Krzysztof

>   - #interconnect-cells: required by the interconnect framework.
> 
> Please note that #interconnect-cells is always zero and node IDs are not
> hardcoded anywhere.
> 
> Signed-off-by: Artur Świgoń 
> ---
>  arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 1 +
>  arch/arm/boot/dts/exynos4412.dtsi   | 9 +
>  2 files changed, 10 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/exynos4412-odroid-common.dtsi 
> b/arch/arm/boot/dts/exynos4412-odroid-common.dtsi
> index ea55f377d17c..bdd61ae86103 100644
> --- a/arch/arm/boot/dts/exynos4412-odroid-common.dtsi
> +++ b/arch/arm/boot/dts/exynos4412-odroid-common.dtsi
> @@ -106,6 +106,7 @@
>  _leftbus {
>   devfreq-events = <_leftbus_3>, <_rightbus_3>;
>   vdd-supply = <_reg>;
> + parent = <_dmc>;
>   status = "okay";
>  };
>  
> diff --git a/arch/arm/boot/dts/exynos4412.dtsi 
> b/arch/arm/boot/dts/exynos4412.dtsi
> index d20db2dfe8e2..a70a671acacd 100644
> --- a/arch/arm/boot/dts/exynos4412.dtsi
> +++ b/arch/arm/boot/dts/exynos4412.dtsi
> @@ -390,6 +390,7 @@
>   clocks = < CLK_DIV_DMC>;
>   clock-names = "bus";
>   operating-points-v2 = <_dmc_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -398,6 +399,7 @@
>   clocks = < CLK_DIV_ACP>;
>   clock-names = "bus";
>   operating-points-v2 = <_acp_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -406,6 +408,7 @@
>   clocks = < CLK_DIV_C2C>;
>   clock-names = "bus";
>   operating-points-v2 = <_dmc_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -459,6 +462,7 @@
>   clocks = < CLK_DIV_GDL>;
>   clock-names = "bus";
>   operating-points-v2 = <_leftbus_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -467,6 +471,7 @@
>   clocks = < CLK_DIV_GDR>;
>   clock-names = "bus";
>   operating-points-v2 = <_leftbus_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -475,6 +480,7 @@
>   clocks = < CLK_ACLK160>;
>   clock-names = "bus";
>   operating-points-v2 = <_display_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -483,6 +489,7 @@
>   clocks = < CLK_ACLK133>;
>   clock-names = "bus";
>   operating-points-v2 = <_fsys_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -491,6 +498,7 @@
>   clocks = < CLK_ACLK100>;
>   clock-names = "bus";
>   operating-points-v2 = <_peri_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> @@ -499,6 +507,7 @@
>   clocks = < CLK_SCLK_MFC>;
>   clock-names = "bus";
>   operating-points-v2 = <_leftbus_opp_table>;
> + #interconnect-cells = <0>;
>   status = "disabled";
>   };
>  
> -- 
> 2.17.1
> 
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [RFC PATCH 11/11] drm: exynos: mixer: Add interconnect support

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:16PM +0200, Artur Świgoń wrote:
> From: Marek Szyprowski 
> 
> This patch adds interconnect support to exynos-mixer. Please note that the
> mixer works the same as before when CONFIG_INTERCONNECT is 'n'.
> 
> Co-developed-by: Artur Świgoń 
> Signed-off-by: Artur Świgoń 
> Signed-off-by: Marek Szyprowski 
> ---
>  drivers/gpu/drm/exynos/exynos_mixer.c | 68 +--
>  1 file changed, 63 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c 
> b/drivers/gpu/drm/exynos/exynos_mixer.c
> index 7b24338fad3c..fb763854b300 100644
> --- a/drivers/gpu/drm/exynos/exynos_mixer.c
> +++ b/drivers/gpu/drm/exynos/exynos_mixer.c
> @@ -13,6 +13,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  #include 
>  #include 
>  #include 
> @@ -97,6 +98,7 @@ struct mixer_context {
>   struct exynos_drm_crtc  *crtc;
>   struct exynos_drm_plane planes[MIXER_WIN_NR];
>   unsigned long   flags;
> + struct icc_path *soc_path;
>  
>   int irq;
>   void __iomem*mixer_regs;
> @@ -931,6 +933,37 @@ static void mixer_disable_vblank(struct exynos_drm_crtc 
> *crtc)
>   mixer_reg_writemask(mixer_ctx, MXR_INT_EN, 0, MXR_INT_EN_VSYNC);
>  }
>  
> +static void mixer_set_memory_bandwidth(struct exynos_drm_crtc *crtc)
> +{
> + struct drm_display_mode *mode = >base.state->adjusted_mode;
> + struct mixer_context *ctx = crtc->ctx;
> + unsigned long bw, bandwidth = 0;
> + int i, j, sub;
> +

Early exit if !ctx->soc_path, no need to figure out the bandwidth.
Optionally check it before calling mixer_set_memory_bandwidth() - should
not hurt readability.

> + for (i = 0; i < MIXER_WIN_NR; i++) {
> + struct drm_plane *plane = >planes[i].base;
> + const struct drm_format_info *format;
> +
> + if (plane->state && plane->state->crtc && plane->state->fb) {
> + format = plane->state->fb->format;
> + bw = mode->hdisplay * mode->vdisplay *
> + drm_mode_vrefresh(mode);
> + if (mode->flags & DRM_MODE_FLAG_INTERLACE)
> + bw /= 2;
> + for (j = 0; j < format->num_planes; j++) {
> + sub = j ? (format->vsub * format->hsub) : 1;
> + bandwidth += format->cpp[j] * bw / sub;
> + }
> + }
> + }
> +
> + /* add 20% safety margin */
> + bandwidth = 5UL * bandwidth / 4;
> +
> + pr_info("exynos-mixer: safe bandwidth %ld Bps\n", bandwidth);

dev_dbg()

Best regards,
Krzysztof


___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [RFC PATCH 00/11] Simple QoS for exynos-bus driver using interconnect

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:05PM +0200, Artur Świgoń wrote:
> The following patchset adds interconnect[1][2] framework support to the
> exynos-bus devfreq driver. Extending the devfreq driver with interconnect
> capabilities started as a response to the issue referenced in [3]. The
> patches can be subdivided into four logical groups:

Nice work! Good to see proper solution :)

Best regards,
Krzysztof



Re: [RFC PATCH 09/11] devfreq: exynos-bus: Add interconnect functionality to exynos-bus

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:14PM +0200, Artur Świgoń wrote:
> This patch adds interconnect functionality to the exynos-bus devfreq
> driver.
> 
> The SoC topology is a graph (or, more specifically, a tree) and most of its
> edges are taken from the devfreq parent-child hierarchy (cf.
> Documentation/devicetree/bindings/devfreq/exynos-bus.txt). The previous
> patch adds missing edges to the DT (under the name 'parent'). Due to

Do not refer to DT patches. They will come through different tree so
"previous" will not be correct anymore. You mentioned dependencies in
cover letter so it is sufficient.

> unspecified relative probing order, -EPROBE_DEFER may be propagated to
> guarantee that a child is probed before its parent.
> 
> Each bus is now an interconnect provider and an interconnect node as well
> (cf. Documentation/interconnect/interconnect.rst), i.e. every bus registers
> itself as a node. Node IDs are not hardcoded but rather assigned at
> runtime, in probing order (subject to the above-mentioned exception
> regarding relative order). This approach allows for using this driver with
> various Exynos SoCs.
> 
> The devfreq target() callback provided by exynos-bus now selects either the
> frequency calculated by the devfreq governor or the frequency requested via
> the interconnect API for the given node, whichever is higher.
> 
> Please note that it is not an error when CONFIG_INTERCONNECT is 'n', in
> which case all interconnect API functions are no-op.
> 
> Signed-off-by: Artur Świgoń 
> ---
>  drivers/devfreq/exynos-bus.c | 145 +++
>  1 file changed, 145 insertions(+)
> 
> diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq/exynos-bus.c
> index 412511ca7703..12fb7c84ae50 100644
> --- a/drivers/devfreq/exynos-bus.c
> +++ b/drivers/devfreq/exynos-bus.c
> @@ -14,6 +14,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  #include 
>  #include 
>  #include 
> @@ -23,6 +24,8 @@
>  #define DEFAULT_SATURATION_RATIO 40
>  #define DEFAULT_VOLTAGE_TOLERANCE2
>  
> +#define icc_units_to_hz(x) ((x) * 1000UL / 8)
> +
>  struct exynos_bus {
>   struct device *dev;
>  
> @@ -31,12 +34,17 @@ struct exynos_bus {
>   unsigned int edev_count;
>   struct mutex lock;
>  
> + unsigned long min_freq;
>   unsigned long curr_freq;
>  
>   struct regulator *regulator;
>   struct clk *clk;
>   unsigned int voltage_tolerance;
>   unsigned int ratio;
> +
> + /* One provider per bus, one node per provider */
> + struct icc_provider provider;
> + struct icc_node *node;
>  };
>  
>  /*
> @@ -61,6 +69,13 @@ exynos_bus_ops_edev(enable_edev);
>  exynos_bus_ops_edev(disable_edev);
>  exynos_bus_ops_edev(set_event);
>  
> +static int exynos_bus_next_id(void)
> +{
> + static int exynos_bus_node_id;
> +
> + return exynos_bus_node_id++;

This does not look robust. Use IDR for IDs. 

> +}
> +
>  static int exynos_bus_get_event(struct exynos_bus *bus,
>   struct devfreq_event_data *edata)
>  {
> @@ -98,6 +113,8 @@ static int exynos_bus_target(struct device *dev, unsigned 
> long *freq, u32 flags)
>   unsigned long old_freq, new_freq, new_volt, tol;
>   int ret = 0;
>  
> + *freq = max(*freq, bus->min_freq);
> +
>   /* Get new opp-bus instance according to new bus clock */
>   new_opp = devfreq_recommended_opp(dev, freq, flags);
>   if (IS_ERR(new_opp)) {
> @@ -208,6 +225,8 @@ static int exynos_bus_passive_target(struct device *dev, 
> unsigned long *freq,
>   unsigned long old_freq, new_freq;
>   int ret = 0;
>  
> + *freq = max(*freq, bus->min_freq);
> +
>   /* Get new opp-bus instance according to new bus clock */
>   new_opp = devfreq_recommended_opp(dev, freq, flags);
>   if (IS_ERR(new_opp)) {
> @@ -251,6 +270,35 @@ static void exynos_bus_passive_exit(struct device *dev)
>   clk_disable_unprepare(bus->clk);
>  }
>  
> +static int exynos_bus_icc_set(struct icc_node *src, struct icc_node *dst)
> +{
> + struct exynos_bus *src_bus = src->data, *dst_bus = dst->data;
> +
> + src_bus->min_freq = icc_units_to_hz(src->peak_bw);
> + dst_bus->min_freq = icc_units_to_hz(dst->peak_bw);
> +
> + return 0;
> +}
> +
> +static int exynos_bus_icc_aggregate(struct icc_node *node, u32 avg_bw,
> + u32 peak_bw, u32 *agg_avg, u32 *agg_peak)
> +{
> + *agg_peak = *agg_avg = peak_bw;
> +
> + return 0;
> +}
> +
> +static struct icc_node *exynos_bus_icc_xlate(struct of_phandle_args *spec,
> +  void *data)
> +{
> + struct exynos_bus *bus = data;
> +
> + if (spec->np != bus->dev->of_node)
> + return ERR_PTR(-EINVAL);
> +
> + return bus->node;
> +}
> +
>  static int exynos_bus_parent_parse_of(struct device_node *np,
>   struct exynos_bus *bus)
>  {
> @@ -469,6 +517,95 @@ static int exynos_bus_profile_init_passive(struct 
> 

Re: [RFC PATCH 03/11] devfreq: exynos-bus: Change goto-based logic to if-else logic

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:08PM +0200, Artur Świgoń wrote:
> This patch improves code readability by changing the following construct:
> 
> >if (cond)
> >goto passive;
> >foo();
> >goto out;
> >passive:
> >bar();
> >out:
> 
> into this:
> 
> >if (cond)
> >bar();
> >else
> >foo();
> 
> Signed-off-by: Artur Świgoń 
> ---
>  drivers/devfreq/exynos-bus.c | 24 +---
>  1 file changed, 9 insertions(+), 15 deletions(-)

Code looks much better:
Reviewed-by: Krzysztof Kozlowski 

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [RFC PATCH 01/11] devfreq: exynos-bus: Extract exynos_bus_profile_init()

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:06PM +0200, Artur Świgoń wrote:
> This patch adds a new static function, exynos_bus_profile_init(), extracted
> from exynos_bus_probe().
> 
> Signed-off-by: Artur Świgoń 
> ---
>  drivers/devfreq/exynos-bus.c | 106 ---
>  1 file changed, 60 insertions(+), 46 deletions(-)
> 
> diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq/exynos-bus.c
> index d9f377912c10..d8f1efaf2d49 100644
> --- a/drivers/devfreq/exynos-bus.c
> +++ b/drivers/devfreq/exynos-bus.c
> @@ -372,12 +372,69 @@ static int exynos_bus_parse_of(struct device_node *np,
>   return ret;
>  }
>  
> +static int exynos_bus_profile_init(struct exynos_bus *bus,
> +struct devfreq_dev_profile *profile)
> +{
> + struct device *dev = bus->dev;
> + struct devfreq_simple_ondemand_data *ondemand_data;
> + int ret;
> +
> + /* Initialize the struct profile and governor data for parent device */
> + profile->polling_ms = 50;
> + profile->target = exynos_bus_target;
> + profile->get_dev_status = exynos_bus_get_dev_status;
> + profile->exit = exynos_bus_exit;
> +
> + ondemand_data = devm_kzalloc(dev, sizeof(*ondemand_data), GFP_KERNEL);
> + if (!ondemand_data) {
> + ret = -ENOMEM;
> + goto err;

Just return proper error code. Less lines, obvious code since you do not
have any cleanup in error path.

> + }
> + ondemand_data->upthreshold = 40;
> + ondemand_data->downdifferential = 5;
> +
> + /* Add devfreq device to monitor and handle the exynos bus */
> + bus->devfreq = devm_devfreq_add_device(dev, profile,
> + DEVFREQ_GOV_SIMPLE_ONDEMAND,
> + ondemand_data);
> + if (IS_ERR(bus->devfreq)) {
> + dev_err(dev, "failed to add devfreq device\n");
> + ret = PTR_ERR(bus->devfreq);
> + goto err;
> + }
> +
> + /* Register opp_notifier to catch the change of OPP  */
> + ret = devm_devfreq_register_opp_notifier(dev, bus->devfreq);
> + if (ret < 0) {
> + dev_err(dev, "failed to register opp notifier\n");
> + goto err;

The same - return err.

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [RFC PATCH 06/11] icc: Relax requirement in of_icc_get_from_provider()

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:11PM +0200, Artur Świgoń wrote:
> This patch relaxes the condition in of_icc_get_from_provider() so that it
> is no longer required to set #interconnect-cells = <1> in the DT. In case
> of the devfreq driver for exynos-bus, #interconnect-cells is always zero.
> 
> Signed-off-by: Artur Świgoń 
> ---

Makes sense to me:
Acked-by: Krzysztof Kozlowski 

Best regards,
Krzysztof


Re: [RFC PATCH 05/11] icc: Export of_icc_get_from_provider()

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:10PM +0200, Artur Świgoń wrote:
> This patch makes the above function public (for use in exynos-bus devfreq
> driver).
> 
> Signed-off-by: Artur Świgoń 
> ---
>  drivers/interconnect/core.c   | 3 ++-
>  include/linux/interconnect-provider.h | 6 ++
>  2 files changed, 8 insertions(+), 1 deletion(-)

Reviewed-by: Krzysztof Kozlowski 

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [RFC PATCH 02/11] devfreq: exynos-bus: Extract exynos_bus_profile_init_passive()

2019-07-24 Thread Krzysztof Kozlowski
On Tue, Jul 23, 2019 at 02:20:07PM +0200, Artur Świgoń wrote:
> This patch adds a new static function, exynos_bus_profile_init_passive(),
> extracted from exynos_bus_probe().
> 
> Signed-off-by: Artur Świgoń 
> ---
>  drivers/devfreq/exynos-bus.c | 70 +---
>  1 file changed, 42 insertions(+), 28 deletions(-)
> 
> diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq/exynos-bus.c
> index d8f1efaf2d49..cf6f6cbd0f55 100644
> --- a/drivers/devfreq/exynos-bus.c
> +++ b/drivers/devfreq/exynos-bus.c
> @@ -430,13 +430,51 @@ static int exynos_bus_profile_init(struct exynos_bus 
> *bus,
>   return ret;
>  }
>  
> +static int exynos_bus_profile_init_passive(struct exynos_bus *bus,
> +struct devfreq_dev_profile *profile)
> +{
> + struct device *dev = bus->dev;
> + struct devfreq *parent_devfreq;
> + struct devfreq_passive_data *passive_data;
> + int ret = 0;
> +
> + /* Initialize the struct profile and governor data for passive device */
> + profile->target = exynos_bus_passive_target;
> + profile->exit = exynos_bus_passive_exit;
> +
> + /* Get the instance of parent devfreq device */
> + parent_devfreq = devfreq_get_devfreq_by_phandle(dev, 0);
> + if (IS_ERR(parent_devfreq)) {
> + ret = -EPROBE_DEFER;
> + goto err;

Same as in previous patch - no need for error goto.

Best regards,
Krzysztof



Re: [RFC PATCH 01/11] devfreq: exynos-bus: Extract exynos_bus_profile_init()

2019-07-26 Thread Krzysztof Kozlowski
On Thu, 25 Jul 2019 at 14:44, Chanwoo Choi  wrote:
>
> 2019년 7월 24일 (수) 오전 8:09, Artur Świgoń 님이 작성:
> >
> > This patch adds a new static function, exynos_bus_profile_init(), extracted
> > from exynos_bus_probe().
> >
> > Signed-off-by: Artur Świgoń 
> > ---
> >  drivers/devfreq/exynos-bus.c | 106 ---
> >  1 file changed, 60 insertions(+), 46 deletions(-)
> >
> > diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq/exynos-bus.c
> > index d9f377912c10..d8f1efaf2d49 100644
> > --- a/drivers/devfreq/exynos-bus.c
> > +++ b/drivers/devfreq/exynos-bus.c
> > @@ -372,12 +372,69 @@ static int exynos_bus_parse_of(struct device_node *np,
> > return ret;
> >  }
> >
> > +static int exynos_bus_profile_init(struct exynos_bus *bus,
> > +  struct devfreq_dev_profile *profile)
> > +{
> > +   struct device *dev = bus->dev;
> > +   struct devfreq_simple_ondemand_data *ondemand_data;
> > +   int ret;
> > +
> > +   /* Initialize the struct profile and governor data for parent 
> > device */
> > +   profile->polling_ms = 50;
> > +   profile->target = exynos_bus_target;
> > +   profile->get_dev_status = exynos_bus_get_dev_status;
> > +   profile->exit = exynos_bus_exit;
> > +
> > +   ondemand_data = devm_kzalloc(dev, sizeof(*ondemand_data), 
> > GFP_KERNEL);
> > +   if (!ondemand_data) {
> > +   ret = -ENOMEM;
> > +   goto err;
> > +   }
> > +   ondemand_data->upthreshold = 40;
> > +   ondemand_data->downdifferential = 5;
> > +
> > +   /* Add devfreq device to monitor and handle the exynos bus */
> > +   bus->devfreq = devm_devfreq_add_device(dev, profile,
> > +   DEVFREQ_GOV_SIMPLE_ONDEMAND,
> > +   ondemand_data);
> > +   if (IS_ERR(bus->devfreq)) {
> > +   dev_err(dev, "failed to add devfreq device\n");
> > +   ret = PTR_ERR(bus->devfreq);
> > +   goto err;
> > +   }
> > +
> > +   /* Register opp_notifier to catch the change of OPP  */
> > +   ret = devm_devfreq_register_opp_notifier(dev, bus->devfreq);
> > +   if (ret < 0) {
> > +   dev_err(dev, "failed to register opp notifier\n");
> > +   goto err;
> > +   }
> > +
> > +   /*
> > +* Enable devfreq-event to get raw data which is used to determine
> > +* current bus load.
> > +*/
> > +   ret = exynos_bus_enable_edev(bus);
> > +   if (ret < 0) {
> > +   dev_err(dev, "failed to enable devfreq-event devices\n");
> > +   goto err;
> > +   }
> > +
> > +   ret = exynos_bus_set_event(bus);
> > +   if (ret < 0) {
> > +   dev_err(dev, "failed to set event to devfreq-event 
> > devices\n");
> > +   goto err;
> > +   }
> > +
> > +err:
> > +   return ret;
> > +}
> > +
> >  static int exynos_bus_probe(struct platform_device *pdev)
> >  {
> > struct device *dev = >dev;
> > struct device_node *np = dev->of_node, *node;
> > struct devfreq_dev_profile *profile;
> > -   struct devfreq_simple_ondemand_data *ondemand_data;
> > struct devfreq_passive_data *passive_data;
> > struct devfreq *parent_devfreq;
> > struct exynos_bus *bus;
> > @@ -418,52 +475,9 @@ static int exynos_bus_probe(struct platform_device 
> > *pdev)
> > if (ret < 0)
> > goto err;
> >
> > -   /* Initialize the struct profile and governor data for parent 
> > device */
> > -   profile->polling_ms = 50;
> > -   profile->target = exynos_bus_target;
> > -   profile->get_dev_status = exynos_bus_get_dev_status;
> > -   profile->exit = exynos_bus_exit;
> > -
> > -   ondemand_data = devm_kzalloc(dev, sizeof(*ondemand_data), 
> > GFP_KERNEL);
> > -   if (!ondemand_data) {
> > -   ret = -ENOMEM;
> > +   ret = exynos_bus_profile_init(bus, profile);
> > +   if (ret < 0)
> > goto err;
> > -   }
> > -   ondemand_data->upthreshold = 40;
> > -   ondemand_data->downdifferential = 5;
> > -
> > -   /* Add devfreq device to monitor and handle the exynos bus */
> > -   bus->devfreq = devm_devfreq_add_device(dev, profile,
> > -   DEVFREQ_GOV_SIMPLE_ONDEMAND,
> > -   ondemand_data);
> > -   if (IS_ERR(bus->devfreq)) {
> > -   dev_err(dev, "failed to add devfreq device\n");
> > -   ret = PTR_ERR(bus->devfreq);
> > -   goto err;
> > -   }
> > -
> > -   /* Register opp_notifier to catch the change of OPP  */
> > -   ret = devm_devfreq_register_opp_notifier(dev, bus->devfreq);
> > -   if (ret < 0) {
> > -   dev_err(dev, "failed to register opp notifier\n");
> > -   goto err;
> > -   }
> > -
> > -   

Re: [RFC PATCH 04/11] devfreq: exynos-bus: Clean up code

2019-07-26 Thread Krzysztof Kozlowski
On Thu, 25 Jul 2019 at 14:51, Chanwoo Choi  wrote:
>
> 2019년 7월 24일 (수) 오전 8:07, Artur Świgoń 님이 작성:
> >
> > This patch adds minor improvements to the exynos-bus driver.
> >
> > Signed-off-by: Artur Świgoń 
> > ---
> >  drivers/devfreq/exynos-bus.c | 49 
> >  1 file changed, 22 insertions(+), 27 deletions(-)
> >
> > diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq/exynos-bus.c
> > index 4bb83b945bf7..412511ca7703 100644
> > --- a/drivers/devfreq/exynos-bus.c
> > +++ b/drivers/devfreq/exynos-bus.c
> > @@ -15,11 +15,10 @@
> >  #include 
> >  #include 
> >  #include 
> > -#include 
> > +#include 
> >  #include 
> >  #include 
> >  #include 
> > -#include 
> >
> >  #define DEFAULT_SATURATION_RATIO   40
> >  #define DEFAULT_VOLTAGE_TOLERANCE  2
> > @@ -256,7 +255,7 @@ static int exynos_bus_parent_parse_of(struct 
> > device_node *np,
> > struct exynos_bus *bus)
> >  {
> > struct device *dev = bus->dev;
> > -   int i, ret, count, size;
> > +   int i, ret, count;
> >
> > /* Get the regulator to provide each bus with the power */
> > bus->regulator = devm_regulator_get(dev, "vdd");
> > @@ -283,8 +282,7 @@ static int exynos_bus_parent_parse_of(struct 
> > device_node *np,
> > }
> > bus->edev_count = count;
> >
> > -   size = sizeof(*bus->edev) * count;
> > -   bus->edev = devm_kzalloc(dev, size, GFP_KERNEL);
> > +   bus->edev = devm_kcalloc(dev, count, sizeof(*bus->edev), 
> > GFP_KERNEL);
> > if (!bus->edev) {
> > ret = -ENOMEM;
> > goto err_regulator;
> > @@ -388,7 +386,7 @@ static int exynos_bus_profile_init(struct exynos_bus 
> > *bus,
> > ondemand_data = devm_kzalloc(dev, sizeof(*ondemand_data), 
> > GFP_KERNEL);
> > if (!ondemand_data) {
> > ret = -ENOMEM;
> > -   goto err;
> > +   goto out;
> > }
> > ondemand_data->upthreshold = 40;
> > ondemand_data->downdifferential = 5;
> > @@ -400,14 +398,14 @@ static int exynos_bus_profile_init(struct exynos_bus 
> > *bus,
> > if (IS_ERR(bus->devfreq)) {
> > dev_err(dev, "failed to add devfreq device\n");
> > ret = PTR_ERR(bus->devfreq);
> > -   goto err;
> > +   goto out;
> > }
> >
> > /* Register opp_notifier to catch the change of OPP  */
> > ret = devm_devfreq_register_opp_notifier(dev, bus->devfreq);
> > if (ret < 0) {
> > dev_err(dev, "failed to register opp notifier\n");
> > -   goto err;
> > +   goto out;
> > }
> >
> > /*
> > @@ -417,16 +415,16 @@ static int exynos_bus_profile_init(struct exynos_bus 
> > *bus,
> > ret = exynos_bus_enable_edev(bus);
> > if (ret < 0) {
> > dev_err(dev, "failed to enable devfreq-event devices\n");
> > -   goto err;
> > +   goto out;
> > }
> >
> > ret = exynos_bus_set_event(bus);
> > if (ret < 0) {
> > dev_err(dev, "failed to set event to devfreq-event 
> > devices\n");
> > -   goto err;
> > +   goto out;
> > }
> >
> > -err:
> > +out:
> > return ret;
> >  }
> >
> > @@ -446,27 +444,28 @@ static int exynos_bus_profile_init_passive(struct 
> > exynos_bus *bus,
> > parent_devfreq = devfreq_get_devfreq_by_phandle(dev, 0);
> > if (IS_ERR(parent_devfreq)) {
> > ret = -EPROBE_DEFER;
> > -   goto err;
> > +   goto out;
> > }
> >
> > passive_data = devm_kzalloc(dev, sizeof(*passive_data), GFP_KERNEL);
> > if (!passive_data) {
> > ret = -ENOMEM;
> > -   goto err;
> > +   goto out;
> > }
> > passive_data->parent = parent_devfreq;
> >
> > /* Add devfreq device for exynos bus with passive governor */
> > -   bus->devfreq = devm_devfreq_add_device(dev, profile, 
> > DEVFREQ_GOV_PASSIVE,
> > +   bus->devfreq = devm_devfreq_add_device(dev, profile,
> > +   DEVFREQ_GOV_PASSIVE,
> > passive_data);
> > if (IS_ERR(bus->devfreq)) {
> > dev_err(dev,
> > "failed to add devfreq dev with passive 
> > governor\n");
> > ret = PTR_ERR(bus->devfreq);
> > -   goto err;
> > +   goto out;
> > }
> >
> > -err:
> > +out:
> > return ret;
> >  }
> >
> > @@ -484,11 +483,11 @@ static int exynos_bus_probe(struct platform_device 
> > *pdev)
> > return -EINVAL;
> > }
> >
> > -   bus = devm_kzalloc(>dev, sizeof(*bus), GFP_KERNEL);
> > +   bus = devm_kzalloc(dev, sizeof(*bus), GFP_KERNEL);
> > if (!bus)
> > return -ENOMEM;
> >  

Re: [PATCH v2 2/8] dt-bindings: sram: Convert SRAM bindings to json-schema

2019-10-01 Thread Krzysztof Kozlowski
On Tue, Oct 01, 2019 at 09:00:03AM -0500, Rob Herring wrote:
> On Wed, Sep 18, 2019 at 07:31:35PM +0200, Krzysztof Kozlowski wrote:
> > Convert generic mmio-sram bindings to DT schema format using
> > json-schema.
> 
> I've been slow getting to this because I started on the same thing...
> 
> > 
> > Signed-off-by: Krzysztof Kozlowski 
> > 
> > ---
> > 
> > Changes since v1:
> > 1. Indent example with four spaces (more readable).
> > ---
> >  .../devicetree/bindings/sram/sram.txt |  80 --
> >  .../devicetree/bindings/sram/sram.yaml| 138 ++
> >  2 files changed, 138 insertions(+), 80 deletions(-)
> >  delete mode 100644 Documentation/devicetree/bindings/sram/sram.txt
> >  create mode 100644 Documentation/devicetree/bindings/sram/sram.yaml
> 
> > diff --git a/Documentation/devicetree/bindings/sram/sram.yaml 
> > b/Documentation/devicetree/bindings/sram/sram.yaml
> > new file mode 100644
> > index ..8d9d6ce494b2
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/sram/sram.yaml
> > @@ -0,0 +1,138 @@
> > +# SPDX-License-Identifier: GPL-2.0
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/sram/sram.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Generic on-chip SRAM
> > +
> > +maintainers:
> > +  - FIXME 
> 
> You can put me.

Sure.

> 
> > +
> > +description: |+
> > +  Simple IO memory regions to be managed by the genalloc API.
> > +
> > +  Each child of the sram node specifies a region of reserved memory. Each
> > +  child node should use a 'reg' property to specify a specific range of
> > +  reserved memory.
> > +
> > +  Following the generic-names recommended practice, node names should
> > +  reflect the purpose of the node. Unit address (@) should be
> > +  appended to the name.
> > +
> > +properties:
> > +  $nodename:
> > +pattern: "^sram(@.*)?"
> > +
> > +  compatible:
> > +items:
> > +  - enum:
> > +  - mmio-sram
> > +  - atmel,sama5d2-securam
> 
> I was trying to go down the path of putting all the compatibles for 
> various SRAM bindings here, but I ran into some issues. I need to 
> revisit as I've forgotten the exact issue.
> 
> This would need to be a 'contains' if this is going to work for others.

OK.

> 
> > +
> > +  reg:
> > +maxItems: 1
> > +
> > +  "#address-cells":
> > +description: Should use the same values as the root node.
> > +
> > +  "#size-cells":
> > +description: Should use the same values as the root node.
> 
> I defined both of these to be 1 as 4GB of SRAM should be enough for a 
> while. We can debate 1 or 2 cells vs. 1, but there's no reason it has to 
> be the same as the root (unless we're failing to do address 
> translation).

That was copied from txt version. I can adjust them to 1 although this
is will more than simple conversion.

> 
> > +
> > +  ranges:
> > +description:
> > +  Should translate from local addresses within the sram to bus 
> > addresses.
> > +
> > +  no-memory-wc:
> > +description:
> > +  The flag indicating, that SRAM memory region has not to be remapped
> > +  as write combining. WC is used by default.
> > +type: boolean
> > +
> > +  # TODO: additionalProperties: false
> > +
> > +patternProperties:
> > +  "^([a-z]*-)?sram@[a-f0-9]$":
> > +type: object
> > +description:
> > +  Each child of the sram node specifies a region of reserved memory.
> > +properties:
> > +  reg:
> > +description:
> > +  IO mem address range, relative to the SRAM range.
> 
> maxItems: 1

OK

> 
> > +
> > +  compatible:
> > +$ref: /schemas/types.yaml#/definitions/string
> > +description:
> > +  Should contain a vendor specific string in the form
> > +  ,[-]
> > +
> > +  pool:
> > +description:
> > +  Indicates that the particular reserved SRAM area is addressable
> > +  and in use by another device or devices.
> > +type: boolean
> > +
> > +  export:
> > +description:
> > +  Indicates that the reserved SRAM area may be accessed outside
> > +  of the kernel, e.g. by bootloader or userspace.
> > +type: boolean
> > +
> > +  protect-exec:
> > +description: |
> > +  Same as 'pool' above but with the additional constraint that code
> > +  will be run from the region and that the memory is maintained as
> > +  read-only, executable during code execution. NOTE: This region 
> > must
> > +  be page aligned on start and end in order to properly allow
> > +  manipulation of the page attributes.
> > +type: boolean
> > +
> > +  label:
> > +$ref: /schemas/types.yaml#/definitions/string
> 
> Already has a type definition.

OK

Best regards,
Krzysztof



Re: [PATCH v2] dt-bindings: gpu: Convert Samsung Image Scaler to dt-schema

2019-09-26 Thread Krzysztof Kozlowski
On Thu, Sep 26, 2019 at 02:56:14PM +0200, Marek Szyprowski wrote:
> From: Maciej Falkowski 
> 
> Convert Samsung Image Scaler to newer dt-schema format.
> 
> Signed-off-by: Maciej Falkowski 
> Signed-off-by: Marek Szyprowski 
> ---
> v2:
> - Removed quotation marks from string in 'compatible' property
> - Added if-then statement for 'clocks' and 'clock-names' property
> - Added include directive to example
> - Added GIC_SPI macro to example
> 
> Best regards,
> Maciej Falkowski
> ---
>  .../bindings/gpu/samsung-scaler.txt   | 27 ---
>  .../bindings/gpu/samsung-scaler.yaml  | 71 +++
>  2 files changed, 71 insertions(+), 27 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.txt
>  create mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
> 
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt 
> b/Documentation/devicetree/bindings/gpu/samsung-scaler.txt
> deleted file mode 100644
> index 9c3d98105dfd..
> --- a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt
> +++ /dev/null
> @@ -1,27 +0,0 @@
> -* Samsung Exynos Image Scaler
> -
> -Required properties:
> -  - compatible : value should be one of the following:
> - (a) "samsung,exynos5420-scaler" for Scaler IP in Exynos5420
> - (b) "samsung,exynos5433-scaler" for Scaler IP in Exynos5433
> -
> -  - reg : Physical base address of the IP registers and length of memory
> -   mapped region.
> -
> -  - interrupts : Interrupt specifier for scaler interrupt, according to 
> format
> -  specific to interrupt parent.
> -
> -  - clocks : Clock specifier for scaler clock, according to generic clock
> -  bindings. (See Documentation/devicetree/bindings/clock/exynos*.txt)
> -
> -  - clock-names : Names of clocks. For exynos scaler, it should be "mscl"
> -   on 5420 and "pclk", "aclk" and "aclk_xiu" on 5433.
> -
> -Example:
> - scaler@1280 {
> - compatible = "samsung,exynos5420-scaler";
> - reg = <0x1280 0x1294>;
> - interrupts = <0 220 IRQ_TYPE_LEVEL_HIGH>;
> - clocks = < CLK_MSCL0>;
> - clock-names = "mscl";
> - };
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml 
> b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
> new file mode 100644
> index ..af19930d052e
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
> @@ -0,0 +1,71 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpu/samsung-scaler.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Samsung Exynos SoC Image Scaler
> +
> +maintainers:
> +  - Inki Dae 
> +
> +properties:
> +  compatible:
> +enum:
> +  - samsung,exynos5420-scaler
> +  - samsung,exynos5433-scaler
> +
> +  reg:
> +maxItems: 1
> +
> +  interrupts:
> +maxItems: 1
> +

I am repeating myself... leave the clocks and clock-names.

"I think it is worth to leave the clocks and clock-names here (could be
empty or with min/max values for number of items). This makes it easy to
find the properties by humans.

Midgard bindings could be used as example."

> +if:
> +  properties:
> +compatible:
> +  contains:
> +const: samsung,exynos5420-scaler
> +then:
> +  properties:
> +clocks:
> +  items:
> +- description: mscl clock
> +
> +clock-names:
> +  items:
> +- const: mscl
> +else:
> +  properties:
> +clocks:
> +  items:
> +- description: mscl clock
> +- description: aclk clock
> +- description: aclk_xiu clock
> +
> +clock-names:
> +  items:
> +- const: pclk
> +- const: aclk
> +- const: aclk_xiu
> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - clock-names
> +
> +examples:
> +  - |
> +#include 
> +#include 
> +
> +scaler@1280 {
> +compatible = "samsung,exynos5420-scaler";
> +reg = <0x1280 0x1294>;
> +interrupts = ;
> +clocks = < CLK_MSCL0>;
> +clock-names = "mscl";
> +};
> +

Unneeded trailing line.

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v3] dt-bindings: gpu: Convert Samsung Image Scaler to dt-schema

2019-09-27 Thread Krzysztof Kozlowski
On Fri, 27 Sep 2019 at 16:33, Marek Szyprowski  wrote:
>
> From: Maciej Falkowski 
>
> Convert Samsung Image Scaler to newer dt-schema format.
>
> Signed-off-by: Maciej Falkowski 
> Signed-off-by: Marek Szyprowski 
> ---
> v3:
> - Fixed description of 'clocks' property:
> rather than 'mscl clock', 'pclk clock'
> - Added empty line within if-else statement
> - Added 'additionalProperties: false'
> - Listed all missing 'properties' in properties scope
>
> Best regards,
> Maciej Falkowski
> ---
>  .../bindings/gpu/samsung-scaler.txt   | 27 ---
>  .../bindings/gpu/samsung-scaler.yaml  | 81 +++
>  2 files changed, 81 insertions(+), 27 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.txt
>  create mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
>
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt 
> b/Documentation/devicetree/bindings/gpu/samsung-scaler.txt
> deleted file mode 100644
> index 9c3d98105dfd..
> --- a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt
> +++ /dev/null
> @@ -1,27 +0,0 @@
> -* Samsung Exynos Image Scaler
> -
> -Required properties:
> -  - compatible : value should be one of the following:
> -   (a) "samsung,exynos5420-scaler" for Scaler IP in Exynos5420
> -   (b) "samsung,exynos5433-scaler" for Scaler IP in Exynos5433
> -
> -  - reg : Physical base address of the IP registers and length of memory
> - mapped region.
> -
> -  - interrupts : Interrupt specifier for scaler interrupt, according to 
> format
> -specific to interrupt parent.
> -
> -  - clocks : Clock specifier for scaler clock, according to generic clock
> -bindings. (See 
> Documentation/devicetree/bindings/clock/exynos*.txt)
> -
> -  - clock-names : Names of clocks. For exynos scaler, it should be "mscl"
> - on 5420 and "pclk", "aclk" and "aclk_xiu" on 5433.
> -
> -Example:
> -   scaler@1280 {
> -   compatible = "samsung,exynos5420-scaler";
> -   reg = <0x1280 0x1294>;
> -   interrupts = <0 220 IRQ_TYPE_LEVEL_HIGH>;
> -   clocks = < CLK_MSCL0>;
> -   clock-names = "mscl";
> -   };
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml 
> b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
> new file mode 100644
> index ..5317ac64426a
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml
> @@ -0,0 +1,81 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpu/samsung-scaler.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Samsung Exynos SoC Image Scaler
> +
> +maintainers:
> +  - Inki Dae 
> +
> +properties:
> +  compatible:
> +enum:
> +  - samsung,exynos5420-scaler
> +  - samsung,exynos5433-scaler
> +
> +  reg:
> +maxItems: 1
> +
> +  interrupts:
> +maxItems: 1
> +
> +  clocks: {}
> +  clock-names: {}
> +  iommus: {}
> +  power-domains: {}
> +
> +if:
> +  properties:
> +compatible:
> +  contains:
> +const: samsung,exynos5420-scaler
> +
> +then:
> +  properties:
> +clocks:
> +  items:
> +- description: mscl clock
> +
> +clock-names:
> +  items:
> +- const: mscl
> +
> +else:
> +  properties:
> +clocks:
> +  items:
> +- description: pclk clock
> +- description: aclk clock
> +- description: aclk_xiu clock
> +
> +clock-names:
> +  items:
> +- const: pclk
> +- const: aclk
> +- const: aclk_xiu
> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - clock-names
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +#include 
> +#include 
> +
> +scaler@1280 {
> +compatible = "samsung,exynos5420-scaler";
> +reg = <0x1280 0x1294>;
> +interrupts = ;
> +clocks = < CLK_MSCL0>;
> +clock-names = "mscl";
> +};
> +
> +...

You have some left-overs at the end. With cleaning them:
Reviewed-by: Krzysztof Kozlowski 

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v3] dt-bindings: gpu: Convert Samsung 2D Graphics Accelerator to dt-schema

2019-09-27 Thread Krzysztof Kozlowski
On Fri, 27 Sep 2019 at 16:33, Marek Szyprowski  wrote:
>
> From: Maciej Falkowski 
>
> Convert Samsung 2D Graphics Accelerator to newer dt-schema format
>
> Signed-off-by: Maciej Falkowski 
> ---
> v3:
> - Merged two if-statements with single if-else statement
> - Added 'additionalProperties: false'
> - Listed all missing 'properties' in properties scope
>
> Best regards,
> Maciej Falkowski
> ---
>  .../devicetree/bindings/gpu/samsung-g2d.txt   | 27 ---
>  .../devicetree/bindings/gpu/samsung-g2d.yaml  | 75 +++
>  2 files changed, 75 insertions(+), 27 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-g2d.txt
>  create mode 100644 Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
>
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-g2d.txt 
> b/Documentation/devicetree/bindings/gpu/samsung-g2d.txt
> deleted file mode 100644
> index 1e7959332dbc..
> --- a/Documentation/devicetree/bindings/gpu/samsung-g2d.txt
> +++ /dev/null
> @@ -1,27 +0,0 @@
> -* Samsung 2D Graphics Accelerator
> -
> -Required properties:
> -  - compatible : value should be one among the following:
> -   (a) "samsung,s5pv210-g2d" for G2D IP present in S5PV210 & Exynos4210 
> SoC
> -   (b) "samsung,exynos4212-g2d" for G2D IP present in Exynos4x12 SoCs
> -   (c) "samsung,exynos5250-g2d" for G2D IP present in Exynos5250 SoC
> -
> -  - reg : Physical base address of the IP registers and length of memory
> - mapped region.
> -
> -  - interrupts : G2D interrupt number to the CPU.
> -  - clocks : from common clock binding: handle to G2D clocks.
> -  - clock-names : names of clocks listed in clocks property, in the same
> - order, depending on SoC type:
> - - for S5PV210 and Exynos4 based SoCs: "fimg2d" and
> -   "sclk_fimg2d"
> - - for Exynos5250 SoC: "fimg2d".
> -
> -Example:
> -   g2d@1280 {
> -   compatible = "samsung,s5pv210-g2d";
> -   reg = <0x1280 0x1000>;
> -   interrupts = <0 89 0>;
> -   clocks = < 177>, < 277>;
> -   clock-names = "sclk_fimg2d", "fimg2d";
> -   };
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml 
> b/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> new file mode 100644
> index ..e7daae862578
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> @@ -0,0 +1,75 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpu/samsung-g2d.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Samsung SoC 2D Graphics Accelerator
> +
> +maintainers:
> +  - Inki Dae 
> +
> +properties:
> +  compatible:
> +enum:
> +  - samsung,s5pv210-g2d# in S5PV210 & Exynos4210 SoC
> +  - samsung,exynos4212-g2d # in Exynos4x12 SoCs
> +  - samsung,exynos5250-g2d
> +
> +  reg:
> +maxItems: 1
> +
> +  interrupts:
> +maxItems: 1
> +
> +  clocks: {}
> +  clock-names: {}
> +  iommus: {}
> +  power-domains: {}
> +
> +if:
> +  properties:
> +compatible:
> +  contains:
> +const: samsung,exynos5250-g2d
> +
> +then:
> +  properties:
> +clocks:
> +  items:
> +- description: fimg2d clock
> +clock-names:
> +  items:
> +- const: fimg2d
> +
> +else:
> +  properties:
> +clocks:
> +  items:
> +- description: sclk_fimg2d clock
> +- description: fimg2d clock
> +clock-names:
> +  items:
> +- const: sclk_fimg2d
> +- const: fimg2d
> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - clock-names
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +g2d@1280 {
> +compatible = "samsung,s5pv210-g2d";
> +reg = <0x1280 0x1000>;
> +interrupts = <0 89 0>;
> +clocks = < 177>, < 277>;
> +clock-names = "sclk_fimg2d", "fimg2d";
> +};
> +
> +...

The same trailing lines. I mentioned this already about scaler
bindings. Please fix all your patches at once for the same commented
issue.

With this fixup:
Reviewed-by: Krzysztof Kozlowski 

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH trivial 3/3] treewide: arch: Fix Kconfig indentation

2019-09-23 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 arch/Kconfig   |  4 ++--
 arch/alpha/Kconfig |  2 +-
 arch/arm/Kconfig.debug |  4 ++--
 arch/arm/mach-ep93xx/Kconfig   |  8 
 arch/arm/mach-hisi/Kconfig |  2 +-
 arch/arm/mach-ixp4xx/Kconfig   | 16 
 arch/arm/mach-mmp/Kconfig  |  2 +-
 arch/arm/mach-omap1/Kconfig| 14 +++---
 arch/arm/mach-prima2/Kconfig   |  6 +++---
 arch/arm/mach-s3c24xx/Kconfig  |  4 ++--
 arch/arm/mach-s3c64xx/Kconfig  |  6 +++---
 arch/arm/plat-samsung/Kconfig  |  2 +-
 arch/arm64/Kconfig |  6 +++---
 arch/arm64/Kconfig.debug   |  2 +-
 arch/h8300/Kconfig |  4 ++--
 arch/h8300/Kconfig.cpu |  4 ++--
 arch/m68k/Kconfig.bus  |  2 +-
 arch/m68k/Kconfig.debug| 16 
 arch/m68k/Kconfig.machine  |  8 
 arch/nds32/Kconfig.cpu | 18 +-
 arch/openrisc/Kconfig  | 26 +-
 arch/powerpc/Kconfig.debug | 18 +-
 arch/powerpc/platforms/Kconfig.cputype |  2 +-
 arch/riscv/Kconfig.socs|  2 +-
 arch/sh/boards/Kconfig |  2 +-
 arch/sh/mm/Kconfig |  2 +-
 arch/um/Kconfig|  2 +-
 arch/x86/Kconfig   | 18 +-
 28 files changed, 101 insertions(+), 101 deletions(-)

diff --git a/arch/Kconfig b/arch/Kconfig
index 5f8a5d84dbbe..8d4f77bbed29 100644
--- a/arch/Kconfig
+++ b/arch/Kconfig
@@ -76,7 +76,7 @@ config JUMP_LABEL
depends on HAVE_ARCH_JUMP_LABEL
depends on CC_HAS_ASM_GOTO
help
- This option enables a transparent branch optimization that
+This option enables a transparent branch optimization that
 makes certain almost-always-true or almost-always-false branch
 conditions even cheaper to execute within the kernel.
 
@@ -84,7 +84,7 @@ config JUMP_LABEL
 scheduler functionality, networking code and KVM have such
 branches and include support for this optimization technique.
 
- If it is detected that the compiler has support for "asm goto",
+If it is detected that the compiler has support for "asm goto",
 the kernel will compile such branches with just a nop
 instruction. When the condition flag is toggled to true, the
 nop will be converted to a jump instruction to execute the
diff --git a/arch/alpha/Kconfig b/arch/alpha/Kconfig
index ef179033a7c2..30a6291355cb 100644
--- a/arch/alpha/Kconfig
+++ b/arch/alpha/Kconfig
@@ -545,7 +545,7 @@ config NR_CPUS
default "4" if !ALPHA_GENERIC && !ALPHA_MARVEL
help
  MARVEL support can handle a maximum of 32 CPUs, all the others
-  with working support have a maximum of 4 CPUs.
+ with working support have a maximum of 4 CPUs.
 
 config ARCH_DISCONTIGMEM_ENABLE
bool "Discontiguous Memory Support"
diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index 8bcbd0cd739b..0e5d52fbddbd 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -274,7 +274,7 @@ choice
select DEBUG_UART_8250
help
  Say Y here if you want the debug print routines to direct
-  their output to the CNS3xxx UART0.
+ their output to the CNS3xxx UART0.
 
config DEBUG_DAVINCI_DA8XX_UART1
bool "Kernel low-level debugging on DaVinci DA8XX using UART1"
@@ -828,7 +828,7 @@ choice
select DEBUG_UART_8250
help
  Say Y here if you want kernel low-level debugging support
-  on Rockchip RV1108 based platforms.
+ on Rockchip RV1108 based platforms.
 
config DEBUG_RV1108_UART1
bool "Kernel low-level debugging messages via Rockchip RV1108 
UART1"
diff --git a/arch/arm/mach-ep93xx/Kconfig b/arch/arm/mach-ep93xx/Kconfig
index f2db5fd38145..bf81dfab7f1b 100644
--- a/arch/arm/mach-ep93xx/Kconfig
+++ b/arch/arm/mach-ep93xx/Kconfig
@@ -126,10 +126,10 @@ config MACH_MICRO9S
  Contec Micro9-Slim board.
 
 config MACH_SIM_ONE
-bool "Support Simplemachines Sim.One board"
-help
-  Say 'Y' here if you want your kernel to support the
-  Simplemachines Sim.One board.
+   bool "Support Simplemachines Sim.One board"
+   help
+ Say 'Y' here if you want your kernel to support the
+ Simplemachines Sim.One board.
 
 config MACH_SNAPPER_CL15
bool "Support B

[PATCH trivial 2/3] treewide: Fix Kconfig indentation

2019-09-23 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 certs/Kconfig  | 14 ++---
 init/Kconfig   | 28 +-
 kernel/trace/Kconfig   |  8 
 lib/Kconfig|  2 +-
 lib/Kconfig.debug  | 36 +-
 lib/Kconfig.kgdb   |  8 
 mm/Kconfig | 28 +-
 samples/Kconfig|  2 +-
 security/apparmor/Kconfig  |  2 +-
 security/integrity/Kconfig | 24 +++
 security/integrity/ima/Kconfig | 12 ++--
 security/safesetid/Kconfig | 24 +++
 12 files changed, 94 insertions(+), 94 deletions(-)

diff --git a/certs/Kconfig b/certs/Kconfig
index c94e93d8bccf..0358c66d3d7c 100644
--- a/certs/Kconfig
+++ b/certs/Kconfig
@@ -6,14 +6,14 @@ config MODULE_SIG_KEY
default "certs/signing_key.pem"
depends on MODULE_SIG
help
- Provide the file name of a private key/certificate in PEM format,
- or a PKCS#11 URI according to RFC7512. The file should contain, or
- the URI should identify, both the certificate and its corresponding
- private key.
+Provide the file name of a private key/certificate in PEM format,
+or a PKCS#11 URI according to RFC7512. The file should contain, or
+the URI should identify, both the certificate and its corresponding
+private key.
 
- If this option is unchanged from its default "certs/signing_key.pem",
- then the kernel will automatically generate the private key and
- certificate as described in 
Documentation/admin-guide/module-signing.rst
+If this option is unchanged from its default "certs/signing_key.pem",
+then the kernel will automatically generate the private key and
+certificate as described in 
Documentation/admin-guide/module-signing.rst
 
 config SYSTEM_TRUSTED_KEYRING
bool "Provide system-wide ring of trusted keys"
diff --git a/init/Kconfig b/init/Kconfig
index 6d4db887f696..f59c854839d2 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -169,10 +169,10 @@ config BUILD_SALT
string "Build ID Salt"
default ""
help
-  The build ID is used to link binaries and their debug info. Setting
-  this option will use the value in the calculation of the build id.
-  This is mostly useful for distributions which want to ensure the
-  build is unique between builds. It's safe to leave the default.
+ The build ID is used to link binaries and their debug info. Setting
+ this option will use the value in the calculation of the build id.
+ This is mostly useful for distributions which want to ensure the
+ build is unique between builds. It's safe to leave the default.
 
 config HAVE_KERNEL_GZIP
bool
@@ -1327,9 +1327,9 @@ menuconfig EXPERT
select DEBUG_KERNEL
help
  This option allows certain base kernel options and settings
-  to be disabled or tweaked. This is for specialized
-  environments which can tolerate a "non-standard" kernel.
-  Only use this if you really know what you are doing.
+ to be disabled or tweaked. This is for specialized
+ environments which can tolerate a "non-standard" kernel.
+ Only use this if you really know what you are doing.
 
 config UID16
bool "Enable 16-bit UID system calls" if EXPERT
@@ -1439,11 +1439,11 @@ config BUG
bool "BUG() support" if EXPERT
default y
help
-  Disabling this option eliminates support for BUG and WARN, reducing
-  the size of your kernel image and potentially quietly ignoring
-  numerous fatal conditions. You should only consider disabling this
-  option for embedded systems with no facilities for reporting errors.
-  Just say Y.
+ Disabling this option eliminates support for BUG and WARN, reducing
+ the size of your kernel image and potentially quietly ignoring
+ numerous fatal conditions. You should only consider disabling this
+ option for embedded systems with no facilities for reporting errors.
+ Just say Y.
 
 config ELF_CORE
depends on COREDUMP
@@ -1459,8 +1459,8 @@ config PCSPKR_PLATFORM
select I8253_LOCK
default y
help
-  This option allows to disable the internal PC-Speaker
-  support, saving some memory.
+ This option allows to disable the internal PC-Speaker
+ support, saving some memory.
 
 config BASE_FULL
default y
diff --git a/kernel/trace/Kconfig b/kernel/trace/Kconfig
index e0

[PATCH v2] drm/panfrost: Reduce the amount of logs on deferred probe

2019-09-23 Thread Krzysztof Kozlowski
There is no point to print deferred probe (and its failures to get
resources) as an error.  Also there is no need to print regulator errors
twice.

In case of multiple probe tries this would pollute the dmesg.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Remove second error message from calling panfrost_regulator_init().
---
 drivers/gpu/drm/panfrost/panfrost_device.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/panfrost/panfrost_device.c 
b/drivers/gpu/drm/panfrost/panfrost_device.c
index 46b0b02e4289..287c6ba314d9 100644
--- a/drivers/gpu/drm/panfrost/panfrost_device.c
+++ b/drivers/gpu/drm/panfrost/panfrost_device.c
@@ -95,7 +95,9 @@ static int panfrost_regulator_init(struct panfrost_device 
*pfdev)
pfdev->regulator = NULL;
if (ret == -ENODEV)
return 0;
-   dev_err(pfdev->dev, "failed to get regulator: %d\n", ret);
+   if (ret != -EPROBE_DEFER)
+   dev_err(pfdev->dev, "failed to get regulator: %d\n",
+   ret);
return ret;
}
 
@@ -133,10 +135,8 @@ int panfrost_device_init(struct panfrost_device *pfdev)
}
 
err = panfrost_regulator_init(pfdev);
-   if (err) {
-   dev_err(pfdev->dev, "regulator init failed %d\n", err);
+   if (err)
goto err_out0;
-   }
 
err = panfrost_reset_init(pfdev);
if (err) {
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH trivial] gpu: Fix Kconfig indentation

2019-09-23 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/Kconfig  |  10 +-
 drivers/gpu/drm/amd/display/Kconfig  |  20 ++--
 drivers/gpu/drm/bridge/Kconfig   |   8 +-
 drivers/gpu/drm/i915/Kconfig |  12 +-
 drivers/gpu/drm/i915/Kconfig.debug   | 144 +++
 drivers/gpu/drm/lima/Kconfig |   2 +-
 drivers/gpu/drm/mgag200/Kconfig  |   8 +-
 drivers/gpu/drm/nouveau/Kconfig  |   2 +-
 drivers/gpu/drm/omapdrm/displays/Kconfig |   6 +-
 drivers/gpu/drm/omapdrm/dss/Kconfig  |  12 +-
 drivers/gpu/drm/rockchip/Kconfig |   8 +-
 drivers/gpu/drm/udl/Kconfig  |   2 +-
 drivers/gpu/vga/Kconfig  |   2 +-
 13 files changed, 118 insertions(+), 118 deletions(-)

diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
index e67c194c2aca..7cb6e4eb99e8 100644
--- a/drivers/gpu/drm/Kconfig
+++ b/drivers/gpu/drm/Kconfig
@@ -207,8 +207,8 @@ config DRM_RADEON
tristate "ATI Radeon"
depends on DRM && PCI && MMU
select FW_LOADER
-select DRM_KMS_HELPER
-select DRM_TTM
+   select DRM_KMS_HELPER
+   select DRM_TTM
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE
@@ -226,9 +226,9 @@ config DRM_AMDGPU
tristate "AMD GPU"
depends on DRM && PCI && MMU
select FW_LOADER
-select DRM_KMS_HELPER
+   select DRM_KMS_HELPER
select DRM_SCHED
-select DRM_TTM
+   select DRM_TTM
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE
@@ -266,7 +266,7 @@ config DRM_VKMS
  If M is selected the module will be called vkms.
 
 config DRM_ATI_PCIGART
-bool
+   bool
 
 source "drivers/gpu/drm/exynos/Kconfig"
 
diff --git a/drivers/gpu/drm/amd/display/Kconfig 
b/drivers/gpu/drm/amd/display/Kconfig
index 71991a28a775..0a35cb8e803a 100644
--- a/drivers/gpu/drm/amd/display/Kconfig
+++ b/drivers/gpu/drm/amd/display/Kconfig
@@ -23,16 +23,16 @@ config DRM_AMD_DC_DCN2_0
depends on DRM_AMD_DC && X86
depends on DRM_AMD_DC_DCN1_0
help
-   Choose this option if you want to have
-   Navi support for display engine
+ Choose this option if you want to have
+ Navi support for display engine
 
 config DRM_AMD_DC_DCN2_1
-bool "DCN 2.1 family"
-depends on DRM_AMD_DC && X86
-depends on DRM_AMD_DC_DCN2_0
-help
-Choose this option if you want to have
-Renoir support for display engine
+   bool "DCN 2.1 family"
+   depends on DRM_AMD_DC && X86
+   depends on DRM_AMD_DC_DCN2_0
+   help
+ Choose this option if you want to have
+ Renoir support for display engine
 
 config DRM_AMD_DC_DSC_SUPPORT
bool "DSC support"
@@ -41,8 +41,8 @@ config DRM_AMD_DC_DSC_SUPPORT
depends on DRM_AMD_DC_DCN1_0
depends on DRM_AMD_DC_DCN2_0
help
-   Choose this option if you want to have
-   Dynamic Stream Compression support
+ Choose this option if you want to have
+ Dynamic Stream Compression support
 
 config DEBUG_KERNEL_DC
bool "Enable kgdb break in DC"
diff --git a/drivers/gpu/drm/bridge/Kconfig b/drivers/gpu/drm/bridge/Kconfig
index 1cc9f502c1f2..a5aa7ec16000 100644
--- a/drivers/gpu/drm/bridge/Kconfig
+++ b/drivers/gpu/drm/bridge/Kconfig
@@ -60,10 +60,10 @@ config DRM_MEGACHIPS_STDP_GE_B850V3_FW
select DRM_KMS_HELPER
select DRM_PANEL
---help---
-  This is a driver for the display bridges of
-  GE B850v3 that convert dual channel LVDS
-  to DP++. This is used with the i.MX6 imx-ldb
-  driver. You are likely to say N here.
+ This is a driver for the display bridges of
+ GE B850v3 that convert dual channel LVDS
+ to DP++. This is used with the i.MX6 imx-ldb
+ driver. You are likely to say N here.
 
 config DRM_NXP_PTN3460
tristate "NXP PTN3460 DP/LVDS bridge"
diff --git a/drivers/gpu/drm/i915/Kconfig b/drivers/gpu/drm/i915/Kconfig
index 0d21402945ab..3c6d57df262d 100644
--- a/drivers/gpu/drm/i915/Kconfig
+++ b/drivers/gpu/drm/i915/Kconfig
@@ -76,7 +76,7 @@ config DRM_I915_CAPTURE_ERROR
  This option enables capturing the GPU state when a hang is detected.
  This information is vital for triaging hangs and assists in debugging.
  Please report any hang to
-https://bugs.freedesktop.org/enter_bug.cgi?product=DRI
+   https://bugs.freedesktop.org/enter_bug.cgi?product=DRI
  for triaging.
 
  If in doubt, say "Y".
@@ -105,11 +105,1

Re: [RESEND PATCH] drm/panfrost: Reduce the amount of logs on deferred probe

2019-09-23 Thread Krzysztof Kozlowski
On Thu, Sep 12, 2019 at 10:36:25AM +0100, Steven Price wrote:
> On 09/09/2019 16:51, Krzysztof Kozlowski wrote:
> > There is no point to print deferred probe (and its failures to get
> > resources) as an error.
> > 
> > In case of multiple probe tries this would pollute the dmesg.
> > 
> > Signed-off-by: Krzysztof Kozlowski 
> 
> Looks like a good idea, however from what I can tell you haven't
> completely silenced the 'error' as the return from
> panfrost_regulator_init() will be -EPROBE_DEFER causing another
> dev_err() output:
> 
> err = panfrost_regulator_init(pfdev);
> if (err) {
> dev_err(pfdev->dev, "regulator init failed %d\n", err);
> goto err_out0;
> }
> 
> Can you fix that up as well? Or indeed drop it altogether since
> panfrost_regulator_init() already outputs an appropriate message.

I'll drop this error message then. Thanks for feedback!

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v2] dt-bindings: gpu: Convert Samsung 2D Graphics Accelerator to dt-schema

2019-09-24 Thread Krzysztof Kozlowski
On Tue, Sep 24, 2019 at 03:46:14PM +0200, Marek Szyprowski wrote:
> From: Maciej Falkowski 
> 
> Convert Samsung 2D Graphics Accelerator to newer dt-schema format
> 
> Signed-off-by: Maciej Falkowski 
> Signed-off-by: Marek Szyprowski 
> ---
> v2:
> - Added if-then statements for 'clocks' and 'clock-names'
> properties.
> 
> Best regards,
> Maciej Falkowski
> ---
>  .../devicetree/bindings/gpu/samsung-g2d.txt   | 27 ---
>  .../devicetree/bindings/gpu/samsung-g2d.yaml  | 76 +++
>  2 files changed, 76 insertions(+), 27 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-g2d.txt
>  create mode 100644 Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> 
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-g2d.txt 
> b/Documentation/devicetree/bindings/gpu/samsung-g2d.txt
> deleted file mode 100644
> index 1e7959332dbc..
> --- a/Documentation/devicetree/bindings/gpu/samsung-g2d.txt
> +++ /dev/null
> @@ -1,27 +0,0 @@
> -* Samsung 2D Graphics Accelerator
> -
> -Required properties:
> -  - compatible : value should be one among the following:
> - (a) "samsung,s5pv210-g2d" for G2D IP present in S5PV210 & Exynos4210 SoC
> - (b) "samsung,exynos4212-g2d" for G2D IP present in Exynos4x12 SoCs
> - (c) "samsung,exynos5250-g2d" for G2D IP present in Exynos5250 SoC
> -
> -  - reg : Physical base address of the IP registers and length of memory
> -   mapped region.
> -
> -  - interrupts : G2D interrupt number to the CPU.
> -  - clocks : from common clock binding: handle to G2D clocks.
> -  - clock-names : names of clocks listed in clocks property, in the same
> -   order, depending on SoC type:
> -   - for S5PV210 and Exynos4 based SoCs: "fimg2d" and
> - "sclk_fimg2d"
> -   - for Exynos5250 SoC: "fimg2d".
> -
> -Example:
> - g2d@1280 {
> - compatible = "samsung,s5pv210-g2d";
> - reg = <0x1280 0x1000>;
> - interrupts = <0 89 0>;
> - clocks = < 177>, < 277>;
> - clock-names = "sclk_fimg2d", "fimg2d";
> - };
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml 
> b/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> new file mode 100644
> index ..5e05e8ccc83f
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> @@ -0,0 +1,76 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpu/samsung-g2d.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Samsung SoC 2D Graphics Accelerator
> +
> +maintainers:
> +  - Inki Dae 
> +
> +properties:
> +  compatible:
> +enum:
> +  - samsung,s5pv210-g2d# in S5PV210 & Exynos4210 SoC
> +  - samsung,exynos4212-g2d # in Exynos4x12 SoCs
> +  - samsung,exynos5250-g2d
> +
> +  reg:
> +maxItems: 1
> +
> +  interrupts:
> +maxItems: 1
> +

I think it is worth to leave the clocks and clock-names here (could be
empty or with min/max values for number of items). This makes it easy to
find the properties by humans.

Midgard bindings could be used as example.

> +allOf:
> +  - if:
> +  properties:
> +compatible:
> +  contains:
> +const: samsung,exynos5250-g2d
> +
> +then:
> +  properties:
> +clocks:
> +  items:
> +- description: fimg2d clock
> +clock-names:
> +  items:
> +- const: fimg2d
> +
> +  - if:

else:

Best regards,
Krzysztof

> +  properties:
> +compatible:
> +  contains:
> +enum:
> +  - samsung,s5pv210-g2d
> +  - samsung,exynos4212-g2d
> +
> +then:
> +  properties:
> +clocks:
> +  items:
> +- description: sclk_fimg2d clock
> +- description: fimg2d clock
> +clock-names:
> +  items:
> +- const: sclk_fimg2d
> +- const: fimg2d
> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - clock-names
> +
> +examples:
> +  - |
> +g2d@1280 {
> +compatible = "samsung,s5pv210-g2d";
> +reg = <0x1280 0x1000>;
> +interrupts = <0 89 0>;
> +clocks = < 177>, < 277>;
> +clock-names = "sclk_fimg2d", "fimg2d";
> +};
> +
> -- 
> 2.17.1
> 
> 
> 


Re: [PATCH] dt-bindings: gpu: Convert Samsung 2D Graphics Accelerator to dt-schema

2019-09-24 Thread Krzysztof Kozlowski
On Tue, Sep 24, 2019 at 01:31:59PM +0200, Marek Szyprowski wrote:
> From: Maciej Falkowski 
> 
> Convert Samsung 2D Graphics Accelerator to newer dt-schema format
> 
> Signed-off-by: Maciej Falkowski 
> Signed-off-by: Marek Szyprowski 
> ---
>  .../devicetree/bindings/gpu/samsung-g2d.txt   | 27 --
>  .../devicetree/bindings/gpu/samsung-g2d.yaml  | 53 +++
>  2 files changed, 53 insertions(+), 27 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-g2d.txt
>  create mode 100644 Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> 
> diff --git a/Documentation/devicetree/bindings/gpu/samsung-g2d.txt 
> b/Documentation/devicetree/bindings/gpu/samsung-g2d.txt
> deleted file mode 100644
> index 1e7959332dbc..
> --- a/Documentation/devicetree/bindings/gpu/samsung-g2d.txt
> +++ /dev/null
> @@ -1,27 +0,0 @@
> -* Samsung 2D Graphics Accelerator
> -
> -Required properties:
> -  - compatible : value should be one among the following:
> - (a) "samsung,s5pv210-g2d" for G2D IP present in S5PV210 & Exynos4210 SoC
> - (b) "samsung,exynos4212-g2d" for G2D IP present in Exynos4x12 SoCs
> - (c) "samsung,exynos5250-g2d" for G2D IP present in Exynos5250 SoC
> -
> -  - reg : Physical base address of the IP registers and length of memory
> -   mapped region.
> -
> -  - interrupts : G2D interrupt number to the CPU.
> -  - clocks : from common clock binding: handle to G2D clocks.
> -  - clock-names : names of clocks listed in clocks property, in the same
> -   order, depending on SoC type:
> -   - for S5PV210 and Exynos4 based SoCs: "fimg2d" and
> - "sclk_fimg2d"
> -   - for Exynos5250 SoC: "fimg2d".
> -
> -Example:
> - g2d@1280 {
> - compatible = "samsung,s5pv210-g2d";
> - reg = <0x1280 0x1000>;
> - interrupts = <0 89 0>;
> - clocks = < 177>, < 277>;
> - clock-names = "sclk_fimg2d", "fimg2d";
> - };
>ss diff --git a/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml 
>b/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> new file mode 100644
> index ..bb0a4bf168cc
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpu/samsung-g2d.yaml
> @@ -0,0 +1,53 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpu/samsung-g2d.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Samsung SoC 2D Graphics Accelerator
> +
> +maintainers:
> +  - Inki Dae 
> +
> +properties:
> +  compatible:
> +enum:
> +  - samsung,s5pv210-g2d# in S5PV210 & Exynos4210 SoC
> +  - samsung,exynos4212-g2d # in Exynos4x12 SoCs
> +  - samsung,exynos5250-g2d
> +
> +  reg:
> +maxItems: 1
> +
> +  interrupts:
> +maxItems: 1
> +
> +  clocks:
> +minItems: 1
> +maxItems: 2
> +
> +  clock-names:
> +oneOf:
> +  - items: # for Exynos5250 SoC
> +  - const: fimg2d
> +  - items: # for S5PV210 and Exynos4 based SoCs
> +  - const: sclk_fimg2d
> +  - const: fimg2d

Just like in previous conversions ("dt-bindings: gpu: Convert Samsung
Image Scaler to dt-schem") - you need to add here proper if-else
constraints.


Best regards,
Krzysztof


> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - clock-names
> +
> +examples
> +  - |
> +g2d@1280 {
> +compatible = "samsung,s5pv210-g2d";
> +reg = <0x1280 0x1000>;
> +interrupts = <0 89 0>;
> +clocks = < 177>, < 277>;
> +clock-names = "sclk_fimg2d", "fimg2d";
> +};
> +
> -- 
> 2.17.1
> 
> 
> 
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH v2 2/3] dt-bindings: power: Convert Samsung Exynos Power Domain bindings to json-schema

2019-10-02 Thread Krzysztof Kozlowski
Convert Samsung Exynos Soc Power Domain bindings to DT schema format using
json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Indent example with four spaces (more readable),
2. Remove unneeded types,
3. Add missing address in example and fix the name.
---
 .../devicetree/bindings/power/pd-samsung.txt  | 45 -
 .../devicetree/bindings/power/pd-samsung.yaml | 66 +++
 2 files changed, 66 insertions(+), 45 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/power/pd-samsung.txt
 create mode 100644 Documentation/devicetree/bindings/power/pd-samsung.yaml

diff --git a/Documentation/devicetree/bindings/power/pd-samsung.txt 
b/Documentation/devicetree/bindings/power/pd-samsung.txt
deleted file mode 100644
index 92ef355e8f64..
--- a/Documentation/devicetree/bindings/power/pd-samsung.txt
+++ /dev/null
@@ -1,45 +0,0 @@
-* Samsung Exynos Power Domains
-
-Exynos processors include support for multiple power domains which are used
-to gate power to one or more peripherals on the processor.
-
-Required Properties:
-- compatible: should be one of the following.
-* samsung,exynos4210-pd - for exynos4210 type power domain.
-* samsung,exynos5433-pd - for exynos5433 type power domain.
-- reg: physical base address of the controller and length of memory mapped
-region.
-- #power-domain-cells: number of cells in power domain specifier;
-must be 0.
-
-Optional Properties:
-- label: Human readable string with domain name. Will be visible in userspace
-   to let user to distinguish between multiple domains in SoC.
-- power-domains: phandle pointing to the parent power domain, for more details
-see Documentation/devicetree/bindings/power/power_domain.txt
-
-Deprecated Properties:
-- clocks
-- clock-names
-
-Node of a device using power domains must have a power-domains property
-defined with a phandle to respective power domain.
-
-Example:
-
-   lcd0: power-domain-lcd0 {
-   compatible = "samsung,exynos4210-pd";
-   reg = <0x10023C00 0x10>;
-   #power-domain-cells = <0>;
-   label = "LCD0";
-   };
-
-   mfc_pd: power-domain@10044060 {
-   compatible = "samsung,exynos4210-pd";
-   reg = <0x10044060 0x20>;
-   #power-domain-cells = <0>;
-   label = "MFC";
-   };
-
-See Documentation/devicetree/bindings/power/power_domain.txt for description
-of consumer-side bindings.
diff --git a/Documentation/devicetree/bindings/power/pd-samsung.yaml 
b/Documentation/devicetree/bindings/power/pd-samsung.yaml
new file mode 100644
index ..09bdd96c1ec1
--- /dev/null
+++ b/Documentation/devicetree/bindings/power/pd-samsung.yaml
@@ -0,0 +1,66 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/power/pd-samsung.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung Exynos SoC Power Domains
+
+maintainers:
+  - Krzysztof Kozlowski 
+
+description: |+
+  Exynos processors include support for multiple power domains which are used
+  to gate power to one or more peripherals on the processor.
+
+allOf:
+  - $ref: power-domain.yaml#
+
+properties:
+  compatible:
+enum:
+  - samsung,exynos4210-pd
+  - samsung,exynos5433-pd
+
+  reg:
+maxItems: 1
+
+  clocks:
+deprecated: true
+maxItems: 1
+
+  clock-names:
+deprecated: true
+maxItems: 1
+
+  label:
+description:
+  Human readable string with domain name. Will be visible in userspace
+  to let user to distinguish between multiple domains in SoC.
+
+  "#power-domain-cells":
+const: 0
+
+  power-domains:
+maxItems: 1
+
+required:
+  - compatible
+  - "#power-domain-cells"
+  - reg
+
+examples:
+  - |
+lcd0_pd: power-domain@10023c80 {
+compatible = "samsung,exynos4210-pd";
+reg = <0x10023c80 0x20>;
+#power-domain-cells = <0>;
+label = "LCD0";
+};
+
+mfc_pd: power-domain@10044060 {
+compatible = "samsung,exynos4210-pd";
+reg = <0x10044060 0x20>;
+#power-domain-cells = <0>;
+label = "MFC";
+};
-- 
2.17.1



[PATCH v2 1/3] dt-bindings: power: Convert Generic Power Domain bindings to json-schema

2019-10-02 Thread Krzysztof Kozlowski
Convert Generic Power Domain bindings to DT schema format using
json-schema.  The consumer bindings are split to separate file.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Select all nodes for consumers,
2. Remove from consumers duplicated properties with dt-schema,
3. Fix power domain pattern,
4. Remove unneeded types.
---
 .../devicetree/bindings/arm/arm,scmi.txt  |   2 +-
 .../devicetree/bindings/arm/arm,scpi.txt  |   2 +-
 .../bindings/arm/freescale/fsl,scu.txt|   2 +-
 .../bindings/clock/clk-exynos-audss.txt   |   2 +-
 .../bindings/clock/exynos5433-clock.txt   |   4 +-
 .../bindings/clock/renesas,cpg-mssr.txt   |   2 +-
 .../clock/renesas,r8a7778-cpg-clocks.txt  |   2 +-
 .../clock/renesas,r8a7779-cpg-clocks.txt  |   2 +-
 .../clock/renesas,rcar-gen2-cpg-clocks.txt|   2 +-
 .../bindings/clock/renesas,rz-cpg-clocks.txt  |   2 +-
 .../bindings/clock/ti/davinci/psc.txt |   2 +-
 .../bindings/display/etnaviv/etnaviv-drm.txt  |   2 +-
 .../devicetree/bindings/display/msm/dpu.txt   |   2 +-
 .../devicetree/bindings/display/msm/mdp5.txt  |   2 +-
 .../devicetree/bindings/dsp/fsl,dsp.yaml  |   2 +-
 .../firmware/nvidia,tegra186-bpmp.txt |   2 +-
 .../bindings/media/imx7-mipi-csi2.txt |   3 +-
 .../bindings/media/mediatek-jpeg-decoder.txt  |   3 +-
 .../bindings/media/mediatek-mdp.txt   |   3 +-
 .../bindings/opp/qcom-nvmem-cpufreq.txt   |   2 +-
 .../devicetree/bindings/pci/pci-keystone.txt  |   2 +-
 .../bindings/phy/ti,phy-am654-serdes.txt  |   2 +-
 .../bindings/power/amlogic,meson-gx-pwrc.txt  |   2 +-
 .../devicetree/bindings/power/fsl,imx-gpc.txt |   2 +-
 .../bindings/power/fsl,imx-gpcv2.txt  |   2 +-
 .../power/power-domain-consumers.yaml | 105 +
 .../bindings/power/power-domain.yaml  | 134 
 .../bindings/power/power_domain.txt   | 205 --
 .../devicetree/bindings/power/qcom,rpmpd.txt  |   2 +-
 .../bindings/power/renesas,rcar-sysc.txt  |   2 +-
 .../bindings/power/renesas,sysc-rmobile.txt   |   2 +-
 .../bindings/power/xlnx,zynqmp-genpd.txt  |   2 +-
 .../bindings/soc/bcm/brcm,bcm2835-pm.txt  |   2 +-
 .../bindings/soc/mediatek/scpsys.txt  |   2 +-
 .../bindings/soc/ti/sci-pm-domain.txt |   2 +-
 .../bindings/usb/nvidia,tegra124-xusb.txt |   4 +-
 MAINTAINERS   |   2 +-
 37 files changed, 278 insertions(+), 241 deletions(-)
 create mode 100644 
Documentation/devicetree/bindings/power/power-domain-consumers.yaml
 create mode 100644 Documentation/devicetree/bindings/power/power-domain.yaml
 delete mode 100644 Documentation/devicetree/bindings/power/power_domain.txt

diff --git a/Documentation/devicetree/bindings/arm/arm,scmi.txt 
b/Documentation/devicetree/bindings/arm/arm,scmi.txt
index 083dbf96ee00..f493d69e6194 100644
--- a/Documentation/devicetree/bindings/arm/arm,scmi.txt
+++ b/Documentation/devicetree/bindings/arm/arm,scmi.txt
@@ -100,7 +100,7 @@ Required sub-node properties:
 
 [0] http://infocenter.arm.com/help/topic/com.arm.doc.den0056a/index.html
 [1] Documentation/devicetree/bindings/clock/clock-bindings.txt
-[2] Documentation/devicetree/bindings/power/power_domain.txt
+[2] Documentation/devicetree/bindings/power/power-domain.yaml
 [3] Documentation/devicetree/bindings/thermal/thermal.txt
 [4] Documentation/devicetree/bindings/sram/sram.txt
 [5] Documentation/devicetree/bindings/reset/reset.txt
diff --git a/Documentation/devicetree/bindings/arm/arm,scpi.txt 
b/Documentation/devicetree/bindings/arm/arm,scpi.txt
index 401831973638..7b83ef43b418 100644
--- a/Documentation/devicetree/bindings/arm/arm,scpi.txt
+++ b/Documentation/devicetree/bindings/arm/arm,scpi.txt
@@ -110,7 +110,7 @@ Required properties:
 [1] Documentation/devicetree/bindings/clock/clock-bindings.txt
 [2] Documentation/devicetree/bindings/thermal/thermal.txt
 [3] Documentation/devicetree/bindings/sram/sram.txt
-[4] Documentation/devicetree/bindings/power/power_domain.txt
+[4] Documentation/devicetree/bindings/power/power-domain.yaml
 
 Example:
 
diff --git a/Documentation/devicetree/bindings/arm/freescale/fsl,scu.txt 
b/Documentation/devicetree/bindings/arm/freescale/fsl,scu.txt
index c149fadc6f47..6c8a61b971f1 100644
--- a/Documentation/devicetree/bindings/arm/freescale/fsl,scu.txt
+++ b/Documentation/devicetree/bindings/arm/freescale/fsl,scu.txt
@@ -124,7 +124,7 @@ Required properties for Pinctrl sub nodes:
CONFIG settings.
 
 [1] Documentation/devicetree/bindings/clock/clock-bindings.txt
-[2] Documentation/devicetree/bindings/power/power_domain.txt
+[2] Documentation/devicetree/bindings/power/power-domain.yaml
 [3] Documentation/devicetree/bindings/pinctrl/fsl,imx-pinctrl.txt
 
 RTC bindings based on SCU Message Protocol
diff --git a/Documentation/devicetree/bindings/clock/clk-exynos-audss.txt 
b/Documentation/devicetree/bindings/clock/clk-exynos-audss.txt
index

[PATCH v2 3/3] ARM: dts: exynos: Rename power domain nodes to "power-domain" in Exynos4

2019-10-02 Thread Krzysztof Kozlowski
The device node name should reflect generic class of a device so rename
power domain nodes to "power-domain".  No functional change.

Signed-off-by: Krzysztof Kozlowski 
---
 arch/arm/boot/dts/exynos4.dtsi| 14 +++---
 arch/arm/boot/dts/exynos4210.dtsi |  2 +-
 arch/arm/boot/dts/exynos4412.dtsi |  2 +-
 3 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/exynos4.dtsi b/arch/arm/boot/dts/exynos4.dtsi
index 433f109d97ca..d2779a790ce3 100644
--- a/arch/arm/boot/dts/exynos4.dtsi
+++ b/arch/arm/boot/dts/exynos4.dtsi
@@ -111,28 +111,28 @@
syscon = <_system_controller>;
};
 
-   pd_mfc: mfc-power-domain@10023c40 {
+   pd_mfc: power-domain@10023c40 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023C40 0x20>;
#power-domain-cells = <0>;
label = "MFC";
};
 
-   pd_g3d: g3d-power-domain@10023c60 {
+   pd_g3d: power-domain@10023c60 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023C60 0x20>;
#power-domain-cells = <0>;
label = "G3D";
};
 
-   pd_lcd0: lcd0-power-domain@10023c80 {
+   pd_lcd0: power-domain@10023c80 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023C80 0x20>;
#power-domain-cells = <0>;
label = "LCD0";
};
 
-   pd_tv: tv-power-domain@10023c20 {
+   pd_tv: power-domain@10023c20 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023C20 0x20>;
#power-domain-cells = <0>;
@@ -140,21 +140,21 @@
label = "TV";
};
 
-   pd_cam: cam-power-domain@10023c00 {
+   pd_cam: power-domain@10023c00 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023C00 0x20>;
#power-domain-cells = <0>;
label = "CAM";
};
 
-   pd_gps: gps-power-domain@10023ce0 {
+   pd_gps: power-domain@10023ce0 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023CE0 0x20>;
#power-domain-cells = <0>;
label = "GPS";
};
 
-   pd_gps_alive: gps-alive-power-domain@10023d00 {
+   pd_gps_alive: power-domain@10023d00 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023D00 0x20>;
#power-domain-cells = <0>;
diff --git a/arch/arm/boot/dts/exynos4210.dtsi 
b/arch/arm/boot/dts/exynos4210.dtsi
index f220716239db..ff9a3fb21a85 100644
--- a/arch/arm/boot/dts/exynos4210.dtsi
+++ b/arch/arm/boot/dts/exynos4210.dtsi
@@ -90,7 +90,7 @@
};
};
 
-   pd_lcd1: lcd1-power-domain@10023ca0 {
+   pd_lcd1: power-domain@10023ca0 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023CA0 0x20>;
#power-domain-cells = <0>;
diff --git a/arch/arm/boot/dts/exynos4412.dtsi 
b/arch/arm/boot/dts/exynos4412.dtsi
index d20db2dfe8e2..1c40bd56ce00 100644
--- a/arch/arm/boot/dts/exynos4412.dtsi
+++ b/arch/arm/boot/dts/exynos4412.dtsi
@@ -206,7 +206,7 @@
};
};
 
-   pd_isp: isp-power-domain@10023ca0 {
+   pd_isp: power-domain@10023ca0 {
compatible = "samsung,exynos4210-pd";
reg = <0x10023CA0 0x20>;
#power-domain-cells = <0>;
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH v3 1/2] dt-bindings: pwm: Convert PWM bindings to json-schema

2019-10-02 Thread Krzysztof Kozlowski
Convert generic PWM bindings to DT schema format using json-schema.  The
consumer bindings are split to separate file.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v2:
1. Change also pwm-sprd.txt

Changes since v1:
1. Indent example with four spaces (more readable),
2. Change pattern for pwm nodes,
3. Remove $ref from #cells.
---
 .../devicetree/bindings/clock/pwm-clock.txt   |  2 +-
 .../bindings/display/bridge/ti,sn65dsi86.txt  |  2 +-
 .../devicetree/bindings/display/ssd1307fb.txt |  2 +-
 .../bindings/leds/backlight/pwm-backlight.txt |  2 +-
 .../devicetree/bindings/leds/leds-pwm.txt |  2 +-
 .../devicetree/bindings/mfd/max77693.txt  |  2 +-
 .../bindings/pwm/atmel-hlcdc-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/atmel-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/atmel-tcb-pwm.txt |  2 +-
 .../bindings/pwm/brcm,bcm7038-pwm.txt |  2 +-
 .../bindings/pwm/brcm,iproc-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/brcm,kona-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/img-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/imx-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/imx-tpm-pwm.txt   |  2 +-
 .../bindings/pwm/lpc1850-sct-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/mxs-pwm.txt   |  2 +-
 .../bindings/pwm/nvidia,tegra20-pwm.txt   |  2 +-
 .../bindings/pwm/nxp,pca9685-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-bcm2835.txt   |  2 +-
 .../devicetree/bindings/pwm/pwm-berlin.txt|  2 +-
 .../bindings/pwm/pwm-consumers.yaml   | 76 +++
 .../devicetree/bindings/pwm/pwm-fsl-ftm.txt   |  2 +-
 .../devicetree/bindings/pwm/pwm-hibvt.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-lp3943.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-mediatek.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-meson.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-mtk-disp.txt  |  2 +-
 .../bindings/pwm/pwm-omap-dmtimer.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-rockchip.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-sifive.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-sprd.txt  |  4 +-
 .../devicetree/bindings/pwm/pwm-stm32-lp.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-stm32.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-tiecap.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-tiehrpwm.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-zx.txt|  2 +-
 Documentation/devicetree/bindings/pwm/pwm.txt | 69 -
 .../devicetree/bindings/pwm/pwm.yaml  | 29 +++
 .../bindings/pwm/renesas,pwm-rcar.txt |  2 +-
 .../bindings/pwm/renesas,tpu-pwm.txt  |  4 +-
 .../devicetree/bindings/pwm/spear-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/st,stmpe-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/ti,twl-pwm.txt|  2 +-
 .../devicetree/bindings/pwm/ti,twl-pwmled.txt |  2 +-
 .../devicetree/bindings/pwm/vt8500-pwm.txt|  2 +-
 .../bindings/regulator/pwm-regulator.txt  |  2 +-
 .../devicetree/bindings/timer/ingenic,tcu.txt |  2 +-
 48 files changed, 152 insertions(+), 116 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm-consumers.yaml
 delete mode 100644 Documentation/devicetree/bindings/pwm/pwm.txt
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm.yaml

diff --git a/Documentation/devicetree/bindings/clock/pwm-clock.txt 
b/Documentation/devicetree/bindings/clock/pwm-clock.txt
index 83db876b3b90..8a791b6d76a9 100644
--- a/Documentation/devicetree/bindings/clock/pwm-clock.txt
+++ b/Documentation/devicetree/bindings/clock/pwm-clock.txt
@@ -3,7 +3,7 @@ Binding for an external clock signal driven by a PWM pin.
 This binding uses the common clock binding[1] and the common PWM binding[2].
 
 [1] Documentation/devicetree/bindings/clock/clock-bindings.txt
-[2] Documentation/devicetree/bindings/pwm/pwm.txt
+[2] Documentation/devicetree/bindings/pwm/pwm-consumers.yaml
 
 Required properties:
 - compatible : shall be "pwm-clock".
diff --git a/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt 
b/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
index 0a3fbb53a16e..8ec4a7f2623a 100644
--- a/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
+++ b/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
@@ -21,7 +21,7 @@ Optional properties:
 - #gpio-cells: Should be two. The first cell is the pin number and
the second cell is used to specify flags.
See ../../gpio/gpio.txt for more information.
-- #pwm-cells : Should be one. See ../../pwm/pwm.txt for description of
+- #pwm-cells : Should be one. See ../../pwm/pwm.yaml for description of
the cell formats.
 
 - clock-names: should be "refclk"
diff --git a/Documentation/devicetree/bindings/display/ssd1307fb.txt 
b/Documentation/devicetree/bindings/display/ssd1307fb.txt
index 27333b9551b3..da9b28153a3c 100644
--- a/Documentation/devicetree/bindings/display

[PATCH v3 2/2] dt-bindings: pwm: Convert Samsung PWM bindings to json-schema

2019-10-02 Thread Krzysztof Kozlowski
Convert Samsung PWM (S3C, S5P and Exynos SoCs) bindings to DT schema
format using json-schema.

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v2:
1. Add additionalProperties: false.

Changes since v1:
1. Indent example with four spaces (more readable),
2. Fix samsung,pwm-outputs after review,
3. Remove double-quotes from clock names.
---
 .../devicetree/bindings/pwm/pwm-samsung.txt   |  51 
 .../devicetree/bindings/pwm/pwm-samsung.yaml  | 109 ++
 2 files changed, 109 insertions(+), 51 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/pwm/pwm-samsung.txt
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm-samsung.yaml

diff --git a/Documentation/devicetree/bindings/pwm/pwm-samsung.txt 
b/Documentation/devicetree/bindings/pwm/pwm-samsung.txt
deleted file mode 100644
index 5538de9c2007..
--- a/Documentation/devicetree/bindings/pwm/pwm-samsung.txt
+++ /dev/null
@@ -1,51 +0,0 @@
-* Samsung PWM timers
-
-Samsung SoCs contain PWM timer blocks which can be used for system clock source
-and clock event timers, as well as to drive SoC outputs with PWM signal. Each
-PWM timer block provides 5 PWM channels (not all of them can drive physical
-outputs - see SoC and board manual).
-
-Be aware that the clocksource driver supports only uniprocessor systems.
-
-Required properties:
-- compatible : should be one of following:
-samsung,s3c2410-pwm - for 16-bit timers present on S3C24xx SoCs
-samsung,s3c6400-pwm - for 32-bit timers present on S3C64xx SoCs
-samsung,s5p6440-pwm - for 32-bit timers present on S5P64x0 SoCs
-samsung,s5pc100-pwm - for 32-bit timers present on S5PC100, S5PV210,
- Exynos4210 rev0 SoCs
-samsung,exynos4210-pwm - for 32-bit timers present on Exynos4210,
-  Exynos4x12, Exynos5250 and Exynos5420 SoCs
-- reg: base address and size of register area
-- interrupts: list of timer interrupts (one interrupt per timer, starting at
-  timer 0)
-- clock-names: should contain all following required clock names:
-- "timers" - PWM base clock used to generate PWM signals,
-  and any subset of following optional clock names:
-- "pwm-tclk0" - first external PWM clock source,
-- "pwm-tclk1" - second external PWM clock source.
-  Note that not all IP variants allow using all external clock sources.
-  Refer to SoC documentation to learn which clock source configurations
-  are available.
-- clocks: should contain clock specifiers of all clocks, which input names
-  have been specified in clock-names property, in same order.
-- #pwm-cells: should be 3. See pwm.txt in this directory for a description of
-  the cells format. The only third cell flag supported by this binding is
-  PWM_POLARITY_INVERTED.
-
-Optional properties:
-- samsung,pwm-outputs: list of PWM channels used as PWM outputs on particular
-platform - an array of up to 5 elements being indices of PWM channels
-(from 0 to 4), the order does not matter.
-
-Example:
-   pwm@7f006000 {
-   compatible = "samsung,s3c6400-pwm";
-   reg = <0x7f006000 0x1000>;
-   interrupt-parent = <>;
-   interrupts = <23>, <24>, <25>, <27>, <28>;
-   clocks = < 67>;
-   clock-names = "timers";
-   samsung,pwm-outputs = <0>, <1>;
-   #pwm-cells = <3>;
-   }
diff --git a/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml 
b/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml
new file mode 100644
index ..ea7f32905172
--- /dev/null
+++ b/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml
@@ -0,0 +1,109 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/pwm/pwm-samsung.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung SoC PWM timers
+
+maintainers:
+  - Thierry Reding 
+  - Krzysztof Kozlowski 
+
+description: |+
+  Samsung SoCs contain PWM timer blocks which can be used for system clock 
source
+  and clock event timers, as well as to drive SoC outputs with PWM signal. Each
+  PWM timer block provides 5 PWM channels (not all of them can drive physical
+  outputs - see SoC and board manual).
+
+  Be aware that the clocksource driver supports only uniprocessor systems.
+
+allOf:
+  - $ref: pwm.yaml#
+
+properties:
+  compatible:
+enum:
+  - samsung,s3c2410-pwm # 16-bit, S3C24xx
+  - samsung,s3c6400-pwm # 32-bit, S3C64xx
+  - samsung,s5p6440-pwm # 32-bit, S5P64x0
+  - samsung,s5pc100-pwm # 32-bit, S5PC100, S5PV210, Exynos4210 
rev0 SoCs
+  - samsung,exynos4210-pwm  # 32-bit, Exynos
+
+  reg:
+maxItems: 1
+
+  clocks:
+minItems: 1
+maxItems: 3
+
+  clock-names:
+description: |
+  Should contain all following required clock

Re: [PATCH 1/2] dt-bindings: gpu: add Exynos Mali vendor specifics

2019-06-16 Thread Krzysztof Kozlowski
On Fri, Jun 14, 2019 at 01:31:43PM -0700, Joseph Kogut wrote:
> Document vendor specific compatible string for Mali gpus on Exynos SoCs.
> 
> Signed-off-by: Joseph Kogut 
> ---
>  Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt 
> b/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt
> index 1b1a74129141..a9704c736d07 100644
> --- a/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt
> +++ b/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt
> @@ -18,6 +18,7 @@ Required properties:
>  + "amlogic,meson-gxm-mali"
>  + "rockchip,rk3288-mali"
>  + "rockchip,rk3399-mali"
> ++ "samsung,exynos-mali"

Are there any driver differences for Exynos? If not then why adding
another compatible?

Best regards,
Krzysztof

>  
>  - reg : Physical base address of the device and length of the register area.
>  
> -- 
> 2.22.0
> 
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v2 2/2] arm: dts: add ARM Mali GPU node for Odroid XU3

2019-06-16 Thread Krzysztof Kozlowski
On Fri, Jun 14, 2019 at 04:57:19PM -0700, Joseph Kogut wrote:
> Add device tree node for mali gpu on Odroid XU3 SoCs.
> 
> Signed-off-by: Joseph Kogut 
> ---
> 
> Changes v1 -> v2:
> - Use interrupt name ordering from binding doc
> - Specify a single clock for GPU node
> - Add gpu opp table
> - Fix warnings from IRQ_TYPE_NONE
> 
>  .../boot/dts/exynos5422-odroidxu3-common.dtsi | 26 +++

This should go to exynos5422-odroid-core.dtsi instead, because it is
common to entire Odroid Exynos5422 family (not only XU3 family).

>  1 file changed, 26 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi 
> b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
> index 93a48f2dda49..b8a4246e3b37 100644
> --- a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
> +++ b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
> @@ -48,6 +48,32 @@
>   cooling-levels = <0 130 170 230>;
>   };
> 
> + gpu: gpu@1180 {
> + compatible = "samsung,exynos-mali", "arm,mali-t628";

This is common to all Exynos542x chips so it should go to
exynos5420.dtsi. Here you would need to only enable it and provide
regulator.

Probably this should be also associated with tmu_gpu as a cooling device
(if Mali registers a cooling device...). Otherwise the tmu_gpu is not
really used for it.

> + reg = <0x1180 0x5000>;
> + interrupts = ,
> +  ,
> +  ;
> + interrupt-names = "job", "mmu", "gpu";
> + clocks = < CLK_G3D>;
> + mali-supply = <_reg>;

Please check if always-on property could be removed from buck4. Also,
what about LDO27? It should be used as well (maybe through
vendor-specific properties which would justify the need of new vendor
compatible).


Best regards,
Krzysztof

> + operating-points-v2 = <_opp_table>;
> + };
> +
> + gpu_opp_table: gpu-opp-table {
> + compatible = "operating-points-v2";
> +
> + opp-17700 {
> + opp-hz = /bits/ 64 <11700>;
> + opp-microvolt = <812500>;
> + };
> +
> + opp-6 {
> + opp-hz = /bits/ 64 <6>;
> + opp-microvolt = <115>;
> + };
> + };
> +
>   thermal-zones {
>   cpu0_thermal: cpu0-thermal {
>   thermal-sensors = <_cpu0 0>;
> --
> 2.22.0
> 
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH 1/7] dt-bindings: gpu: mali-midgard: Tidy up conversion to YAML

2019-11-06 Thread Krzysztof Kozlowski
On Wed, 6 Nov 2019 at 15:25, Rob Herring  wrote:
>
> On Sun, Nov 3, 2019 at 7:40 PM Andreas Färber  wrote:
> >
> > Instead of grouping alphabetically by third-party vendor, leading to
> > one-element enums, sort by Mali model number, as done for Utgard.
> >
> > This already allows us to de-duplicate two "arm,mali-t760" sections and
> > will make it easier to add new vendor compatibles.
>
> That was the intent. Not sure how I messed that up...
>
> This patch is problematic because there's changes in arm-soc juno/dt
> branch and there's now a patch for exynos5420 (t628). I'd propose I
> apply this such that we don't get a merge conflict with juno/dt and we
> finish resorting after rc1 (or when both branches are in Linus' tree).

After resubmit, you could take the exynos5420 bindings one (and I'll
take the DTS). However the submitter should base then on latest next,
assuming you'll apply this one.

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/sun4i: Fix Kconfig indentation

2019-11-21 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/sun4i/Kconfig | 16 
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/drivers/gpu/drm/sun4i/Kconfig b/drivers/gpu/drm/sun4i/Kconfig
index 37e90e42943f..5755f0432e77 100644
--- a/drivers/gpu/drm/sun4i/Kconfig
+++ b/drivers/gpu/drm/sun4i/Kconfig
@@ -17,18 +17,18 @@ config DRM_SUN4I
 if DRM_SUN4I
 
 config DRM_SUN4I_HDMI
-   tristate "Allwinner A10 HDMI Controller Support"
-   default DRM_SUN4I
-   help
+   tristate "Allwinner A10 HDMI Controller Support"
+   default DRM_SUN4I
+   help
  Choose this option if you have an Allwinner SoC with an HDMI
  controller.
 
 config DRM_SUN4I_HDMI_CEC
-   bool "Allwinner A10 HDMI CEC Support"
-   depends on DRM_SUN4I_HDMI
-   select CEC_CORE
-   select CEC_PIN
-   help
+   bool "Allwinner A10 HDMI CEC Support"
+   depends on DRM_SUN4I_HDMI
+   select CEC_CORE
+   select CEC_PIN
+   help
  Choose this option if you have an Allwinner SoC with an HDMI
  controller and want to use CEC.
 
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/vc4: Fix Kconfig indentation

2019-11-21 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/vc4/Kconfig | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/vc4/Kconfig b/drivers/gpu/drm/vc4/Kconfig
index 7c2317efd5b7..118e8a426b1a 100644
--- a/drivers/gpu/drm/vc4/Kconfig
+++ b/drivers/gpu/drm/vc4/Kconfig
@@ -22,9 +22,9 @@ config DRM_VC4
  our display setup.
 
 config DRM_VC4_HDMI_CEC
-   bool "Broadcom VC4 HDMI CEC Support"
-   depends on DRM_VC4
-   select CEC_CORE
-   help
+   bool "Broadcom VC4 HDMI CEC Support"
+   depends on DRM_VC4
+   select CEC_CORE
+   help
  Choose this option if you have a Broadcom VC4 GPU
  and want to use CEC.
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/amd: Fix Kconfig indentation

2019-11-21 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/amd/acp/Kconfig | 10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/gpu/drm/amd/acp/Kconfig b/drivers/gpu/drm/amd/acp/Kconfig
index d968c2471412..19bae9100da4 100644
--- a/drivers/gpu/drm/amd/acp/Kconfig
+++ b/drivers/gpu/drm/amd/acp/Kconfig
@@ -2,11 +2,11 @@
 menu "ACP (Audio CoProcessor) Configuration"
 
 config DRM_AMD_ACP
-   bool "Enable AMD Audio CoProcessor IP support"
-   depends on DRM_AMDGPU
-   select MFD_CORE
-   select PM_GENERIC_DOMAINS if PM
-   help
+   bool "Enable AMD Audio CoProcessor IP support"
+   depends on DRM_AMDGPU
+   select MFD_CORE
+   select PM_GENERIC_DOMAINS if PM
+   help
Choose this option to enable ACP IP support for AMD SOCs.
This adds the ACP (Audio CoProcessor) IP driver and wires
it up into the amdgpu driver.  The ACP block provides the DMA
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v2] backlight: pwm_bl: Switch to full GPIO descriptor

2019-12-16 Thread Krzysztof Kozlowski
On Fri, 13 Dec 2019 at 11:23, Linus Walleij  wrote:
>
> The PWM backlight still supports passing a enable GPIO line as
> platform data using the legacy  API.
>
> It turns out that ever board using this mechanism except one
> is pass .enable_gpio = -1. So we drop all these cargo-culted -1's
> from all instances of this platform data in the kernel.
>
> The remaning board, Palm TC, is converted to pass a machine
> descriptior table with the "enable" GPIO instead, and delete the
> platform data entry for enable_gpio and the code handling it
> and things should work smoothly with the new API.
>
> Cc: Krzysztof Kozlowski 
> Cc: Robert Jarzmik 
> Cc: Guan Xuetao 
> Reviewed-by: Bartosz Golaszewski 
> Signed-off-by: Linus Walleij 
> ---
> ChangeLog v1->v2:
> - Located a missing removal of .enable_gpio in the Palm TC
>   board file, pointed out by Daniel.
> - Grepped to ascertain there is not a single instance of
>   the string "enable_gpio" in the affected board files.
> ---
>  arch/arm/mach-pxa/cm-x300.c   |  1 -
>  arch/arm/mach-pxa/colibri-pxa270-income.c |  1 -
>  arch/arm/mach-pxa/ezx.c   |  1 -
>  arch/arm/mach-pxa/hx4700.c|  1 -
>  arch/arm/mach-pxa/lpd270.c|  1 -
>  arch/arm/mach-pxa/magician.c  |  1 -
>  arch/arm/mach-pxa/mainstone.c |  1 -
>  arch/arm/mach-pxa/mioa701.c   |  1 -
>  arch/arm/mach-pxa/palm27x.c   |  1 -
>  arch/arm/mach-pxa/palmtc.c| 11 ++-
>  arch/arm/mach-pxa/palmte2.c   |  1 -
>  arch/arm/mach-pxa/pcm990-baseboard.c  |  1 -
>  arch/arm/mach-pxa/tavorevb.c  |  2 --
>  arch/arm/mach-pxa/viper.c |  1 -
>  arch/arm/mach-pxa/z2.c|  2 --
>  arch/arm/mach-pxa/zylonite.c  |  1 -
>  arch/arm/mach-s3c24xx/mach-h1940.c|  1 -
>  arch/arm/mach-s3c24xx/mach-rx1950.c   |  1 -
>  arch/arm/mach-s3c64xx/dev-backlight.c |  3 ---
>  arch/arm/mach-s3c64xx/mach-crag6410.c |  1 -
>  arch/arm/mach-s3c64xx/mach-hmt.c  |  1 -
>  arch/arm/mach-s3c64xx/mach-smartq.c   |  1 -
>  arch/arm/mach-s3c64xx/mach-smdk6410.c |  2 +-

For s3c:
Acked-by: Krzysztof Kozlowski 

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel


[PATCH] dt-bindings: display: st,stm32-dsi: Fix white spaces

2019-10-21 Thread Krzysztof Kozlowski
Remove unneeded indentation in blank line and space at end of line.

Signed-off-by: Krzysztof Kozlowski 
---
 Documentation/devicetree/bindings/display/st,stm32-dsi.yaml  | 2 +-
 Documentation/devicetree/bindings/display/st,stm32-ltdc.yaml | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/display/st,stm32-dsi.yaml 
b/Documentation/devicetree/bindings/display/st,stm32-dsi.yaml
index de6c99198cbe..3be76d15bf6c 100644
--- a/Documentation/devicetree/bindings/display/st,stm32-dsi.yaml
+++ b/Documentation/devicetree/bindings/display/st,stm32-dsi.yaml
@@ -108,7 +108,7 @@ examples:
 resets = < DSI_R>;
 reset-names = "apb";
 phy-dsi-supply = <>;
-
+
 #address-cells = <1>;
 #size-cells = <0>;
 
diff --git a/Documentation/devicetree/bindings/display/st,stm32-ltdc.yaml 
b/Documentation/devicetree/bindings/display/st,stm32-ltdc.yaml
index a40197ab281e..bf8ad916e9b0 100644
--- a/Documentation/devicetree/bindings/display/st,stm32-ltdc.yaml
+++ b/Documentation/devicetree/bindings/display/st,stm32-ltdc.yaml
@@ -37,7 +37,7 @@ properties:
   port:
 type: object
 description:
-  "Video port for DPI RGB output. 
+  "Video port for DPI RGB output.
   ltdc has one video port with up to 2 endpoints:
   - for external dpi rgb panel or bridge, using gpios.
   - for internal dpi input of the MIPI DSI host controller.
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH v4 2/2] dt-bindings: pwm: Convert Samsung PWM bindings to json-schema

2019-10-21 Thread Krzysztof Kozlowski
Convert Samsung PWM (S3C, S5P and Exynos SoCs) bindings to DT schema
format using json-schema.

Signed-off-by: Krzysztof Kozlowski 
Reviewed-by: Rob Herring 

---

Changes since v3:
1. Add reviewed-by.

Changes since v2:
1. Add additionalProperties: false.

Changes since v1:
1. Indent example with four spaces (more readable),
2. Fix samsung,pwm-outputs after review,
3. Remove double-quotes from clock names.
---
 .../devicetree/bindings/pwm/pwm-samsung.txt   |  51 
 .../devicetree/bindings/pwm/pwm-samsung.yaml  | 109 ++
 2 files changed, 109 insertions(+), 51 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/pwm/pwm-samsung.txt
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm-samsung.yaml

diff --git a/Documentation/devicetree/bindings/pwm/pwm-samsung.txt 
b/Documentation/devicetree/bindings/pwm/pwm-samsung.txt
deleted file mode 100644
index 5538de9c2007..
--- a/Documentation/devicetree/bindings/pwm/pwm-samsung.txt
+++ /dev/null
@@ -1,51 +0,0 @@
-* Samsung PWM timers
-
-Samsung SoCs contain PWM timer blocks which can be used for system clock source
-and clock event timers, as well as to drive SoC outputs with PWM signal. Each
-PWM timer block provides 5 PWM channels (not all of them can drive physical
-outputs - see SoC and board manual).
-
-Be aware that the clocksource driver supports only uniprocessor systems.
-
-Required properties:
-- compatible : should be one of following:
-samsung,s3c2410-pwm - for 16-bit timers present on S3C24xx SoCs
-samsung,s3c6400-pwm - for 32-bit timers present on S3C64xx SoCs
-samsung,s5p6440-pwm - for 32-bit timers present on S5P64x0 SoCs
-samsung,s5pc100-pwm - for 32-bit timers present on S5PC100, S5PV210,
- Exynos4210 rev0 SoCs
-samsung,exynos4210-pwm - for 32-bit timers present on Exynos4210,
-  Exynos4x12, Exynos5250 and Exynos5420 SoCs
-- reg: base address and size of register area
-- interrupts: list of timer interrupts (one interrupt per timer, starting at
-  timer 0)
-- clock-names: should contain all following required clock names:
-- "timers" - PWM base clock used to generate PWM signals,
-  and any subset of following optional clock names:
-- "pwm-tclk0" - first external PWM clock source,
-- "pwm-tclk1" - second external PWM clock source.
-  Note that not all IP variants allow using all external clock sources.
-  Refer to SoC documentation to learn which clock source configurations
-  are available.
-- clocks: should contain clock specifiers of all clocks, which input names
-  have been specified in clock-names property, in same order.
-- #pwm-cells: should be 3. See pwm.txt in this directory for a description of
-  the cells format. The only third cell flag supported by this binding is
-  PWM_POLARITY_INVERTED.
-
-Optional properties:
-- samsung,pwm-outputs: list of PWM channels used as PWM outputs on particular
-platform - an array of up to 5 elements being indices of PWM channels
-(from 0 to 4), the order does not matter.
-
-Example:
-   pwm@7f006000 {
-   compatible = "samsung,s3c6400-pwm";
-   reg = <0x7f006000 0x1000>;
-   interrupt-parent = <>;
-   interrupts = <23>, <24>, <25>, <27>, <28>;
-   clocks = < 67>;
-   clock-names = "timers";
-   samsung,pwm-outputs = <0>, <1>;
-   #pwm-cells = <3>;
-   }
diff --git a/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml 
b/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml
new file mode 100644
index ..ea7f32905172
--- /dev/null
+++ b/Documentation/devicetree/bindings/pwm/pwm-samsung.yaml
@@ -0,0 +1,109 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/pwm/pwm-samsung.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung SoC PWM timers
+
+maintainers:
+  - Thierry Reding 
+  - Krzysztof Kozlowski 
+
+description: |+
+  Samsung SoCs contain PWM timer blocks which can be used for system clock 
source
+  and clock event timers, as well as to drive SoC outputs with PWM signal. Each
+  PWM timer block provides 5 PWM channels (not all of them can drive physical
+  outputs - see SoC and board manual).
+
+  Be aware that the clocksource driver supports only uniprocessor systems.
+
+allOf:
+  - $ref: pwm.yaml#
+
+properties:
+  compatible:
+enum:
+  - samsung,s3c2410-pwm # 16-bit, S3C24xx
+  - samsung,s3c6400-pwm # 32-bit, S3C64xx
+  - samsung,s5p6440-pwm # 32-bit, S5P64x0
+  - samsung,s5pc100-pwm # 32-bit, S5PC100, S5PV210, Exynos4210 
rev0 SoCs
+  - samsung,exynos4210-pwm  # 32-bit, Exynos
+
+  reg:
+maxItems: 1
+
+  clocks:
+minItems: 1
+maxItems: 3
+
+  clock-names:
+

[PATCH v4 1/2] dt-bindings: pwm: Convert PWM bindings to json-schema

2019-10-21 Thread Krzysztof Kozlowski
Convert generic PWM controller bindings to DT schema format using
json-schema.  The consumer bindings are provided by dt-schema.

Signed-off-by: Krzysztof Kozlowski 
Acked-by: Stephen Boyd 
Acked-by: Paul Walmsley 

---

Changes since v3:
1. Remove pwm-consumers.yaml as they do not give anything new except
   description.
2. Leave pwm.txt with consumers description.
3. Add acks.

Changes since v2:
1. Change also pwm-sprd.txt

Changes since v1:
1. Indent example with four spaces (more readable),
2. Change pattern for pwm nodes,
3. Remove $ref from #cells.
---
 .../bindings/display/bridge/ti,sn65dsi86.txt  |  2 +-
 .../bindings/pwm/atmel-hlcdc-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/atmel-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/atmel-tcb-pwm.txt |  2 +-
 .../bindings/pwm/brcm,bcm7038-pwm.txt |  2 +-
 .../bindings/pwm/brcm,iproc-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/brcm,kona-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/img-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/imx-pwm.txt   |  2 +-
 .../devicetree/bindings/pwm/imx-tpm-pwm.txt   |  2 +-
 .../bindings/pwm/lpc1850-sct-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/mxs-pwm.txt   |  2 +-
 .../bindings/pwm/nvidia,tegra20-pwm.txt   |  2 +-
 .../bindings/pwm/nxp,pca9685-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-bcm2835.txt   |  2 +-
 .../devicetree/bindings/pwm/pwm-berlin.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-fsl-ftm.txt   |  2 +-
 .../devicetree/bindings/pwm/pwm-hibvt.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-lp3943.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-mediatek.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-meson.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-mtk-disp.txt  |  2 +-
 .../bindings/pwm/pwm-omap-dmtimer.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-rockchip.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-sifive.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-stm32-lp.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-stm32.txt |  2 +-
 .../devicetree/bindings/pwm/pwm-tiecap.txt|  2 +-
 .../devicetree/bindings/pwm/pwm-tiehrpwm.txt  |  2 +-
 .../devicetree/bindings/pwm/pwm-zx.txt|  2 +-
 Documentation/devicetree/bindings/pwm/pwm.txt | 11 +--
 .../devicetree/bindings/pwm/pwm.yaml  | 29 +++
 .../bindings/pwm/renesas,pwm-rcar.yaml|  2 +-
 .../bindings/pwm/renesas,tpu-pwm.yaml |  2 +-
 .../devicetree/bindings/pwm/spear-pwm.txt |  2 +-
 .../devicetree/bindings/pwm/st,stmpe-pwm.txt  |  2 +-
 .../devicetree/bindings/pwm/ti,twl-pwm.txt|  2 +-
 .../devicetree/bindings/pwm/ti,twl-pwmled.txt |  2 +-
 .../devicetree/bindings/pwm/vt8500-pwm.txt|  2 +-
 .../devicetree/bindings/timer/ingenic,tcu.txt |  2 +-
 40 files changed, 68 insertions(+), 48 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm.yaml

diff --git a/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt 
b/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
index 0a3fbb53a16e..8ec4a7f2623a 100644
--- a/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
+++ b/Documentation/devicetree/bindings/display/bridge/ti,sn65dsi86.txt
@@ -21,7 +21,7 @@ Optional properties:
 - #gpio-cells: Should be two. The first cell is the pin number and
the second cell is used to specify flags.
See ../../gpio/gpio.txt for more information.
-- #pwm-cells : Should be one. See ../../pwm/pwm.txt for description of
+- #pwm-cells : Should be one. See ../../pwm/pwm.yaml for description of
the cell formats.
 
 - clock-names: should be "refclk"
diff --git a/Documentation/devicetree/bindings/pwm/atmel-hlcdc-pwm.txt 
b/Documentation/devicetree/bindings/pwm/atmel-hlcdc-pwm.txt
index cfda0d57d302..afa501bf7f94 100644
--- a/Documentation/devicetree/bindings/pwm/atmel-hlcdc-pwm.txt
+++ b/Documentation/devicetree/bindings/pwm/atmel-hlcdc-pwm.txt
@@ -10,7 +10,7 @@ Required properties:
  - pinctrl-0: should contain the pinctrl states described by pinctrl
default.
  - #pwm-cells: should be set to 3. This PWM chip use the default 3 cells
-   bindings defined in pwm.txt in this directory.
+   bindings defined in pwm.yaml in this directory.
 
 Example:
 
diff --git a/Documentation/devicetree/bindings/pwm/atmel-pwm.txt 
b/Documentation/devicetree/bindings/pwm/atmel-pwm.txt
index 591ecdd39c7b..fbb5325be1f0 100644
--- a/Documentation/devicetree/bindings/pwm/atmel-pwm.txt
+++ b/Documentation/devicetree/bindings/pwm/atmel-pwm.txt
@@ -7,7 +7,7 @@ Required properties:
 - "atmel,sama5d2-pwm"
 - "microchip,sam9x60-pwm"
   - reg: physical base address and length of the controller's registers
-  - #pwm-cells: Should be 3. See pwm.txt in this directory for a
+  - #pwm-cells: Should be 3. See pwm.yaml in this directory for a
 description of the cells format.
 
 Example:
diff --git a/Documentation/dev

Re: [PATCH 00/36] ARM: samsung platform cleanup

2019-10-23 Thread Krzysztof Kozlowski
On Thu, Oct 10, 2019 at 10:28:02PM +0200, Arnd Bergmann wrote:
> I've spent some time looking at the remaining ARMv4/ARMv5 platforms
> that are not part of ARCH_MULTIPLATFORM, and tried to get them closer
> to that. Here is what came out of that for the samsung platforms:
> 
> * Exynos and s5pv210 are made independent of plat-samsung
> * device drivers stop using mach/*.h headers for s3c24xx
>   (and other platforms not in this series)
> * s3c24xx and s3c64xx get merged into mach-s3c, removing
>   the need for plat-samsung (I have other patches for the
>   remaining plat-* directories)
> * mach/io.h gets cleaned up to only be needed for BAST
>   PC104 mode (looking for ideas to proceed)
> * mach/irqs.h remains for now, this still needs to be converted
>   to sparse IRQs.
> 
> Some bits are a little ugly, but overall I think this a big
> improvement.
> 
> The contents are available for testing in
> 
> git://kernel.org:/pub/scm/linux/kernel/git/arnd/playground.git 
> s3c-multiplatform

When sending v2, can you Cc:

Paweł Chmiel 
Lihua Yao 
(or Lihua Yao  if outlook.com bounces)
Sergio Prado 
Sylwester Nawrocki 

These are folks which to my knowledge had working S3C and S5P boards
so maybe they could provide testing.

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH 28/36] fbdev: s3c2410fb: remove mach header dependency

2019-10-23 Thread Krzysztof Kozlowski
On Thu, Oct 10, 2019 at 10:30:12PM +0200, Arnd Bergmann wrote:
> The s3c2410fb driver is too deeply intertwined with the s3c24xx
> platform code. Change it in a way that avoids the use of platform
> header files but having all interface data in a platform_data
> header, and the private register definitions next to the driver
> itself.
> 
> One ugly bit here is that the driver pokes directly into gpio
> registers, which are owned by another driver. Passing the
> mapped addresses in platform_data is somewhat suboptimal, but
> it is a small improvement over the previous version.
> 
> Signed-off-by: Arnd Bergmann 
> ---
>  arch/arm/mach-s3c24xx/include/mach/fb.h   |  2 --
>  arch/arm/mach-s3c24xx/mach-amlm5900.c |  7 ++--
>  arch/arm/mach-s3c24xx/mach-anubis.c   |  1 -
>  arch/arm/mach-s3c24xx/mach-at2440evb.c|  3 +-
>  arch/arm/mach-s3c24xx/mach-bast.c |  3 +-
>  arch/arm/mach-s3c24xx/mach-gta02.c|  2 +-
>  arch/arm/mach-s3c24xx/mach-h1940.c|  7 ++--
>  arch/arm/mach-s3c24xx/mach-jive.c | 10 --
>  arch/arm/mach-s3c24xx/mach-mini2440.c |  9 +++--
>  arch/arm/mach-s3c24xx/mach-n30.c  |  3 +-
>  arch/arm/mach-s3c24xx/mach-osiris.c   |  1 -
>  arch/arm/mach-s3c24xx/mach-qt2410.c   |  3 +-
>  arch/arm/mach-s3c24xx/mach-rx1950.c   |  8 +++--
>  arch/arm/mach-s3c24xx/mach-rx3715.c   |  7 ++--
>  arch/arm/mach-s3c24xx/mach-smdk2413.c |  3 +-
>  arch/arm/mach-s3c24xx/mach-smdk2416.c |  1 -
>  arch/arm/mach-s3c24xx/mach-smdk2440.c |  8 +++--
>  arch/arm/mach-s3c24xx/mach-smdk2443.c |  3 +-
>  arch/arm/mach-s3c24xx/mach-vstms.c|  3 +-
>  arch/arm/plat-samsung/devs.c  |  2 +-
>  .../video/fbdev/s3c2410fb-regs-lcd.h  | 28 
>  drivers/video/fbdev/s3c2410fb.c   | 16 +
>  .../linux/platform_data}/fb-s3c2410.h | 33 ++-
>  23 files changed, 98 insertions(+), 65 deletions(-)
>  delete mode 100644 arch/arm/mach-s3c24xx/include/mach/fb.h
>  rename arch/arm/mach-s3c24xx/include/mach/regs-lcd.h => 
> drivers/video/fbdev/s3c2410fb-regs-lcd.h (84%)
>  rename {arch/arm/plat-samsung/include/plat => 
> include/linux/platform_data}/fb-s3c2410.h (57%)
> 
> diff --git a/arch/arm/mach-s3c24xx/include/mach/fb.h 
> b/arch/arm/mach-s3c24xx/include/mach/fb.h
> deleted file mode 100644
> index 4e539cb8b884..
> --- a/arch/arm/mach-s3c24xx/include/mach/fb.h
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -/* SPDX-License-Identifier: GPL-2.0 */
> -#include 
> diff --git a/arch/arm/mach-s3c24xx/mach-amlm5900.c 
> b/arch/arm/mach-s3c24xx/mach-amlm5900.c
> index 40ad23b52bc0..ef6de1b1d0c6 100644
> --- a/arch/arm/mach-s3c24xx/mach-amlm5900.c
> +++ b/arch/arm/mach-s3c24xx/mach-amlm5900.c
> @@ -30,9 +30,8 @@
>  #include 
>  #include 
>  #include 
> -#include 
> +#include 
>  
> -#include 
>  #include 
>  #include 
>  
> @@ -194,13 +193,17 @@ static struct s3c2410fb_mach_info __initdata 
> amlm5900_fb_info = {
>  
>   .gpccon =   0x,
>   .gpccon_mask =  0x,
> + .gpccon_reg =   S3C2410_GPCCON,
>   .gpcup =0x,
>   .gpcup_mask =   0x,
> + .gpcup_reg =S3C2410_GPCUP,
>  
>   .gpdcon =   0x,
>   .gpdcon_mask =  0x,
> + .gpdcon_reg =   S3C2410_GPDCON,
>   .gpdup =0x,
>   .gpdup_mask =   0x,
> + .gpdup_reg =S3C2410_GPDUP,
>  };
>  #endif
>  
> diff --git a/arch/arm/mach-s3c24xx/mach-anubis.c 
> b/arch/arm/mach-s3c24xx/mach-anubis.c
> index 072966dcad78..e1a73274e90b 100644
> --- a/arch/arm/mach-s3c24xx/mach-anubis.c
> +++ b/arch/arm/mach-s3c24xx/mach-anubis.c
> @@ -29,7 +29,6 @@
>  #include 
>  
>  #include 
> -#include 
>  #include 
>  #include 
>  #include 
> diff --git a/arch/arm/mach-s3c24xx/mach-at2440evb.c 
> b/arch/arm/mach-s3c24xx/mach-at2440evb.c
> index b2199906e678..bfda6dd2a9d5 100644
> --- a/arch/arm/mach-s3c24xx/mach-at2440evb.c
> +++ b/arch/arm/mach-s3c24xx/mach-at2440evb.c
> @@ -25,12 +25,11 @@
>  #include 
>  
>  #include 
> -#include 
> +#include 
>  #include 
>  #include 
>  
>  #include 
> -#include 
>  #include 
>  #include 
>  #include 
> diff --git a/arch/arm/mach-s3c24xx/mach-bast.c 
> b/arch/arm/mach-s3c24xx/mach-bast.c
> index a7c3955ae8f6..cc941b5030ea 100644
> --- a/arch/arm/mach-s3c24xx/mach-bast.c
> +++ b/arch/arm/mach-s3c24xx/mach-bast.c
> @@ -40,10 +40,9 @@
>  #include 
>  #include 
>  
> -#include 
>  #include 
> +#include 
>  #include 
> -#include 
>  #include 
>  
>  #include 
> diff --git a/arch/arm/mach-s3c24xx/mach-gta02.c 
> b/arch/arm/mach-s3c24xx/mach-gta02.c
> index 61b8c6badeb8..1e42782dbd30 100644
> --- a/arch/arm/mach-s3c24xx/mach-gta02.c
> +++ b/arch/arm/mach-s3c24xx/mach-gta02.c
> @@ -57,8 +57,8 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  
> -#include 
>  #include 
>  #include 
>  #include 
> diff --git 

Re: [PATCH v2 1/3] dt-bindings: power: Convert Generic Power Domain bindings to json-schema

2019-10-23 Thread Krzysztof Kozlowski
On Fri, Oct 11, 2019 at 10:03:39AM -0500, Rob Herring wrote:
> On Wed, Oct 02, 2019 at 06:06:30PM +0200, Krzysztof Kozlowski wrote:
> > Convert Generic Power Domain bindings to DT schema format using
> > json-schema.  The consumer bindings are split to separate file.
> > 
> > Signed-off-by: Krzysztof Kozlowski 
> > 
> > ---
> > 
> > Changes since v1:
> > 1. Select all nodes for consumers,
> > 2. Remove from consumers duplicated properties with dt-schema,
> > 3. Fix power domain pattern,
> > 4. Remove unneeded types.
> > ---
> >  .../devicetree/bindings/arm/arm,scmi.txt  |   2 +-
> >  .../devicetree/bindings/arm/arm,scpi.txt  |   2 +-
> >  .../bindings/arm/freescale/fsl,scu.txt|   2 +-
> >  .../bindings/clock/clk-exynos-audss.txt   |   2 +-
> >  .../bindings/clock/exynos5433-clock.txt   |   4 +-
> >  .../bindings/clock/renesas,cpg-mssr.txt   |   2 +-
> >  .../clock/renesas,r8a7778-cpg-clocks.txt  |   2 +-
> >  .../clock/renesas,r8a7779-cpg-clocks.txt  |   2 +-
> >  .../clock/renesas,rcar-gen2-cpg-clocks.txt|   2 +-
> >  .../bindings/clock/renesas,rz-cpg-clocks.txt  |   2 +-
> >  .../bindings/clock/ti/davinci/psc.txt |   2 +-
> >  .../bindings/display/etnaviv/etnaviv-drm.txt  |   2 +-
> >  .../devicetree/bindings/display/msm/dpu.txt   |   2 +-
> >  .../devicetree/bindings/display/msm/mdp5.txt  |   2 +-
> >  .../devicetree/bindings/dsp/fsl,dsp.yaml  |   2 +-
> >  .../firmware/nvidia,tegra186-bpmp.txt |   2 +-
> >  .../bindings/media/imx7-mipi-csi2.txt |   3 +-
> >  .../bindings/media/mediatek-jpeg-decoder.txt  |   3 +-
> >  .../bindings/media/mediatek-mdp.txt   |   3 +-
> >  .../bindings/opp/qcom-nvmem-cpufreq.txt   |   2 +-
> >  .../devicetree/bindings/pci/pci-keystone.txt  |   2 +-
> >  .../bindings/phy/ti,phy-am654-serdes.txt  |   2 +-
> >  .../bindings/power/amlogic,meson-gx-pwrc.txt  |   2 +-
> >  .../devicetree/bindings/power/fsl,imx-gpc.txt |   2 +-
> >  .../bindings/power/fsl,imx-gpcv2.txt  |   2 +-
> >  .../power/power-domain-consumers.yaml | 105 +
> >  .../bindings/power/power-domain.yaml  | 134 
> >  .../bindings/power/power_domain.txt   | 205 --
> >  .../devicetree/bindings/power/qcom,rpmpd.txt  |   2 +-
> >  .../bindings/power/renesas,rcar-sysc.txt  |   2 +-
> >  .../bindings/power/renesas,sysc-rmobile.txt   |   2 +-
> >  .../bindings/power/xlnx,zynqmp-genpd.txt  |   2 +-
> >  .../bindings/soc/bcm/brcm,bcm2835-pm.txt  |   2 +-
> >  .../bindings/soc/mediatek/scpsys.txt  |   2 +-
> >  .../bindings/soc/ti/sci-pm-domain.txt |   2 +-
> >  .../bindings/usb/nvidia,tegra124-xusb.txt |   4 +-
> >  MAINTAINERS   |   2 +-
> >  37 files changed, 278 insertions(+), 241 deletions(-)
> >  create mode 100644 
> > Documentation/devicetree/bindings/power/power-domain-consumers.yaml
> >  create mode 100644 
> > Documentation/devicetree/bindings/power/power-domain.yaml
> >  delete mode 100644 Documentation/devicetree/bindings/power/power_domain.txt
> 
> 
> > diff --git 
> > a/Documentation/devicetree/bindings/power/power-domain-consumers.yaml 
> > b/Documentation/devicetree/bindings/power/power-domain-consumers.yaml
> > new file mode 100644
> > index ..f65078e1260e
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/power/power-domain-consumers.yaml
> > @@ -0,0 +1,105 @@
> > +# SPDX-License-Identifier: GPL-2.0
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/power/power-domain-consumers.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: PM domain consumers
> > +
> > +maintainers:
> > +  - Rafael J. Wysocki 
> > +  - Kevin Hilman 
> > +  - Ulf Hansson 
> > +
> > +description: |+
> > +  See power-domain.yaml
> > +
> > +select: true
> > +
> > +allOf:
> > +  - $ref: /schemas/power-domain/power-domain-consumer.yaml
> 
> I don't like this split. We should move the contents of this file to the 
> above file.
> 
> I checked the authorship of the relevant lines and they are all except 
> for a small number of lines from Linaro authors (Viresh and Ulf). I have 
> permission from Linaro to dual license Linaro authored bindings, so it's 
> not a problem to move this. I can do that and you can just drop this file.

Sure, what to do with the references to power-domain consumers part? I
could leave the text file and 

Re: [PATCH] dt-bindings: power: Fix path to power-domain.txt bindings

2019-11-19 Thread Krzysztof Kozlowski
On Wed, 20 Nov 2019 at 01:02, Rob Herring  wrote:
>
> On Tue, Nov 19, 2019 at 8:43 AM Krzysztof Kozlowski  wrote:
> >
> > With split of power domain controller bindings to power-domain.yaml, the
> > consumer part was renamed to power-domain.txt.  Update the references in
> > other bindings.
> >
> > Reported-by: Geert Uytterhoeven 
> > Fixes: abb4805e343a ("dt-bindings: power: Convert Samsung Exynos Power 
> > Domain bindings to json-schema")
> > Signed-off-by: Krzysztof Kozlowski 
> > ---
> >  Documentation/devicetree/bindings/clock/clk-exynos-audss.txt  | 2 +-
> >  Documentation/devicetree/bindings/clock/exynos5433-clock.txt  | 2 +-
> >  .../devicetree/bindings/clock/renesas,r8a7778-cpg-clocks.txt  | 2 +-
> >  .../devicetree/bindings/clock/renesas,r8a7779-cpg-clocks.txt  | 2 +-
> >  .../bindings/clock/renesas,rcar-gen2-cpg-clocks.txt   | 2 +-
> >  .../devicetree/bindings/clock/renesas,rz-cpg-clocks.txt   | 2 +-
> >  .../devicetree/bindings/display/etnaviv/etnaviv-drm.txt   | 2 +-
> >  Documentation/devicetree/bindings/display/msm/dpu.txt | 2 +-
> >  Documentation/devicetree/bindings/display/msm/mdp5.txt| 2 +-
> >  Documentation/devicetree/bindings/dsp/fsl,dsp.yaml| 2 +-
> >  Documentation/devicetree/bindings/media/imx7-mipi-csi2.txt| 2 +-
> >  .../devicetree/bindings/media/mediatek-jpeg-decoder.txt   | 2 +-
> >  Documentation/devicetree/bindings/media/mediatek-mdp.txt  | 2 +-
> >  Documentation/devicetree/bindings/opp/qcom-nvmem-cpufreq.txt  | 2 +-
> >  Documentation/devicetree/bindings/pci/pci-keystone.txt| 2 +-
> >  Documentation/devicetree/bindings/phy/ti,phy-am654-serdes.txt | 2 +-
> >  Documentation/devicetree/bindings/power/qcom,rpmpd.txt| 2 +-
> >  Documentation/devicetree/bindings/power/renesas,rcar-sysc.txt | 2 +-
> >  .../devicetree/bindings/usb/nvidia,tegra124-xusb.txt  | 4 ++--
> >  19 files changed, 20 insertions(+), 20 deletions(-)
>
> Please no. Can you just undo the renaming back to power_domain.txt

The renaming was done to make it consistent with yaml and other
bindings but indeed it creates some churn... I'll send rename-undo
then.

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] video: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/video/backlight/Kconfig |  8 ++--
 drivers/video/console/Kconfig   | 76 -
 2 files changed, 42 insertions(+), 42 deletions(-)

diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig
index 403707a3e503..95e2000c1491 100644
--- a/drivers/video/backlight/Kconfig
+++ b/drivers/video/backlight/Kconfig
@@ -9,7 +9,7 @@ menu "Backlight & LCD device support"
 # LCD
 #
 config LCD_CLASS_DEVICE
-tristate "Lowlevel LCD controls"
+   tristate "Lowlevel LCD controls"
help
  This framework adds support for low-level control of LCD.
  Some framebuffer devices connect to platform-specific LCD modules
@@ -141,10 +141,10 @@ endif # LCD_CLASS_DEVICE
 # Backlight
 #
 config BACKLIGHT_CLASS_DEVICE
-tristate "Lowlevel Backlight controls"
+   tristate "Lowlevel Backlight controls"
help
  This framework adds support for low-level control of the LCD
-  backlight. This includes support for brightness and power.
+ backlight. This includes support for brightness and power.
 
  To have support for your specific LCD panel you will have to
  select the proper drivers which depend on this option.
@@ -272,7 +272,7 @@ config BACKLIGHT_APPLE
tristate "Apple Backlight Driver"
depends on X86 && ACPI
help
- If you have an Intel-based Apple say Y to enable a driver for its
+If you have an Intel-based Apple say Y to enable a driver for its
 backlight.
 
 config BACKLIGHT_TOSA
diff --git a/drivers/video/console/Kconfig b/drivers/video/console/Kconfig
index c10e17fb9a9a..ac3a28c08f78 100644
--- a/drivers/video/console/Kconfig
+++ b/drivers/video/console/Kconfig
@@ -27,7 +27,7 @@ config VGACON_SOFT_SCROLLBACK
depends on VGA_CONSOLE
default n
help
- The scrollback buffer of the standard VGA console is located in
+The scrollback buffer of the standard VGA console is located in
 the VGA RAM.  The size of this RAM is fixed and is quite small.
 If you require a larger scrollback buffer, this can be placed in
 System RAM which is dynamically allocated during initialization.
@@ -84,12 +84,12 @@ config MDA_CONSOLE
  If unsure, say N.
 
 config SGI_NEWPORT_CONSOLE
-tristate "SGI Newport Console support"
+   tristate "SGI Newport Console support"
depends on SGI_IP22 && HAS_IOMEM
-select FONT_SUPPORT
-help
-  Say Y here if you want the console on the Newport aka XL graphics
-  card of your Indy.  Most people say Y here.
+   select FONT_SUPPORT
+   help
+ Say Y here if you want the console on the Newport aka XL graphics
+ card of your Indy.  Most people say Y here.
 
 config DUMMY_CONSOLE
bool
@@ -97,24 +97,24 @@ config DUMMY_CONSOLE
default y
 
 config DUMMY_CONSOLE_COLUMNS
-int "Initial number of console screen columns"
-depends on DUMMY_CONSOLE && !ARM
-default 160 if PARISC
-default 80
-help
-  On PA-RISC, the default value is 160, which should fit a 1280x1024
-  monitor.
-  Select 80 if you use a 640x480 resolution by default.
+   int "Initial number of console screen columns"
+   depends on DUMMY_CONSOLE && !ARM
+   default 160 if PARISC
+   default 80
+   help
+ On PA-RISC, the default value is 160, which should fit a 1280x1024
+ monitor.
+ Select 80 if you use a 640x480 resolution by default.
 
 config DUMMY_CONSOLE_ROWS
-int "Initial number of console screen rows"
-depends on DUMMY_CONSOLE && !ARM
-default 64 if PARISC
-default 25
-help
-  On PA-RISC, the default value is 64, which should fit a 1280x1024
-  monitor.
-  Select 25 if you use a 640x480 resolution by default.
+   int "Initial number of console screen rows"
+   depends on DUMMY_CONSOLE && !ARM
+   default 64 if PARISC
+   default 25
+   help
+ On PA-RISC, the default value is 64, which should fit a 1280x1024
+ monitor.
+ Select 25 if you use a 640x480 resolution by default.
 
 config FRAMEBUFFER_CONSOLE
bool "Framebuffer Console support"
@@ -130,11 +130,11 @@ config FRAMEBUFFER_CONSOLE_DETECT_PRIMARY
depends on FRAMEBUFFER_CONSOLE
default n
---help---
- If this option is selected, the framebuffer console will
- automatically select the primary display device (if the architecture
+If this optio

Re: [PATCH] video: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
On Wed, Nov 20, 2019 at 08:45:46AM -0500, Daniel Thompson wrote:
> On Wed, Nov 20, 2019 at 09:38:38PM +0800, Krzysztof Kozlowski wrote:
> > Adjust indentation from spaces to tab (+optional two spaces) as in
> > coding style with command like:
> > $ sed -e 's/^/\t/' -i */Kconfig
> > 
> > Signed-off-by: Krzysztof Kozlowski 
> 
> No particular objections but I wonder if this would be better sent to
> triv...@kernel.org .

Thanks for feedback.

I sent to trivial and kernel-janitors my previous version of this
patchset which was not split per-subsystem and there was no feedback.
Few other patches already came through maintainers. If there will be no
reply, I'll send next version through trivial.

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] vga: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/vga/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/vga/Kconfig b/drivers/gpu/vga/Kconfig
index c8c770b05ed9..1ad4c4ef0b5e 100644
--- a/drivers/gpu/vga/Kconfig
+++ b/drivers/gpu/vga/Kconfig
@@ -28,6 +28,6 @@ config VGA_SWITCHEROO
help
  Many laptops released in 2008/9/10 have two GPUs with a multiplexer
  to switch between them. This adds support for dynamic switching when
-  X isn't running and delayed switching until the next logoff. This
+ X isn't running and delayed switching until the next logoff. This
  feature is called hybrid graphics, ATI PowerXpress, and Nvidia
  HybridPower.
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/udl: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/udl/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/udl/Kconfig b/drivers/gpu/drm/udl/Kconfig
index b4d179b87f01..b13aa33990f3 100644
--- a/drivers/gpu/drm/udl/Kconfig
+++ b/drivers/gpu/drm/udl/Kconfig
@@ -8,4 +8,4 @@ config DRM_UDL
select DRM_KMS_HELPER
help
  This is a KMS driver for the USB displaylink video adapters.
-  Say M/Y to add support for these devices via drm/kms interfaces.
+ Say M/Y to add support for these devices via drm/kms interfaces.
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/rockchip: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/rockchip/Kconfig | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/rockchip/Kconfig b/drivers/gpu/drm/rockchip/Kconfig
index 6f4222f8beeb..1670a5cae3c7 100644
--- a/drivers/gpu/drm/rockchip/Kconfig
+++ b/drivers/gpu/drm/rockchip/Kconfig
@@ -28,17 +28,17 @@ config ROCKCHIP_ANALOGIX_DP
  on RK3288 or RK3399 based SoC, you should select this option.
 
 config ROCKCHIP_CDN_DP
-bool "Rockchip cdn DP"
+   bool "Rockchip cdn DP"
depends on EXTCON=y || (EXTCON=m && DRM_ROCKCHIP=m)
-help
+   help
  This selects support for Rockchip SoC specific extensions
  for the cdn DP driver. If you want to enable Dp on
  RK3399 based SoC, you should select this
  option.
 
 config ROCKCHIP_DW_HDMI
-bool "Rockchip specific extensions for Synopsys DW HDMI"
-help
+   bool "Rockchip specific extensions for Synopsys DW HDMI"
+   help
  This selects support for Rockchip SoC specific extensions
  for the Synopsys DesignWare HDMI driver. If you want to
  enable HDMI on RK3288 or RK3399 based SoC, you should select
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/Kconfig | 30 +++---
 1 file changed, 15 insertions(+), 15 deletions(-)

diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
index 1168351267fd..ad1b6ecd2e08 100644
--- a/drivers/gpu/drm/Kconfig
+++ b/drivers/gpu/drm/Kconfig
@@ -94,18 +94,18 @@ config DRM_KMS_FB_HELPER
  FBDEV helpers for KMS drivers.
 
 config DRM_DEBUG_DP_MST_TOPOLOGY_REFS
-bool "Enable refcount backtrace history in the DP MST helpers"
-select STACKDEPOT
-depends on DRM_KMS_HELPER
-depends on DEBUG_KERNEL
-depends on EXPERT
-help
-  Enables debug tracing for topology refs in DRM's DP MST helpers. A
-  history of each topology reference/dereference will be printed to the
-  kernel log once a port or branch device's topology refcount reaches 
0.
-
-  This has the potential to use a lot of memory and print some very
-  large kernel messages. If in doubt, say "N".
+   bool "Enable refcount backtrace history in the DP MST helpers"
+   select STACKDEPOT
+   depends on DRM_KMS_HELPER
+   depends on DEBUG_KERNEL
+   depends on EXPERT
+   help
+ Enables debug tracing for topology refs in DRM's DP MST helpers. A
+ history of each topology reference/dereference will be printed to the
+ kernel log once a port or branch device's topology refcount reaches 0.
+
+ This has the potential to use a lot of memory and print some very
+ large kernel messages. If in doubt, say "N".
 
 config DRM_FBDEV_EMULATION
bool "Enable legacy fbdev support for your modesetting driver"
@@ -234,8 +234,8 @@ config DRM_RADEON
tristate "ATI Radeon"
depends on DRM && PCI && MMU
select FW_LOADER
-select DRM_KMS_HELPER
-select DRM_TTM
+   select DRM_KMS_HELPER
+   select DRM_TTM
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE
@@ -294,7 +294,7 @@ config DRM_VKMS
  If M is selected the module will be called vkms.
 
 config DRM_ATI_PCIGART
-bool
+   bool
 
 source "drivers/gpu/drm/exynos/Kconfig"
 
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/mgag200: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/mgag200/Kconfig | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/mgag200/Kconfig b/drivers/gpu/drm/mgag200/Kconfig
index aed11f4f4c55..d60aa4b9ccd4 100644
--- a/drivers/gpu/drm/mgag200/Kconfig
+++ b/drivers/gpu/drm/mgag200/Kconfig
@@ -8,8 +8,8 @@ config DRM_MGAG200
select DRM_TTM_HELPER
help
 This is a KMS driver for the MGA G200 server chips, it
- does not support the original MGA G200 or any of the desktop
- chips. It requires 0.3.0 of the modesetting userspace driver,
- and a version of mga driver that will fail on KMS enabled
- devices.
+does not support the original MGA G200 or any of the desktop
+chips. It requires 0.3.0 of the modesetting userspace driver,
+and a version of mga driver that will fail on KMS enabled
+devices.
 
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/bridge: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/bridge/Kconfig | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/bridge/Kconfig b/drivers/gpu/drm/bridge/Kconfig
index 34362976cd6f..176efa18e32c 100644
--- a/drivers/gpu/drm/bridge/Kconfig
+++ b/drivers/gpu/drm/bridge/Kconfig
@@ -60,10 +60,10 @@ config DRM_MEGACHIPS_STDP_GE_B850V3_FW
select DRM_KMS_HELPER
select DRM_PANEL
---help---
-  This is a driver for the display bridges of
-  GE B850v3 that convert dual channel LVDS
-  to DP++. This is used with the i.MX6 imx-ldb
-  driver. You are likely to say N here.
+ This is a driver for the display bridges of
+ GE B850v3 that convert dual channel LVDS
+ to DP++. This is used with the i.MX6 imx-ldb
+ driver. You are likely to say N here.
 
 config DRM_NXP_PTN3460
tristate "NXP PTN3460 DP/LVDS bridge"
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/omap: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/omapdrm/displays/Kconfig |  6 +++---
 drivers/gpu/drm/omapdrm/dss/Kconfig  | 12 ++--
 2 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/drivers/gpu/drm/omapdrm/displays/Kconfig 
b/drivers/gpu/drm/omapdrm/displays/Kconfig
index 240dda102845..b562a8cd61bf 100644
--- a/drivers/gpu/drm/omapdrm/displays/Kconfig
+++ b/drivers/gpu/drm/omapdrm/displays/Kconfig
@@ -8,18 +8,18 @@ config DRM_OMAP_ENCODER_OPA362
  through a GPIO.
 
 config DRM_OMAP_ENCODER_TPD12S015
-tristate "TPD12S015 HDMI ESD protection and level shifter"
+   tristate "TPD12S015 HDMI ESD protection and level shifter"
help
  Driver for TPD12S015, which offers HDMI ESD protection and level
  shifting.
 
 config DRM_OMAP_CONNECTOR_HDMI
-tristate "HDMI Connector"
+   tristate "HDMI Connector"
help
  Driver for a generic HDMI connector.
 
 config DRM_OMAP_CONNECTOR_ANALOG_TV
-tristate "Analog TV Connector"
+   tristate "Analog TV Connector"
help
  Driver for a generic analog TV connector.
 
diff --git a/drivers/gpu/drm/omapdrm/dss/Kconfig 
b/drivers/gpu/drm/omapdrm/dss/Kconfig
index 956f23e1452d..72ae79c0c9b4 100644
--- a/drivers/gpu/drm/omapdrm/dss/Kconfig
+++ b/drivers/gpu/drm/omapdrm/dss/Kconfig
@@ -6,12 +6,12 @@ config OMAP_DSS_BASE
tristate
 
 menuconfig OMAP2_DSS
-tristate "OMAP2+ Display Subsystem support"
+   tristate "OMAP2+ Display Subsystem support"
select OMAP_DSS_BASE
select VIDEOMODE_HELPERS
select OMAP2_DSS_INIT
select HDMI
-help
+   help
  OMAP2+ Display Subsystem support.
 
 if OMAP2_DSS
@@ -52,7 +52,7 @@ config OMAP2_DSS_DPI
 
 config OMAP2_DSS_VENC
bool "VENC support"
-default y
+   default y
help
  OMAP Video Encoder support for S-Video and composite TV-out.
 
@@ -61,7 +61,7 @@ config OMAP2_DSS_HDMI_COMMON
 
 config OMAP4_DSS_HDMI
bool "HDMI support for OMAP4"
-default y
+   default y
select OMAP2_DSS_HDMI_COMMON
help
  HDMI support for OMAP4 based SoCs.
@@ -85,7 +85,7 @@ config OMAP5_DSS_HDMI
 
 config OMAP2_DSS_SDI
bool "SDI support"
-default n
+   default n
help
  SDI (Serial Display Interface) support.
 
@@ -94,7 +94,7 @@ config OMAP2_DSS_SDI
 
 config OMAP2_DSS_DSI
bool "DSI support"
-default n
+   default n
help
  MIPI DSI (Display Serial Interface) support.
 
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/nouveau: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/nouveau/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/nouveau/Kconfig b/drivers/gpu/drm/nouveau/Kconfig
index 3558df043592..9c990266e876 100644
--- a/drivers/gpu/drm/nouveau/Kconfig
+++ b/drivers/gpu/drm/nouveau/Kconfig
@@ -2,7 +2,7 @@
 config DRM_NOUVEAU
tristate "Nouveau (NVIDIA) cards"
depends on DRM && PCI && MMU
-select FW_LOADER
+   select FW_LOADER
select DRM_KMS_HELPER
select DRM_TTM
select BACKLIGHT_CLASS_DEVICE if DRM_NOUVEAU_BACKLIGHT
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] drm/lima: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/gpu/drm/lima/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/lima/Kconfig b/drivers/gpu/drm/lima/Kconfig
index 571dc369a7e9..d589f09d04d9 100644
--- a/drivers/gpu/drm/lima/Kconfig
+++ b/drivers/gpu/drm/lima/Kconfig
@@ -11,4 +11,4 @@ config DRM_LIMA
select DRM_SCHED
select DRM_GEM_SHMEM_HELPER
help
- DRM driver for ARM Mali 400/450 GPUs.
+DRM driver for ARM Mali 400/450 GPUs.
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] staging: fbtft: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 drivers/staging/fbtft/Kconfig | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/staging/fbtft/Kconfig b/drivers/staging/fbtft/Kconfig
index d994aea84b21..19d9d88e9150 100644
--- a/drivers/staging/fbtft/Kconfig
+++ b/drivers/staging/fbtft/Kconfig
@@ -95,8 +95,8 @@ config FB_TFT_PCD8544
  Generic Framebuffer support for PCD8544
 
 config FB_TFT_RA8875
-tristate "FB driver for the RA8875 LCD Controller"
-depends on FB_TFT
+   tristate "FB driver for the RA8875 LCD Controller"
+   depends on FB_TFT
help
  Generic Framebuffer support for RA8875
 
@@ -132,10 +132,10 @@ config FB_TFT_SSD1289
  Framebuffer support for SSD1289
 
 config FB_TFT_SSD1305
-tristate "FB driver for the SSD1305 OLED Controller"
-depends on FB_TFT
-help
-  Framebuffer support for SSD1305
+   tristate "FB driver for the SSD1305 OLED Controller"
+   depends on FB_TFT
+   help
+ Framebuffer support for SSD1305
 
 config FB_TFT_SSD1306
tristate "FB driver for the SSD1306 OLED Controller"
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH] dt-bindings: power: Fix path to power-domain.txt bindings

2019-11-19 Thread Krzysztof Kozlowski
With split of power domain controller bindings to power-domain.yaml, the
consumer part was renamed to power-domain.txt.  Update the references in
other bindings.

Reported-by: Geert Uytterhoeven 
Fixes: abb4805e343a ("dt-bindings: power: Convert Samsung Exynos Power Domain 
bindings to json-schema")
Signed-off-by: Krzysztof Kozlowski 
---
 Documentation/devicetree/bindings/clock/clk-exynos-audss.txt  | 2 +-
 Documentation/devicetree/bindings/clock/exynos5433-clock.txt  | 2 +-
 .../devicetree/bindings/clock/renesas,r8a7778-cpg-clocks.txt  | 2 +-
 .../devicetree/bindings/clock/renesas,r8a7779-cpg-clocks.txt  | 2 +-
 .../bindings/clock/renesas,rcar-gen2-cpg-clocks.txt   | 2 +-
 .../devicetree/bindings/clock/renesas,rz-cpg-clocks.txt   | 2 +-
 .../devicetree/bindings/display/etnaviv/etnaviv-drm.txt   | 2 +-
 Documentation/devicetree/bindings/display/msm/dpu.txt | 2 +-
 Documentation/devicetree/bindings/display/msm/mdp5.txt| 2 +-
 Documentation/devicetree/bindings/dsp/fsl,dsp.yaml| 2 +-
 Documentation/devicetree/bindings/media/imx7-mipi-csi2.txt| 2 +-
 .../devicetree/bindings/media/mediatek-jpeg-decoder.txt   | 2 +-
 Documentation/devicetree/bindings/media/mediatek-mdp.txt  | 2 +-
 Documentation/devicetree/bindings/opp/qcom-nvmem-cpufreq.txt  | 2 +-
 Documentation/devicetree/bindings/pci/pci-keystone.txt| 2 +-
 Documentation/devicetree/bindings/phy/ti,phy-am654-serdes.txt | 2 +-
 Documentation/devicetree/bindings/power/qcom,rpmpd.txt| 2 +-
 Documentation/devicetree/bindings/power/renesas,rcar-sysc.txt | 2 +-
 .../devicetree/bindings/usb/nvidia,tegra124-xusb.txt  | 4 ++--
 19 files changed, 20 insertions(+), 20 deletions(-)

diff --git a/Documentation/devicetree/bindings/clock/clk-exynos-audss.txt 
b/Documentation/devicetree/bindings/clock/clk-exynos-audss.txt
index 6030afb10b5c..e6c6b43e9770 100644
--- a/Documentation/devicetree/bindings/clock/clk-exynos-audss.txt
+++ b/Documentation/devicetree/bindings/clock/clk-exynos-audss.txt
@@ -36,7 +36,7 @@ Required Properties:
 Optional Properties:
 
   - power-domains: a phandle to respective power domain node as described by
-generic PM domain bindings (see power/power_domain.txt for more
+generic PM domain bindings (see power/power-domain.txt for more
 information).
 
 The following is the list of clocks generated by the controller. Each clock is
diff --git a/Documentation/devicetree/bindings/clock/exynos5433-clock.txt 
b/Documentation/devicetree/bindings/clock/exynos5433-clock.txt
index 183c327a7d6b..972d4e45f8c1 100644
--- a/Documentation/devicetree/bindings/clock/exynos5433-clock.txt
+++ b/Documentation/devicetree/bindings/clock/exynos5433-clock.txt
@@ -178,7 +178,7 @@ Required Properties:
 
 Optional properties:
   - power-domains: a phandle to respective power domain node as described by
-   generic PM domain bindings (see power/power_domain.txt for more
+   generic PM domain bindings (see power/power-domain.txt for more
information).
 
 Each clock is assigned an identifier and client nodes can use this identifier
diff --git 
a/Documentation/devicetree/bindings/clock/renesas,r8a7778-cpg-clocks.txt 
b/Documentation/devicetree/bindings/clock/renesas,r8a7778-cpg-clocks.txt
index 7cc4c0330b53..46ecbbce277c 100644
--- a/Documentation/devicetree/bindings/clock/renesas,r8a7778-cpg-clocks.txt
+++ b/Documentation/devicetree/bindings/clock/renesas,r8a7778-cpg-clocks.txt
@@ -17,7 +17,7 @@ Required Properties:
 SoC devices that are part of the CPG/MSTP Clock Domain and can be power-managed
 through an MSTP clock should refer to the CPG device node in their
 "power-domains" property, as documented by the generic PM domain bindings in
-Documentation/devicetree/bindings/power/power_domain.txt.
+Documentation/devicetree/bindings/power/power-domain.txt.
 
 
 Examples
diff --git 
a/Documentation/devicetree/bindings/clock/renesas,r8a7779-cpg-clocks.txt 
b/Documentation/devicetree/bindings/clock/renesas,r8a7779-cpg-clocks.txt
index 8c81547c29f5..cb32b4f41046 100644
--- a/Documentation/devicetree/bindings/clock/renesas,r8a7779-cpg-clocks.txt
+++ b/Documentation/devicetree/bindings/clock/renesas,r8a7779-cpg-clocks.txt
@@ -19,7 +19,7 @@ Required Properties:
 SoC devices that are part of the CPG/MSTP Clock Domain and can be power-managed
 through an MSTP clock should refer to the CPG device node in their
 "power-domains" property, as documented by the generic PM domain bindings in
-Documentation/devicetree/bindings/power/power_domain.txt.
+Documentation/devicetree/bindings/power/power-domain.txt.
 
 
 Examples
diff --git 
a/Documentation/devicetree/bindings/clock/renesas,rcar-gen2-cpg-clocks.txt 
b/Documentation/devicetree/bindings/clock/renesas,rcar-gen2-cpg-clocks.txt
index f8c05bb4116e..58f9054704c2 100644
--- a/Documentation/devicetree/bindings/clock/renesas,rcar-gen2-cpg-clocks.txt
+++ b/Documentation/devicetree/bindings/clock/renesas,rcar-gen2

Re: [PATCH] drm/vc4: Fix Kconfig indentation

2019-11-27 Thread Krzysztof Kozlowski
On Wed, 27 Nov 2019 at 21:14, Jani Nikula  wrote:
>
> On Thu, 21 Nov 2019, Krzysztof Kozlowski  wrote:
> > Adjust indentation from spaces to tab (+optional two spaces) as in
> > coding style with command like:
> >   $ sed -e 's/^/\t/' -i */Kconfig
>
> Btw have you updated checkpatch.pl to try to keep the Kconfigs from
> bitrotting back to having different indentation? Or the config tools?

Perl is not my domain but I can try. Let's see...

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH v2] video: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Fix also 7-space and tab+1 space indentation issues.
---
 drivers/video/Kconfig   |   4 +-
 drivers/video/backlight/Kconfig |  16 ++---
 drivers/video/console/Kconfig   | 132 
 3 files changed, 76 insertions(+), 76 deletions(-)

diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
index 427a993c7f57..74c2f39cec90 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -26,8 +26,8 @@ endmenu
 source "drivers/video/backlight/Kconfig"
 
 config VGASTATE
-   tristate
-   default n
+   tristate
+   default n
 
 config VIDEOMODE_HELPERS
bool
diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig
index 403707a3e503..e25fdd8ce3e7 100644
--- a/drivers/video/backlight/Kconfig
+++ b/drivers/video/backlight/Kconfig
@@ -9,7 +9,7 @@ menu "Backlight & LCD device support"
 # LCD
 #
 config LCD_CLASS_DEVICE
-tristate "Lowlevel LCD controls"
+   tristate "Lowlevel LCD controls"
help
  This framework adds support for low-level control of LCD.
  Some framebuffer devices connect to platform-specific LCD modules
@@ -141,10 +141,10 @@ endif # LCD_CLASS_DEVICE
 # Backlight
 #
 config BACKLIGHT_CLASS_DEVICE
-tristate "Lowlevel Backlight controls"
+   tristate "Lowlevel Backlight controls"
help
  This framework adds support for low-level control of the LCD
-  backlight. This includes support for brightness and power.
+ backlight. This includes support for brightness and power.
 
  To have support for your specific LCD panel you will have to
  select the proper drivers which depend on this option.
@@ -269,11 +269,11 @@ config BACKLIGHT_MAX8925
  WLED output, say Y here to enable this driver.
 
 config BACKLIGHT_APPLE
-   tristate "Apple Backlight Driver"
-   depends on X86 && ACPI
-   help
- If you have an Intel-based Apple say Y to enable a driver for its
-backlight.
+   tristate "Apple Backlight Driver"
+   depends on X86 && ACPI
+   help
+ If you have an Intel-based Apple say Y to enable a driver for its
+ backlight.
 
 config BACKLIGHT_TOSA
tristate "Sharp SL-6000 Backlight Driver"
diff --git a/drivers/video/console/Kconfig b/drivers/video/console/Kconfig
index c10e17fb9a9a..ed8480d324b1 100644
--- a/drivers/video/console/Kconfig
+++ b/drivers/video/console/Kconfig
@@ -23,26 +23,26 @@ config VGA_CONSOLE
  Say Y.
 
 config VGACON_SOFT_SCROLLBACK
-   bool "Enable Scrollback Buffer in System RAM"
-   depends on VGA_CONSOLE
-   default n
-   help
- The scrollback buffer of the standard VGA console is located in
-the VGA RAM.  The size of this RAM is fixed and is quite small.
-If you require a larger scrollback buffer, this can be placed in
-System RAM which is dynamically allocated during initialization.
-Placing the scrollback buffer in System RAM will slightly slow
-down the console.
-
-If you want this feature, say 'Y' here and enter the amount of
-RAM to allocate for this buffer.  If unsure, say 'N'.
+   bool "Enable Scrollback Buffer in System RAM"
+   depends on VGA_CONSOLE
+   default n
+   help
+ The scrollback buffer of the standard VGA console is located in
+ the VGA RAM.  The size of this RAM is fixed and is quite small.
+ If you require a larger scrollback buffer, this can be placed in
+ System RAM which is dynamically allocated during initialization.
+ Placing the scrollback buffer in System RAM will slightly slow
+ down the console.
+
+ If you want this feature, say 'Y' here and enter the amount of
+ RAM to allocate for this buffer.  If unsure, say 'N'.
 
 config VGACON_SOFT_SCROLLBACK_SIZE
-   int "Scrollback Buffer Size (in KB)"
-   depends on VGACON_SOFT_SCROLLBACK
-   range 1 1024
-   default "64"
-   help
+   int "Scrollback Buffer Size (in KB)"
+   depends on VGACON_SOFT_SCROLLBACK
+   range 1 1024
+   default "64"
+   help
  Enter the amount of System RAM to allocate for scrollback
  buffers of VGA consoles. Each 64KB will give you approximately
  16 80x25 screenfuls of scrollback buffer.
@@ -84,12 +84,12 @@ config MDA_CONSOLE
  If unsure, say N.
 
 config SGI_NEWPORT_CONSOLE
-tristate "SGI Newport Console support"
+   tristate "SGI Newport Console support"
depends on SGI_I

[PATCH v3] video: Fix Kconfig indentation

2019-11-20 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
Acked-by: Bartlomiej Zolnierkiewicz 

---

Changes since v2:
1. Add Bartlomiej's ack.

Changes since v1:
1. Fix also 7-space and tab+1 space indentation issues.
---
 drivers/video/Kconfig   |   4 +-
 drivers/video/backlight/Kconfig |  16 ++---
 drivers/video/console/Kconfig   | 132 
 3 files changed, 76 insertions(+), 76 deletions(-)

diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
index 427a993c7f57..74c2f39cec90 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -26,8 +26,8 @@ endmenu
 source "drivers/video/backlight/Kconfig"
 
 config VGASTATE
-   tristate
-   default n
+   tristate
+   default n
 
 config VIDEOMODE_HELPERS
bool
diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig
index 403707a3e503..e25fdd8ce3e7 100644
--- a/drivers/video/backlight/Kconfig
+++ b/drivers/video/backlight/Kconfig
@@ -9,7 +9,7 @@ menu "Backlight & LCD device support"
 # LCD
 #
 config LCD_CLASS_DEVICE
-tristate "Lowlevel LCD controls"
+   tristate "Lowlevel LCD controls"
help
  This framework adds support for low-level control of LCD.
  Some framebuffer devices connect to platform-specific LCD modules
@@ -141,10 +141,10 @@ endif # LCD_CLASS_DEVICE
 # Backlight
 #
 config BACKLIGHT_CLASS_DEVICE
-tristate "Lowlevel Backlight controls"
+   tristate "Lowlevel Backlight controls"
help
  This framework adds support for low-level control of the LCD
-  backlight. This includes support for brightness and power.
+ backlight. This includes support for brightness and power.
 
  To have support for your specific LCD panel you will have to
  select the proper drivers which depend on this option.
@@ -269,11 +269,11 @@ config BACKLIGHT_MAX8925
  WLED output, say Y here to enable this driver.
 
 config BACKLIGHT_APPLE
-   tristate "Apple Backlight Driver"
-   depends on X86 && ACPI
-   help
- If you have an Intel-based Apple say Y to enable a driver for its
-backlight.
+   tristate "Apple Backlight Driver"
+   depends on X86 && ACPI
+   help
+ If you have an Intel-based Apple say Y to enable a driver for its
+ backlight.
 
 config BACKLIGHT_TOSA
tristate "Sharp SL-6000 Backlight Driver"
diff --git a/drivers/video/console/Kconfig b/drivers/video/console/Kconfig
index c10e17fb9a9a..ed8480d324b1 100644
--- a/drivers/video/console/Kconfig
+++ b/drivers/video/console/Kconfig
@@ -23,26 +23,26 @@ config VGA_CONSOLE
  Say Y.
 
 config VGACON_SOFT_SCROLLBACK
-   bool "Enable Scrollback Buffer in System RAM"
-   depends on VGA_CONSOLE
-   default n
-   help
- The scrollback buffer of the standard VGA console is located in
-the VGA RAM.  The size of this RAM is fixed and is quite small.
-If you require a larger scrollback buffer, this can be placed in
-System RAM which is dynamically allocated during initialization.
-Placing the scrollback buffer in System RAM will slightly slow
-down the console.
-
-If you want this feature, say 'Y' here and enter the amount of
-RAM to allocate for this buffer.  If unsure, say 'N'.
+   bool "Enable Scrollback Buffer in System RAM"
+   depends on VGA_CONSOLE
+   default n
+   help
+ The scrollback buffer of the standard VGA console is located in
+ the VGA RAM.  The size of this RAM is fixed and is quite small.
+ If you require a larger scrollback buffer, this can be placed in
+ System RAM which is dynamically allocated during initialization.
+ Placing the scrollback buffer in System RAM will slightly slow
+ down the console.
+
+ If you want this feature, say 'Y' here and enter the amount of
+ RAM to allocate for this buffer.  If unsure, say 'N'.
 
 config VGACON_SOFT_SCROLLBACK_SIZE
-   int "Scrollback Buffer Size (in KB)"
-   depends on VGACON_SOFT_SCROLLBACK
-   range 1 1024
-   default "64"
-   help
+   int "Scrollback Buffer Size (in KB)"
+   depends on VGACON_SOFT_SCROLLBACK
+   range 1 1024
+   default "64"
+   help
  Enter the amount of System RAM to allocate for scrollback
  buffers of VGA consoles. Each 64KB will give you approximately
  16 80x25 screenfuls of scrollback buffer.
@@ -84,12 +84,12 @@ config MDA_CONSOLE
  If unsure, say N.
 
 config SGI_NEWPORT_CONSOLE
-tristate "SGI Newport Console support"
+   tristat

Re: [PATCH v2 5/8] dt-bindings: watchdog: Convert Samsung SoC watchdog bindings to json-schema

2019-09-20 Thread Krzysztof Kozlowski
On Wed, 18 Sep 2019 at 19:32, Krzysztof Kozlowski  wrote:
>
> Convert Samsung S3C/S5P/Exynos watchdog bindings to DT schema format
> using json-schema.
>
> Signed-off-by: Krzysztof Kozlowski 
>
> ---
>
> Changes since v1:
> 1. Indent example with four spaces (more readable),
> 2. Remove unneeded timeout-sec description.

Superseded by v3 (although named v2...).

Best regards,
Krzysztof


[PATCH v3] drm/amd: Fix Kconfig indentation

2019-10-07 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v2:
1. Split AMD and i915 to separate patches.
---
 drivers/gpu/drm/Kconfig |  4 ++--
 drivers/gpu/drm/amd/display/Kconfig | 32 ++---
 2 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
index 108e1b7f4564..7cb6e4eb99e8 100644
--- a/drivers/gpu/drm/Kconfig
+++ b/drivers/gpu/drm/Kconfig
@@ -226,9 +226,9 @@ config DRM_AMDGPU
tristate "AMD GPU"
depends on DRM && PCI && MMU
select FW_LOADER
-select DRM_KMS_HELPER
+   select DRM_KMS_HELPER
select DRM_SCHED
-select DRM_TTM
+   select DRM_TTM
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE
diff --git a/drivers/gpu/drm/amd/display/Kconfig 
b/drivers/gpu/drm/amd/display/Kconfig
index 1bbe762ee6ba..313183b80032 100644
--- a/drivers/gpu/drm/amd/display/Kconfig
+++ b/drivers/gpu/drm/amd/display/Kconfig
@@ -23,16 +23,16 @@ config DRM_AMD_DC_DCN2_0
depends on DRM_AMD_DC && X86
depends on DRM_AMD_DC_DCN1_0
help
-   Choose this option if you want to have
-   Navi support for display engine
+ Choose this option if you want to have
+ Navi support for display engine
 
 config DRM_AMD_DC_DCN2_1
-bool "DCN 2.1 family"
-depends on DRM_AMD_DC && X86
-depends on DRM_AMD_DC_DCN2_0
-help
-Choose this option if you want to have
-Renoir support for display engine
+   bool "DCN 2.1 family"
+   depends on DRM_AMD_DC && X86
+   depends on DRM_AMD_DC_DCN2_0
+   help
+ Choose this option if you want to have
+ Renoir support for display engine
 
 config DRM_AMD_DC_DSC_SUPPORT
bool "DSC support"
@@ -41,16 +41,16 @@ config DRM_AMD_DC_DSC_SUPPORT
depends on DRM_AMD_DC_DCN1_0
depends on DRM_AMD_DC_DCN2_0
help
-   Choose this option if you want to have
-   Dynamic Stream Compression support
+ Choose this option if you want to have
+ Dynamic Stream Compression support
 
 config DRM_AMD_DC_HDCP
-bool "Enable HDCP support in DC"
-depends on DRM_AMD_DC
-help
- Choose this option
- if you want to support
- HDCP authentication
+   bool "Enable HDCP support in DC"
+   depends on DRM_AMD_DC
+   help
+Choose this option
+if you want to support
+HDCP authentication
 
 config DEBUG_KERNEL_DC
bool "Enable kgdb break in DC"
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH v3] gpu: Fix Kconfig indentation

2019-10-07 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v2:
1. Split AMD and i915 to separate patches.
---
 drivers/gpu/drm/Kconfig  |  6 +++---
 drivers/gpu/drm/bridge/Kconfig   |  8 
 drivers/gpu/drm/lima/Kconfig |  2 +-
 drivers/gpu/drm/mgag200/Kconfig  |  8 
 drivers/gpu/drm/nouveau/Kconfig  |  2 +-
 drivers/gpu/drm/omapdrm/displays/Kconfig |  6 +++---
 drivers/gpu/drm/omapdrm/dss/Kconfig  | 12 ++--
 drivers/gpu/drm/rockchip/Kconfig |  8 
 drivers/gpu/drm/udl/Kconfig  |  2 +-
 drivers/gpu/vga/Kconfig  |  2 +-
 10 files changed, 28 insertions(+), 28 deletions(-)

diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
index e67c194c2aca..108e1b7f4564 100644
--- a/drivers/gpu/drm/Kconfig
+++ b/drivers/gpu/drm/Kconfig
@@ -207,8 +207,8 @@ config DRM_RADEON
tristate "ATI Radeon"
depends on DRM && PCI && MMU
select FW_LOADER
-select DRM_KMS_HELPER
-select DRM_TTM
+   select DRM_KMS_HELPER
+   select DRM_TTM
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE
@@ -266,7 +266,7 @@ config DRM_VKMS
  If M is selected the module will be called vkms.
 
 config DRM_ATI_PCIGART
-bool
+   bool
 
 source "drivers/gpu/drm/exynos/Kconfig"
 
diff --git a/drivers/gpu/drm/bridge/Kconfig b/drivers/gpu/drm/bridge/Kconfig
index 1cc9f502c1f2..a5aa7ec16000 100644
--- a/drivers/gpu/drm/bridge/Kconfig
+++ b/drivers/gpu/drm/bridge/Kconfig
@@ -60,10 +60,10 @@ config DRM_MEGACHIPS_STDP_GE_B850V3_FW
select DRM_KMS_HELPER
select DRM_PANEL
---help---
-  This is a driver for the display bridges of
-  GE B850v3 that convert dual channel LVDS
-  to DP++. This is used with the i.MX6 imx-ldb
-  driver. You are likely to say N here.
+ This is a driver for the display bridges of
+ GE B850v3 that convert dual channel LVDS
+ to DP++. This is used with the i.MX6 imx-ldb
+ driver. You are likely to say N here.
 
 config DRM_NXP_PTN3460
tristate "NXP PTN3460 DP/LVDS bridge"
diff --git a/drivers/gpu/drm/lima/Kconfig b/drivers/gpu/drm/lima/Kconfig
index bb4ddc6bb0a6..652af7f50ea9 100644
--- a/drivers/gpu/drm/lima/Kconfig
+++ b/drivers/gpu/drm/lima/Kconfig
@@ -10,4 +10,4 @@ config DRM_LIMA
depends on OF
select DRM_SCHED
help
- DRM driver for ARM Mali 400/450 GPUs.
+DRM driver for ARM Mali 400/450 GPUs.
diff --git a/drivers/gpu/drm/mgag200/Kconfig b/drivers/gpu/drm/mgag200/Kconfig
index 76fee0fbdcae..4b31ef376abc 100644
--- a/drivers/gpu/drm/mgag200/Kconfig
+++ b/drivers/gpu/drm/mgag200/Kconfig
@@ -6,8 +6,8 @@ config DRM_MGAG200
select DRM_VRAM_HELPER
help
 This is a KMS driver for the MGA G200 server chips, it
- does not support the original MGA G200 or any of the desktop
- chips. It requires 0.3.0 of the modesetting userspace driver,
- and a version of mga driver that will fail on KMS enabled
- devices.
+does not support the original MGA G200 or any of the desktop
+chips. It requires 0.3.0 of the modesetting userspace driver,
+and a version of mga driver that will fail on KMS enabled
+devices.
 
diff --git a/drivers/gpu/drm/nouveau/Kconfig b/drivers/gpu/drm/nouveau/Kconfig
index 3558df043592..9c990266e876 100644
--- a/drivers/gpu/drm/nouveau/Kconfig
+++ b/drivers/gpu/drm/nouveau/Kconfig
@@ -2,7 +2,7 @@
 config DRM_NOUVEAU
tristate "Nouveau (NVIDIA) cards"
depends on DRM && PCI && MMU
-select FW_LOADER
+   select FW_LOADER
select DRM_KMS_HELPER
select DRM_TTM
select BACKLIGHT_CLASS_DEVICE if DRM_NOUVEAU_BACKLIGHT
diff --git a/drivers/gpu/drm/omapdrm/displays/Kconfig 
b/drivers/gpu/drm/omapdrm/displays/Kconfig
index 240dda102845..b562a8cd61bf 100644
--- a/drivers/gpu/drm/omapdrm/displays/Kconfig
+++ b/drivers/gpu/drm/omapdrm/displays/Kconfig
@@ -8,18 +8,18 @@ config DRM_OMAP_ENCODER_OPA362
  through a GPIO.
 
 config DRM_OMAP_ENCODER_TPD12S015
-tristate "TPD12S015 HDMI ESD protection and level shifter"
+   tristate "TPD12S015 HDMI ESD protection and level shifter"
help
  Driver for TPD12S015, which offers HDMI ESD protection and level
  shifting.
 
 config DRM_OMAP_CONNECTOR_HDMI
-tristate "HDMI Connector"
+   tristate "HDMI Connector"
help
  Driver for a generic HDMI connector.
 
 config DRM_OMAP_CONNECTOR_ANALOG_TV
-tristate "Analog TV Connector"
+   tristate "Analog TV Connector"
he

[PATCH v3] drm/i915: Fix Kconfig indentation

2019-10-07 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v2:
1. Split AMD and i915 to separate patches.
---
 drivers/gpu/drm/i915/Kconfig   |  12 +--
 drivers/gpu/drm/i915/Kconfig.debug | 144 ++---
 2 files changed, 78 insertions(+), 78 deletions(-)

diff --git a/drivers/gpu/drm/i915/Kconfig b/drivers/gpu/drm/i915/Kconfig
index 0d21402945ab..3c6d57df262d 100644
--- a/drivers/gpu/drm/i915/Kconfig
+++ b/drivers/gpu/drm/i915/Kconfig
@@ -76,7 +76,7 @@ config DRM_I915_CAPTURE_ERROR
  This option enables capturing the GPU state when a hang is detected.
  This information is vital for triaging hangs and assists in debugging.
  Please report any hang to
-https://bugs.freedesktop.org/enter_bug.cgi?product=DRI
+   https://bugs.freedesktop.org/enter_bug.cgi?product=DRI
  for triaging.
 
  If in doubt, say "Y".
@@ -105,11 +105,11 @@ config DRM_I915_USERPTR
  If in doubt, say "Y".
 
 config DRM_I915_GVT
-bool "Enable Intel GVT-g graphics virtualization host support"
-depends on DRM_I915
-depends on 64BIT
-default n
-help
+   bool "Enable Intel GVT-g graphics virtualization host support"
+   depends on DRM_I915
+   depends on 64BIT
+   default n
+   help
  Choose this option if you want to enable Intel GVT-g graphics
  virtualization technology host support with integrated graphics.
  With GVT-g, it's possible to have one integrated graphics
diff --git a/drivers/gpu/drm/i915/Kconfig.debug 
b/drivers/gpu/drm/i915/Kconfig.debug
index 00786a142ff0..eea79125b3ea 100644
--- a/drivers/gpu/drm/i915/Kconfig.debug
+++ b/drivers/gpu/drm/i915/Kconfig.debug
@@ -1,34 +1,34 @@
 # SPDX-License-Identifier: GPL-2.0-only
 config DRM_I915_WERROR
-bool "Force GCC to throw an error instead of a warning when compiling"
-# As this may inadvertently break the build, only allow the user
-# to shoot oneself in the foot iff they aim really hard
-depends on EXPERT
-# We use the dependency on !COMPILE_TEST to not be enabled in
-# allmodconfig or allyesconfig configurations
-depends on !COMPILE_TEST
+   bool "Force GCC to throw an error instead of a warning when compiling"
+   # As this may inadvertently break the build, only allow the user
+   # to shoot oneself in the foot iff they aim really hard
+   depends on EXPERT
+   # We use the dependency on !COMPILE_TEST to not be enabled in
+   # allmodconfig or allyesconfig configurations
+   depends on !COMPILE_TEST
select HEADER_TEST
-default n
-help
-  Add -Werror to the build flags for (and only for) i915.ko.
-  Do not enable this unless you are writing code for the i915.ko 
module.
+   default n
+   help
+ Add -Werror to the build flags for (and only for) i915.ko.
+ Do not enable this unless you are writing code for the i915.ko module.
 
-  Recommended for driver developers only.
+ Recommended for driver developers only.
 
-  If in doubt, say "N".
+ If in doubt, say "N".
 
 config DRM_I915_DEBUG
-bool "Enable additional driver debugging"
-depends on DRM_I915
-select DEBUG_FS
-select PREEMPT_COUNT
-select REFCOUNT_FULL
-select I2C_CHARDEV
-select STACKDEPOT
-select DRM_DP_AUX_CHARDEV
-select X86_MSR # used by igt/pm_rpm
-select DRM_VGEM # used by igt/prime_vgem (dmabuf interop checks)
-select DRM_DEBUG_MM if DRM=y
+   bool "Enable additional driver debugging"
+   depends on DRM_I915
+   select DEBUG_FS
+   select PREEMPT_COUNT
+   select REFCOUNT_FULL
+   select I2C_CHARDEV
+   select STACKDEPOT
+   select DRM_DP_AUX_CHARDEV
+   select X86_MSR # used by igt/pm_rpm
+   select DRM_VGEM # used by igt/prime_vgem (dmabuf interop checks)
+   select DRM_DEBUG_MM if DRM=y
select DRM_DEBUG_SELFTEST
select DMABUF_SELFTESTS
select SW_SYNC # signaling validation framework (igt/syncobj*)
@@ -36,14 +36,14 @@ config DRM_I915_DEBUG
select DRM_I915_SELFTEST
select DRM_I915_DEBUG_RUNTIME_PM
select DRM_I915_DEBUG_MMIO
-default n
-help
-  Choose this option to turn on extra driver debugging that may affect
-  performance but will catch some internal issues.
+   default n
+   help
+ Choose this option to turn on extra driver debugging that may affect
+ performance but will catch some internal issues.
 
-  Recommended for driver developers only.
+ Recommended for 

Re: [PATCH TRIVIAL v2] gpu: Fix Kconfig indentation

2019-10-07 Thread Krzysztof Kozlowski
On Mon, 7 Oct 2019 at 18:09, Alex Deucher  wrote:
>
> On Mon, Oct 7, 2019 at 7:39 AM Jani Nikula  
> wrote:
> >
> > On Fri, 04 Oct 2019, Krzysztof Kozlowski  wrote:
> > >  drivers/gpu/drm/i915/Kconfig |  12 +-
> > >  drivers/gpu/drm/i915/Kconfig.debug   | 144 +++
> >
> > Please split these out to a separate patch. Can't speak for others, but
> > the patch looks like it'll be conflicts galore and a problem to manage
> > if merged in one big lump.
>
> Yes, it would be nice to have the amd patch separate as well.

I'll split the AMD and i915 although I am not sure if it is sense to
split such trivial patch per each driver.

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH 1/3] dt-bindings: arm: samsung: Force clkoutN names to be unique in PMU

2019-10-08 Thread Krzysztof Kozlowski
On Tue, Oct 08, 2019 at 05:04:56PM +0200, Krzysztof Kozlowski wrote:
> On Tue, Oct 08, 2019 at 09:38:15AM -0500, Rob Herring wrote:
> > Are you running using DT_SCHEMA_FILES? If so, you won't get the core schema.
> 
> Ah, yes, now I see proper errors. Thanks for pointing this.
> 
> I'll send next version of this patch only (if others are ok).
> 

Of course, there will be no v2, this patch can be just skipped.

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH 1/3] dt-bindings: arm: samsung: Force clkoutN names to be unique in PMU

2019-10-08 Thread Krzysztof Kozlowski
On Tue, Oct 08, 2019 at 09:17:16AM -0500, Rob Herring wrote:
> On Tue, Oct 8, 2019 at 9:05 AM Rob Herring  wrote:
> >
> > On Tue, Oct 8, 2019 at 7:50 AM Krzysztof Kozlowski  wrote:
> > >
> > > On Tue, Oct 08, 2019 at 07:38:14AM -0500, Rob Herring wrote:
> > > > On Fri, Oct 4, 2019 at 10:14 AM Krzysztof Kozlowski  
> > > > wrote:
> > > > >
> > > > > The clkoutN names of clocks must be unique because they represent
> > > > > unique inputs of clock multiplexer.
> > > > >
> > > > > Signed-off-by: Krzysztof Kozlowski 
> > > > > ---
> > > > >  Documentation/devicetree/bindings/arm/samsung/pmu.yaml | 6 --
> > > > >  1 file changed, 4 insertions(+), 2 deletions(-)
> > > > >
> > > > > diff --git a/Documentation/devicetree/bindings/arm/samsung/pmu.yaml 
> > > > > b/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
> > > > > index 73b56fc5bf58..d8e03716f5d2 100644
> > > > > --- a/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
> > > > > +++ b/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
> > > > > @@ -53,8 +53,10 @@ properties:
> > > > >List of clock names for particular CLKOUT mux inputs
> > > > >  minItems: 1
> > > > >  maxItems: 32
> > > > > -items:
> > > > > -  pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'
> > > > > +allOf:
> > > > > +  - items:
> > > > > +  pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'
> > > > > +  - uniqueItems: true
> > > >
> > > > You shouldn't need the 'allOf', just add uniqueItems at the same level 
> > > > as items.
> > >
> > > If you mean something like:
> > >   56 uniqueItems: true
> > >   57 items:
> > >   58   pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'
> > >
> > > Then the dt_binding_check fails:
> > >
> > > dev/linux/Documentation/devicetree/bindings/arm/samsung/pmu.yaml: 
> > > properties:clock-names:
> > > 'uniqueItems' is not one of ['$ref', 'additionalItems', 
> > > 'additionalProperties', 'allOf', 'anyOf', 'const', 'contains', 'default', 
> > > 'dependencies', 'deprecated', 'description', 'else', 'enum', 'items', 
> > > 'if', 'minItems', 'minimum', 'maxItems', 'maximum', 'not', 'oneOf', 
> > > 'pattern', 'patternProperties', 'properties', 'required', 'then', 'type', 
> > > 'typeSize', 'unevaluatedProperties']
> >
> > I can add it.
> >
> > The other option is to fix this in the clock schema. I'm not sure if
> > there's a need for duplicate clock-names. Seems unlikely. I'll test
> > that.
> 
> Actually, clock-names is already set to be unique. Did you see otherwise?

Yeah, I duplicated on purpose "clkout1" and it was not reported as an
error. That's why I added "uniqueItems".

Best regards,
Krzysztof



Re: [PATCH 1/3] dt-bindings: arm: samsung: Force clkoutN names to be unique in PMU

2019-10-08 Thread Krzysztof Kozlowski
On Tue, Oct 08, 2019 at 09:38:15AM -0500, Rob Herring wrote:
> Are you running using DT_SCHEMA_FILES? If so, you won't get the core schema.

Ah, yes, now I see proper errors. Thanks for pointing this.

I'll send next version of this patch only (if others are ok).

Best regards,
Krzysztof



Re: [PATCH 1/3] dt-bindings: arm: samsung: Force clkoutN names to be unique in PMU

2019-10-08 Thread Krzysztof Kozlowski
On Tue, Oct 08, 2019 at 07:38:14AM -0500, Rob Herring wrote:
> On Fri, Oct 4, 2019 at 10:14 AM Krzysztof Kozlowski  wrote:
> >
> > The clkoutN names of clocks must be unique because they represent
> > unique inputs of clock multiplexer.
> >
> > Signed-off-by: Krzysztof Kozlowski 
> > ---
> >  Documentation/devicetree/bindings/arm/samsung/pmu.yaml | 6 --
> >  1 file changed, 4 insertions(+), 2 deletions(-)
> >
> > diff --git a/Documentation/devicetree/bindings/arm/samsung/pmu.yaml 
> > b/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
> > index 73b56fc5bf58..d8e03716f5d2 100644
> > --- a/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
> > +++ b/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
> > @@ -53,8 +53,10 @@ properties:
> >List of clock names for particular CLKOUT mux inputs
> >  minItems: 1
> >  maxItems: 32
> > -items:
> > -  pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'
> > +allOf:
> > +  - items:
> > +  pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'
> > +  - uniqueItems: true
> 
> You shouldn't need the 'allOf', just add uniqueItems at the same level as 
> items.

If you mean something like:
  56 uniqueItems: true
  57 items:
  58   pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'

Then the dt_binding_check fails:

dev/linux/Documentation/devicetree/bindings/arm/samsung/pmu.yaml: 
properties:clock-names:
'uniqueItems' is not one of ['$ref', 'additionalItems', 'additionalProperties', 
'allOf', 'anyOf', 'const', 'contains', 'default', 'dependencies', 'deprecated', 
'description', 'else', 'enum', 'items', 'if', 'minItems', 'minimum', 
'maxItems', 'maximum', 'not', 'oneOf', 'pattern', 'patternProperties', 
'properties', 'required', 'then', 'type', 'typeSize', 'unevaluatedProperties']

Best regards,
Krzysztof


___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH v2 3/3] ARM: dts: exynos: Rename power domain nodes to "power-domain" in Exynos4

2019-10-06 Thread Krzysztof Kozlowski
On Wed, Oct 02, 2019 at 06:06:32PM +0200, Krzysztof Kozlowski wrote:
> The device node name should reflect generic class of a device so rename
> power domain nodes to "power-domain".  No functional change.
> 
> Signed-off-by: Krzysztof Kozlowski 
> ---
>  arch/arm/boot/dts/exynos4.dtsi| 14 +++---
>  arch/arm/boot/dts/exynos4210.dtsi |  2 +-
>  arch/arm/boot/dts/exynos4412.dtsi |  2 +-
>  3 files changed, 9 insertions(+), 9 deletions(-)

Applied.

Best regards,
Krzysztof


[PATCH TRIVIAL v2] gpu: Fix Kconfig indentation

2019-10-04 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 

---

Changes since v1:
1. Fix also DRM_AMD_DC_HDCP (new arrival since v1).
---
 drivers/gpu/drm/Kconfig  |  10 +-
 drivers/gpu/drm/amd/display/Kconfig  |  32 ++---
 drivers/gpu/drm/bridge/Kconfig   |   8 +-
 drivers/gpu/drm/i915/Kconfig |  12 +-
 drivers/gpu/drm/i915/Kconfig.debug   | 144 +++
 drivers/gpu/drm/lima/Kconfig |   2 +-
 drivers/gpu/drm/mgag200/Kconfig  |   8 +-
 drivers/gpu/drm/nouveau/Kconfig  |   2 +-
 drivers/gpu/drm/omapdrm/displays/Kconfig |   6 +-
 drivers/gpu/drm/omapdrm/dss/Kconfig  |  12 +-
 drivers/gpu/drm/rockchip/Kconfig |   8 +-
 drivers/gpu/drm/udl/Kconfig  |   2 +-
 drivers/gpu/vga/Kconfig  |   2 +-
 13 files changed, 124 insertions(+), 124 deletions(-)

diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
index e67c194c2aca..7cb6e4eb99e8 100644
--- a/drivers/gpu/drm/Kconfig
+++ b/drivers/gpu/drm/Kconfig
@@ -207,8 +207,8 @@ config DRM_RADEON
tristate "ATI Radeon"
depends on DRM && PCI && MMU
select FW_LOADER
-select DRM_KMS_HELPER
-select DRM_TTM
+   select DRM_KMS_HELPER
+   select DRM_TTM
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE
@@ -226,9 +226,9 @@ config DRM_AMDGPU
tristate "AMD GPU"
depends on DRM && PCI && MMU
select FW_LOADER
-select DRM_KMS_HELPER
+   select DRM_KMS_HELPER
select DRM_SCHED
-select DRM_TTM
+   select DRM_TTM
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE
@@ -266,7 +266,7 @@ config DRM_VKMS
  If M is selected the module will be called vkms.
 
 config DRM_ATI_PCIGART
-bool
+   bool
 
 source "drivers/gpu/drm/exynos/Kconfig"
 
diff --git a/drivers/gpu/drm/amd/display/Kconfig 
b/drivers/gpu/drm/amd/display/Kconfig
index 1bbe762ee6ba..313183b80032 100644
--- a/drivers/gpu/drm/amd/display/Kconfig
+++ b/drivers/gpu/drm/amd/display/Kconfig
@@ -23,16 +23,16 @@ config DRM_AMD_DC_DCN2_0
depends on DRM_AMD_DC && X86
depends on DRM_AMD_DC_DCN1_0
help
-   Choose this option if you want to have
-   Navi support for display engine
+ Choose this option if you want to have
+ Navi support for display engine
 
 config DRM_AMD_DC_DCN2_1
-bool "DCN 2.1 family"
-depends on DRM_AMD_DC && X86
-depends on DRM_AMD_DC_DCN2_0
-help
-Choose this option if you want to have
-Renoir support for display engine
+   bool "DCN 2.1 family"
+   depends on DRM_AMD_DC && X86
+   depends on DRM_AMD_DC_DCN2_0
+   help
+ Choose this option if you want to have
+ Renoir support for display engine
 
 config DRM_AMD_DC_DSC_SUPPORT
bool "DSC support"
@@ -41,16 +41,16 @@ config DRM_AMD_DC_DSC_SUPPORT
depends on DRM_AMD_DC_DCN1_0
depends on DRM_AMD_DC_DCN2_0
help
-   Choose this option if you want to have
-   Dynamic Stream Compression support
+ Choose this option if you want to have
+ Dynamic Stream Compression support
 
 config DRM_AMD_DC_HDCP
-bool "Enable HDCP support in DC"
-depends on DRM_AMD_DC
-help
- Choose this option
- if you want to support
- HDCP authentication
+   bool "Enable HDCP support in DC"
+   depends on DRM_AMD_DC
+   help
+Choose this option
+if you want to support
+HDCP authentication
 
 config DEBUG_KERNEL_DC
bool "Enable kgdb break in DC"
diff --git a/drivers/gpu/drm/bridge/Kconfig b/drivers/gpu/drm/bridge/Kconfig
index 1cc9f502c1f2..a5aa7ec16000 100644
--- a/drivers/gpu/drm/bridge/Kconfig
+++ b/drivers/gpu/drm/bridge/Kconfig
@@ -60,10 +60,10 @@ config DRM_MEGACHIPS_STDP_GE_B850V3_FW
select DRM_KMS_HELPER
select DRM_PANEL
---help---
-  This is a driver for the display bridges of
-  GE B850v3 that convert dual channel LVDS
-  to DP++. This is used with the i.MX6 imx-ldb
-  driver. You are likely to say N here.
+ This is a driver for the display bridges of
+ GE B850v3 that convert dual channel LVDS
+ to DP++. This is used with the i.MX6 imx-ldb
+ driver. You are likely to say N here.
 
 config DRM_NXP_PTN3460
tristate "NXP PTN3460 DP/LVDS bridge"
diff --git a/drivers/gpu/drm/i915/Kconfig b/drivers/gpu/drm/i915/Kconfig
index 0d21402945ab..3c6d57df262d 100644
--- a/drivers/gpu/drm/i915/Kconfig
+++ 

[PATCH 3/3] dt-bindings: serial: Convert Samsung UART bindings to json-schema

2019-10-04 Thread Krzysztof Kozlowski
Convert Samsung S3C/S5P/Exynos Serial/UART bindings to DT schema format
using json-schema.

Signed-off-by: Krzysztof Kozlowski 
---
 .../bindings/mfd/samsung,exynos5433-lpass.txt |   2 +-
 .../bindings/serial/samsung_uart.txt  |  58 ---
 .../bindings/serial/samsung_uart.yaml | 148 ++
 3 files changed, 149 insertions(+), 59 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/serial/samsung_uart.txt
 create mode 100644 Documentation/devicetree/bindings/serial/samsung_uart.yaml

diff --git a/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt 
b/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt
index d759da606f75..30ea27c3936d 100644
--- a/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt
+++ b/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt
@@ -18,7 +18,7 @@ an optional sub-node. For "samsung,exynos5433-lpass" 
compatible this includes:
 UART, SLIMBUS, PCM, I2S, DMAC, Timers 0...4, VIC, WDT 0...1 devices.
 
 Bindings of the sub-nodes are described in:
-  ../serial/samsung_uart.txt
+  ../serial/samsung_uart.yaml
   ../sound/samsung-i2s.txt
   ../dma/arm-pl330.txt
 
diff --git a/Documentation/devicetree/bindings/serial/samsung_uart.txt 
b/Documentation/devicetree/bindings/serial/samsung_uart.txt
deleted file mode 100644
index e85f37ec33f0..
--- a/Documentation/devicetree/bindings/serial/samsung_uart.txt
+++ /dev/null
@@ -1,58 +0,0 @@
-* Samsung's UART Controller
-
-The Samsung's UART controller is used for interfacing SoC with serial
-communicaion devices.
-
-Required properties:
-- compatible: should be one of following:
-  - "samsung,exynos4210-uart" -  Exynos4210 SoC,
-  - "samsung,s3c2410-uart" - compatible with ports present on S3C2410 SoC,
-  - "samsung,s3c2412-uart" - compatible with ports present on S3C2412 SoC,
-  - "samsung,s3c2440-uart" - compatible with ports present on S3C2440 SoC,
-  - "samsung,s3c6400-uart" - compatible with ports present on S3C6400 SoC,
-  - "samsung,s5pv210-uart" - compatible with ports present on S5PV210 SoC.
-
-- reg: base physical address of the controller and length of memory mapped
-  region.
-
-- interrupts: a single interrupt signal to SoC interrupt controller,
-  according to interrupt bindings documentation [1].
-
-- clock-names: input names of clocks used by the controller:
-  - "uart" - controller bus clock,
-  - "clk_uart_baudN" - Nth baud base clock input (N = 0, 1, ...),
-according to SoC User's Manual (only N = 0 is allowedfor SoCs without
-internal baud clock mux).
-- clocks: phandles and specifiers for all clocks specified in "clock-names"
-  property, in the same order, according to clock bindings documentation [2].
-
-[1] Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
-[2] Documentation/devicetree/bindings/clock/clock-bindings.txt
-
-Optional properties:
-- samsung,uart-fifosize: The fifo size supported by the UART channel
-
-Note: Each Samsung UART should have an alias correctly numbered in the
-"aliases" node, according to serialN format, where N is the port number
-(non-negative decimal integer) as specified by User's Manual of respective
-SoC.
-
-Example:
-   aliases {
-   serial0 = 
-   serial1 = 
-   serial2 = 
-   };
-
-Example:
-   uart1: serial@7f005400 {
-   compatible = "samsung,s3c6400-uart";
-   reg = <0x7f005400 0x100>;
-   interrupt-parent = <>;
-   interrupts = <6>;
-   clock-names = "uart", "clk_uart_baud2",
-   "clk_uart_baud3";
-   clocks = < PCLK_UART1>, < PCLK_UART1>,
-   < SCLK_UART>;
-   samsung,uart-fifosize = <16>;
-   };
diff --git a/Documentation/devicetree/bindings/serial/samsung_uart.yaml 
b/Documentation/devicetree/bindings/serial/samsung_uart.yaml
new file mode 100644
index ..276bea1c231a
--- /dev/null
+++ b/Documentation/devicetree/bindings/serial/samsung_uart.yaml
@@ -0,0 +1,148 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/serial/samsung_uart.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Samsung S3C, S5P and Exynos SoC UART Controller
+
+maintainers:
+  - Krzysztof Kozlowski 
+  - Greg Kroah-Hartman 
+
+description: |+
+  Each Samsung UART should have an alias correctly numbered in the "aliases"
+  node, according to serialN format, where N is the port number (non-negative
+  decimal integer) as specified by User's Manual of respective SoC.
+
+properties:
+  compatible:
+items:
+  - enum:
+  - samsung,s3c2410-uart
+  - samsung,s3c2412-uart
+  - samsung,s3c244

[PATCH 1/3] dt-bindings: arm: samsung: Force clkoutN names to be unique in PMU

2019-10-04 Thread Krzysztof Kozlowski
The clkoutN names of clocks must be unique because they represent
unique inputs of clock multiplexer.

Signed-off-by: Krzysztof Kozlowski 
---
 Documentation/devicetree/bindings/arm/samsung/pmu.yaml | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/arm/samsung/pmu.yaml 
b/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
index 73b56fc5bf58..d8e03716f5d2 100644
--- a/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
+++ b/Documentation/devicetree/bindings/arm/samsung/pmu.yaml
@@ -53,8 +53,10 @@ properties:
   List of clock names for particular CLKOUT mux inputs
 minItems: 1
 maxItems: 32
-items:
-  pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'
+allOf:
+  - items:
+  pattern: '^clkout([0-9]|[12][0-9]|3[0-1])$'
+  - uniqueItems: true
 
   clocks:
 minItems: 1
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH 2/3] dt-bindings: gpu: samsung-rotator: Fix indentation

2019-10-04 Thread Krzysztof Kozlowski
Array elements under 'items' should be indented.

Signed-off-by: Krzysztof Kozlowski 
---
 Documentation/devicetree/bindings/gpu/samsung-rotator.yaml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/gpu/samsung-rotator.yaml 
b/Documentation/devicetree/bindings/gpu/samsung-rotator.yaml
index 45ce562435fa..f4dfa6fc724c 100644
--- a/Documentation/devicetree/bindings/gpu/samsung-rotator.yaml
+++ b/Documentation/devicetree/bindings/gpu/samsung-rotator.yaml
@@ -27,7 +27,7 @@ properties:
 
   clock-names:
 items:
-- const: rotator
+  - const: rotator
 
 required:
   - compatible
-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[RESEND TRIVIAL 3/3] treewide: arch: Fix Kconfig indentation

2019-10-04 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 arch/Kconfig   |  4 ++--
 arch/alpha/Kconfig |  2 +-
 arch/arm/Kconfig.debug |  4 ++--
 arch/arm/mach-ep93xx/Kconfig   |  8 
 arch/arm/mach-hisi/Kconfig |  2 +-
 arch/arm/mach-ixp4xx/Kconfig   | 16 
 arch/arm/mach-mmp/Kconfig  |  2 +-
 arch/arm/mach-omap1/Kconfig| 14 +++---
 arch/arm/mach-prima2/Kconfig   |  6 +++---
 arch/arm/mach-s3c24xx/Kconfig  |  4 ++--
 arch/arm/mach-s3c64xx/Kconfig  |  6 +++---
 arch/arm/plat-samsung/Kconfig  |  2 +-
 arch/arm64/Kconfig |  6 +++---
 arch/arm64/Kconfig.debug   |  2 +-
 arch/h8300/Kconfig |  4 ++--
 arch/h8300/Kconfig.cpu |  4 ++--
 arch/m68k/Kconfig.bus  |  2 +-
 arch/m68k/Kconfig.debug| 16 
 arch/m68k/Kconfig.machine  |  8 
 arch/nds32/Kconfig.cpu | 18 +-
 arch/openrisc/Kconfig  | 26 +-
 arch/powerpc/Kconfig.debug | 18 +-
 arch/powerpc/platforms/Kconfig.cputype |  2 +-
 arch/riscv/Kconfig.socs|  2 +-
 arch/sh/boards/Kconfig |  2 +-
 arch/sh/mm/Kconfig |  2 +-
 arch/um/Kconfig|  2 +-
 arch/x86/Kconfig   | 18 +-
 28 files changed, 101 insertions(+), 101 deletions(-)

diff --git a/arch/Kconfig b/arch/Kconfig
index 5f8a5d84dbbe..8d4f77bbed29 100644
--- a/arch/Kconfig
+++ b/arch/Kconfig
@@ -76,7 +76,7 @@ config JUMP_LABEL
depends on HAVE_ARCH_JUMP_LABEL
depends on CC_HAS_ASM_GOTO
help
- This option enables a transparent branch optimization that
+This option enables a transparent branch optimization that
 makes certain almost-always-true or almost-always-false branch
 conditions even cheaper to execute within the kernel.
 
@@ -84,7 +84,7 @@ config JUMP_LABEL
 scheduler functionality, networking code and KVM have such
 branches and include support for this optimization technique.
 
- If it is detected that the compiler has support for "asm goto",
+If it is detected that the compiler has support for "asm goto",
 the kernel will compile such branches with just a nop
 instruction. When the condition flag is toggled to true, the
 nop will be converted to a jump instruction to execute the
diff --git a/arch/alpha/Kconfig b/arch/alpha/Kconfig
index ef179033a7c2..30a6291355cb 100644
--- a/arch/alpha/Kconfig
+++ b/arch/alpha/Kconfig
@@ -545,7 +545,7 @@ config NR_CPUS
default "4" if !ALPHA_GENERIC && !ALPHA_MARVEL
help
  MARVEL support can handle a maximum of 32 CPUs, all the others
-  with working support have a maximum of 4 CPUs.
+ with working support have a maximum of 4 CPUs.
 
 config ARCH_DISCONTIGMEM_ENABLE
bool "Discontiguous Memory Support"
diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index 8bcbd0cd739b..0e5d52fbddbd 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -274,7 +274,7 @@ choice
select DEBUG_UART_8250
help
  Say Y here if you want the debug print routines to direct
-  their output to the CNS3xxx UART0.
+ their output to the CNS3xxx UART0.
 
config DEBUG_DAVINCI_DA8XX_UART1
bool "Kernel low-level debugging on DaVinci DA8XX using UART1"
@@ -828,7 +828,7 @@ choice
select DEBUG_UART_8250
help
  Say Y here if you want kernel low-level debugging support
-  on Rockchip RV1108 based platforms.
+ on Rockchip RV1108 based platforms.
 
config DEBUG_RV1108_UART1
bool "Kernel low-level debugging messages via Rockchip RV1108 
UART1"
diff --git a/arch/arm/mach-ep93xx/Kconfig b/arch/arm/mach-ep93xx/Kconfig
index f2db5fd38145..bf81dfab7f1b 100644
--- a/arch/arm/mach-ep93xx/Kconfig
+++ b/arch/arm/mach-ep93xx/Kconfig
@@ -126,10 +126,10 @@ config MACH_MICRO9S
  Contec Micro9-Slim board.
 
 config MACH_SIM_ONE
-bool "Support Simplemachines Sim.One board"
-help
-  Say 'Y' here if you want your kernel to support the
-  Simplemachines Sim.One board.
+   bool "Support Simplemachines Sim.One board"
+   help
+ Say 'Y' here if you want your kernel to support the
+ Simplemachines Sim.One board.
 
 config MACH_SNAPPER_CL15
bool "Support B

[RESEND TRIVIAL 2/3] treewide: Fix Kconfig indentation

2019-10-04 Thread Krzysztof Kozlowski
Adjust indentation from spaces to tab (+optional two spaces) as in
coding style with command like:
$ sed -e 's/^/\t/' -i */Kconfig

Signed-off-by: Krzysztof Kozlowski 
---
 certs/Kconfig  | 14 ++---
 init/Kconfig   | 28 +-
 kernel/trace/Kconfig   |  8 
 lib/Kconfig|  2 +-
 lib/Kconfig.debug  | 36 +-
 lib/Kconfig.kgdb   |  8 
 mm/Kconfig | 28 +-
 samples/Kconfig|  2 +-
 security/apparmor/Kconfig  |  2 +-
 security/integrity/Kconfig | 24 +++
 security/integrity/ima/Kconfig | 12 ++--
 security/safesetid/Kconfig | 24 +++
 12 files changed, 94 insertions(+), 94 deletions(-)

diff --git a/certs/Kconfig b/certs/Kconfig
index c94e93d8bccf..0358c66d3d7c 100644
--- a/certs/Kconfig
+++ b/certs/Kconfig
@@ -6,14 +6,14 @@ config MODULE_SIG_KEY
default "certs/signing_key.pem"
depends on MODULE_SIG
help
- Provide the file name of a private key/certificate in PEM format,
- or a PKCS#11 URI according to RFC7512. The file should contain, or
- the URI should identify, both the certificate and its corresponding
- private key.
+Provide the file name of a private key/certificate in PEM format,
+or a PKCS#11 URI according to RFC7512. The file should contain, or
+the URI should identify, both the certificate and its corresponding
+private key.
 
- If this option is unchanged from its default "certs/signing_key.pem",
- then the kernel will automatically generate the private key and
- certificate as described in 
Documentation/admin-guide/module-signing.rst
+If this option is unchanged from its default "certs/signing_key.pem",
+then the kernel will automatically generate the private key and
+certificate as described in 
Documentation/admin-guide/module-signing.rst
 
 config SYSTEM_TRUSTED_KEYRING
bool "Provide system-wide ring of trusted keys"
diff --git a/init/Kconfig b/init/Kconfig
index b4daad2bac23..e1a6f31da281 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -169,10 +169,10 @@ config BUILD_SALT
string "Build ID Salt"
default ""
help
-  The build ID is used to link binaries and their debug info. Setting
-  this option will use the value in the calculation of the build id.
-  This is mostly useful for distributions which want to ensure the
-  build is unique between builds. It's safe to leave the default.
+ The build ID is used to link binaries and their debug info. Setting
+ this option will use the value in the calculation of the build id.
+ This is mostly useful for distributions which want to ensure the
+ build is unique between builds. It's safe to leave the default.
 
 config HAVE_KERNEL_GZIP
bool
@@ -1327,9 +1327,9 @@ menuconfig EXPERT
select DEBUG_KERNEL
help
  This option allows certain base kernel options and settings
-  to be disabled or tweaked. This is for specialized
-  environments which can tolerate a "non-standard" kernel.
-  Only use this if you really know what you are doing.
+ to be disabled or tweaked. This is for specialized
+ environments which can tolerate a "non-standard" kernel.
+ Only use this if you really know what you are doing.
 
 config UID16
bool "Enable 16-bit UID system calls" if EXPERT
@@ -1439,11 +1439,11 @@ config BUG
bool "BUG() support" if EXPERT
default y
help
-  Disabling this option eliminates support for BUG and WARN, reducing
-  the size of your kernel image and potentially quietly ignoring
-  numerous fatal conditions. You should only consider disabling this
-  option for embedded systems with no facilities for reporting errors.
-  Just say Y.
+ Disabling this option eliminates support for BUG and WARN, reducing
+ the size of your kernel image and potentially quietly ignoring
+ numerous fatal conditions. You should only consider disabling this
+ option for embedded systems with no facilities for reporting errors.
+ Just say Y.
 
 config ELF_CORE
depends on COREDUMP
@@ -1459,8 +1459,8 @@ config PCSPKR_PLATFORM
select I8253_LOCK
default y
help
-  This option allows to disable the internal PC-Speaker
-  support, saving some memory.
+ This option allows to disable the internal PC-Speaker
+ support, saving some memory.
 
 config BASE_FULL
default y
diff --git a/kernel/trace/Kconfig b/kernel/trace/Kconfig
index e0

Re: [PATCH] drm/exynos: dsi: silence warning about regulators during deferred probe

2020-02-26 Thread Krzysztof Kozlowski
On Wed, 26 Feb 2020 at 11:11, Marek Szyprowski  wrote:
>
> Don't confuse user with meaningless warning about failure in getting
> regulators in case of deferred probe.

You are doing actually more than you explained here. You fixed
inaccurate error code (EPROBE_DEFER) being returned in case of
failures of getting regulators.

This change makes sense but commit message looks too innocent.

Best regards,
Krzysztof

>
> Signed-off-by: Marek Szyprowski 
> ---
>  drivers/gpu/drm/exynos/exynos_drm_dsi.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_dsi.c 
> b/drivers/gpu/drm/exynos/exynos_drm_dsi.c
> index 08a8ce3f499c..a85365c56d4d 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_dsi.c
> +++ b/drivers/gpu/drm/exynos/exynos_drm_dsi.c
> @@ -1773,8 +1773,9 @@ static int exynos_dsi_probe(struct platform_device 
> *pdev)
> ret = devm_regulator_bulk_get(dev, ARRAY_SIZE(dsi->supplies),
>   dsi->supplies);
> if (ret) {
> -   dev_info(dev, "failed to get regulators: %d\n", ret);
> -   return -EPROBE_DEFER;
> +   if (ret != -EPROBE_DEFER)
> +   dev_info(dev, "failed to get regulators: %d\n", ret);
> +   return ret;
> }
>
> dsi->clks = devm_kcalloc(dev,
> --
> 2.17.1
>
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel


Re: [PATCH] drm/bridge: sii9234: silence warning about regulators during deferred probe

2020-02-26 Thread Krzysztof Kozlowski
On Wed, 26 Feb 2020 at 11:13, Marek Szyprowski  wrote:
>
> Don't confuse user with meaningless warning about failure in getting
> regulators in case of deferred probe.
>
> Signed-off-by: Marek Szyprowski 
> ---
>  drivers/gpu/drm/bridge/sii9234.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)

Reviewed-by: Krzysztof Kozlowski 

Best regards,
Krzysztof
___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel


Re: [PATCH v2] drm/exynos: dsi: propagate error value and silence meaningless warning

2020-02-27 Thread Krzysztof Kozlowski
On Thu, Feb 27, 2020 at 08:06:37AM +0100, Marek Szyprowski wrote:
> Properly propagate error value from devm_regulator_bulk_get() and don't
> confuse user with meaningless warning about failure in getting regulators
> in case of deferred probe.
> 
> Signed-off-by: Marek Szyprowski 
> ---
> v2: rephrased commit message
> ---
>  drivers/gpu/drm/exynos/exynos_drm_dsi.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)

Reviewed-by: Krzysztof Kozlowski 

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel


Re: [RESEND PATCH v2 9/9] ath5k: Constify ioreadX() iomem argument (as in generic implementation)

2020-02-24 Thread Krzysztof Kozlowski
On Thu, Feb 20, 2020 at 10:48:33AM +0100, Jiri Slaby wrote:
> On 19. 02. 20, 18:50, Krzysztof Kozlowski wrote:
> > The ioreadX() helpers have inconsistent interface.  On some architectures
> > void *__iomem address argument is a pointer to const, on some not.
> > 
> > Implementations of ioreadX() do not modify the memory under the address
> > so they can be converted to a "const" version for const-safety and
> > consistency among architectures.
> > 
> > Signed-off-by: Krzysztof Kozlowski 
> > Acked-by: Kalle Valo 
> > ---
> >  drivers/net/wireless/ath/ath5k/ahb.c | 10 +-
> >  1 file changed, 5 insertions(+), 5 deletions(-)
> > 
> > diff --git a/drivers/net/wireless/ath/ath5k/ahb.c 
> > b/drivers/net/wireless/ath/ath5k/ahb.c
> > index 2c9cec8b53d9..8bd01df369fb 100644
> > --- a/drivers/net/wireless/ath/ath5k/ahb.c
> > +++ b/drivers/net/wireless/ath/ath5k/ahb.c
> > @@ -138,18 +138,18 @@ static int ath_ahb_probe(struct platform_device *pdev)
> >  
> > if (bcfg->devid >= AR5K_SREV_AR2315_R6) {
> > /* Enable WMAC AHB arbitration */
> > -   reg = ioread32((void __iomem *) AR5K_AR2315_AHB_ARB_CTL);
> > +   reg = ioread32((const void __iomem *) AR5K_AR2315_AHB_ARB_CTL);
> 
> While I understand why the parameter of ioread32 should be const, I
> don't see a reason for these casts on the users' side. What does it
> bring except longer code to read?

Because the argument is an int:

drivers/net/wireless/ath/ath5k/ahb.c: In function ‘ath_ahb_probe’:
drivers/net/wireless/ath/ath5k/ahb.c:141:18: warning: passing argument 1 of 
‘ioread32’ makes pointer from integer without a cast [-Wint-conversion]
   reg = ioread32(AR5K_AR2315_AHB_ARB_CTL);

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel


Re: [RESEND PATCH v2 9/9] ath5k: Constify ioreadX() iomem argument (as in generic implementation)

2020-02-24 Thread Krzysztof Kozlowski
On Mon, Feb 24, 2020 at 01:54:00PM +0100, Geert Uytterhoeven wrote:
> Hi Krzysztof,
> 
> On Mon, Feb 24, 2020 at 1:47 PM Krzysztof Kozlowski  wrote:
> > On Thu, Feb 20, 2020 at 10:48:33AM +0100, Jiri Slaby wrote:
> > > On 19. 02. 20, 18:50, Krzysztof Kozlowski wrote:
> > > > The ioreadX() helpers have inconsistent interface.  On some 
> > > > architectures
> > > > void *__iomem address argument is a pointer to const, on some not.
> > > >
> > > > Implementations of ioreadX() do not modify the memory under the address
> > > > so they can be converted to a "const" version for const-safety and
> > > > consistency among architectures.
> > > >
> > > > Signed-off-by: Krzysztof Kozlowski 
> > > > Acked-by: Kalle Valo 
> > > > ---
> > > >  drivers/net/wireless/ath/ath5k/ahb.c | 10 +-
> > > >  1 file changed, 5 insertions(+), 5 deletions(-)
> > > >
> > > > diff --git a/drivers/net/wireless/ath/ath5k/ahb.c 
> > > > b/drivers/net/wireless/ath/ath5k/ahb.c
> > > > index 2c9cec8b53d9..8bd01df369fb 100644
> > > > --- a/drivers/net/wireless/ath/ath5k/ahb.c
> > > > +++ b/drivers/net/wireless/ath/ath5k/ahb.c
> > > > @@ -138,18 +138,18 @@ static int ath_ahb_probe(struct platform_device 
> > > > *pdev)
> > > >
> > > > if (bcfg->devid >= AR5K_SREV_AR2315_R6) {
> > > > /* Enable WMAC AHB arbitration */
> > > > -   reg = ioread32((void __iomem *) AR5K_AR2315_AHB_ARB_CTL);
> > > > +   reg = ioread32((const void __iomem *) 
> > > > AR5K_AR2315_AHB_ARB_CTL);
> > >
> > > While I understand why the parameter of ioread32 should be const, I
> > > don't see a reason for these casts on the users' side. What does it
> > > bring except longer code to read?
> >
> > Because the argument is an int:
> >
> > drivers/net/wireless/ath/ath5k/ahb.c: In function ‘ath_ahb_probe’:
> > drivers/net/wireless/ath/ath5k/ahb.c:141:18: warning: passing argument 1 of 
> > ‘ioread32’ makes pointer from integer without a cast [-Wint-conversion]
> >reg = ioread32(AR5K_AR2315_AHB_ARB_CTL);
> 
> That's an argument for keeping the cast to "void __iomem *", not for
> adding the "const", right?

Yes, correct. Maybe I misunderstood the question... The const on the
other hand does not have to be in the cast. It is merely for making it
consistent with interface. It is not required. I also mentioned it in
the cover letter:
"PAtches 5-9 are optional cleanup, without actual impact"

Feel free to ignore this one if it is not worth the effort.

Best regards,
Krzysztof

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel


[RESEND PATCH v2 0/9] iomap: Constify ioreadX() iomem argument

2020-02-19 Thread Krzysztof Kozlowski
Hi,


Changes since v1

https://lore.kernel.org/lkml/1578415992-24054-1-git-send-email-k...@kernel.org/
1. Constify also ioreadX_rep() and mmio_insX(),
2. Squash lib+alpha+powerpc+parisc+sh into one patch for bisectability,
3. Add acks and reviews,
4. Re-order patches so all optional driver changes are at the end.


Description
===
The ioread8/16/32() and others have inconsistent interface among the
architectures: some taking address as const, some not.

It seems there is nothing really stopping all of them to take
pointer to const.

Patchset was only compile tested on affected architectures.  No real
testing.


volatile

There is still interface inconsistency between architectures around
"volatile" qualifier:
 - include/asm-generic/io.h:static inline u32 ioread32(const volatile void 
__iomem *addr)
 - include/asm-generic/iomap.h:extern unsigned int ioread32(const void __iomem 
*);

This is still discussed and out of scope of this patchset.


Merging
===
Multiple architectures are affected in first patch so acks are welcomed.

1. All patches depend on first patch,
2. Patches 2-4 unify the interface also in few drivers,
3. PAtches 5-9 are optional cleanup, without actual impact.


Best regards,
Krzysztof


Krzysztof Kozlowski (9):
  iomap: Constify ioreadX() iomem argument (as in generic
implementation)
  rtl818x: Constify ioreadX() iomem argument (as in generic
implementation)
  ntb: intel: Constify ioreadX() iomem argument (as in generic
implementation)
  virtio: pci: Constify ioreadX() iomem argument (as in generic
implementation)
  arc: Constify ioreadX() iomem argument (as in generic implementation)
  drm/mgag200: Constify ioreadX() iomem argument (as in generic
implementation)
  drm/nouveau: Constify ioreadX() iomem argument (as in generic
implementation)
  media: fsl-viu: Constify ioreadX() iomem argument (as in generic
implementation)
  ath5k: Constify ioreadX() iomem argument (as in generic
implementation)

 arch/alpha/include/asm/core_apecs.h   |  6 +-
 arch/alpha/include/asm/core_cia.h |  6 +-
 arch/alpha/include/asm/core_lca.h |  6 +-
 arch/alpha/include/asm/core_marvel.h  |  4 +-
 arch/alpha/include/asm/core_mcpcia.h  |  6 +-
 arch/alpha/include/asm/core_t2.h  |  2 +-
 arch/alpha/include/asm/io.h   | 12 ++--
 arch/alpha/include/asm/io_trivial.h   | 16 ++---
 arch/alpha/include/asm/jensen.h   |  2 +-
 arch/alpha/include/asm/machvec.h  |  6 +-
 arch/alpha/kernel/core_marvel.c   |  2 +-
 arch/alpha/kernel/io.c| 12 ++--
 arch/arc/plat-axs10x/axs10x.c |  4 +-
 arch/parisc/include/asm/io.h  |  4 +-
 arch/parisc/lib/iomap.c   | 72 +--
 arch/powerpc/kernel/iomap.c   | 28 
 arch/sh/kernel/iomap.c| 22 +++---
 drivers/gpu/drm/mgag200/mgag200_drv.h |  4 +-
 drivers/gpu/drm/nouveau/nouveau_bo.c  |  2 +-
 drivers/media/platform/fsl-viu.c  |  2 +-
 drivers/net/wireless/ath/ath5k/ahb.c  | 10 +--
 .../realtek/rtl818x/rtl8180/rtl8180.h |  6 +-
 drivers/ntb/hw/intel/ntb_hw_gen1.c|  2 +-
 drivers/ntb/hw/intel/ntb_hw_gen3.h|  2 +-
 drivers/ntb/hw/intel/ntb_hw_intel.h   |  2 +-
 drivers/virtio/virtio_pci_modern.c|  6 +-
 include/asm-generic/iomap.h   | 28 
 include/linux/io-64-nonatomic-hi-lo.h |  4 +-
 include/linux/io-64-nonatomic-lo-hi.h |  4 +-
 lib/iomap.c   | 30 
 30 files changed, 156 insertions(+), 156 deletions(-)

-- 
2.17.1

___
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel


[RESEND PATCH v2 1/9] iomap: Constify ioreadX() iomem argument (as in generic implementation)

2020-02-19 Thread Krzysztof Kozlowski
The ioreadX() and ioreadX_rep() helpers have inconsistent interface.  On
some architectures void *__iomem address argument is a pointer to const,
on some not.

Implementations of ioreadX() do not modify the memory under the address
so they can be converted to a "const" version for const-safety and
consistency among architectures.

Suggested-by: Geert Uytterhoeven 
Signed-off-by: Krzysztof Kozlowski 
Reviewed-by: Geert Uytterhoeven 
Reviewed-by: Arnd Bergmann 

---

Changes since v1:
1. Constify also ioreadX_rep() and mmio_insX(),
2. Squash lib+alpha+powerpc+parisc+sh into one patch for bisectability,
3. Add Geert's review.
4. Add Arnd's review.
---
 arch/alpha/include/asm/core_apecs.h   |  6 +--
 arch/alpha/include/asm/core_cia.h |  6 +--
 arch/alpha/include/asm/core_lca.h |  6 +--
 arch/alpha/include/asm/core_marvel.h  |  4 +-
 arch/alpha/include/asm/core_mcpcia.h  |  6 +--
 arch/alpha/include/asm/core_t2.h  |  2 +-
 arch/alpha/include/asm/io.h   | 12 ++---
 arch/alpha/include/asm/io_trivial.h   | 16 +++---
 arch/alpha/include/asm/jensen.h   |  2 +-
 arch/alpha/include/asm/machvec.h  |  6 +--
 arch/alpha/kernel/core_marvel.c   |  2 +-
 arch/alpha/kernel/io.c| 12 ++---
 arch/parisc/include/asm/io.h  |  4 +-
 arch/parisc/lib/iomap.c   | 72 +--
 arch/powerpc/kernel/iomap.c   | 28 +--
 arch/sh/kernel/iomap.c| 22 
 include/asm-generic/iomap.h   | 28 +--
 include/linux/io-64-nonatomic-hi-lo.h |  4 +-
 include/linux/io-64-nonatomic-lo-hi.h |  4 +-
 lib/iomap.c   | 30 +--
 20 files changed, 136 insertions(+), 136 deletions(-)

diff --git a/arch/alpha/include/asm/core_apecs.h 
b/arch/alpha/include/asm/core_apecs.h
index 0a07055bc0fe..2d9726fc02ef 100644
--- a/arch/alpha/include/asm/core_apecs.h
+++ b/arch/alpha/include/asm/core_apecs.h
@@ -384,7 +384,7 @@ struct el_apecs_procdata
}   \
} while (0)
 
-__EXTERN_INLINE unsigned int apecs_ioread8(void __iomem *xaddr)
+__EXTERN_INLINE unsigned int apecs_ioread8(const void __iomem *xaddr)
 {
unsigned long addr = (unsigned long) xaddr;
unsigned long result, base_and_type;
@@ -420,7 +420,7 @@ __EXTERN_INLINE void apecs_iowrite8(u8 b, void __iomem 
*xaddr)
*(vuip) ((addr << 5) + base_and_type) = w;
 }
 
-__EXTERN_INLINE unsigned int apecs_ioread16(void __iomem *xaddr)
+__EXTERN_INLINE unsigned int apecs_ioread16(const void __iomem *xaddr)
 {
unsigned long addr = (unsigned long) xaddr;
unsigned long result, base_and_type;
@@ -456,7 +456,7 @@ __EXTERN_INLINE void apecs_iowrite16(u16 b, void __iomem 
*xaddr)
*(vuip) ((addr << 5) + base_and_type) = w;
 }
 
-__EXTERN_INLINE unsigned int apecs_ioread32(void __iomem *xaddr)
+__EXTERN_INLINE unsigned int apecs_ioread32(const void __iomem *xaddr)
 {
unsigned long addr = (unsigned long) xaddr;
if (addr < APECS_DENSE_MEM)
diff --git a/arch/alpha/include/asm/core_cia.h 
b/arch/alpha/include/asm/core_cia.h
index c706a7f2b061..cb22991f6761 100644
--- a/arch/alpha/include/asm/core_cia.h
+++ b/arch/alpha/include/asm/core_cia.h
@@ -342,7 +342,7 @@ struct el_CIA_sysdata_mcheck {
 #define vuip   volatile unsigned int __force *
 #define vulp   volatile unsigned long __force *
 
-__EXTERN_INLINE unsigned int cia_ioread8(void __iomem *xaddr)
+__EXTERN_INLINE unsigned int cia_ioread8(const void __iomem *xaddr)
 {
unsigned long addr = (unsigned long) xaddr;
unsigned long result, base_and_type;
@@ -374,7 +374,7 @@ __EXTERN_INLINE void cia_iowrite8(u8 b, void __iomem *xaddr)
*(vuip) ((addr << 5) + base_and_type) = w;
 }
 
-__EXTERN_INLINE unsigned int cia_ioread16(void __iomem *xaddr)
+__EXTERN_INLINE unsigned int cia_ioread16(const void __iomem *xaddr)
 {
unsigned long addr = (unsigned long) xaddr;
unsigned long result, base_and_type;
@@ -404,7 +404,7 @@ __EXTERN_INLINE void cia_iowrite16(u16 b, void __iomem 
*xaddr)
*(vuip) ((addr << 5) + base_and_type) = w;
 }
 
-__EXTERN_INLINE unsigned int cia_ioread32(void __iomem *xaddr)
+__EXTERN_INLINE unsigned int cia_ioread32(const void __iomem *xaddr)
 {
unsigned long addr = (unsigned long) xaddr;
if (addr < CIA_DENSE_MEM)
diff --git a/arch/alpha/include/asm/core_lca.h 
b/arch/alpha/include/asm/core_lca.h
index 84d5e5b84f4f..ec86314418cb 100644
--- a/arch/alpha/include/asm/core_lca.h
+++ b/arch/alpha/include/asm/core_lca.h
@@ -230,7 +230,7 @@ union el_lca {
} while (0)
 
 
-__EXTERN_INLINE unsigned int lca_ioread8(void __iomem *xaddr)
+__EXTERN_INLINE unsigned int lca_ioread8(const void __iomem *xaddr)
 {
unsigned long addr = (unsigned long) xaddr;
unsigned long result, base_and_type;
@@ -266,7 +266,7 @@ __EXTERN_INLINE void lca_iowrite8(u8 b, void __iomem *xaddr)

<    1   2   3   4   5   6   7   8   9   10   >