aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/bridge (follow)
AgeCommit message (Collapse)AuthorFilesLines
2017-08-08drm: Nuke drm_atomic_helper_connector_dpmsDaniel Vetter12-12/+0
It's dead code, the core handles all this directly now. The only special case is nouveau and tda988x which used one function for both legacy modeset code and -nv50 atomic world instead of 2 vtables. But amounts to exactly the same. v2: Rebase over the panel/brideg refactorings in stm/ltdc. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Cc: Archit Taneja <architt@codeaurora.org> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Laurent Pinchart <Laurent.pinchart@ideasonboard.com> Cc: Peter Senna Tschudin <peter.senna@collabora.com> Cc: Martin Donnelly <martin.donnelly@ge.com> Cc: Martyn Welch <martyn.welch@collabora.co.uk> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Jani Nikula <jani.nikula@linux.intel.com> Cc: Sean Paul <seanpaul@chromium.org> Cc: David Airlie <airlied@linux.ie> Cc: Inki Dae <inki.dae@samsung.com> Cc: Joonyoung Shim <jy0922.shim@samsung.com> Cc: Seung-Woo Kim <sw0312.kim@samsung.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Kukjin Kim <kgene@kernel.org> Cc: Krzysztof Kozlowski <krzk@kernel.org> Cc: Stefan Agner <stefan@agner.ch> Cc: Alison Wang <alison.wang@freescale.com> Cc: Russell King <linux@armlinux.org.uk> Cc: Philipp Zabel <p.zabel@pengutronix.de> Cc: CK Hu <ck.hu@mediatek.com> Cc: Matthias Brugger <matthias.bgg@gmail.com> Cc: Neil Armstrong <narmstrong@baylibre.com> Cc: Carlo Caione <carlo@caione.org> Cc: Kevin Hilman <khilman@baylibre.com> Cc: Marek Vasut <marex@denx.de> Cc: Ben Skeggs <bskeggs@redhat.com> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Eric Anholt <eric@anholt.net> Cc: Mark Yao <mark.yao@rock-chips.com> Cc: Heiko Stuebner <heiko@sntech.de> Cc: Benjamin Gaignard <benjamin.gaignard@linaro.org> Cc: Vincent Abriou <vincent.abriou@st.com> Cc: Yannick Fertre <yannick.fertre@st.com> Cc: Philippe Cornu <philippe.cornu@st.com> Cc: Maxime Ripard <maxime.ripard@free-electrons.com> Cc: Chen-Yu Tsai <wens@csie.org> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Jonathan Hunter <jonathanh@nvidia.com> Cc: Jyri Sarha <jsarha@ti.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Shawn Guo <shawnguo@kernel.org> Cc: John Stultz <john.stultz@linaro.org> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Cc: Jeffy Chen <jeffy.chen@rock-chips.com> Cc: Tomeu Vizoso <tomeu.vizoso@collabora.com> Cc: Yakir Yang <kuankuan.y@gmail.com> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Jose Abreu <Jose.Abreu@synopsys.com> Cc: Romain Perier <romain.perier@collabora.com> Cc: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com> Cc: Xinliang Liu <z.liuxinliang@hisilicon.com> Cc: Alexey Brodkin <abrodkin@synopsys.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Rongrong Zou <zourongrong@gmail.com> Cc: Rob Clark <robdclark@gmail.com> Cc: Hai Li <hali@codeaurora.org> Cc: "Noralf Trønnes" <noralf@tronnes.org> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-samsung-soc@vger.kernel.org Cc: intel-gfx@lists.freedesktop.org Cc: linux-mediatek@lists.infradead.org Cc: linux-amlogic@lists.infradead.org Cc: nouveau@lists.freedesktop.org Cc: linux-renesas-soc@vger.kernel.org Cc: linux-rockchip@lists.infradead.org Cc: linux-tegra@vger.kernel.org Cc: virtualization@lists.linux-foundation.org Cc: zain wang <wzz@rock-chips.com> Cc: Baoyou Xie <baoyou.xie@linaro.org> Cc: Boris Brezillon <boris.brezillon@free-electrons.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20170725080122.20548-8-daniel.vetter@ffwll.ch Acked-by: Neil Armstrong <narmstrong@baylibre.com> Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Acked-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Archit Taneja <architt@codeaurora.org> Tested-by: Philippe Cornu <philippe.cornu@st.com> (on stm) Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Shawn Guo <shawnguo@kernel.org> Acked-by: Shawn Guo <shawnguo@kernel.org> Acked-by: Noralf Trønnes <noralf@tronnes.org> Acked-by: Vincent Abriou <vincent.abriou@st.com>
2017-08-08drm: bridge: synopsys/dw-hdmi: Provide default configuration function for HDMI 2.0 PHYJose Abreu1-0/+1
Currently HDMI 2.0 PHYs do not have a default configuration function. As *some* of the HDMI 2.0 PHYs have the same register layout as the 3D PHYs we can provide the same default configuration function for both and still let user overwrite this with custom configuration function if needed. If, for some reason, the PHY is custom or has a register different register layout then custom configuration function *must* be provided in order for the system to work correctly. As we prefer the pdata provided configuration function over the internal one this change will not make any impact in custom platforms. Signed-off-by: Jose Abreu <joabreu@synopsys.com> Tested-by: Mark Yao <mark.yao@rock-chips.com> Cc: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com> Cc: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Cc: Archit Taneja <architt@codeaurora.org> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Mark Yao <mark.yao@rock-chips.com> Cc: Carlos Palminha <palminha@synopsys.com> Cc: Heiko Stübner <heiko@sntech.de> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/185ccf7d4473fa557044732402ca20b3d4007952.1498209896.git.joabreu@synopsys.com
2017-08-07drm/bridge: dw-hdmi: remove CEC engine register definitionsRussell King1-45/+0
We don't need the CEC engine register definitions, so let's remove them. Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Tested-by: Hans Verkuil <hans.verkuil@cisco.com> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/20170802184108.7913-5-hverkuil@xs4all.nl
2017-08-07drm/bridge: dw-hdmi: add cec driverRussell King6-1/+398
Add a CEC driver for the dw-hdmi hardware. Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk> [hans.verkuil: unsigned -> unsigned int] [hans.verkuil: cec_transmit_done -> cec_transmit_attempt_done] [hans.verkuil: add missing CEC_CAP_PASSTHROUGH] Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Tested-by: Hans Verkuil <hans.verkuil@cisco.com> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/20170802184108.7913-4-hverkuil@xs4all.nl
2017-08-07drm/bridge: dw-hdmi: add missing cec_notifier_putHans Verkuil1-0/+3
The __dw_hdmi_remove() function was missing a call to cec_notifier_put to balance the cec_notifier_get in the probe function. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/a7688d13-2d61-ed16-f2df-28cbb5007f38@xs4all.nl
2017-08-07drm: dw-hdmi-i2s: add missing company name on CopyrightKuninori Morimoto1-1/+2
This driver's Copyright is under Renesas Solutions Corp. This patch updates the year, because this driver was moved into synopsys folder in 2017. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/87tw1khvnq.wl%kuninori.morimoto.gx@renesas.com
2017-08-04drm/bridge: dw-hdmi: add better clock disable controlRussell King1-11/+18
The video setup path aways sets the clock disable register to a specific value, which has the effect of disabling the CEC engine. When we add the CEC driver, this becomes a problem. Fix this by only setting/clearing the bits that the video path needs to. Reviewed-by: Jose Abreu <joabreu@synopsys.com> Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/E1dcBha-00088l-DE@rmk-PC.armlinux.org.uk
2017-08-04drm/bridge: dw-hdmi: add cec notifier supportRussell King2-1/+22
Add CEC notifier support to the HDMI bridge driver, so that the CEC part of the IP can receive its physical address. Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk> Tested-by: Neil Armstrong <narmstrong@baylibre.com> Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/E1dcBhV-00088e-8x@rmk-PC.armlinux.org.uk
2017-07-26drm/bridge: Add a devm_ allocator for panel bridge.Eric Anholt1-0/+30
This will let drivers reduce the error cleanup they need, in particular the "is_panel_bridge" flag. v2: Slight cleanup of remove function by Andrzej Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Reviewed-by: Philippe Cornu <philippe.cornu@st.com> Tested-by: Philippe Cornu <philippe.cornu@st.com> Link: https://patchwork.freedesktop.org/patch/msgid/20170718210510.12229-2-eric@anholt.net
2017-07-26Merge airlied/drm-next into drm-misc-nextDaniel Vetter3-1/+44
I need this to be able to apply the deferred fbdev setup patches, I need the relevant prep work that landed through the drm-intel tree. Also squash in conflict fixup from Laurent Pinchart. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2017-07-18drm/bridge/synopsys: Add MIPI DSI host controller bridgePhilippe CORNU3-0/+989
Add a Synopsys Designware MIPI DSI host DRM bridge driver, based on the Rockchip version from rockchip/dw-mipi-dsi.c with phy & bridge APIs. Signed-off-by: Philippe CORNU <philippe.cornu@st.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: https://patchwork.freedesktop.org/patch/msgid/1500277223-29553-5-git-send-email-philippe.cornu@st.com
2017-07-14drm: handle HDMI 2.0 VICs in AVI info-framesShashank Sharma3-3/+4
HDMI 1.4b support the CEA video modes as per range of CEA-861-D (VIC 1-64). For any other mode, the VIC filed in AVI infoframes should be 0. HDMI 2.0 sinks, support video modes range as per CEA-861-F spec, which is extended to (VIC 1-107). This patch adds a bool input variable, which indicates if the connected sink is a HDMI 2.0 sink or not. This will make sure that we don't pass a HDMI 2.0 VIC to a HDMI 1.4 sink. This patch touches all drm drivers, who are callers of this function drm_hdmi_avi_infoframe_from_display_mode but to make sure there is no change in current behavior, is_hdmi2 is kept as false. In case of I915 driver, this patch: - checks if the connected display is HDMI 2.0. - HDMI infoframes carry one of this two type of information: - VIC for 4K modes for HDMI 1.4 sinks - S3D information for S3D modes As CEA-861-F has already defined VICs for 4K videomodes, this patch doesn't allow sending HDMI infoframes for HDMI 2.0 sinks, until the mode is 3D. Cc: Ville Syrjala <ville.syrjala@linux.intel.com> Cc: Jose Abreu <jose.abreu@synopsys.com> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Daniel Vetter <daniel.vetter@intel.com> PS: This patch touches a few lines in few files, which were already above 80 char, so checkpatch gives 80 char warning again. - gpu/drm/omapdrm/omap_encoder.c - gpu/drm/i915/intel_sdvo.c V2: Rebase, Added r-b from Andrzej V3: Addressed review comment from Ville: - Do not send VICs in both AVI-IF and HDMI-IF send only one of it. V4: Rebase V5: Added r-b from Neil. Addressed review comments from Ville - Do not block HDMI vendor IF, instead check for VIC while handling AVI infoframes V6: Rebase V7: Rebase Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Shashank Sharma <shashank.sharma@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1499960000-9232-2-git-send-email-shashank.sharma@intel.com Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-07-13Merge tag 'drm-fixes-for-v4.13-rc1' of git://people.freedesktop.org/~airlied/linuxLinus Torvalds1-1/+1
Pull more drm updates from Dave Airlie: "i915, amd and some core fixes + mediatek color support. Some fixes tree came in since the main pull request for rc1, primarily i915 and drm-misc and one amd fix. The drm core vblank regression fix is probably the most important thing. I've also added the mediatek feature pull, it wasn't that big and didn't look like it would have any impact outside of mediatek, in fact it looks to just be a single feature, and some cleanups" * tag 'drm-fixes-for-v4.13-rc1' of git://people.freedesktop.org/~airlied/linux: (31 commits) drm/i915: Make DP-MST connector info work drm/i915/gvt: Use fence error from GVT request for workload status drm/i915/gvt: remove scheduler_mutex in per-engine workload_thread drm/i915/gvt: Revert "drm/i915/gvt: Fix possible recursive locking issue" drm/i915/gvt: Audit the command buffer address drm/i915/gvt: Fix a memory leak in intel_gvt_init_gtt() drm/rockchip: fix NULL check on devm_kzalloc() return value drm/i915/fbdev: Check for existence of ifbdev->vma before operations drm/radeon: Fix eDP for single-display iMac10,1 (v2) drm/i915: Hold RPM wakelock while initializing OA buffer drm/i915/cnl: Fix the CURSOR_COEFF_MASK used in DDI Vswing Programming drm/i915/cfl: Fix Workarounds. drm/i915: Avoid undefined behaviour of "u32 >> 32" drm/i915: reintroduce VLV/CHV PFI programming power domain workaround drm/i915: Fix an error checking test drm/i915: Disable MSI for all pre-gen5 drm/atomic: Add missing drm_atomic_state_clear to atomic_remove_fb drm: vblank: Fix vblank timestamp update drm/i915/gvt: Make function dpy_reg_mmio_readx safe drm/mediatek: separate color module to fixup error memory reallocation ...
2017-07-09Merge tag 'drm-for-v4.13' of git://people.freedesktop.org/~airlied/linuxLinus Torvalds9-202/+297
Pull drm updates from Dave Airlie: "This is the main pull request for the drm, I think I've got one later driver pull for mediatek SoC driver, I'm undecided on if it needs to go to you yet. Otherwise summary below: Core drm: - Atomic add driver private objects - Deprecate preclose hook in modern drivers - MST bandwidth tracking - Use kvmalloc in more places - Add mode_valid hook for crtc/encoder/bridge - Reduce sync_file construction time - Documentation updates - New DRM synchronisation object support New drivers: - pl111 - pl111 CLCD display controller Panel: - Innolux P079ZCA panel driver - Add NL12880B20-05, NL192108AC18-02D, P320HVN03 panels - panel-samsung-s6e3ha2: Add s6e3hf2 panel support i915: - SKL+ watermark fixes - G4x/G33 reset improvements - DP AUX backlight improvements - Buffer based GuC/host communication - New getparam for (sub)slice infomation - Cannonlake and Coffeelake initial patches - Execbuf optimisations radeon/amdgpu: - Lots of Vega10 bug fixes - Preliminary raven support - KIQ support for compute rings - MEC queue management rework - DCE6 Audio support - SR-IOV improvements - Better radeon/amdgpu selection support nouveau: - HDMI stereoscopic support - Display code rework for >= GM20x GPUs msm: - GEM rework for fine-grained locking - Per-process pagetable work - HDMI fixes for Snapdragon 820. vc4: - Remove 256MB CMA limit from vc4 - Add out-fence support - Add support for cygnus - Get/set tiling ioctls support - Add T-format tiling support for scanout zte: - add VGA support. etnaviv: - Thermal throttle support for newer GPUs - Restore userspace buffer cache performance - dma-buf sync fix stm: - add stm32f429 display support exynos: - Rework vblank handling - Fixup sw-trigger code sun4i: - V3s display engine support - HDMI support for older SoCs - Preliminary work on dual-pipeline SoCs. rcar-du: - VSP work imx-drm: - Remove counter load enable from PRE - Double read/write reduction flag support tegra: - Documentation for the host1x and drm driver. - Lots of staging ioctl fixes due to grate project work. omapdrm: - dma-buf fence support - TILER rotation fixes" * tag 'drm-for-v4.13' of git://people.freedesktop.org/~airlied/linux: (1270 commits) drm: Remove unused drm_file parameter to drm_syncobj_replace_fence() drm/amd/powerplay: fix bug fail to remove sysfs when rmmod amdgpu. amdgpu: Set cik/si_support to 1 by default if radeon isn't built drm/amdgpu/gfx9: fix driver reload with KIQ drm/amdgpu/gfx8: fix driver reload with KIQ drm/amdgpu: Don't call amd_powerplay_destroy() if we don't have powerplay drm/ttm: Fix use-after-free in ttm_bo_clean_mm drm/amd/amdgpu: move get memory type function from early init to sw init drm/amdgpu/cgs: always set reference clock in mode_info drm/amdgpu: fix vblank_time when displays are off drm/amd/powerplay: power value format change for Vega10 drm/amdgpu/gfx9: support the amdgpu.disable_cu option drm/amd/powerplay: change PPSMC_MSG_GetCurrPkgPwr for Vega10 drm/amdgpu: Make amdgpu_cs_parser_init static (v2) drm/amdgpu/cs: fix a typo in a comment drm/amdgpu: Fix the exported always on CU bitmap drm/amdgpu/gfx9: gfx_v9_0_enable_gfx_static_mg_power_gating() can be static drm/amdgpu/psp: upper_32_bits/lower_32_bits for address setup drm/amd/powerplay/cz: print message if smc message fails drm/amdgpu: fix typo in amdgpu_debugfs_test_ib_init ...
2017-07-06drm/bridge: ti-tfp410: clean up drm_bridge_add callInki Dae1-5/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-12-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: tc358767: clean up drm_bridge_add callInki Dae1-5/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-11-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: synopsys: dw-hdmi: clean up drm_bridge_add callInki Dae1-6/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-10-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: sii902x: clean up drm_bridge_add callInki Dae1-5/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-9-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: ps8622: clean up drm_bridge_add callInki Dae1-5/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-8-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: panel: clean up drm_bridge_add callInki Dae1-4/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-7-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: nxp-ptn3460: clean up drm_bridge_add callInki Dae1-5/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-6-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: vga-dac: clean up drm_bridge_add callInki Dae1-6/+3
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-5-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: analogix-anx78xx: clean up drm_bridge_add callInki Dae1-5/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-4-git-send-email-inki.dae@samsung.com
2017-07-06drm/bridge: adv7511: clean up drm_bridge_add callInki Dae1-5/+1
This patch removes unnecessary checking of return value. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1499071350-25168-3-git-send-email-inki.dae@samsung.com
2017-07-03Merge remote-tracking branches 'asoc/topic/davinci', 'asoc/topic/drm', 'asoc/topic/dwc' and 'asoc/topic/es8316' into asoc-nextMark Brown2-0/+43
2017-06-28drm: adv7511_audio: Add .get_dai_id callback to map port number to dai idJohn Stultz1-0/+22
ALSA SoC needs to know connected DAI ID for probing. Using the new audio-card-graph approach, ports/endpoints are used to describe how the links are connected. Unfortunately, since ports/endpoints are used as well for video linkages, there are some issues mixing the port ids to the two (video and audio) namespaces. To solve this issue, this patch adds new .get_dai_id callback on hdmi_codec_ops. The will assume that HDMI audio out will be connected to reg = <2>. This will then be remapped to the ALSA SoC side will as DAI 0. Allowing the adv7511's hdmi audio support to be used with the audio-card-graph. Credit to Kuninori Morimoto who's patch to dw-hdmi-i2s-audio.c was what this was mostly copy-pasted from. Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Cc: Archit Taneja <architt@codeaurora.org> Cc: Mark Brown <broonie@kernel.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: David Airlie <airlied@linux.ie> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Linux-ALSA <alsa-devel@alsa-project.org> Cc: dri-devel@lists.freedesktop.org Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-06-28drm: dw-hdmi-i2s: add .get_dai_id callback for ALSA SoCKuninori Morimoto1-0/+21
ALSA SoC needs to know connected DAI ID for probing. It is not a big problem if device/driver was only for sound, but getting DAI ID will be difficult if device includes both Video/Sound, like HDMI. To solve this issue, this patch adds new .get_dai_id callback on hdmi_codec_ops. dw-hdmi-i2s will assume that HDMI sound will be connected to reg = <2>. Then, ALSA SoC side will recognized it as DAI 0 ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; /* HDMI Video IN */ }; port@1 { reg = <1>; /* HDMI OUT */ }; port@2 { reg = <2>; /* HDMI Sound IN */ }; }; Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-06-27Backmerge tag 'v4.12-rc7' into drm-nextDave Airlie1-0/+1
Linux 4.12-rc7 Needed at least rc6 for drm-misc-next-fixes, may as well go to rc7
2017-06-21bridge: Fix panel-bridge error return on !panel.Eric Anholt1-1/+1
ERR_PTR() needs a negative errno argument. Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/20170615175423.17954-1-eric@anholt.net
2017-06-20Merge remote-tracking branch 'airlied/drm-next' into drm-misc-next-fixesSean Paul9-202/+297
Backmerging airlied/drm-next
2017-06-12drm: dw-hdmi: Fix compilation breakage by selecting REGMAP_MMIOLaurent Pinchart1-0/+1
The dw-hdmi driver switched to regmap-mmio, but lacks the dependency in Kconfig. This can result in compilation breakages. Fix it by selecting REGMAP_MMIO. Fixes: 80e2f97968b5 ("drm: bridge: dw-hdmi: Switch to regmap for register access") Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/20170610085943.15788-1-laurent.pinchart+renesas@ideasonboard.com
2017-06-05drm/bridge: Refactor out the panel wrapper from the lvds-encoder bridge.Eric Anholt3-141/+227
Many DRM drivers have common code to make a stub connector implementation that wraps a drm_panel. By wrapping the panel in a DRM bridge, all of the connector code (including calls during encoder enable/disable) goes away. v2: Fix build with CONFIG_DRM=m, drop "dev" argument that should just be the panel's dev, move kerneldoc up a level and document _remove(). v3: Fix another breakage with CONFIG_DRM=m, fix breakage with CONFIG_OF=n, move protos under CONFIG_DRM_PANEL_BRIDGE, wrap a line. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> (v1) Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> (v2) Acked-by: Archit Taneja <architt@codeaurora.org> (v2) Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/20170602202514.11900-1-eric@anholt.net
2017-06-05drm/bridge/synopsys: dw-hdmi: Use bridge->mode_valid() callbackJose Abreu1-28/+13
Now that we have a callback to check if bridge supports a given mode we can use it in Synopsys Designware HDMI bridge so that we restrict the number of probbed modes to the ones we can actually display. Also, there is no need to use mode_fixup() callback as mode_valid() will handle the mode validation. NOTE: I also had to change the pdata declaration of mode_valid custom callback so that the passed modes are const. I also changed in the platforms I found. Not even compiled it though. Signed-off-by: Jose Abreu <joabreu@synopsys.com> Acked-by: Neil Armstrong <narmstrong@baylibre.com> Acked-by: Philipp Zabel <p.zabel@pengutronix.de> Cc: Carlos Palminha <palminha@synopsys.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Archit Taneja <architt@codeaurora.org> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Laurent Pinchart <Laurent.pinchart@ideasonboard.com> Cc: David Airlie <airlied@linux.ie> Cc: Philipp Zabel <p.zabel@pengutronix.de> Cc: Carlo Caione <carlo@caione.org> Cc: Kevin Hilman <khilman@baylibre.com> Cc: Mark Yao <mark.yao@rock-chips.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/3d8d449e4d13d2535fa292c75f5fa931de4a4fa8.1495720737.git.joabreu@synopsys.com
2017-05-30drm/bridge: analogix-anx78xx: Use bridge->mode_valid() callbackJose Abreu1-7/+7
Now that we have a callback to check if bridge supports a given mode we can use it in Analogix bridge so that we restrict the number of probbed modes to the ones we can actually display. Also, there is no need to use mode_fixup() callback as mode_valid() will handle the mode validation. Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Jose Abreu <joabreu@synopsys.com> Cc: Carlos Palminha <palminha@synopsys.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Archit Taneja <architt@codeaurora.org> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Laurent Pinchart <Laurent.pinchart@ideasonboard.com> Cc: David Airlie <airlied@linux.ie> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/1d0ed1858ae56c827bd09cc1fa6ff4a05d1530eb.1495720737.git.joabreu@synopsys.com
2017-05-16drm/bridge: fix include notation and remove -Iinclude/drm flagMasahiro Yamada3-15/+9
Include <drm/*.h> instead of relative path from include/drm, then remove the -Iinclude/drm compiler flag. While we are here, sort the touched parts alphabetically. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1493009447-31524-7-git-send-email-yamada.masahiro@socionext.com
2017-05-04Merge tag 'drm-for-v4.12' of git://people.freedesktop.org/~airlied/linux into drm-misc-nextSean Paul1-0/+15
Backmerging Dave's 'drm-for-v4.12' pull request now that it's landed. There are a bunch of non-drm changes which are just random bits we hadn't yet picked up in misc-next. main drm pull request for 4.12 kernel Signed-off-by: Sean Paul <seanpaul@chromium.org> Link: http://patchwork.freedesktop.org/patch/msgid/CAPM=9ty0jHgzG18zOr5CYODyTqZfH55kOCOFqNnXiWnTb_uNWw@mail.gmail.com
2017-04-20drm: dw-hdmi: gate audio clock from the I2S enablement callbacksRomain Perier1-6/+14
Currently, the audio sampler clock is enabled from dw_hdmi_setup() at step E. and is kept enabled for later use. This clock should be enabled and disabled along with the actual audio stream and not always on (that is bad for PM). Furthermore, as described by the datasheet, the I2S variant needs to gate/ungate the clock when the stream is enabled/disabled. This commit adds a parameter to hdmi_audio_enable_clk() that controls when the audio sample clock must be enabled or disabled. Then, it adds the call to this function from dw_hdmi_i2s_audio_enable() and dw_hdmi_i2s_audio_disable(). Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Romain Perier <romain.perier@collabora.com> Link: http://patchwork.freedesktop.org/patch/msgid/20170414083113.4255-3-romain.perier@collabora.com Signed-off-by: Archit Taneja <architt@codeaurora.org>
2017-04-20drm: dw-hdmi: add specific I2S and AHB functions for stream handlingRomain Perier1-2/+24
Currently, CTS+N is forced to zero as a workaround of the IP block for i.MX platforms. This is requested in the datasheet of the corresponding IP for AHB mode only. However, we have seen that it introduces glitches or delays when playing a sound on HDMI for I2S mode. This proves that we cannot keep the current functions for handling audio stream as-is if these contain workaround that are specific to a mode. This commit introduces two callbacks, one for each variant. dw_hdmi_setup defines the right function depending on the detected variant. Then, the exported functions dw_hdmi_audio_enable and dw_hdmi_audio_disable calls the corresponding callbacks Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Romain Perier <romain.perier@collabora.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/20170414083113.4255-2-romain.perier@collabora.com
2017-04-13drm/bridge: sii902x: Add missing \n to the end of some dev_err messagesLiu Ying1-3/+3
Trivial fix. Some dev_err messages in this driver are missing \n, so add them. Signed-off-by: Liu Ying <gnuiyl@gmail.com> Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Link: http://patchwork.freedesktop.org/patch/msgid/1491877339-19913-1-git-send-email-gnuiyl@gmail.com
2017-04-10drm: dw-hdmi: Implement the mode_fixup drm helperRomain Perier1-0/+15
This helper is supposed to validate or reject the modeline before it applied by the mode setting. Currently this function has been dropped, it was previously set to a dummy function that always returned true. For both cases, this means that userspace can ask for a bad modeline that will be always accepted. On some platforms, like Rockchip, the drm dw_hdmi-rockchip variant driver already implements the atomic_check drm helper, so mode_fixup cannot be handled and implemented there (as drm_atomic_helper relies on either atomic_check or mode_fixup). This commit implements this helper. It only checks that this mode is correct from the connector point of view. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Romain Perier <romain.perier@collabora.com> Signed-off-by: Archit Taneja <architt@codeaurora.org> Link: http://patchwork.freedesktop.org/patch/msgid/20170407121743.4142-1-romain.perier@collabora.com
2017-04-07drm: bridge: analogix: Destroy connector & encoder when unbindingJeffy Chen1-0/+2
Normally we do this in drm_mode_config_cleanup. But: 1/ analogix dp's connector is allocated in bind, and freed after unbind. So we need to destroy it in unbind to avoid further access. 2/ the drm bridge is attached in bind, and detached in encoder cleanup. So we need to destroy encoder in unbind. Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Sean Paul <seanpaul@chromium.org> Link: http://patchwork.freedesktop.org/patch/msgid/1491481885-13775-5-git-send-email-jeffy.chen@rock-chips.com
2017-04-07drm: bridge: analogix: Disable clock when unbindingJeffy Chen1-0/+1
The clock is enabled when binding analogix dp. Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Sean Paul <seanpaul@chromium.org> Link: http://patchwork.freedesktop.org/patch/msgid/1491481885-13775-4-git-send-email-jeffy.chen@rock-chips.com
2017-04-07drm: bridge: analogix: Unregister dp aux when unbindingJeffy Chen1-0/+1
The dp aux is registered when binding analogix dp. Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Sean Paul <seanpaul@chromium.org> Link: http://patchwork.freedesktop.org/patch/msgid/1491481885-13775-3-git-send-email-jeffy.chen@rock-chips.com
2017-04-07drm: bridge: analogix: Detach panel when unbinding analogix dpJeffy Chen1-0/+2
The panel is attached when binding analogix dp. Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Sean Paul <seanpaul@chromium.org> Link: http://patchwork.freedesktop.org/patch/msgid/1491481885-13775-2-git-send-email-jeffy.chen@rock-chips.com
2017-04-07drm: bridge: dw-hdmi: fix input format/encoding from plat_dataNeil Armstrong1-2/+2
The plat_data->input_bus_format and plat_data->input_bus_encoding are unsigned long and are always >=0, but the value 0 was still considered as RGB888 for input_bus_format and default color space for input_bus_encoding in the reworked code. This patch changes the if statement check for a non-zero value to either use the default input bus_format and/or bus_encoding for a zero value and the provided bus_format and/or bus_encoding for a non zero value. Thanks to Dan Carpenter for his bug report at [1]. Tested on Amlogic P230 (with CSC enabled for YUV444 to RGB) and Rockchip RK3288 ACT8846 EVB Board (no CSC involved, direct RGB passthrough). [1] http://lkml.kernel.org/r/20170406052120.GA26578@mwanda Cc: Dan Carpenter <dan.carpenter@oracle.com> Fixes: def23aa7e982 ("drm: bridge: dw-hdmi: Switch to V4L bus format and encodings") Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Reviewed-by: Archit Taneja <architt@codeaurora.org> [narmstrong@baylibre.com: reworded commit message and added Fixes tag] Link: http://patchwork.freedesktop.org/patch/msgid/1491471244-24989-1-git-send-email-narmstrong@baylibre.com
2017-04-06drm: convert drivers to use drm_of_find_panel_or_bridgeRob Herring3-48/+11
Similar to the previous commit, convert drivers open coding OF graph parsing to use drm_of_find_panel_or_bridge instead. This changes some error messages to debug messages (in the graph core). Graph connections are often "no connects" depending on the particular board, so we want to avoid spurious messages. Plus the kernel is not a DT validator. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Archit Taneja <architt@codeaurora.org> Tested-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> [seanpaul dropped rockchip changes since they're now obsolete] Signed-off-by: Sean Paul <seanpaul@chromium.org>
2017-04-06drm: convert drivers to use of_graph_get_remote_nodeRob Herring3-32/+10
Convert drivers to use the new of_graph_get_remote_node() helper instead of parsing the endpoint node and then getting the remote device node. Now drivers can just specify the device node and which port/endpoint and get back the connected remote device node. The details of the graph binding are nicely abstracted into the core OF graph code. This changes some error messages to debug messages (in the graph core). Graph connections are often "no connects" depending on the particular board, so we want to avoid spurious messages. Plus the kernel is not a DT validator. Signed-off-by: Rob Herring <robh@kernel.org> Acked-by: Neil Armstrong <narmstrong@baylibre.com> Tested-by: Liviu Dudau <liviu.dudau@arm.com> Tested-by: Eric Anholt <eric@anholt.net> Tested-by: Jyri Sarha <jsarha@ti.com> Tested by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Sean Paul <seanpaul@chromium.org>
2017-04-06drm: bridge: dw-hdmi: Add a missing break statementDan Carpenter1-0/+1
There was supposed to be a break before the next case statement. Fixes: def23aa7e982 ("drm: bridge: dw-hdmi: Switch to V4L bus format and encodings") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Link: http://patchwork.freedesktop.org/patch/msgid/20170406052132.GA26605@mwanda
2017-04-06drm: bridge: dw-hdmi: remove unused hdmi_bus_fmt_is_yuv420Neil Armstrong1-14/+0
Remove usused yet hdmi_bus_fmt_is_yuv420 function. Fixes: def23aa7e982 ("drm: bridge: dw-hdmi: Switch to V4L bus format and encodings") Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Link: http://patchwork.freedesktop.org/patch/msgid/1491377579-9353-1-git-send-email-narmstrong@baylibre.com
2017-04-04drm: bridge: dw-hdmi: Move HPD handling to PHY operationsNeil Armstrong1-54/+81
The HDMI TX controller support HPD and RXSENSE signaling from the PHY via it's STAT0 PHY interface, but some vendor PHYs can manage these signals independently from the controller, thus these STAT0 handling should be moved to PHY specific operations and become optional. The existing STAT0 HPD and RXSENSE handling code is refactored into a supplementaty set of default PHY operations that are used automatically when the platform glue doesn't provide its own operations. Reviewed-by: Jose Abreu <joabreu@synopsys.com> Reviewed-by: Archit Taneja <architt@codeaurora.org> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Link: http://patchwork.freedesktop.org/patch/msgid/1491309119-24220-2-git-send-email-narmstrong@baylibre.com