Re: [PATCH 2/3] drm/exynos: fimc: Clock control is unused if !PM

2015-09-25 Thread Andrzej Hajda
On 09/24/2015 12:14 PM, Thierry Reding wrote: > From: Thierry Reding > > Protect the fimc_clk_ctrl() function with an #ifdef CONFIG_PM guard to > avoid "defined but not used" warnings. > > Signed-off-by: Thierry Reding Reviewed-by: Andrzej Hajda

Re: [PATCH 3/3] drm/exynos: rotator: Clock control is unused if !PM

2015-09-25 Thread Andrzej Hajda
On 09/24/2015 12:14 PM, Thierry Reding wrote: > From: Thierry Reding > > Protect the rotator_clk_crtl() function with an #ifdef CONFIG_PM guard > to avoid "defined but not used" warnings. > > Signed-off-by: Thierry Reding Reviewed-by: Andrzej Hajda

Re: [PATCH 1/3] drm/exynos: Suspend/resume is unused if !PM

2015-09-25 Thread Andrzej Hajda
On 09/24/2015 12:14 PM, Thierry Reding wrote: > From: Thierry Reding > > Protect the suspend and resume callbacks with an #ifdef CONFIG_PM_SLEEP > guard to avoid "defined but not used" warnings. > > Signed-off-by: Thierry Reding The best solution would

[PATCH 00/16] drm/exynos/hdmi: refactoring/cleanup patches

2015-09-25 Thread Andrzej Hajda
Hi, This is another set of cleanup/improvement patches for HDMI. The patchset is based on exynos-drm-next. It was tested on Universal and Odroid U3. Regards Andrzej Andrzej Hajda (15): drm/exynos/hdmi: remove support for deprecated compatible dt-bindings: remove deprecated compatible

[PATCH 05/16] drm/exynos/hdmi: simplify HDMI-PHY power sequence

2015-09-25 Thread Andrzej Hajda
Currently driver tries to set specific HDMI-PHY registers in three situations: - before reset, - before power off, - after applying HDMI-PHY configuration. First two cases seems to be unnecessary - register contents will be lost anyway. The third case can be merged with HDMI-PHY configuration by

[PATCH 06/16] drm/exynos/hdmi: replace all writeb with writel

2015-09-25 Thread Andrzej Hajda
Registers are 32-bit, even if only lower 8-bits are used. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_hdmi.c

[PATCH 09/16] drm/exynos/hdmi: use constant size array for regulators

2015-09-25 Thread Andrzej Hajda
Driver always uses the same number of regulators, so there is no point in dynamic allocation. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 25 + 1 file changed, 9 insertions(+), 16 deletions(-) diff --git

[PATCH 13/16] drm/exynos/hdmi: convert container_of macro to inline function

2015-09-25 Thread Andrzej Hajda
Inline function is safer than macro, also the name has been changed to be consistent with other inline function encoder_to_hdmi. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) diff

[PATCH 08/16] drm/exynos/hdmi: use optional regulator_get for hdmi-en

2015-09-25 Thread Andrzej Hajda
hdmi-en is an optional regulator so it should be better handled by devm_regulator_get_optional call. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 24 +++- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git

[PATCH 04/16] drm/exynos/hdmi: move PLL stabilization check code to separate function

2015-09-25 Thread Andrzej Hajda
The patch moves PLL stabilization check to separate function, adjust timeout parameters and de-duplicates code common for both HW variants. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 68 ++-- 1 file changed, 26

[PATCH 03/16] drm/exynos/hdmi: use mappings for registers with IP dependent address

2015-09-25 Thread Andrzej Hajda
Some registers resides at different offsets depending on device version. This patch adds infrastructure for mapping such registers to proper address based on hdmi_type. It adds also mappings to some registers. Signed-off-by: Andrzej Hajda ---

[PATCH 10/16] drm/exynos/hdmi: simplify clock re-parenting

2015-09-25 Thread Andrzej Hajda
Driver tries to disable sclk_hdmi during re-parenting, to avoid possible glitches. It is ineffective as the clock is used also by other devices (mixer). Anyway driver works without disabling sclk_hdmi. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c |

[PATCH 15/16] drm/exynos/hdmi: remove unused field

2015-09-25 Thread Andrzej Hajda
The patch removes unused hdmi_context field. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos_hdmi.c b/drivers/gpu/drm/exynos/exynos_hdmi.c index a4ec8b9..b0f5ff4 100644

[PATCH 16/16] drm: exynos: mixer: fix using usleep() in atomic context

2015-09-25 Thread Andrzej Hajda
From: Tomasz Stanislawski This patch fixes calling usleep_range() after taking reg_slock using spin_lock_irqsave(). The mdelay() is used instead. Waiting in atomic context is not the best idea in general. Hopefully, waiting occurs only when Video Processor fails to

[PATCH 07/16] drm/exynos/hdmi: fix removal order

2015-09-25 Thread Andrzej Hajda
DRM device should be destroyed before releasing resources. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_hdmi.c

[PATCH 12/16] drm/exynos/hdmi: remove deprecated hdmi_resources structure

2015-09-25 Thread Andrzej Hajda
hdmi_resources structure was filled by old platform data code and is not necessary anymore. The patch removes it at groups together resource related fields in hdmi_context. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 105

[PATCH 11/16] drm/exynos/hdmi: convert to gpiod API

2015-09-25 Thread Andrzej Hajda
The patch converts API to gpiod and moves initialization code to hdmi_resources_init. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 37 ++-- 1 file changed, 14 insertions(+), 23 deletions(-) diff --git

[PATCH 02/16] dt-bindings: remove deprecated compatible string from exynos-hdmi

2015-09-25 Thread Andrzej Hajda
samsung,exynos5-hdmi compatible was marked as deprecated in Jun 2013. It was never used since then. Signed-off-by: Andrzej Hajda --- Documentation/devicetree/bindings/video/exynos_hdmi.txt | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git

[PATCH 01/16] drm/exynos/hdmi: remove support for deprecated compatible

2015-09-25 Thread Andrzej Hajda
This compatible was marked as deprecated in Jun 2013 and it is not used since then. Additionally its driver data points to wrong pll settings, so it cannot work anyway. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_hdmi.c | 10 -- 1 file changed, 10

[PATCH] ARM: dts: exynos4412-trats2: remove regulator-compatible usage

2015-09-25 Thread Javier Martinez Canillas
The regulator-compatible property from the regulator DT binding was deprecated and the correct approach is to use the node's name. This patch has no functional changes but by not using a deprecated property, new DTS based on this one will not carry the same issue. Signed-off-by: Javier Martinez