[PATCH] drm: rcar-du: Support panels connected directly to the DPAD outputs

2019-03-02 Thread Laurent Pinchart
DPAD outputs are encoders or panels based on the number of ports of their DT node, and retrieve the corresponding type of DRM objects. For panels, additionally create panel bridge instances. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/rcar-du/rcar_du_encoder.c | 54

Re: [PATCH 12/17] drm/rcar-du: Convert to using __drm_atomic_helper_crtc_reset() for reset.

2019-03-01 Thread Laurent Pinchart
Hi Marteen, On Fri, Mar 01, 2019 at 03:47:02PM +0100, Maarten Lankhorst wrote: > Op 01-03-2019 om 15:36 schreef Laurent Pinchart: > > On Fri, Mar 01, 2019 at 03:08:20PM +0100, Maarten Lankhorst wrote: > >> Op 01-03-2019 om 14:13 schreef Laurent Pinchart: > >>> On F

Re: [PATCH 12/17] drm/rcar-du: Convert to using __drm_atomic_helper_crtc_reset() for reset.

2019-03-01 Thread Laurent Pinchart
Hi Marteen, On Fri, Mar 01, 2019 at 03:08:20PM +0100, Maarten Lankhorst wrote: > Op 01-03-2019 om 14:13 schreef Laurent Pinchart: > > On Fri, Mar 01, 2019 at 01:56:22PM +0100, Maarten Lankhorst wrote: > >> Convert rcar-du to using __drm_atomic_helper_crtc_reset(), instead of &g

Re: [PATCH 12/17] drm/rcar-du: Convert to using __drm_atomic_helper_crtc_reset() for reset.

2019-03-01 Thread Laurent Pinchart
state. I don't think the second sentence applies to this patch. > Signed-off-by: Maarten Lankhorst > Cc: Laurent Pinchart > Cc: Kieran Bingham > Cc: linux-renesas-soc@vger.kernel.org > --- > drivers/gpu/drm/rcar-du/rcar_du_crtc.c | 11 +++ > 1 file changed, 3 inse

Re: [PATCH 1/5] media: dt-bindings: media: rcar-csi2: Add r8a774a1 support

2019-03-01 Thread Laurent Pinchart
ices. It is used in conjunction > >> +with the R-Car VIN module, which provides the video capture capabilities. > >> > >> Mandatory properties > >> > >> - compatible: Must be one or more of the following > >> + - "renesas,r8a774a1-csi2" for the R8A774A1 device. > >> - "renesas,r8a7795-csi2" for the R8A7795 device. > >> - "renesas,r8a7796-csi2" for the R8A7796 device. > >> - "renesas,r8a77965-csi2" for the R8A77965 device. -- Regards, Laurent Pinchart

Re: [PATCH v2 0/6] R-Car DU DPAD support for D3 and E3

2019-02-25 Thread Laurent Pinchart
an find a merge of those two branches in my repository in the drm/du/base branch. -- Regards, Laurent Pinchart

Re: [PATCH v2 09/30] media: entity: Swap pads if route is checked from source to sink

2019-02-22 Thread Laurent Pinchart
Hi Jacopo, On Mon, Feb 18, 2019 at 10:21:07AM +0100, Jacopo Mondi wrote: > On Tue, Jan 22, 2019 at 05:20:30PM +0200, Laurent Pinchart wrote: > > On Tue, Jan 22, 2019 at 05:15:06PM +0200, Sakari Ailus wrote: > >> On Wed, Jan 16, 2019 at 12:57:43AM +0200, Laurent Pinchart wrote:

[PATCH VSP test suite] Remove dependency on a particular yavta branch

2019-02-22 Thread Laurent Pinchart
All the changes required by the VSP test suite have been integrated in the master branch of yavta. There is no need to depend on the vsp branch anymore, remove the corresponding paragraph from the documentation. Signed-off-by: Laurent Pinchart --- README | 4 1 file changed, 4 deletions

Re: [PATCH 7/7] iommu/ipmmu-vmsa: Add suspend/resume support

2019-02-20 Thread Laurent Pinchart
Hi Geert, On Wed, Feb 20, 2019 at 05:05:49PM +0100, Geert Uytterhoeven wrote: > On Wed, Feb 20, 2019 at 4:42 PM Laurent Pinchart wrote: > > On Wed, Feb 20, 2019 at 04:05:31PM +0100, Geert Uytterhoeven wrote: > >> During PSCI system suspend, R-Car Gen3 SoCs are powered down,

Re: [PATCH 5/7] iommu/ipmmu-vmsa: Move num_utlbs to SoC-specific features

2019-02-20 Thread Laurent Pinchart
et up the correct value for both R-Car Gen2 > and Gen3 SoCs. > > Note that currently no code uses this value. > > Signed-off-by: Geert Uytterhoeven Reviewed-by: Laurent Pinchart > --- > drivers/iommu/ipmmu-vmsa.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-

Re: [PATCH 7/7] iommu/ipmmu-vmsa: Add suspend/resume support

2019-02-20 Thread Laurent Pinchart
atic const struct dev_pm_ops ipmmu_pm = { > + SET_NOIRQ_SYSTEM_SLEEP_PM_OPS(NULL, ipmmu_resume_noirq) > +}; > +#define DEV_PM_OPS &ipmmu_pm > +#else > +#define DEV_PM_OPS NULL > +#endif /* CONFIG_PM_SLEEP && CONFIG_ARM_PSCI_FW */ > + > static struct platfo

Re: [PATCH 6/7] iommu/ipmmu-vmsa: Extract hardware context initialization

2019-02-20 Thread Laurent Pinchart
root, domain); > + if (ret < 0) > + return ret; > + > + domain->context_id = ret; > + > + domain->iop = alloc_io_pgtable_ops(ARM_32_LPAE_S1, &domain->cfg, > +domain); > + if (!domain->iop) { > + ipmmu_domain_free_context(domain->mmu->root, > + domain->context_id); > + return -EINVAL; > + } > > + ipmmu_context_init(domain); > return 0; > } > -- Regards, Laurent Pinchart

Re: [PATCH 4/7] iommu/ipmmu-vmsa: Make IPMMU_CTX_MAX unsigned

2019-02-20 Thread Laurent Pinchart
> Signed-off-by: Geert Uytterhoeven Reviewed-by: Laurent Pinchart > --- > drivers/iommu/ipmmu-vmsa.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/drivers/iommu/ipmmu-vmsa.c b/drivers/iommu/ipmmu-vmsa.c > index 4d07c26c97848b65..4e3134a9a52f8d8

Re: [PATCH 3/7] iommu/ipmmu-vmsa: Prepare to handle 40-bit error addresses

2019-02-20 Thread Laurent Pinchart
t; > if (!(status & (IMSTR_PF | IMSTR_TF))) > @@ -559,7 +563,7 @@ static irqreturn_t ipmmu_domain_irq(struct > ipmmu_vmsa_domain *domain) > return IRQ_HANDLED; > > dev_err_ratelimited(mmu->dev, > - "Unhandled fault: status 0x%08x iova 0x%08x\n", > + "Unhandled fault: status 0x%08x iova 0x%lx\n", > status, iova); > > return IRQ_HANDLED; -- Regards, Laurent Pinchart

Re: [PATCH 2/7] iommu/ipmmu-vmsa: Call ipmmu_ctx_write_root() instead of open coding

2019-02-20 Thread Laurent Pinchart
TX_SIZE + reg, data); > + ipmmu_ctx_write_root(domain, reg, data); This makes the code harder to read in my opinion, and I don't think it bring much optimization. > } > > /* > ----- -- Regards, Laurent Pinchart

Re: [PATCH 1/7] iommu/ipmmu-vmsa: Link IOMMUs and devices in sysfs

2019-02-20 Thread Laurent Pinchart
uot; subdirectories are empty. > Likewise, devices tied to an IOMMU do not have an "iommu" backlink. > > Make sure all links are created, on both arm32 and arm64. > > Signed-off-by: Geert Uytterhoeven Reviewed-by: Laurent Pinchart > --- > drivers/iommu/ipmm

Re: [VSP-Tests PATCH 6/7] vsp-lib: Support late queuing of buffers in yavta

2019-02-19 Thread Laurent Pinchart
Hi Kieran, On Sun, Feb 17, 2019 at 08:57:51PM +, Kieran Bingham wrote: > On 17/02/2019 12:00, Laurent Pinchart wrote: > > On Tue, Dec 04, 2018 at 03:51:45PM +, Kieran Bingham wrote: > >> Provide the pass-through option of --queue-late to vsp-runner, to request > >

Re: [VSP-Tests PATCH 5/7] vsp-lib: Allow forcing pixel perfect comparisons

2019-02-19 Thread Laurent Pinchart
Hi Kieran, On Sun, Feb 17, 2019 at 08:51:52PM +, Kieran Bingham wrote: > On 17/02/2019 11:59, Laurent Pinchart wrote: > > On Tue, Dec 04, 2018 at 03:51:44PM +, Kieran Bingham wrote: > >> Provide a means for the tester to request pixel perfect matches on tests. >

Re: [PATCH] Add support to reset device controls

2019-02-19 Thread Laurent Pinchart
main(int argc, char *argv[]) > case OPT_QUEUE_LATE: > do_queue_late = 1; > break; > + case OPT_RESET_CONTROLS: > + do_reset_controls = 1; > + break; > case OPT_REQUEUE_LAST: > do_requeue_last = 1; > break; > @@ -2185,7 +2219,10 @@ int main(int argc, char *argv[]) > set_control(&dev, ctrl_name, ctrl_value); > > if (do_list_controls) > - video_list_controls(&dev); > + video_list_controls(&dev, false); > + > + if (do_reset_controls) > + video_list_controls(&dev, true); > > if (do_enum_formats) { > printf("- Available formats:\n"); > -- > 2.17.1 > -- Regards, Laurent Pinchart

Re: [VSP-Tests PATCH 6/7] vsp-lib: Support late queuing of buffers in yavta

2019-02-17 Thread Laurent Pinchart
rmat} ${size:+-s $size} \ > ${skip:+--skip $skip} ${file:+--file=$file} ${pause:+-p$pause} \ > + ${queue_late:+--$queue_late} \ > $videodev | ./logger.sh $entity >> $logfile > } > -- Regards, Laurent Pinchart

Re: [VSP-Tests PATCH 5/7] vsp-lib: Allow forcing pixel perfect comparisons

2019-02-17 Thread Laurent Pinchart
frameskeep generated and captured frames" > + echo " -p|--pixel-perfect frames must match with pixel > perfection" > echo " -h|--help this help" > exit > shift -- Regards, Laurent Pinchart

Re: [VSP-Tests PATCH 7/7] vsp-lib: Reset controls to defaults on each test run

2019-02-17 Thread Laurent Pinchart
te before a test was run > anyway. Therefore it is more effective to reset state at the beginning > of a test. > > To repair this - reset all control values to their defaults at the start > of every test during test_init() > > Signed-off-by: Kieran Bingham Reviewed-by: Lauren

Re: [VSP-Tests PATCH 3/7] vsp-lib: Provide command line argument parsing

2019-02-16 Thread Laurent Pinchart
; + exit > + shift > + ;; > + *)# unknown option > + POSITIONAL+=("$1") # save it in an array for later > + shift # past argument > + ;; > +esac > +done > +set -- "${POSITIONAL[@]}" # restore positional parameters -- Regards, Laurent Pinchart

Re: [VSP-Tests PATCH 2/7] tests: Provide copy test to validate 1xN streams

2019-02-16 Thread Laurent Pinchart
+ test_copy $format 1024x768 > + test_copy $format 128x128 > + test_copy $format 128x1 If the purpose is to test Nx1 and 1xN, do we need the first two resolutions ? Shouldn't the test_start message describe the exact purpose ? > + > + # Skipped : Test framework does not yet support strides != width > + #test_copy $format 1x128 > + done > +} > + > +test_init $0 "$features" > +test_run -- Regards, Laurent Pinchart

Re: [VSP-Tests PATCH 4/7] vsp-lib: trivial: Fix spelling of Reference

2019-02-16 Thread Laurent Pinchart
Hi Kieran, Thank you for the patch. On Tue, Dec 04, 2018 at 03:51:43PM +, Kieran Bingham wrote: > Signed-off-by: Kieran Bingham Reviewed-by: Laurent Pinchart > --- > scripts/vsp-lib.sh | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/scripts/vs

Re: [VSP-Tests PATCH 1/7] tests: add pseudo platform test

2019-02-16 Thread Laurent Pinchart
raw2rgbpnm: " `which raw2rgbpnm` > + echo " stress: " `which stress` > + echo " yavta: " `which yavta` > +} > + > +check_all | column -ts ":" Could we remove the dependency on the column tool ? I don't have it in my buildroot environment :-) I could of course add it, but in this case I think it's easy enough to align the columns manually. With these fixed, Reviewed-by: Laurent Pinchart -- Regards, Laurent Pinchart

Re: [PATCH v2 5/6] arm64: dts: renesas: r8a77990: ebisu: Enable LVDS1 encoder

2019-02-15 Thread Laurent Pinchart
Hi Simon, On Wed, Jan 23, 2019 at 11:03:04AM +0100, Simon Horman wrote: > On Wed, Jan 23, 2019 at 11:55:52AM +0200, Laurent Pinchart wrote: > > On Wed, Jan 23, 2019 at 09:56:57AM +0100, Simon Horman wrote: > >> On Wed, Jan 23, 2019 at 12:54:04AM +0200, Laurent Pinchart wrot

Re: [PATCH v3 2/5] dt-bindings: display: renesas: lvds: Document r8a7744 bindings

2019-02-01 Thread Laurent Pinchart
Hi Rob, On Wed, Jan 30, 2019 at 10:39:10AM -0600, Rob Herring wrote: > On Tue, Jan 22, 2019 at 05:44:28PM +0200, Laurent Pinchart wrote: > > On Tue, Jan 22, 2019 at 03:25:46PM +, Biju Das wrote: > >> Document the RZ/G1N (R8A7744) LVDS bindings. > >> &

Re: [PATCH v2 5/6] arm64: dts: renesas: r8a77990: ebisu: Enable LVDS1 encoder

2019-01-23 Thread Laurent Pinchart
Hi Simon, On Wed, Jan 23, 2019 at 09:56:57AM +0100, Simon Horman wrote: > On Wed, Jan 23, 2019 at 12:54:04AM +0200, Laurent Pinchart wrote: > > The LVDS1 encoder must supply a pixel clock to the DU for the DPAD > > output when the LVDS0 encoder is used. Enable it despite its outpu

[PATCH v2 2/6] drm: rcar-du: lvds: Don't fail probe if output is not connected on D3/E3

2019-01-22 Thread Laurent Pinchart
case on D3 and E3. Signed-off-by: Laurent Pinchart --- Changes since v1: - Typo fix in the commit message --- drivers/gpu/drm/rcar-du/rcar_lvds.c | 17 +++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/rcar-du/rcar_lvds.c b/drivers/gpu/drm/rc

[PATCH v2 1/6] drm: rcar-du: Simplify encoder registration

2019-01-22 Thread Laurent Pinchart
, removing most of the DT parsing. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/rcar-du/rcar_du_encoder.c | 3 +- drivers/gpu/drm/rcar-du/rcar_du_encoder.h | 3 +- drivers/gpu/drm/rcar-du/rcar_du_kms.c | 52 ++- 3 files changed, 6 insertions(+), 52 deletions(-) diff

[PATCH v2 0/6] R-Car DU DPAD support for D3 and E3

2019-01-22 Thread Laurent Pinchart
in the DT files. The patches have been tested on Draak only as I don't have access to an Ebisu board, but they should work equally well on both boards. For your convenience the patches are available from git://linuxtv.org/pinchartl/media.git drm/du/d3e3 Laurent Pinchart (6): drm:

[PATCH v2 6/6] arm64: dts: renesas: r8a77995: draak: Enable LVDS1 encoder

2019-01-22 Thread Laurent Pinchart
The LVDS1 encoder must supply a pixel clock to the DU for the DPAD output when the LVDS0 encoder is used. Enable it despite its output not being connected. Signed-off-by: Laurent Pinchart --- Changes since v1: - Add a comment in the DT to explain why the LVDS1 encoder needs to be enabled

[PATCH v2 4/6] drm: rcar-du: Turn LVDS clock output on/off for DPAD0 output on D3/E3

2019-01-22 Thread Laurent Pinchart
On the D3 and E3 SoCs the LVDS PLL clock output provides the dot clock to the DU channels, even when the LVDS outputs are not in use. Enable and disable the LVDS clock output when enabling or disabling a CRTC connected to the DPAD0 output. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm

[PATCH v2 3/6] drm: rcar-du: lvds: Add API to enable/disable clock output

2019-01-22 Thread Laurent Pinchart
, the LVDS PLL needs to be controlled manually. Add an API to do so, to be called by the DU driver. The drivers/gpu/drm/rcar-du/ directory has to be treated as obj-y unconditionally, as the LVDS driver could be built-in while the DU driver is compiled as a module. Signed-off-by: Laurent Pinchart

[PATCH v2 5/6] arm64: dts: renesas: r8a77990: ebisu: Enable LVDS1 encoder

2019-01-22 Thread Laurent Pinchart
The LVDS1 encoder must supply a pixel clock to the DU for the DPAD output when the LVDS0 encoder is used. Enable it despite its output not being connected. Signed-off-by: Laurent Pinchart --- Changes since v1: - Add a comment in the DT to explain why the LVDS1 encoder needs to be enabled

Re: [PATCH 5/6] arm64: dts: renesas: r8a77990: ebisu: Enable LVDS1 encoder

2019-01-22 Thread Laurent Pinchart
Hi Geert, On Thu, Jan 17, 2019 at 11:21:32AM +0100, Geert Uytterhoeven wrote: > On Thu, Jan 17, 2019 at 3:07 AM Laurent Pinchart > wrote: > > The LVDS1 encoder must supply a pixel clock to the DU for the DPAD > > output when the LVDS0 encoder is used. Enable it despite its ou

Re: [PATCH] drm: rcar-du: Fix build error

2019-01-22 Thread Laurent Pinchart
c96f2 100644 > --- a/drivers/gpu/drm/rcar-du/rcar_dw_hdmi.c > +++ b/drivers/gpu/drm/rcar-du/rcar_dw_hdmi.c > @@ -12,6 +12,7 @@ > #include > > #include > +#include > > #define RCAR_HDMI_PHY_OPMODE_PLLCFG 0x06/* Mode of operation and PLL > dividers */ > #define RCAR_HDMI_PHY_PLLCURRGMPCTRL 0x10/* PLL current and Gmp > (conductance) */ -- Regards, Laurent Pinchart

Re: [PATCH v3 5/5] ARM: dts: r8a7744: Add LVDS support

2019-01-22 Thread Laurent Pinchart
Hi Biju, Thank you for the patch. On Tue, Jan 22, 2019 at 03:25:49PM +, Biju Das wrote: > Add LVDS encoder node to r8a7744 SoC DT. > > Signed-off-by: Biju Das Reviewed-by: Laurent Pinchart I expect Simon to pick this up. > --- > arch/arm/boot/dts/r8

Re: [PATCH v3 1/5] ARM: dts: r8a7743: Convert to new LVDS DT bindings

2019-01-22 Thread Laurent Pinchart
bridge > driver") Sorry for the breakage. The DT and DU series raced each other, but I should have still caught it. > Signed-off-by: Biju Das Reviewed-by: Laurent Pinchart I expect Simon to pick this up. > --- > arch/arm/boot/dts/r8a7743.dtsi | 36

Re: [PATCH v3 4/5] ARM: dts: r8a7744: Add DU support

2019-01-22 Thread Laurent Pinchart
Hi Biju, Thank you for the patch. On Tue, Jan 22, 2019 at 03:25:48PM +, Biju Das wrote: > Add du node to r8a7744 SoC DT. Boards that want to enable the DU > need to specify the output topology. > > Signed-off-by: Biju Das Reviewed-by: Laurent Pinchart I expect Simon to

Re: [PATCH v2 16/30] v4l: subdev: Add [GS]_ROUTING subdev ioctls and operations

2019-01-22 Thread Laurent Pinchart
Hi Sakari, On Tue, Jan 22, 2019 at 06:14:57PM +0200, Sakari Ailus wrote: > On Wed, Jan 16, 2019 at 01:51:45AM +0200, Laurent Pinchart wrote: > > On Fri, Nov 02, 2018 at 12:31:30AM +0100, Niklas Söderlund wrote: > >> From: Laurent Pinchart > >> > >> Signed-o

Re: [PATCH v3 3/5] drm: rcar-du: lvds: Add r8a7744 support

2019-01-22 Thread Laurent Pinchart
Hi Biju, Thank you for the patch. On Tue, Jan 22, 2019 at 03:25:47PM +, Biju Das wrote: > The LVDS encoders on RZ/G1N SoC is similar to RZ/G1M. Add support for > RZ/G1N (R8A7744) SoC to the LVDS encoder driver. > > Signed-off-by: Biju Das Reviewed-by: Laurent Pinchart and

Re: [PATCH v3 2/5] dt-bindings: display: renesas: lvds: Document r8a7744 bindings

2019-01-22 Thread Laurent Pinchart
Hi Biju, Thank you for the patch. On Tue, Jan 22, 2019 at 03:25:46PM +, Biju Das wrote: > Document the RZ/G1N (R8A7744) LVDS bindings. > > Signed-off-by: Biju Das Reviewed-by: Laurent Pinchart and taken in my tree. > --- > Documentation/devicetree/bindings/display

Re: [PATCH v2 12/30] media: entity: Add an iterator helper for connected pads

2019-01-22 Thread Laurent Pinchart
Hi Sakari, On Tue, Jan 22, 2019 at 05:36:55PM +0200, Sakari Ailus wrote: > On Wed, Jan 16, 2019 at 01:24:05AM +0200, Laurent Pinchart wrote: > > On Fri, Nov 02, 2018 at 12:31:26AM +0100, Niklas Söderlund wrote: > >> From: Sakari Ailus > >> > >> Add a helpe

Re: [PATCH v2 06/30] media: entity: Use pad as the starting point for a pipeline

2019-01-22 Thread Laurent Pinchart
Hi Sakari, On Tue, Jan 22, 2019 at 05:31:34PM +0200, Sakari Ailus wrote: > On Wed, Jan 16, 2019 at 12:54:20AM +0200, Laurent Pinchart wrote: > > On Fri, Nov 02, 2018 at 12:31:20AM +0100, Niklas Söderlund wrote: > >> From: Sakari Ailus > >> > >> The pipeline

Re: [PATCH v2 09/30] media: entity: Swap pads if route is checked from source to sink

2019-01-22 Thread Laurent Pinchart
Hi Sakari, On Tue, Jan 22, 2019 at 05:15:06PM +0200, Sakari Ailus wrote: > On Wed, Jan 16, 2019 at 12:57:43AM +0200, Laurent Pinchart wrote: > >> > >> This way the pads are always passed to the has_route() op sink pad first. > >> Makes sense. > > > >

Re: [PATCH/RFC] drm: Remove unused Renesas SH Mobile DRM driver

2019-01-21 Thread Laurent Pinchart
. It's not even using DT yet :-/ I'd prefer dropping the fbdev driver too, but that would require porting the SH boards to the DRM driver, and implement DT support for the ARM board. I don't think anyone is willing to invest time in this, so I'm fine dropping this driver as the boards are pretty much dead. I would, however, also drop the fbdev driver in that case. -- Regards, Laurent Pinchart

Re: [PATCH 1/2] media: i2c: adv748x: Convert SW reset routine to function

2019-01-18 Thread Laurent Pinchart
Hi Kieran, On Sat, Jan 12, 2019 at 04:50:32PM +, Kieran Bingham wrote: > On 11/01/2019 20:15, Laurent Pinchart wrote: > > On Friday, 11 January 2019 19:41:40 EET Kieran Bingham wrote: > >> The ADV748x is currently reset by writting a small table of registers to > >>

[PATCH 0/6] R-Car DU DPAD support for D3 and E3

2019-01-16 Thread Laurent Pinchart
ually well on both boards. For your convenience the patches are available from git://linuxtv.org/pinchartl/media.git drm/du/next Laurent Pinchart (6): drm: rcar-du: Simplify encoder registration drm: rcar-du: lvds: Don't fail probe if output is not connected on D3/E3 drm: rca

[PATCH 2/6] drm: rcar-du: lvds: Don't fail probe if output is not connected on D3/E3

2019-01-16 Thread Laurent Pinchart
cose on D3 and E3. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/rcar-du/rcar_lvds.c | 17 +++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/rcar-du/rcar_lvds.c b/drivers/gpu/drm/rcar-du/rcar_lvds.c index 96d749a35b25..a8ec6c6fa983 100644

[PATCH 3/6] drm: rcar-du: lvds: Add API to enable/disable clock output

2019-01-16 Thread Laurent Pinchart
, the LVDS PLL needs to be controlled manually. Add an API to do so, to be called by the DU driver. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/rcar-du/rcar_lvds.c | 75 + drivers/gpu/drm/rcar-du/rcar_lvds.h | 18 +++ 2 files changed, 83 insertions(+), 10

[PATCH 1/6] drm: rcar-du: Simplify encoder registration

2019-01-16 Thread Laurent Pinchart
, removing most of the DT parsing. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/rcar-du/rcar_du_encoder.c | 3 +- drivers/gpu/drm/rcar-du/rcar_du_encoder.h | 3 +- drivers/gpu/drm/rcar-du/rcar_du_kms.c | 52 ++- 3 files changed, 6 insertions(+), 52 deletions(-) diff

[PATCH 6/6] arm64: dts: renesas: r8a77995: draak: Enable LVDS1 encoder

2019-01-16 Thread Laurent Pinchart
The LVDS1 encoder must supply a pixel clock to the DU for the DPAD output when the LVDS0 encoder is used. Enable it despite its output not being connected. Signed-off-by: Laurent Pinchart --- arch/arm64/boot/dts/renesas/r8a77995-draak.dts | 2 ++ 1 file changed, 2 insertions(+) diff --git a

[PATCH 4/6] drm: rcar-du: Turn LVDS clock output on/off for DPAD0 output on D3/E3

2019-01-16 Thread Laurent Pinchart
On the D3 and E3 SoCs the LVDS PLL clock output provides the dot clock to the DU channels, even when the LVDS outputs are not in use. Enable and disable the LVDS clock output when enabling or disabling a CRTC connected to the DPAD0 output. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm

[PATCH 5/6] arm64: dts: renesas: r8a77990: ebisu: Enable LVDS1 encoder

2019-01-16 Thread Laurent Pinchart
The LVDS1 encoder must supply a pixel clock to the DU for the DPAD output when the LVDS0 encoder is used. Enable it despite its output not being connected. Signed-off-by: Laurent Pinchart --- arch/arm64/boot/dts/renesas/r8a77990-ebisu.dts | 2 ++ 1 file changed, 2 insertions(+) diff --git a

Re: [PATCH v2 17/30] v4l: subdev: compat: Implement handling for VIDIOC_SUBDEV_[GS]_ROUTING

2019-01-15 Thread Laurent Pinchart
t_v4l2_subdev_routing(new_p64, p32); > + compatible_arg = 0; > + break; > + > case VIDIOC_G_EDID: > case VIDIOC_S_EDID: > err = alloc_userspace(sizeof(struct v4l2_edid), 0, &new_p64); > @@ -1368,6 +1441,10 @@ static long do_video_ioctl(struct file *file, unsigned > int cmd, unsigned long ar > if (put_v4l2_edid32(new_p64, p32)) > err = -EFAULT; > break; > + case VIDIOC_SUBDEV_G_ROUTING: > + case VIDIOC_SUBDEV_S_ROUTING: > + err = put_v4l2_subdev_routing(new_p64, p32); > + break; > } > if (err) > return err; -- Regards, Laurent Pinchart

Re: [PATCH v2 16/30] v4l: subdev: Add [GS]_ROUTING subdev ioctls and operations

2019-01-15 Thread Laurent Pinchart
Hi Niklas, Thank you for the patch. On Fri, Nov 02, 2018 at 12:31:30AM +0100, Niklas Söderlund wrote: > From: Laurent Pinchart > > Signed-off-by: Laurent Pinchart > Signed-off-by: Michal Simek > > - Add sink and source streams for multiplexed links > - Copy the argume

Re: [PATCH v2 15/30] media: entity: Look for indirect routes

2019-01-15 Thread Laurent Pinchart
return true; > + } Isn't this best implemented in drivers ? I fear the complexity you need here isn't worth it, especially given that you would also need to support cases such as Pads 0, 1 and 2 are sink, pads 3 and 4 are sources. has_route(0, 3), has_route(1, 3), has_route(1, 4) and has_route(2, 4) are all true, has_route(0, 4) and has_route(2, 3) are all false. media_entity_has_route(0, 2) should return true. > + return false; > + > } > EXPORT_SYMBOL_GPL(media_entity_has_route); > -- Regards, Laurent Pinchart

Re: [PATCH v2 14/30] media: entity: Add debug information in graph walk route check

2019-01-15 Thread Laurent Pinchart
u -> %u (no route)\n", > + pad->entity->name, pad->index, local->index); Maybe "%s: skipping...", __func__, ? Apart from that, Reviewed-by: Laurent Pinchart > return; > } > -- Regards, Laurent Pinchart

Re: [PATCH v2 13/30] media: entity: Add only connected pads to the pipeline

2019-01-15 Thread Laurent Pinchart
> Signed-off-by: Sakari Ailus > Reviewed-by: Niklas Söderlund Reviewed-by: Laurent Pinchart > --- > drivers/media/media-entity.c | 20 ++-- > 1 file changed, 6 insertions(+), 14 deletions(-) > > diff --git a/drivers/media/media-entity.c b/drivers/media/med

Re: [PATCH v2 03/30] media: entity: Walk the graph based on pads

2019-01-15 Thread Laurent Pinchart
Hi Sakari, On Wed, Jan 16, 2019 at 12:34:07AM +0200, Sakari Ailus wrote: > On Wed, Jan 16, 2019 at 12:21:36AM +0200, Laurent Pinchart wrote: > > On Fri, Nov 02, 2018 at 12:31:17AM +0100, Niklas Söderlund wrote: > >> From: Sakari Ailus > >> > >> Instead of

Re: [PATCH v2 12/30] media: entity: Add an iterator helper for connected pads

2019-01-15 Thread Laurent Pinchart
iter < &(start)->entity->pads[(start)->entity->num_pads]; \ > + iter = __media_entity_for_routed_pads_next(start, iter + 1)) > + > /** > * media_graph_walk_cleanup - Release resources used by graph walk. > * -- Regards, Laurent Pinchart

Re: [PATCH v2 11/30] media: entity: Skip link validation for pads to which there is no route to

2019-01-15 Thread Laurent Pinchart
gt; part of the pipeline, however. Skip the link validation for such pads. > > Signed-off-by: Sakari Ailus > Reviewed-by: Niklas Söderlund Reviewed-by: Laurent Pinchart > --- > drivers/media/media-entity.c | 5 + > 1 file changed, 5 insertions(+) > > diff --git a/drive

Re: [PATCH v2 09/30] media: entity: Swap pads if route is checked from source to sink

2019-01-15 Thread Laurent Pinchart
ad0].flags & MEDIA_PAD_FL_SOURCE > + && entity->pads[pad1].flags & MEDIA_PAD_FL_SINK) > + swap(pad0, pad1); > + > return entity->ops->has_route(entity, pad0, pad1); > } > EXPORT_SYMBOL_GPL(media_entity_has_route); -- Regards, Laurent Pinchart

Re: [PATCH v2 06/30] media: entity: Use pad as the starting point for a pipeline

2019-01-15 Thread Laurent Pinchart
t() > */ > -__must_check int __media_pipeline_start(struct media_entity *entity, > +__must_check int __media_pipeline_start(struct media_pad *pad, > struct media_pipeline *pipe); > > /** > * media_pipeline_stop - Mark a pipeline as

Re: [PATCH v2 05/30] media: entity: Move the pipeline from entity to pads

2019-01-15 Thread Laurent Pinchart
, numbered from 0 to n > * @sig_type:Type of the signal inside a media pad > * @flags: Pad flags, as defined in > * :ref:`include/uapi/linux/media.h ` > * (seek for ``MEDIA_PAD_FL_*``) > + * .. note:: > + * > + *@stream_count reference co

Re: [PATCH v2 04/30] v4l: mc: Start walk from a specific pad in use count calculation

2019-01-15 Thread Laurent Pinchart
) { > if (is_media_entity_v4l2_video_device(pad->entity)) > @@ -388,7 +387,7 @@ static int pipeline_pm_power_one(struct media_entity > *entity, int change) > > /* > * pipeline_pm_power - Apply power change to all entities in a pipeline > - * @entity: The entit

Re: [PATCH v2 03/30] media: entity: Walk the graph based on pads

2019-01-15 Thread Laurent Pinchart
dia_pad *pad); > * The graph structure must have been previously initialized with a call to > * media_graph_walk_start(). > * > - * Return: returns the next entity in the graph or %NULL if the whole graph > - * have been traversed. > + * Return: returns the next pad in the g

Re: [PATCH v2 02/30] media: entity: Use pads instead of entities in the media graph walk stack

2019-01-15 Thread Laurent Pinchart
w be called media_pad_other() ? > { > - if (link->source->entity == entity) > - return link->sink->entity; > + if (link->source == pad) > + return link->sink; > else > - return link->source->entity; > + return link->source; > } [snip] -- Regards, Laurent Pinchart

Re: [PATCH v2 02/30] media: entity: Use pads instead of entities in the media graph walk stack

2019-01-15 Thread Laurent Pinchart
*/ > - while (link_top(graph) != &stack_top(graph)->links) > + while (link_top(graph) != &stack_top(graph)->entity->links) > media_graph_walk_iter(graph); > > - entity = stack_pop(graph); > + entity

Re: [PATCH v2 01/30] media: entity: Use pad as a starting point for graph walk

2019-01-15 Thread Laurent Pinchart
t; > Signed-off-by: Sakari Ailus > Reviewed-by: Niklas Söderlund Reviewed-by: Laurent Pinchart > --- > Documentation/media/kapi/mc-core.rst| 2 +- > drivers/media/media-entity.c| 17 - > drivers/media/platform/exynos4-is/media-d

Re: [PATCH] drm: Split out drm_probe_helper.h

2019-01-15 Thread Laurent Pinchart
his will also conflict with ongoing drmP.h cleanup by others I > expect. > > v3: Rebase on top of atomic bochs. > > Cc: Sam Ravnborg > Cc: Jani Nikula > Cc: Laurent Pinchart > Acked-by: Rodrigo Vivi (v2) > Acked-by: Benjamin Gaignard (v2) > Signed-off-by

Re: [PATCH 1/3 v2] drm: rcar-du: add missing of_node_put

2019-01-14 Thread Laurent Pinchart
!= of_node_put(e) > when != of_fwnode_handle(e) > ( > return e; > > *return ...; > ) > // > > Signed-off-by: Julia Lawall Reviewed-by: Laurent Pinchart and applied to my tree. > --- > v2: Add the second of_node_put(entity);, as suggested by Kieran Bingham. &

Re: [PATCH 2/2] media: i2c: adv748x: Remove PAGE_WAIT

2019-01-11 Thread Laurent Pinchart
gt; while (regs->page != ADV748X_PAGE_EOR) { While at it you could write this as for (; regs->page != ADV748X_PAGE_EOR; ++regs) and remove the regs++ below. Reviewed-by: Laurent Pinchart > - if (regs->page == ADV748X_PAGE_WAIT) { > -

Re: [PATCH 1/2] media: i2c: adv748x: Convert SW reset routine to function

2019-01-11 Thread Laurent Pinchart
> + return ret; > + > + usleep_range(5000, 6000); > + > + /* Disable CEC Wakeup from power-down mode */ > + ret = io_clrset(state, ADV748X_IO_REG_01, ADV748X_IO_REG_01_PWRDN_MASK, > + ADV748X_IO_REG_01_PWRDNB); What's the reas

Re: [PATCH] arm64: dts: renesas: r8a77990: ebisu: Fix backlight regulator numbering

2019-01-10 Thread Laurent Pinchart
; > compatible = "regulator-fixed"; > > > regulator-name = "D12.0V"; > > > regulator-min-microvolt = <1200>; > > > > Perhaps the node name should get a more descriptive suffix > > (e.g. "regulator-12p0v"), like is already done for some of the other > > regulators? > > I think I would prefer that addressed in a follow-up patch. Agreed, but it would still be a very good idea. I think we need to standardize names for regulators, otherwise this is bound to happen again in the future. -- Regards, Laurent Pinchart

Re: [PATCH] arm64: dts: renesas: r8a77990: ebisu: Fix backlight regulator numbering

2019-01-10 Thread Laurent Pinchart
t; by the other, ultimatelly resulting in inoperable eMMC, which depends on > the former. Fix this by renumbering the backlight regulator to regulator2. > > Signed-off-by: Marek Vasut > Cc: Laurent Pinchart > Cc: Simon Horman > Cc: Wolfram Sang > Cc: linux-renesas-soc@vger.ke

Re: [PATCH v2 6/6] media: adv748x: Implement TX link_setup callback

2019-01-10 Thread Laurent Pinchart
Hi Jacopo, On Thursday, 10 January 2019 10:51:00 EET Jacopo Mondi wrote: > On Wed, Jan 09, 2019 at 02:15:04AM +0200, Laurent Pinchart wrote: > > On Monday, 7 January 2019 14:36:28 EET Kieran Bingham wrote: > >> On 06/01/2019 15:54, Jacopo Mondi wrote: > >>> When

Re: [PATCH v2 6/6] media: adv748x: Implement TX link_setup callback

2019-01-08 Thread Laurent Pinchart
t; + > > +static const struct media_entity_operations adv748x_tx_media_ops = { > > + .link_setup = adv748x_link_setup, > > + .link_validate = v4l2_subdev_link_validate, > > +}; > > > > static const struct media_entity_operations adv748x_media_ops = { > > .link_validate = v4l2_subdev_link_validate, > > @@ -516,7 +570,8 @@ void adv748x_subdev_init(struct v4l2_subdev *sd, > > struct adv748x_state *state, > > state->client->addr, ident); > > > > sd->entity.function = function; > > - sd->entity.ops = &adv748x_media_ops; > > + sd->entity.ops = is_tx(adv748x_sd_to_csi2(sd)) ? > > +&adv748x_tx_media_ops : &adv748x_media_ops; > > Aha - yes that's a neat solution to ensure that only the TX links > generate link_setup calls :) Another option would be to bail out from adv748x_link_setup() if the entity is not a TX*. > > } [snip] -- Regards, Laurent Pinchart

Re: [PATCH v2 3/6] media: adv748x: csi2: Link AFE with TXA and TXB

2019-01-08 Thread Laurent Pinchart
ten "Create link", but then realized that the function is named adv748x_csi2_register_link(). Looking at its definition, I now see this means "register and link". That seems a bit of a hack, especially seeing how double registration is skipped in the function by checking src->v4l2_dev. Kieran, could this be fixed ? > + if (is_txb(tx) || !is_hdmi_enabled(state)) > + return 0; > + > + return adv748x_csi2_register_link(tx, sd->v4l2_dev, &state->hdmi.sd, > + ADV748X_HDMI_SOURCE, true); > } > > static const struct v4l2_subdev_internal_ops adv748x_csi2_internal_ops = { -- Regards, Laurent Pinchart

Re: [PATCH v2 1/6] media: adv748x: Add is_txb()

2019-01-08 Thread Laurent Pinchart
#x27;is_tx()' macro this series adds in > > 6/6. > > > > If it is easier to have an '((_tx) == &(_tx)->state->txb)' I can > > change this. I would find it cleaner to write out is_txa and is_txb explicitly instead of hiding the implementation behind an __is_tx macro, especially given that we won't have to extend this in the future. Reviewed-by: Laurent Pinchart > It's fine for me as you've got it. > > It's still clear and readable, and implements the required functionality. > > -- Regards, Laurent Pinchart

Re: [PATCH] clk: vc5: Abort clock configuration without upstream clock

2018-12-29 Thread Laurent Pinchart
Hi Stephen, On Saturday, 29 December 2018 00:30:16 EET Stephen Boyd wrote: > Quoting Marek Vasut (2018-12-16 09:14:29) > > On 12/16/2018 08:19 AM, Laurent Pinchart wrote: > > > On Saturday, 15 December 2018 02:55:19 EET Marek Vasut wrote: > > >> In case the upstrea

[PATCH] drm: rcar-du: Remove inclusion of drmP.h

2018-12-27 Thread Laurent Pinchart
forward declarations of structures. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/rcar-du/rcar_du_crtc.c| 1 - drivers/gpu/drm/rcar-du/rcar_du_crtc.h| 1 - drivers/gpu/drm/rcar-du/rcar_du_drv.c | 1 - drivers/gpu/drm/rcar-du/rcar_du_drv.h | 1 + drivers/gpu/drm/rcar-du

Re: [PATCH/RFC 0/2] R-Car DU: Support importing non-contiguous dma-buf with VSP

2018-12-17 Thread Laurent Pinchart
Hi Kieran, On Monday, 13 November 2017 15:48:19 EET Kieran Bingham wrote: > On 13/11/17 10:32, Laurent Pinchart wrote: > > Hello everybody, > > > > This patch series fixes two issues related to dma-buf import for the > > Renesas R-Car DU when the imported buff

Re: [PATCH -next] drm/shmob: Fix return value check in shmob_drm_probe

2018-12-17 Thread Laurent Pinchart
s: 8f1597c8f1a5 ("drm: shmobile: Perform initialization/cleanup at > probe/remove time") > Signed-off-by: YueHaibing Reviewed-by: Laurent Pinchart and applied to my tree. > --- > drivers/gpu/drm/shmobile/shmob_drm_drv.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 de

[GIT PULL FOR renesas-drivers] DU -next branch

2018-12-16 Thread Laurent Pinchart
r-du: lvds: add R8A774C0 support Geert Uytterhoeven (1): drm: rcar-du: Convert live DT patches to sugar syntax Laurent Pinchart (4): drm: rcar-du: dw-hdmi: Reject modes with a too high clock frequency drm: rcar-du: Replace EXT_CTRL_REGS feature flag with generation check drm: rca

[PATCH] arm64: dts: renesas: r8a77990: ebisu: Add backlight

2018-12-16 Thread Laurent Pinchart
Add the backlight device for the LVDS1 output, in preparation for panel support. Signed-off-by: Laurent Pinchart --- .../arm64/boot/dts/renesas/r8a77990-ebisu.dts | 19 +++ 1 file changed, 19 insertions(+) diff --git a/arch/arm64/boot/dts/renesas/r8a77990-ebisu.dts b/arch

[PATCH] arm64: dts: renesas: r8a77995: draak: Set better backlight levels

2018-12-16 Thread Laurent Pinchart
The backlight levels provided in the Draak DT produce a perceived brightness very biased towards high brightness. Use better brightness levels based on the CIE 1931 formula. Signed-off-by: Laurent Pinchart --- arch/arm64/boot/dts/renesas/r8a77995-draak.dts | 4 ++-- 1 file changed, 2 insertions

Re: [PATCH] clk: vc5: Initialize src in vc5_mux_set_parent()

2018-12-15 Thread Laurent Pinchart
#x27;d thus add a comment to explain that the goal is only to silence a compiler warning. > Cc: Marek Vasut > Cc: Alexey Firago > Cc: Laurent Pinchart > Cc: linux-renesas-soc@vger.kernel.org > Signed-off-by: Stephen Boyd > --- > drivers/clk/clk-versaclock5.c | 2 +-

Re: [PATCH] clk: vc5: Abort clock configuration without upstream clock

2018-12-15 Thread Laurent Pinchart
ernal oscilator present in some VC5 models is also considered > upstream clock. > > Signed-off-by: Marek Vasut > Cc: Alexey Firago > Cc: Laurent Pinchart > Cc: Stephen Boyd > Cc: linux-renesas-soc@vger.kernel.org > --- > NOTE: This is an updated version of

Re: [PATCH 2/2] pinctrl: sh-pfc: r8a77995: Fix MOD_SEL bit numbering

2018-12-14 Thread Laurent Pinchart
Hello Shimoda-san, On Friday, 14 December 2018 12:41:32 EET Yoshihiro Shimoda wrote: > From: Laurent Pinchart, Sent: Thursday, December 13, 2018 10:53 PM > > On Wednesday, 12 December 2018 12:19:35 EET Yoshihiro Shimoda wrote: > > > From: Takeshi Kihara > > >

Re: [PATCH 4/4] rcar-vin: add support for suspend and resume

2018-12-14 Thread Laurent Pinchart
@@ enum rvin_csi_id { > }; > > /** > - * STOPPED - No operation in progress > - * STARTING - Capture starting up > - * RUNNING - Operation in progress have buffers > - * STOPPING - Stopping operation > + * STOPPED - No operation in progress > + * STARTING - Capture

Re: [PATCH 3/4] rcar-vin: make rvin_{start,stop}_streaming() available for internal use

2018-12-14 Thread Laurent Pinchart
gt; d21fc991b7a9da36..700fae1c1225a2f3 100644 > --- a/drivers/media/platform/rcar-vin/rcar-vin.h > +++ b/drivers/media/platform/rcar-vin/rcar-vin.h > @@ -269,4 +269,7 @@ void rvin_crop_scale_comp(struct rvin_dev *vin); > > int rvin_set_channel_routing(struct rvin_dev *vin, u8 chsel); > > +int rvin_start_streaming(struct rvin_dev *vin); > +void rvin_stop_streaming(struct rvin_dev *vin); > + > #endif -- Regards, Laurent Pinchart

Re: [PATCH 2/4] rcar-vin: cache the CSI-2 channel selection value

2018-12-14 Thread Laurent Pinchart
@state: keeps track of operation state > * > * @is_csi: flag to mark the VIN as using a CSI-2 subdevice > + * @chselCached value of the current CSI-2 channel selection Nitpicking, the documentation for other fields don't start with a

Re: [PATCH 1/4] rcar-vin: fix wrong return value in rvin_set_channel_routing()

2018-12-14 Thread Laurent Pinchart
rn the use count to the caller but to return > 0 on success else none zero. > > Fix this by always returning 0 if the operation is successful. > > Signed-off-by: Niklas Söderlund Reviewed-by: Laurent Pinchart > --- > drivers/media/platform/rcar-vin/rcar-dma.c | 2 +- >

Re: [PATCH 2/2] drm: rcar-du: Add Standby Mode to suspend()

2018-12-14 Thread Laurent Pinchart
{ > + dev_err(dev, "failed to enter Standby mode\n"); > + return ret; > + } > + } Could you please explain why this is needed ? The call to drm_mode_config_helper_suspend() should disable all CRTCs, so there shouldn't be a need to disable them manually first. > return drm_mode_config_helper_suspend(rcdu->ddev); > } -- Regards, Laurent Pinchart

Re: [PATCH] drm: rcar-du: Add r8a77965 LVDS dts overlay

2018-12-14 Thread Laurent Pinchart
r8a77965.dts > b/drivers/gpu/drm/rcar-du/rcar_du_of_lvds_r8a77965.dts new file mode 100644 > index 000..34aea91 > --- /dev/null > +++ b/drivers/gpu/drm/rcar-du/rcar_du_of_lvds_r8a77965.dts > @@ -0,0 +1,50 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* > + * rca

Re: [PATCH] drm: rcar-du: Convert live DT patches to sugar syntax

2018-12-14 Thread Laurent Pinchart
Hi Kieran, On Friday, 14 December 2018 09:39:55 EET Kieran Bingham wrote: > On 29/11/2018 12:43, Laurent Pinchart wrote: > > On Thursday, 29 November 2018 12:58:50 EET Geert Uytterhoeven wrote: > >> Using overlay sugar syntax makes the DTS files easier to read (and > >>

Re: [PATCH] dt-bindings: display: renesas: du: Document r8a774c0 bindings

2018-12-13 Thread Laurent Pinchart
Hi Fabrizio, Thank you for the patch. On Thursday, 13 December 2018 22:20:45 EET Fabrizio Castro wrote: > Document the RZ/G2E (a.k.a. r8a774c0) SoC in the R-Car DU bindings. > > Signed-off-by: Fabrizio Castro Reviewed-by: Laurent Pinchart and applied to my tree. > --- >

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