Re: linux-next: build failure after merge of the drm-misc tree

2020-10-14 Thread Paul Cercueil
Hi Stephen, Le lun. 12 oct. 2020 à 15:24, Stephen Rothwell a écrit : Hi all, On Thu, 8 Oct 2020 15:42:02 +1100 Stephen Rothwell wrote: On Thu, 8 Oct 2020 14:09:03 +1100 Stephen Rothwell wrote: > > After merging the drm-misc tree, today's linux-next build (x86_64 > allmodconfig)

Re: linux-next: build failure after merge of the drm-misc tree

2020-10-13 Thread Paul Cercueil
Hi Stephen, Le lun. 12 oct. 2020 à 15:24, Stephen Rothwell a écrit : Hi all, On Thu, 8 Oct 2020 15:42:02 +1100 Stephen Rothwell wrote: On Thu, 8 Oct 2020 14:09:03 +1100 Stephen Rothwell wrote: > > After merging the drm-misc tree, today's linux-next build (x86_64 > allmodconfig)

Re: [PATCH] drm/ingenic: Fix bad revert

2020-10-13 Thread Paul Cercueil
Le lun. 12 oct. 2020 à 16:10, Daniel Vetter a écrit : On Mon, Oct 12, 2020 at 12:25:09PM +0200, Paul Cercueil wrote: Fix a badly reverted commit. The revert commit was cherry-picked from drm-misc-next to drm-misc-next-fixes, and in the process some unrelated code was added. Fixes

[PATCH] drm/ingenic: Fix bad revert

2020-10-13 Thread Paul Cercueil
Fix a badly reverted commit. The revert commit was cherry-picked from drm-misc-next to drm-misc-next-fixes, and in the process some unrelated code was added. Fixes: a3fb64c00d44 "Revert "gpu/drm: ingenic: Add option to mmap GEM buffers cached"" Signed-off-by: Paul Cercueil

Re: [PATCH] Revert "gpu/drm: ingenic: Add option to mmap GEM buffers cached"

2020-10-06 Thread Paul Cercueil
Hi, Le lun. 5 oct. 2020 à 16:05, Daniel Vetter a écrit : On Mon, Oct 05, 2020 at 11:01:50PM +1100, Stephen Rothwell wrote: Hi Paul, On Sun, 04 Oct 2020 22:11:23 +0200 Paul Cercueil wrote: > > Pushed to drm-misc-next with the changelog fix, thanks. > > Stephen: > Now

Re: [PATCH] Revert "gpu/drm: ingenic: Add option to mmap GEM buffers cached"

2020-10-05 Thread Paul Cercueil
Hi, Le dim. 4 oct. 2020 à 21:59, Sam Ravnborg a écrit : Hi Paul. On Sun, Oct 04, 2020 at 04:17:58PM +0200, Paul Cercueil wrote: This reverts commit 37054fc81443cc6a8c3a38395f384412b8373d82. In the changelog please refer to commits like this: 37054fc81443 ("gpu/drm: ingenic: Add o

[PATCH] Revert "gpu/drm: ingenic: Add option to mmap GEM buffers cached"

2020-10-05 Thread Paul Cercueil
. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 114 +- drivers/gpu/drm/ingenic/ingenic-drm.h | 4 - drivers/gpu/drm/ingenic/ingenic-ipu.c | 12 +-- 3 files changed, 4 insertions(+), 126 deletions(-) diff --git a/drivers/gpu/drm/ingenic

Re: linux-next: build failure after merge of the drm tree

2020-10-01 Thread Paul Cercueil
Le mer. 30 sept. 2020 à 18:11, Christoph Hellwig a écrit : On Wed, Sep 30, 2020 at 03:33:13PM +0200, Paul Cercueil wrote: One thing missing for remap_pfn_range(), I have no alternative for this: vma->vm_page_prot = dma_pgprot(dev, vma->vm_page_prot, DMA_ATTR_NON_CONSISTENT);

[PATCH 3/3] drm/ingenic: Alloc cached GEM buffers with dma_alloc_noncoherent

2020-10-01 Thread Paul Cercueil
dma_alloc_noncoherent() if non-coherent memory is what we want. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 48 ++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic-drm

Re: linux-next: build failure after merge of the drm tree

2020-10-01 Thread Paul Cercueil
Le mer. 30 sept. 2020 à 18:40, Christoph Hellwig a écrit : On Wed, Sep 30, 2020 at 06:39:18PM +0200, Paul Cercueil wrote: dma_alloc_pages gives you cached memory, so you can't just use an uncached protection for the userspace mmap here. If you want uncached memory you need to use

Re: linux-next: build failure after merge of the drm tree

2020-10-01 Thread Paul Cercueil
Hi Christoph, Le mer. 30 sept. 2020 à 11:02, Christoph Hellwig a écrit : On Mon, Sep 28, 2020 at 03:31:28PM +0200, Paul Cercueil wrote: It's allocated with dma_alloc_wc, but then it's only accessed as non-coherent. Anyway, for the time being I guess you could revert 37054fc81443. But I

[PATCH 2/3] drm/ingenic: Update code to mmap GEM buffers cached

2020-10-01 Thread Paul Cercueil
The DMA API changed at the same time commit 37054fc81443 ("gpu/drm: ingenic: Add option to mmap GEM buffers cached") was added. Rework the code to work with the new DMA API. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 24 +++ 1 fi

[PATCH 1/3] drm: Add and export function drm_gem_cma_create_noalloc

2020-10-01 Thread Paul Cercueil
Add and export the function drm_gem_cma_create_noalloc(), which is just __drm_gem_cma_create() renamed. This function can be used by drivers that need to create a GEM object without allocating the backing memory. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/drm_gem_cma_helper.c | 11

Re: linux-next: build failure after merge of the drm tree

2020-09-29 Thread Paul Cercueil
Hi Christoph, Le lun. 28 sept. 2020 à 8:04, Christoph Hellwig a écrit : On Mon, Sep 28, 2020 at 01:54:05PM +1000, Stephen Rothwell wrote: Hi all, After merging the drm tree, today's linux-next build (x86_64 allmodconfig) failed like this: The driver needs to switch do

Re: linux-next: build failure after merge of the drm tree

2020-09-29 Thread Paul Cercueil
Le lun. 28 sept. 2020 à 14:10, Christoph Hellwig a écrit : On Mon, Sep 28, 2020 at 01:46:55PM +0200, Paul Cercueil wrote: dma_mmap_attrs can only be used on allocations from dma_mmap_attrs with the same attrs. As there is no allocation using DMA_ATTR_NON_CONSISTENT in the drm core

Re: linux-next: build failure after merge of the drm tree

2020-09-29 Thread Paul Cercueil
Le lun. 28 sept. 2020 à 13:34, Christoph Hellwig a écrit : On Mon, Sep 28, 2020 at 12:15:56PM +0200, Paul Cercueil wrote: Hi Christoph, Le lun. 28 sept. 2020 à 8:04, Christoph Hellwig a écrit : On Mon, Sep 28, 2020 at 01:54:05PM +1000, Stephen Rothwell wrote: Hi all, After

Re: [PATCH v2 0/7] Ingenic-drm improvements + new pixel formats

2020-09-28 Thread Paul Cercueil
Hi, Le sam. 26 sept. 2020 à 20:25, Sam Ravnborg a écrit : Hi Paul. On Sat, Sep 26, 2020 at 07:04:54PM +0200, Paul Cercueil wrote: Hi, This is a V2 of my small patchset "Small improvements to ingenic-drm" that I sent about two weeks ago. In that time, I worked on new improv

[PATCH v3 1/1] drm/ingenic: Add support for paletted 8bpp

2020-09-28 Thread Paul Cercueil
On JZ4725B and newer, the F0 plane supports paletted 8bpp with a 256-entry palette. Add support for it. v3: Only accept a full 256-entry palette. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 66 +-- 1 file changed, 62 insertions(+), 4

[PATCH v3 0/1] 8bpp support for Ingenic-drm

2020-09-28 Thread Paul Cercueil
mplete 256-entry palette is accepted. Cheers, -Paul Paul Cercueil (1): drm/ingenic: Add support for paletted 8bpp drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 66 +-- 1 file changed, 62 insertions(+), 4 deletions(-) -- 2.28.0 ___

[PATCH v2 4/7] drm/ingenic: Support handling different pixel formats in F0/F1 planes

2020-09-28 Thread Paul Cercueil
in JZ4725B, 30bpp was added in JZ4770. Prepare the inclusion of paletted 8bpp, 24bpp and 30bpp support by having separate pixel format lists for F0 and F1 planes. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 57 +++ 1 file changed, 47

[PATCH v2 0/7] Ingenic-drm improvements + new pixel formats

2020-09-28 Thread Paul Cercueil
ed, I kept your acked-by on them, please tell me if that's OK. Cheers, -Paul Paul Cercueil (7): drm/ingenic: Reset pixclock rate when parent clock rate changes drm/ingenic: Add support for reserved memory drm/ingenic: Alloc F0 and F1 DMA descriptors at once drm/ingenic: Support handling diffe

[PATCH v2 6/7] drm/ingenic: Add support for 30-bit modes

2020-09-28 Thread Paul Cercueil
Starting from the JZ4760 SoC, the primary and overlay planes support 30-bit pixel modes (10 bits per color component). Add support for these in the ingenic-drm driver. Signed-off-by: Paul Cercueil Acked-by: Sam Ravnborg --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 8 drivers/gpu

Re: [PATCH 2/3] drm/ingenic: Reset pixclock rate when parent clock rate changes

2020-09-28 Thread Paul Cercueil
Hi Sam, Le jeu. 24 sept. 2020 à 22:22, Sam Ravnborg a écrit : Hi Paul. On Tue, Sep 15, 2020 at 02:38:17PM +0200, Paul Cercueil wrote: Old Ingenic SoCs can overclock very well, up to +50% of their nominal clock rate, whithout requiring overvolting or anything like that, just by changing

[PATCH v2 2/7] drm/ingenic: Add support for reserved memory

2020-09-28 Thread Paul Cercueil
fine provided the kernel configuration is sane. Signed-off-by: Paul Cercueil Acked-by: Sam Ravnborg --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic

Re: [PATCH v3 1/1] drm/ingenic: Add support for paletted 8bpp

2020-09-28 Thread Paul Cercueil
Le dim. 27 sept. 2020 à 22:27, Sam Ravnborg a écrit : On Sun, Sep 27, 2020 at 09:36:45PM +0200, Paul Cercueil wrote: On JZ4725B and newer, the F0 plane supports paletted 8bpp with a 256-entry palette. Add support for it. v3: Only accept a full 256-entry palette. Signed-off-by: Paul

[PATCH v2 1/7] drm/ingenic: Reset pixclock rate when parent clock rate changes

2020-09-28 Thread Paul Cercueil
Signed-off-by: Paul Cercueil Acked-by: Sam Ravnborg --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 61 ++- 1 file changed, 60 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic-drm-drv.c index 937d080f5d06

[PATCH v2 5/7] drm/ingenic: Add support for paletted 8bpp

2020-09-28 Thread Paul Cercueil
On JZ4725B and newer, the F0 plane supports paletted 8bpp with a 256-entry palette. Add support for it. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 60 +-- 1 file changed, 56 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/ingenic

[PATCH v2 7/7] drm/ingenic: Add support for 24-bit modes

2020-09-28 Thread Paul Cercueil
Starting from the JZ4725B SoC, the primary and overlay planes support 24-bit pixel modes (8 bits per color component, without dummy byte). Add support for these in the ingenic-drm driver. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 8 drivers/gpu/drm

[PATCH v2 3/7] drm/ingenic: Alloc F0 and F1 DMA descriptors at once

2020-09-28 Thread Paul Cercueil
, for an unknown reason. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 51 +-- 1 file changed, 28 insertions(+), 23 deletions(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic-drm-drv.c index d34e76f5f57d

[PATCH 0/3] Small improvements to ingenic-drm

2020-09-15 Thread Paul Cercueil
sure that there will always be space for our GEM buffers (provided they fit in the memory area). Cheers, -Paul Paul Cercueil (3): drm/ingenic: Add support for 30-bit modes drm/ingenic: Reset pixclock rate when parent clock rate changes drm/ingenic: Add support for reserved memory drivers/gpu

[PATCH 3/3] drm/ingenic: Add support for reserved memory

2020-09-15 Thread Paul Cercueil
Add support for static memory reserved from Device Tree. Since we're using GEM buffers backed by CMA, it is interesting to have an option to specify the CMA area where the GEM buffers will be allocated. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 19

[PATCH 1/3] drm/ingenic: Add support for 30-bit modes

2020-09-15 Thread Paul Cercueil
Starting from the JZ4760 SoC, the primary and overlay planes support 30-bit pixel modes (10 bits per color component). Add support for these in the ingenic-drm driver. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 41 +-- drivers/gpu/drm

[PATCH 2/3] drm/ingenic: Reset pixclock rate when parent clock rate changes

2020-09-15 Thread Paul Cercueil
clock. To counter that issue, we make sure that the panel is in VBLANK before the rate change happens, and we will then re-set the pixel clock rate afterwards, once the PLL has been changed, to be as close as possible to the pixel rate requested by the encoder. Signed-off-by: Paul Cercueil

Re: [PATCH v4] gpu/drm: ingenic: Add option to mmap GEM buffers cached

2020-09-10 Thread Paul Cercueil
Any love for my patch? I have more pending :) Thanks, -Paul Le sam. 22 août 2020 à 18:42, Paul Cercueil a écrit : Ingenic SoCs are most notably used in cheap chinese handheld gaming consoles. There, the games and applications generally render in software directly into GEM buffers

Re: 答复: [PATCH v2 6/6] drm/panel: Add Ilitek ILI9341 DBI panel driver

2020-09-07 Thread Paul Cercueil
Le dim. 30 août 2020 à 22:28, Sam Ravnborg a écrit : Hi Laurent. > > Please read the cover letter, it explains why it's done this way. The > whole point of this patchset is to merge DSI and DBI frameworks in a > way that can be maintained. I think this proves the point that the

Re: 答复: [PATCH v2 6/6] drm/panel: Add Ilitek ILI9341 DBI panel driver

2020-08-31 Thread Paul Cercueil
Hi Leon, Le dim. 30 août 2020 à 16:36, 何小龙 (Leon He) a écrit : +struct ili9341 { + struct drm_panel panel; + struct mipi_dsi_device *dsi; + const struct ili9341_pdata *pdata; + + struct gpio_desc*reset_gpiod; + u32 rotation; +}; + Hi Paul, you

Re: [PATCH v2 2/2] drm/ingenic: Fix driver not probing when IPU port is missing

2020-08-31 Thread Paul Cercueil
Le dim. 30 août 2020 à 21:21, Ezequiel Garcia a écrit : Hi Paul, On Thu, 27 Aug 2020 at 09:04, Paul Cercueil wrote: Even if support for the IPU was compiled in, we may run on a device (e.g. the Qi LB60) where the IPU is not available, or simply with an old devicetree without

Re: [PATCH v2 1/2] drm/ingenic: Fix leak of device_node pointer

2020-08-31 Thread Paul Cercueil
Hi Sam, Le sam. 29 août 2020 à 23:07, Sam Ravnborg a écrit : On Thu, Aug 27, 2020 at 01:44:03PM +0200, Paul Cercueil wrote: of_graph_get_remote_node() requires of_node_put() to be called on the device_node pointer when it's no more in use. Fixes: fc1acf317b01 ("drm/ingenic: Add su

[PATCH v2 1/2] drm/ingenic: Fix leak of device_node pointer

2020-08-28 Thread Paul Cercueil
of_graph_get_remote_node() requires of_node_put() to be called on the device_node pointer when it's no more in use. Fixes: fc1acf317b01 ("drm/ingenic: Add support for the IPU") Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 1 + 1 file changed, 1 insertio

[PATCH v2 2/2] drm/ingenic: Fix driver not probing when IPU port is missing

2020-08-28 Thread Paul Cercueil
in devicetree (but then IPU support is disabled of course). v2: Take a different approach Fixes: fc1acf317b01 ("drm/ingenic: Add support for the IPU") Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 19 +++ 1 file changed, 11 insertions(+), 8

[PATCH] drm/ingenic: Fix driver not probing when IPU port is missing

2020-08-27 Thread Paul Cercueil
in devicetree (but then IPU support is disabled of course). Fixes: fc1acf317b01 ("drm/ingenic: Add support for the IPU") Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 23 --- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/d

Re: drm/bridge: Synopsys DW-HDMI bridge driver for the Ingenic JZ4780 (was Re: Specialising the Synopsys DW-HDMI bridge driver for the Ingenic JZ4780)

2020-08-25 Thread Paul Cercueil
Le lun. 24 août 2020 à 14:38, Ezequiel Garcia a écrit : On Mon, 24 Aug 2020 at 13:05, H. Nikolaus Schaller wrote: Hi Ezequiel, > Am 24.08.2020 um 15:46 schrieb Ezequiel Garcia : > > On Fri, 21 Aug 2020 at 19:24, Paul Cercueil wrote: >> >> >> >

[PATCH v2 2/6] drm: dsi: Let host and device specify supported bus

2020-08-24 Thread Paul Cercueil
ult to MIPI_DCS_BUS_TYPE_DSI if the bitmask is not populated. - Create a 'enum mipi_dcs_bus_type' instead of macros - Rename values to avoid confusion about SPI modes Signed-off-by: Paul Cercueil --- drivers/gpu/drm/drm_mipi_dsi.c | 9 + include/drm/drm_mipi_dsi.h |

[PATCH v2 6/6] drm/panel: Add Ilitek ILI9341 DBI panel driver

2020-08-24 Thread Paul Cercueil
This driver is for the Ilitek ILI9341 based YX240QV29-T 2.4" 240x320 TFT LCD panel from Adafruit. v2: - Remove custom handling of backlight - Call drm_panel_disable() / drm_panel_unprepare() on module exit - drm_panel_add() is a void function now Signed-off-by: Paul Cer

[PATCH v2 0/6] DSI/DBI, panel drivers, & tinyDRM v2

2020-08-24 Thread Paul Cercueil
are} on module exit, and various small fixes. For a more detailed changelog, see the header of each individual patch. Paul Cercueil (6): dt-bindings: display: Document NewVision NV3052C DT node drm: dsi: Let host and device specify supported bus drm: Add SPI DBI host driver drm/tiny: Ad

[PATCH v4] gpu/drm: ingenic: Add option to mmap GEM buffers cached

2020-08-24 Thread Paul Cercueil
full frames v4: Avoid dma_pgprot() which is not exported. Using vm_get_page_prot() is enough in this case. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 107 +- drivers/gpu/drm/ingenic/ingenic-drm.h | 4 + drivers/gpu/drm/ingenic/ingenic

[PATCH v2 5/6] drm/panel: Add panel driver for NewVision NV3052C based LCDs

2020-08-24 Thread Paul Cercueil
stead of nv3052c_{disable,unprepare} - Silence error when backlight probe defers - Remove 'dev' field in priv structure, use drm_panel->dev instead Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/Kconfig | 9 + drivers/gpu/drm/panel/Makefile| 1 + ...

[PATCH v2 3/6] drm: Add SPI DBI host driver

2020-08-24 Thread Paul Cercueil
MIPI Display Bus Interface (DBI) SPI support + * + * Copyright 2016 Noralf Trønnes + * Copyright 2020 Paul Cercueil + */ + +#include +#include +#include + +#include +#include + +#include + +struct dbi_spi { + struct mipi_dsi_host host; + struct mipi_dsi_host_ops host_ops; + + st

[PATCH v2 4/6] drm/tiny: Add TinyDRM for DSI/DBI panels

2020-08-24 Thread Paul Cercueil
is registered with it. This TinyDRM driver expects that a DCS-compliant protocol is used by the DSI/DBI panel and can only be used with these. v2: No change Signed-off-by: Paul Cercueil --- drivers/gpu/drm/tiny/Kconfig| 8 + drivers/gpu/drm/tiny/Makefile | 1 + drivers/gpu/drm/tiny

[PATCH v2 1/6] dt-bindings: display: Document NewVision NV3052C DT node

2020-08-24 Thread Paul Cercueil
description to avoid confusion about 'driver' - Use 4-space indent in example Signed-off-by: Paul Cercueil --- .../display/panel/newvision,nv3052c.yaml | 100 ++ 1 file changed, 100 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/panel/newvision

Re: drm/bridge: Synopsys DW-HDMI bridge driver for the Ingenic JZ4780 (was Re: Specialising the Synopsys DW-HDMI bridge driver for the Ingenic JZ4780)

2020-08-22 Thread Paul Cercueil
being set in particular "atomic" methods and not during probing. Also, the upstream driver has specific plane descriptors whereas my own modifications introduced dual descriptors in a slightly different way. Plus, the upstream driver doesn't support extended descriptors, as far as I am

Re: [PATCH v2 1/2] drm/panel: novatek, nt39016: Reorder calls in probe

2020-08-21 Thread Paul Cercueil
Hi Sam, Le jeu. 20 août 2020 à 17:53, Sam Ravnborg a écrit : On Thu, Aug 20, 2020 at 02:12:55PM +0200, Paul Cercueil wrote: The drm_panel_of_backlight() function must be called after drm_panel_init(), according to the function's documentation; otherwise the backlight won't be properly

[PATCH v2 0/2] NT39016 cleanup

2020-08-21 Thread Paul Cercueil
in the driver's private structure. Cheers, -Paul Paul Cercueil (2): drm/panel: novatek,nt39016: Reorder calls in probe drm/panel: novatek,nt39016: Remove 'dev' field in priv struct drivers/gpu/drm/panel/panel-novatek-nt39016.c | 16 +++- 1 file changed, 7 insertions(+), 9 deletions

[PATCH v2 2/2] drm/panel: novatek, nt39016: Remove 'dev' field in priv struct

2020-08-21 Thread Paul Cercueil
There is already a 'struct device' pointer in the drm_panel structure, that we can access easily from our priv structure, so there's no need for a separate 'dev' field there. v2: Don't initialize drm_panel->dev manually, it is done by drm_panel_init(). Signed-off-by: Paul Cercueil --- driv

[PATCH v2 1/2] drm/panel: novatek,nt39016: Reorder calls in probe

2020-08-21 Thread Paul Cercueil
The drm_panel_of_backlight() function must be called after drm_panel_init(), according to the function's documentation; otherwise the backlight won't be properly initialized. v2: New patch Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-novatek-nt39016.c | 6 +++--- 1 file changed

[PATCH v3] gpu/drm: ingenic: Add option to mmap GEM buffers cached

2020-08-21 Thread Paul Cercueil
full frames Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 108 +- drivers/gpu/drm/ingenic/ingenic-drm.h | 4 + drivers/gpu/drm/ingenic/ingenic-ipu.c | 12 ++- 3 files changed, 120 insertions(+), 4 deletions(-) diff --git a/drivers/gpu

[PATCH] drm/panel: novatek, nt39016: Remove 'dev' field in priv struct

2020-08-20 Thread Paul Cercueil
. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-novatek-nt39016.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-novatek-nt39016.c b/drivers/gpu/drm/panel/panel-novatek-nt39016.c index 39f7be679da5..292ad1d58313 100644

[PATCH 2/5] drm/panel: novatek, nt39016: Add missing CR to error messages

2020-08-11 Thread Paul Cercueil
If you pass a string that is not terminated with a carriage return to dev_err(), it will eventually be printed with a carriage return, but not right away, since the kernel will wait for a pr_cont(). Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-novatek-nt39016.c | 18

[PATCH 3/5] drm/panel: simple: Convert sharp, ls020b1dd01d from timings to videomode

2020-08-11 Thread Paul Cercueil
Convert the Sharp LS020B1DD01D panel entry from using a struct display_timing to using a struct drm_display_mode, as display_timing seems to be the old and legacy format. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-simple.c | 28 +++- 1 file changed, 15

[PATCH 0/5] drm/panel: A few cleanups and improvements

2020-08-11 Thread Paul Cercueil
, to make it use 'struct drm_display_mode' instead of 'struct display_timing', modify the timings to get a perfect 60.00 Hz rate, and add a 50 Hz mode. Cheers, -Paul Paul Cercueil (5): drm/panel: novatek,nt39016: Handle backlight the standard way drm/panel: novatek,nt39016: Add missing CR

[PATCH 1/5] drm/panel: novatek, nt39016: Handle backlight the standard way

2020-08-11 Thread Paul Cercueil
Instead of manipulating the backlight directly in this driver, register it in the probe using drm_panel_of_backlight() and let the drm_panel framework code handle it. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-novatek-nt39016.c | 16 1 file changed, 4

[PATCH 5/5] drm/panel: simple: Add 50Hz mode for sharp,ls020b1dd01d

2020-08-11 Thread Paul Cercueil
Add a perfect 50.00 Hz frame rate mode to the list of available modes for the Sharp LS020B1DD01D panel. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-simple.c | 12 1 file changed, 12 insertions(+) diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm

[PATCH 4/5] drm/panel: simple: Tweak timings of sharp, ls020b1dd01d for perfect 60Hz

2020-08-11 Thread Paul Cercueil
Modify the video mode in order to obtain a perfect 60.00 Hz frame rate using a 3 MHz pixel clock. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-simple.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-simple.c b

Re: [PATCH v2 3/3] drm/ingenic: ipu: Only enable clock when needed

2020-07-31 Thread Paul Cercueil
Le jeu. 30 juil. 2020 à 17:29, Sam Ravnborg a écrit : On Thu, Jul 30, 2020 at 04:48:30PM +0200, Paul Cercueil wrote: Instead of keeping the IPU clock enabled constantly, enable and disable it on demand, when the IPU plane is used. That way, we won't use any extra power when the IPU

[PATCH v2 0/3] More IPU cleanups v2

2020-07-31 Thread Paul Cercueil
Patch [1/3] unchanged. Patches [2/3] and [3/3] have had their commit message slightly modified, but the patches themselves are the same as before. Cheers, -Paul Paul Cercueil (3): drm/ingenic: ipu: Only restart manually on older SoCs drm/ingenic: ipu: Remove YUV422 from supported formats

[PATCH v2 1/3] drm/ingenic: ipu: Only restart manually on older SoCs

2020-07-31 Thread Paul Cercueil
frame restart signal. Reviewed-by: Sam Ravnborg Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-ipu.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-ipu.c b/drivers/gpu/drm/ingenic/ingenic-ipu.c index 7a0a8bd865d3

[PATCH v2 2/3] drm/ingenic: ipu: Remove YUV422 from supported formats on JZ4725B

2020-07-31 Thread Paul Cercueil
this issue by removing support for YUV 4:2:2 on the IPU of the JZ4725B. v2: Update commit message (remove the "crash beyond repair" bit) Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-ipu.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/ingen

[PATCH v2 3/3] drm/ingenic: ipu: Only enable clock when needed

2020-07-31 Thread Paul Cercueil
Instead of keeping the IPU clock enabled constantly, enable and disable it on demand, when the IPU plane is used. That way, we won't use any extra power when the IPU is not used. v2: Explain the reason of this patch Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-ipu.c | 23

[PATCH 3/3] drm/ingenic: ipu: Only enable clock when needed

2020-07-30 Thread Paul Cercueil
Instead of keeping the IPU clock enabled constantly, enable and disable it on demand, when the IPU plane is used. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-ipu.c | 23 --- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm

[PATCH 2/3] drm/ingenic: ipu: Remove YUV422 from supported formats on JZ4725B

2020-07-30 Thread Paul Cercueil
around, address this issue by removing support for YUV 4:2:2 on the IPU of the JZ4725B. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-ipu.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/ingenic/ingenic-ipu.c b/drivers/gpu/drm/ingenic/ingenic-ipu.c index

[PATCH 1/3] drm/ingenic: ipu: Only restart manually on older SoCs

2020-07-30 Thread Paul Cercueil
frame restart signal. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-ipu.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-ipu.c b/drivers/gpu/drm/ingenic/ingenic-ipu.c index 7a0a8bd865d3..7eae56fa92ea 100644

[PATCH 0/3] More ingenic-drm IPU cleanups

2020-07-30 Thread Paul Cercueil
. Cheers, -Paul Paul Cercueil (3): drm/ingenic: ipu: Only restart manually on older SoCs drm/ingenic: ipu: Remove YUV422 from supported formats on JZ4725B drm/ingenic: ipu: Only enable clock when needed drivers/gpu/drm/ingenic/ingenic-ipu.c | 38 +++ 1 file changed

Re: [PATCH 0/2] Small cleanups to ingenic-drm driver

2020-07-29 Thread Paul Cercueil
Le mer. 29 juil. 2020 à 0:00, dan...@ffwll.ch a écrit : On Tue, Jul 28, 2020 at 10:17:36PM +0200, Sam Ravnborg wrote: Hi Paul. On Tue, Jul 28, 2020 at 05:16:39PM +0200, Paul Cercueil wrote: > Here are a few cleanups to the ingenic-drm driver. > - some error paths were missing an

[PATCH 2/2] drm/ingenic: Validate mode in a .mode_valid callback

2020-07-28 Thread Paul Cercueil
Validate modes in the drm_crtc_helper_funcs.mode_valid() callback, which is designed for this purpose, instead of doing it in drm_crtc_helper_funcs.atomic_check(). Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 34 +-- 1 file changed, 20

[PATCH 1/2] drm/ingenic: Handle errors of drm_atomic_get_plane_state

2020-07-28 Thread Paul Cercueil
drm_atomic_get_plane_state() can return errors, so we need to handle these. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic-drm

[PATCH 0/2] Small cleanups to ingenic-drm driver

2020-07-28 Thread Paul Cercueil
Here are a few cleanups to the ingenic-drm driver. - some error paths were missing and have been added; - the mode validation has been moved to the .mode_valid helper callback. Cheers, -Paul Paul Cercueil (2): drm/ingenic: Handle errors of drm_atomic_get_plane_state drm/ingenic: Validate

[PATCH 4/6] drm/panel: Add panel driver for NewVision NV3052C based LCDs

2020-07-27 Thread Paul Cercueil
This driver supports the NewVision NV3052C based LCDs. Right now, it only supports the LeadTek LTK035C5444T 2.4" 640x480 TFT LCD panel, which can be found in the Anbernic RG-350M handheld console. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/Kconfig | 9 + dr

[PATCH 3/6] drm/bridge: Add SPI DBI host driver

2020-07-27 Thread Paul Cercueil
by a separate GPIO. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/bridge/Kconfig | 8 + drivers/gpu/drm/bridge/Makefile | 1 + drivers/gpu/drm/bridge/dbi-spi.c | 261 +++ 3 files changed, 270 insertions(+) create mode 100644 drivers/gpu/drm/bridge/dbi-spi.c

[PATCH 2/6] drm: dsi: Let host and device specify supported bus

2020-07-27 Thread Paul Cercueil
with. The DSI host driver can then use the information provided by the DBI/DSI device driver, such as the bus type and the number of lanes, to configure its hardware properly. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/drm_mipi_dsi.c | 9 + include/drm/drm_mipi_dsi.h | 12

[PATCH 6/6] drm/panel: Add Ilitek ILI9341 DBI panel driver

2020-07-27 Thread Paul Cercueil
This driver is for the Ilitek ILI9341 based YX240QV29-T 2.4" 240x320 TFT LCD panel from Adafruit. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/Kconfig| 9 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-ilitek-ili9341.c

Re: [PATCH 3/6] drm/bridge: Add SPI DBI host driver

2020-07-27 Thread Paul Cercueil
Hi Laurent, Le lun. 27 juil. 2020 à 20:06, Laurent Pinchart a écrit : Hi Paul, Thank you for the patch. On Mon, Jul 27, 2020 at 06:46:10PM +0200, Paul Cercueil wrote: This driver will register a DBI host driver for panels connected over SPI. DBI types c1 and c3 are supported. C1

[PATCH 0/6] DBI/DSI, panel drivers, and tinyDRM compat

2020-07-27 Thread Paul Cercueil
afruit,yx240qv29" must be added to the dbi-spi bridge driver (unless a custom rule is added for a "dbi-spi" fallback compatible string). I still think that it's a small price to pay to avoid breaking the Device Tree bindings. Feedback welcome. Cheers, -Paul Paul Cercueil (6): dt-binding

[PATCH 5/6] drm/tiny: Add TinyDRM for DSI/DBI panels

2020-07-27 Thread Paul Cercueil
is registered with it. This TinyDRM driver expects that a DCS-compliant protocol is used by the DSI/DBI panel and can only be used with these. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/tiny/Kconfig| 8 + drivers/gpu/drm/tiny/Makefile | 1 + drivers/gpu/drm/tiny/tiny-dsi.c | 266

Re: [PATCH 3/6] drm/bridge: Add SPI DBI host driver

2020-07-27 Thread Paul Cercueil
Hi Sam, Le lun. 27 juil. 2020 à 22:31, Sam Ravnborg a écrit : Hi Paul. On Mon, Jul 27, 2020 at 06:46:10PM +0200, Paul Cercueil wrote: This driver will register a DBI host driver for panels connected over SPI. So this is actually a MIPI DBI host driver. I personally would love to have

Re: [PATCH 2/6] drm: dsi: Let host and device specify supported bus

2020-07-27 Thread Paul Cercueil
Hi Laurent, Le lun. 27 juil. 2020 à 20:02, Laurent Pinchart a écrit : Hi Paul, Thank you for the patch. On Mon, Jul 27, 2020 at 06:46:09PM +0200, Paul Cercueil wrote: The current MIPI DSI framework can very well be used to support MIPI DBI panels. In order to add support for the various

[PATCH 1/6] dt-bindings: display: Document NewVision NV3052C DT node

2020-07-27 Thread Paul Cercueil
Add documentation for the Device Tree node for LCD panels based on the NewVision NV3052C controller. Signed-off-by: Paul Cercueil --- .../display/panel/newvision,nv3052c.yaml | 69 +++ 1 file changed, 69 insertions(+) create mode 100644 Documentation/devicetree/bindings

Re: [bug report] drm/ingenic: Add support for the IPU

2020-07-21 Thread Paul Cercueil
Hi Dan, Le lun. 20 juil. 2020 à 10:22, dan.carpen...@oracle.com a écrit : Hello Paul Cercueil, The patch fc1acf317b01: "drm/ingenic: Add support for the IPU" from Jul 16, 2020, leads to the following static checker warning: drivers/gpu/drm/ingenic/ingenic-drm

Re: [PATCH] drm/ingenic: Silence uninitialized-variable warning

2020-07-20 Thread Paul Cercueil
Hi Sam, Le dim. 19 juil. 2020 à 12:23, Sam Ravnborg a écrit : Hi Paul. On Sun, Jul 19, 2020 at 11:38:34AM +0200, Paul Cercueil wrote: Silence compiler warning about used but uninitialized 'ipu_state' variable. In practice, the variable would never be used when uninitialized

[PATCH] drm/ingenic: Silence uninitialized-variable warning

2020-07-20 Thread Paul Cercueil
lue to NULL. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic-drm-drv.c index b6d946fbeaf5..ada990a7f911 100644 --- a/driv

[PATCH v2 1/2] drm/panel-simple: Fix inverted V/H SYNC for Frida FRD350H54004 panel

2020-07-17 Thread Paul Cercueil
panel: simple: Add support for the Frida FRD350H54004 panel") Cc: sta...@vger.kernel.org # v5.5 Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-simple.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/p

[PATCH v3 10/12] drm/ingenic: Add support for the IPU

2020-07-17 Thread Paul Cercueil
a bit more code comments Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/Kconfig | 11 + drivers/gpu/drm/ingenic/Makefile | 3 +- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 171 - drivers/gpu/drm/ingenic/ingenic-drm.h | 12 + drivers/gpu/drm/ingenic

[PATCH v3 01/12] drm/ingenic: Fix incorrect assumption about plane->index

2020-07-17 Thread Paul Cercueil
7xx SoCs") Signed-off-by: Paul Cercueil Acked-by: Sam Ravnborg --- drivers/gpu/drm/ingenic/ingenic-drm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm.c b/drivers/gpu/drm/ingenic/ingenic-drm.c index deb37b4a8e91..606d8acb0954 100644 ---

[PATCH v3 03/12] dt-bindings: display: Add ingenic,ipu.yaml

2020-07-17 Thread Paul Cercueil
Add documentation of the Device Tree bindings for the Image Processing Unit (IPU) found in most Ingenic SoCs. v2: Add missing 'const' in items list v3: No change Signed-off-by: Paul Cercueil Reviewed-by: Rob Herring Acked-by: Sam Ravnborg --- .../bindings/display/ingenic,ipu.yaml

[PATCH v3 07/12] drm/ingenic: Move register definitions to ingenic-drm.h

2020-07-17 Thread Paul Cercueil
Move the register definitions to ingenic-drm.h, to keep ingenic-drm-drv.c tidy. v2: Fix SPDX license tag v3: No change Signed-off-by: Paul Cercueil Acked-by: Sam Ravnborg --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 116 +--- drivers/gpu/drm/ingenic/ingenic-drm.h | 126

[PATCH v3 08/12] drm/ingenic: Use dmam_alloc_coherent()

2020-07-17 Thread Paul Cercueil
Use dmam_alloc_coherent() instead of dma_alloc_coherent(). Then we don't need to register a custom cleanup handler. v3: New patch Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 18 +++--- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git

[PATCH v3 02/12] dt-bindings: display: Convert ingenic, lcd.txt to YAML

2020-07-17 Thread Paul Cercueil
Convert the ingenic,lcd.txt to a new ingenic,lcd.yaml file. In the process, the new ingenic,jz4780-lcd compatible string has been added. v2: Add info about IPU at port@8 v3: No change Signed-off-by: Paul Cercueil Reviewed-by: Rob Herring Acked-by: Sam Ravnborg --- .../bindings/display

[PATCH v3 12/12] drm/ingenic: Bump driver to version 1.1

2020-07-17 Thread Paul Cercueil
Bump version to 1.1 and set date to 2020-07-16. v3: New patch Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic-drm

[PATCH v3 09/12] drm/ingenic: Add support for OSD mode

2020-07-17 Thread Paul Cercueil
IDs - Add a bit more code comments Signed-off-by: Paul Cercueil --- drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 303 ++ drivers/gpu/drm/ingenic/ingenic-drm.h | 35 +++ 2 files changed, 288 insertions(+), 50 deletions(-) diff --git a/drivers/gpu/drm/ingenic/ingenic

Re: [PATCH v3 01/12] drm/ingenic: Fix incorrect assumption about plane->index

2020-07-17 Thread Paul Cercueil
Hi Sam, Le jeu. 16 juil. 2020 à 19:43, Sam Ravnborg a écrit : Hi Paul. On Thu, Jul 16, 2020 at 06:38:35PM +0200, Paul Cercueil wrote: plane->index is NOT the index of the color plane in a YUV frame. Actually, a YUV frame is represented by a single drm_plane, even though it conta

[PATCH v2 2/2] drm/panel-simple: Add 50 Hz mode to the Frida FRD350H54004 panel

2020-07-17 Thread Paul Cercueil
By changing the pixel clock and the length of the back porch, it is possible to obtain a perfect 50 Hz refresh rate. v2: Rebase on drm-misc-next Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/panel-simple.c | 40 +++- 1 file changed, 27 insertions(+), 13

  1   2   3   4   >