Re: [PATCH v3 2/3] drm/panel/lg-sw43408: select CONFIG_DRM_DISPLAY_DP_HELPER
On 22/05/2024 08:25, Dmitry Baryshkov wrote: This panel driver uses DSC PPS functions and as such depends on the DRM_DISPLAY_DP_HELPER. Select this symbol to make required functions available to the driver. Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202404200800.kysryyli-...@intel.com/ Fixes: 069a6c0e94f9 ("drm: panel: Add LG sw43408 panel driver") Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/panel/Kconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index 4a2f621433ef..3e3f63479544 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -340,6 +340,8 @@ config DRM_PANEL_LG_SW43408 depends on OF depends on DRM_MIPI_DSI depends on BACKLIGHT_CLASS_DEVICE + select DRM_DISPLAY_DSC_HELPER + select DRM_DISPLAY_HELPER help Say Y here if you want to enable support for LG sw43408 panel. The panel has a 1080x2160@60Hz resolution and uses 24 bit RGB per Reviewed-by: Neil Armstrong
Re: [PATCH v3 3/3] drm/panel/lg-sw43408: mark sw43408_backlight_ops as static
On 22/05/2024 08:25, Dmitry Baryshkov wrote: Fix sparse warning regarding symbol 'sw43408_backlight_ops' not being declared. Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202404200739.hbwzvohr-...@intel.com/ Reviewed-by: Neil Armstrong Fixes: 069a6c0e94f9 ("drm: panel: Add LG sw43408 panel driver") Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/panel/panel-lg-sw43408.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c index 115f4702d59f..2b3a73696dce 100644 --- a/drivers/gpu/drm/panel/panel-lg-sw43408.c +++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c @@ -182,7 +182,7 @@ static int sw43408_backlight_update_status(struct backlight_device *bl) return mipi_dsi_dcs_set_display_brightness_large(dsi, brightness); } -const struct backlight_ops sw43408_backlight_ops = { +static const struct backlight_ops sw43408_backlight_ops = { .update_status = sw43408_backlight_update_status, }; Reviewed-by: Neil Armstrong
Re: [PATCH] MAINTAINERS: drm/ci: add entries for xfail files
On 19/09/2023 20:22, Helen Koike wrote: DRM CI keeps track of which tests are failing, flaking or being skipped by the ci in the expectations files. Add entries for those files to the corresponding driver maintainer, so they can be notified when they change. Signed-off-by: Helen Koike --- For reference: https://www.mail-archive.com/dri-devel@lists.freedesktop.org/msg463165.html MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 90f13281d297..740a2ce2689c 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -6614,6 +6614,7 @@ S:Maintained B:https://gitlab.freedesktop.org/drm/msm/-/issues T:git https://gitlab.freedesktop.org/drm/msm.git F:Documentation/devicetree/bindings/display/msm/ +F: drivers/gpu/drm/ci/xfails/msm* F:drivers/gpu/drm/msm/ F:include/uapi/drm/msm_drm.h @@ -6886,6 +6887,7 @@ T: git git://anongit.freedesktop.org/drm/drm-misc F:Documentation/devicetree/bindings/display/amlogic,meson-dw-hdmi.yaml F:Documentation/devicetree/bindings/display/amlogic,meson-vpu.yaml F:Documentation/gpu/meson.rst +F: drivers/gpu/drm/ci/xfails/meson* F:drivers/gpu/drm/meson/ DRM DRIVERS FOR ATMEL HLCDC @@ -6994,6 +6996,7 @@ L:dri-de...@lists.freedesktop.org L:linux-media...@lists.infradead.org (moderated for non-subscribers) S:Supported F:Documentation/devicetree/bindings/display/mediatek/ +F: drivers/gpu/drm/ci/xfails/mediatek* F:drivers/gpu/drm/mediatek/ F:drivers/phy/mediatek/phy-mtk-dp.c F:drivers/phy/mediatek/phy-mtk-hdmi* @@ -7034,6 +7037,7 @@ L:dri-de...@lists.freedesktop.org S:Maintained T:git git://anongit.freedesktop.org/drm/drm-misc F:Documentation/devicetree/bindings/display/rockchip/ +F: drivers/gpu/drm/ci/xfails/rockchip* F:drivers/gpu/drm/rockchip/ DRM DRIVERS FOR STI @@ -10476,6 +10480,7 @@ C: irc://irc.oftc.net/intel-gfx T:git git://anongit.freedesktop.org/drm-intel F:Documentation/ABI/testing/sysfs-driver-intel-i915-hwmon F:Documentation/gpu/i915.rst +F: drivers/gpu/drm/ci/xfails/i915* F:drivers/gpu/drm/i915/ F:include/drm/i915* F:include/uapi/drm/i915_drm.h @@ -17862,6 +17867,7 @@ C: irc://irc.oftc.net/radeon T:git https://gitlab.freedesktop.org/agd5f/linux.git F:Documentation/gpu/amdgpu/ F:drivers/gpu/drm/amd/ +F: drivers/gpu/drm/ci/xfails/amd* F:drivers/gpu/drm/radeon/ F:include/uapi/drm/amdgpu_drm.h F:include/uapi/drm/radeon_drm.h @@ -22846,6 +22852,7 @@ L: dri-de...@lists.freedesktop.org L:virtualizat...@lists.linux-foundation.org S:Maintained T:git git://anongit.freedesktop.org/drm/drm-misc +F: drivers/gpu/drm/ci/xfails/virtio* F:drivers/gpu/drm/virtio/ F:include/uapi/linux/virtio_gpu.h Reviewed-by: Neil Armstrong
Re: [PATCH 2/4] drm/bridge-connector: handle subconnector types
On 29/07/2023 02:49, Dmitry Baryshkov wrote: If the created connector type supports subconnector type property, create and attach corresponding it. The default subtype value is 0, which maps to the DRM_MODE_SUBCONNECTOR_Unknown type. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/drm_bridge_connector.c | 33 +- include/drm/drm_bridge.h | 4 2 files changed, 36 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/drm_bridge_connector.c b/drivers/gpu/drm/drm_bridge_connector.c index 07b5930b1282..a7b92f0d2430 100644 --- a/drivers/gpu/drm/drm_bridge_connector.c +++ b/drivers/gpu/drm/drm_bridge_connector.c @@ -329,7 +329,9 @@ struct drm_connector *drm_bridge_connector_init(struct drm_device *drm, struct drm_connector *connector; struct i2c_adapter *ddc = NULL; struct drm_bridge *bridge, *panel_bridge = NULL; + enum drm_mode_subconnector subconnector; int connector_type; + int ret; bridge_connector = kzalloc(sizeof(*bridge_connector), GFP_KERNEL); if (!bridge_connector) @@ -365,8 +367,10 @@ struct drm_connector *drm_bridge_connector_init(struct drm_device *drm, if (bridge->ops & DRM_BRIDGE_OP_MODES) bridge_connector->bridge_modes = bridge; - if (!drm_bridge_get_next_bridge(bridge)) + if (!drm_bridge_get_next_bridge(bridge)) { connector_type = bridge->type; + subconnector = bridge->subtype; + } #ifdef CONFIG_OF if (!drm_bridge_get_next_bridge(bridge) && @@ -399,6 +403,33 @@ struct drm_connector *drm_bridge_connector_init(struct drm_device *drm, if (panel_bridge) drm_panel_bridge_set_orientation(connector, panel_bridge); + if (connector_type == DRM_MODE_CONNECTOR_DisplayPort) { + drm_connector_attach_dp_subconnector_property(connector, subconnector); + } else if (connector_type == DRM_MODE_CONNECTOR_DVII) { + ret = drm_mode_create_dvi_i_properties(drm); + if (ret) + return ERR_PTR(ret); + + drm_object_attach_property(>base, + drm->mode_config.dvi_i_subconnector_property, + subconnector); + } else if (connector_type == DRM_MODE_CONNECTOR_TV) { + ret = drm_mode_create_tv_properties(drm, + BIT(DRM_MODE_TV_MODE_NTSC) | + BIT(DRM_MODE_TV_MODE_NTSC_443) | + BIT(DRM_MODE_TV_MODE_NTSC_J) | + BIT(DRM_MODE_TV_MODE_PAL) | + BIT(DRM_MODE_TV_MODE_PAL_M) | + BIT(DRM_MODE_TV_MODE_PAL_N) | + BIT(DRM_MODE_TV_MODE_SECAM)); + if (ret) + return ERR_PTR(ret); I don't think this is right, this should be called from the appropriate encoder device depending on the analog tv mode capabilities. + + drm_object_attach_property(>base, + drm->mode_config.tv_subconnector_property, + subconnector); Here, only add the property if drm->mode_config.tv_subconnector_property exists, and perhaps add a warning if not. AFAIK same for DRM_MODE_CONNECTOR_DVII. + } + return connector; } EXPORT_SYMBOL_GPL(drm_bridge_connector_init); diff --git a/include/drm/drm_bridge.h b/include/drm/drm_bridge.h index bf964cdfb330..68b14ac5ac0d 100644 --- a/include/drm/drm_bridge.h +++ b/include/drm/drm_bridge.h @@ -739,6 +739,10 @@ struct drm_bridge { * identifies the type of connected display. */ int type; + /** +* @subtype: the subtype of the connector for the DP/TV/DVI-I cases. +*/ + enum drm_mode_subconnector subtype; /** * @interlace_allowed: Indicate that the bridge can handle interlaced * modes.
Re: [PATCH 1/2] drm/amdgpu: Fix no-procfs build
Hi, On Thu, 25 May 2023 08:52:24 -0700, Rob Clark wrote: > Fixes undefined symbol when PROC_FS is not enabled. > > Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (drm-misc-next) [1/2] drm/amdgpu: Fix no-procfs build https://cgit.freedesktop.org/drm/drm-misc/commit/?id=1a56fcf08ae463a4564d111356091b2bdb6c7bce [2/2] drm/amdgpu: Remove duplicate fdinfo fields (no commit info) -- Neil
Re: [PATCH 2/2] drm/amdgpu: Remove duplicate fdinfo fields
Hi Rob, On 25/05/2023 17:52, Rob Clark wrote: From: Rob Clark Some of the fields that are handled by drm_show_fdinfo() crept back in when rebasing the patch. Remove them again. Fixes: 376c25f8ca47 ("drm/amdgpu: Switch to fdinfo helper") Signed-off-by: Rob Clark --- drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c index 13d7413d4ca3..a93e5627901a 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c @@ -80,23 +80,20 @@ void amdgpu_show_fdinfo(struct drm_printer *p, struct drm_file *file) amdgpu_ctx_mgr_usage(>ctx_mgr, usage); /* * ** * For text output format description please see drm-usage-stats.rst! * ** */ drm_printf(p, "pasid:\t%u\n", fpriv->vm.pasid); - drm_printf(p, "drm-driver:\t%s\n", file->minor->dev->driver->name); - drm_printf(p, "drm-pdev:\t%04x:%02x:%02x.%d\n", domain, bus, dev, fn); - drm_printf(p, "drm-client-id:\t%Lu\n", vm->immediate.fence_context); drm_printf(p, "drm-memory-vram:\t%llu KiB\n", stats.vram/1024UL); drm_printf(p, "drm-memory-gtt: \t%llu KiB\n", stats.gtt/1024UL); drm_printf(p, "drm-memory-cpu: \t%llu KiB\n", stats.cpu/1024UL); drm_printf(p, "amd-memory-visible-vram:\t%llu KiB\n", stats.visible_vram/1024UL); drm_printf(p, "amd-evicted-vram:\t%llu KiB\n", stats.evicted_vram/1024UL); drm_printf(p, "amd-evicted-visible-vram:\t%llu KiB\n", stats.evicted_visible_vram/1024UL); drm_printf(p, "amd-requested-vram:\t%llu KiB\n", I got: drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c: In function ‘amdgpu_show_fdinfo’: drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c:64:32: error: variable ‘domain’ set but not used [-Werror=unused-but-set-variable] 64 | uint32_t bus, dev, fn, domain; |^~ drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c:64:28: error: variable ‘fn’ set but not used [-Werror=unused-but-set-variable] 64 | uint32_t bus, dev, fn, domain; |^~ drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c:64:23: error: variable ‘dev’ set but not used [-Werror=unused-but-set-variable] 64 | uint32_t bus, dev, fn, domain; | ^~~ drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c:64:18: error: variable ‘bus’ set but not used [-Werror=unused-but-set-variable] 64 | uint32_t bus, dev, fn, domain; after applying patch 2, can you fix it ? Seems you can keep the drm-pdev print line I applied patch 1 Thanks, Neil
Re: (subset) [PATCH v4 0/9] drm: fdinfo memory stats
On 24/05/2023 18:10, Neil Armstrong wrote: Hi, On Mon, 15 May 2023 07:30:07 -0700, Rob Clark wrote: Similar motivation to other similar recent attempt[1]. But with an attempt to have some shared code for this. As well as documentation. It is probably a bit UMA-centric, I guess devices with VRAM might want some placement stats as well. But this seems like a reasonable start. Basic gputop support: https://patchwork.freedesktop.org/series/116236/ And already nvtop support: https://github.com/Syllo/nvtop/pull/204 [...] Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (drm-misc-next) [1/9] drm/docs: Fix usage stats typos https://cgit.freedesktop.org/drm/drm-misc/commit/?id=0020582a8afe9a8570f80ec503c59bf049a616de [2/9] drm: Add common fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=3f09a0cd4ea3b9d34495450d686227d48e7ec648 [3/9] drm/msm: Switch to fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=51d86ee5e07ccef85af04ee9850b0baa107999b6 [4/9] drm/amdgpu: Switch to fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=376c25f8ca47084c4f0aff0f14684780756ccef4 [5/9] drm: Add fdinfo memory stats https://cgit.freedesktop.org/drm/drm-misc/commit/?id=686b21b5f6ca2f8a716f9a4ade07246dbfb2713e [6/9] drm/msm: Add memory stats to fdinfo https://cgit.freedesktop.org/drm/drm-misc/commit/?id=3e9757f5ddb98238226ad68a1609aa313de35adb [7/9] drm/doc: Relax fdinfo string constraints https://cgit.freedesktop.org/drm/drm-misc/commit/?id=90d63a150b85fd1debb9c01237fb78faee02746a Hmm no idea what happened, but I really applied v5 ! Neil
Re: [PATCH v5 0/7] drm: fdinfo memory stats
Hi, On Wed, 24 May 2023 08:59:30 -0700, Rob Clark wrote: > From: Rob Clark > > Similar motivation to other similar recent attempt[1]. But with an > attempt to have some shared code for this. As well as documentation. > > It is probably a bit UMA-centric, I guess devices with VRAM might want > some placement stats as well. But this seems like a reasonable start. > > [...] Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (drm-misc-next) [1/7] drm/docs: Fix usage stats typos https://cgit.freedesktop.org/drm/drm-misc/commit/?id=0020582a8afe9a8570f80ec503c59bf049a616de [2/7] drm: Add common fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=3f09a0cd4ea3b9d34495450d686227d48e7ec648 [3/7] drm/msm: Switch to fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=51d86ee5e07ccef85af04ee9850b0baa107999b6 [4/7] drm/amdgpu: Switch to fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=376c25f8ca47084c4f0aff0f14684780756ccef4 [5/7] drm: Add fdinfo memory stats https://cgit.freedesktop.org/drm/drm-misc/commit/?id=686b21b5f6ca2f8a716f9a4ade07246dbfb2713e [6/7] drm/msm: Add memory stats to fdinfo https://cgit.freedesktop.org/drm/drm-misc/commit/?id=3e9757f5ddb98238226ad68a1609aa313de35adb [7/7] drm/doc: Relax fdinfo string constraints https://cgit.freedesktop.org/drm/drm-misc/commit/?id=90d63a150b85fd1debb9c01237fb78faee02746a -- Neil
Re: (subset) [PATCH v4 0/9] drm: fdinfo memory stats
Hi, On Mon, 15 May 2023 07:30:07 -0700, Rob Clark wrote: > Similar motivation to other similar recent attempt[1]. But with an > attempt to have some shared code for this. As well as documentation. > > It is probably a bit UMA-centric, I guess devices with VRAM might want > some placement stats as well. But this seems like a reasonable start. > > Basic gputop support: https://patchwork.freedesktop.org/series/116236/ > And already nvtop support: https://github.com/Syllo/nvtop/pull/204 > > [...] Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (drm-misc-next) [1/9] drm/docs: Fix usage stats typos https://cgit.freedesktop.org/drm/drm-misc/commit/?id=0020582a8afe9a8570f80ec503c59bf049a616de [2/9] drm: Add common fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=3f09a0cd4ea3b9d34495450d686227d48e7ec648 [3/9] drm/msm: Switch to fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=51d86ee5e07ccef85af04ee9850b0baa107999b6 [4/9] drm/amdgpu: Switch to fdinfo helper https://cgit.freedesktop.org/drm/drm-misc/commit/?id=376c25f8ca47084c4f0aff0f14684780756ccef4 [5/9] drm: Add fdinfo memory stats https://cgit.freedesktop.org/drm/drm-misc/commit/?id=686b21b5f6ca2f8a716f9a4ade07246dbfb2713e [6/9] drm/msm: Add memory stats to fdinfo https://cgit.freedesktop.org/drm/drm-misc/commit/?id=3e9757f5ddb98238226ad68a1609aa313de35adb [7/9] drm/doc: Relax fdinfo string constraints https://cgit.freedesktop.org/drm/drm-misc/commit/?id=90d63a150b85fd1debb9c01237fb78faee02746a -- Neil
Re: [PATCH 01/13] drm/connector: Add define for HDMI 1.4 Maximum Pixel Rate
On 02/11/2021 15:59, Maxime Ripard wrote: > A lot of drivers open-code the HDMI 1.4 maximum pixel rate in their > driver to test whether the resolutions are supported or if the > scrambling needs to be enabled. > > Let's create a common define for everyone to use it. > > Cc: Alex Deucher > Cc: amd-gfx@lists.freedesktop.org > Cc: Andrzej Hajda > Cc: Benjamin Gaignard > Cc: "Christian König" > Cc: Emma Anholt > Cc: intel-...@lists.freedesktop.org > Cc: Jani Nikula > Cc: Jernej Skrabec > Cc: Jerome Brunet > Cc: Jonas Karlman > Cc: Jonathan Hunter > Cc: Joonas Lahtinen > Cc: Kevin Hilman > Cc: Laurent Pinchart > Cc: linux-amlo...@lists.infradead.org > Cc: linux-arm-ker...@lists.infradead.org > Cc: linux-te...@vger.kernel.org > Cc: Martin Blumenstingl > Cc: Neil Armstrong > Cc: "Pan, Xinhui" > Cc: Robert Foss > Cc: Rodrigo Vivi > Cc: Thierry Reding > Signed-off-by: Maxime Ripard > --- > drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 4 ++-- > drivers/gpu/drm/drm_edid.c | 2 +- > drivers/gpu/drm/i915/display/intel_hdmi.c | 2 +- > drivers/gpu/drm/meson/meson_dw_hdmi.c | 4 ++-- > drivers/gpu/drm/radeon/radeon_encoders.c | 2 +- > drivers/gpu/drm/sti/sti_hdmi_tx3g4c28phy.c | 2 +- > drivers/gpu/drm/tegra/sor.c| 8 > drivers/gpu/drm/vc4/vc4_hdmi.c | 4 ++-- > include/drm/drm_connector.h| 2 ++ > 9 files changed, 16 insertions(+), 14 deletions(-) For meson & bridge/synopsys/dw-hdmi: Acked-by: Neil Armstrong > > diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c > b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c > index 62ae63565d3a..3a58db357be0 100644 > --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c > +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c > @@ -46,7 +46,7 @@ > /* DW-HDMI Controller >= 0x200a are at least compliant with SCDC version 1 */ > #define SCDC_MIN_SOURCE_VERSION 0x1 > > -#define HDMI14_MAX_TMDSCLK 34000 > +#define HDMI14_MAX_TMDSCLK (DRM_HDMI_14_MAX_TMDS_CLK_KHZ * 1000) > > enum hdmi_datamap { > RGB444_8B = 0x01, > @@ -1264,7 +1264,7 @@ static bool dw_hdmi_support_scdc(struct dw_hdmi *hdmi, >* for low rates is not supported either >*/ > if (!display->hdmi.scdc.scrambling.low_rates && > - display->max_tmds_clock <= 34) > + display->max_tmds_clock <= DRM_HDMI_14_MAX_TMDS_CLK_KHZ) > return false; > > return true; > diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c > index 7aa2a56a71c8..ec8fb2d098ae 100644 > --- a/drivers/gpu/drm/drm_edid.c > +++ b/drivers/gpu/drm/drm_edid.c > @@ -4966,7 +4966,7 @@ static void drm_parse_hdmi_forum_vsdb(struct > drm_connector *connector, > u32 max_tmds_clock = hf_vsdb[5] * 5000; > struct drm_scdc *scdc = >scdc; > > - if (max_tmds_clock > 34) { > + if (max_tmds_clock > DRM_HDMI_14_MAX_TMDS_CLK_KHZ) { > display->max_tmds_clock = max_tmds_clock; > DRM_DEBUG_KMS("HF-VSDB: max TMDS clock %d kHz\n", > display->max_tmds_clock); > diff --git a/drivers/gpu/drm/i915/display/intel_hdmi.c > b/drivers/gpu/drm/i915/display/intel_hdmi.c > index d2e61f6c6e08..0666203d52b7 100644 > --- a/drivers/gpu/drm/i915/display/intel_hdmi.c > +++ b/drivers/gpu/drm/i915/display/intel_hdmi.c > @@ -2226,7 +2226,7 @@ int intel_hdmi_compute_config(struct intel_encoder > *encoder, > if (scdc->scrambling.low_rates) > pipe_config->hdmi_scrambling = true; > > - if (pipe_config->port_clock > 34) { > + if (pipe_config->port_clock > DRM_HDMI_14_MAX_TMDS_CLK_KHZ) { > pipe_config->hdmi_scrambling = true; > pipe_config->hdmi_high_tmds_clock_ratio = true; > } > diff --git a/drivers/gpu/drm/meson/meson_dw_hdmi.c > b/drivers/gpu/drm/meson/meson_dw_hdmi.c > index 0afbd1e70bfc..8078667aea0e 100644 > --- a/drivers/gpu/drm/meson/meson_dw_hdmi.c > +++ b/drivers/gpu/drm/meson/meson_dw_hdmi.c > @@ -434,7 +434,7 @@ static int dw_hdmi_phy_init(struct dw_hdmi *hdmi, void > *data, > readl_relaxed(priv->io_base + _REG(VPU_HDMI_SETTING)); > > DRM_DEBUG_DRIVER("\"%s\" div%d\n", mode->name, > - mode->clock > 34 ? 40 : 10); > + mode->clock > DRM_HDMI_14_MAX_TMDS_CLK_KHZ ? 40 : 10); > > /* Enable clocks */ > regm
Re: [PATCH] drm/aperture: Pass DRM driver structure instead of driver name
Hi, On 29/06/2021 15:58, Thomas Zimmermann wrote: > Print the name of the DRM driver when taking over fbdev devices. Makes > the output to dmesg more consistent. Note that the driver name is only > used for printing a string to the kernel log. No UAPI is affected by this > change. > > Signed-off-by: Thomas Zimmermann > --- ... > drivers/gpu/drm/meson/meson_drv.c | 2 +- Acked-by: Neil Armstrong ... > > diff --git a/drivers/gpu/drm/meson/meson_drv.c > b/drivers/gpu/drm/meson/meson_drv.c > index a7388bf7c838..3d0ccc7eef1b 100644 > --- a/drivers/gpu/drm/meson/meson_drv.c > +++ b/drivers/gpu/drm/meson/meson_drv.c > @@ -285,7 +285,7 @@ static int meson_drv_bind_master(struct device *dev, bool > has_components) >* Remove early framebuffers (ie. simplefb). The framebuffer can be >* located anywhere in RAM >*/ > - ret = drm_aperture_remove_framebuffers(false, "meson-drm-fb"); > + ret = drm_aperture_remove_framebuffers(false, _driver); > if (ret) > goto free_drm; > ... ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH 2/2] drm/edid: Add alternate clock for SMPTE 4K
On 12/11/2019 08:53, Wayne Lin wrote: > [Why] > In hdmi_mode_alternate_clock(), it adds an exception for VIC 4 > mode (4096x2160@24) due to there is no alternate clock defined for > that mode in HDMI1.4b. But HDMI2.0 adds 23.98Hz for that mode. > > [How] > Remove the exception Shouldn't it be only bypassed when the sink is HDMI2 ? Neil > > Signed-off-by: Wayne Lin > --- > drivers/gpu/drm/drm_edid.c | 3 --- > 1 file changed, 3 deletions(-) > > diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c > index fcd7ae29049d..ed2782c53a93 100644 > --- a/drivers/gpu/drm/drm_edid.c > +++ b/drivers/gpu/drm/drm_edid.c > @@ -3126,9 +3126,6 @@ static enum hdmi_picture_aspect > drm_get_hdmi_aspect_ratio(const u8 video_code) > static unsigned int > hdmi_mode_alternate_clock(const struct drm_display_mode *hdmi_mode) > { > - if (hdmi_mode->vdisplay == 4096 && hdmi_mode->hdisplay == 2160) > - return hdmi_mode->clock; > - > return cea_mode_alternate_clock(hdmi_mode); > } > > ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH v7 0/9] drm: cec: convert DRM drivers to the new notifier API
Hi Dariusz, Hans, I can apply the dw-hdmi patches if necessary. Neil On 19/08/2019 11:38, Hans Verkuil wrote: > Hi all, > > The patches in this series can be applied independently from each other. > > If you maintain one of these drivers and you want to merge it for v5.4 > yourself, then please do so and let me know. If you prefer I commit it > to drm-misc, then please review and (hopefully) Ack the patch. > > I would really like to get this in for v5.4 so I can get the userspace > bits in for v5.4 as well through the media subsystem. > > Dariusz, can you post a v7.1 for patch 5/9 fixing the typo? > > Thanks! > > Hans > > On 8/14/19 12:44 PM, Dariusz Marcinkiewicz wrote: >> This series updates DRM drivers to use new CEC notifier API. >> >> Changes since v6: >> Made CEC notifiers' registration and de-registration symmetric >> in tda998x and dw-hdmi drivers. Also, accidentally dropped one >> patch in v6 (change to drm_dp_cec), brought it back now. >> Changes since v5: >> Fixed a warning about a missing comment for a new member of >> drm_dp_aux_cec struct. Sending to a wider audience, >> including maintainers of respective drivers. >> Changes since v4: >> Addressing review comments. >> Changes since v3: >> Updated adapter flags in dw-hdmi-cec. >> Changes since v2: >> Include all DRM patches from "cec: improve notifier support, >> add connector info connector info" series. >> Changes since v1: >> Those patches delay creation of notifiers until respective >> connectors are constructed. It seems that those patches, for a >> couple of drivers, by adding the delay, introduce a race between >> notifiers' creation and the IRQs handling threads - at least I >> don't see anything obvious in there that would explicitly forbid >> such races to occur. v2 adds a write barrier to make sure IRQ >> threads see the notifier once it is created (replacing the >> WRITE_ONCE I put in v1). The best thing to do here, I believe, >> would be not to have any synchronization and make sure that an IRQ >> only gets enabled after the notifier is created. >> Dariusz Marcinkiewicz (9): >> drm_dp_cec: add connector info support. >> drm/i915/intel_hdmi: use cec_notifier_conn_(un)register >> dw-hdmi-cec: use cec_notifier_cec_adap_(un)register >> tda9950: use cec_notifier_cec_adap_(un)register >> drm: tda998x: use cec_notifier_conn_(un)register >> drm: sti: use cec_notifier_conn_(un)register >> drm: tegra: use cec_notifier_conn_(un)register >> drm: dw-hdmi: use cec_notifier_conn_(un)register >> drm: exynos: exynos_hdmi: use cec_notifier_conn_(un)register >> >> .../display/amdgpu_dm/amdgpu_dm_mst_types.c | 2 +- >> drivers/gpu/drm/bridge/synopsys/dw-hdmi-cec.c | 13 +++--- >> drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 46 +-- >> drivers/gpu/drm/drm_dp_cec.c | 25 ++ >> drivers/gpu/drm/exynos/exynos_hdmi.c | 31 +++-- >> drivers/gpu/drm/i2c/tda9950.c | 12 ++--- >> drivers/gpu/drm/i2c/tda998x_drv.c | 36 ++- >> drivers/gpu/drm/i915/display/intel_dp.c | 4 +- >> drivers/gpu/drm/i915/display/intel_hdmi.c | 13 -- >> drivers/gpu/drm/nouveau/nouveau_connector.c | 3 +- >> drivers/gpu/drm/sti/sti_hdmi.c| 19 +--- >> drivers/gpu/drm/tegra/output.c| 28 --- >> include/drm/drm_dp_helper.h | 17 --- >> 13 files changed, 155 insertions(+), 94 deletions(-) >> > ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH 02/13] drm/radeon: Eliminate possible use of an uninitialized variable
Hi Andrzej, I had to revert the previous patch, so you should re-spin it entirely : After merging the drm-misc tree, today's linux-next build (x86_64 allmodconfig) failed like this: drivers/gpu/drm/radeon/radeon_connectors.c: In function 'radeon_add_legacy_connector': drivers/gpu/drm/radeon/radeon_connectors.c:2433:5: error: 'ddc' undeclared (first use in this function) ddc = _connector->ddc_bus->adapter; ^~~ drivers/gpu/drm/radeon/radeon_connectors.c:2433:5: note: each undeclared identifier is reported only once for each function it appears in Caused by commit bed7a2182de6 ("drm/radeon: Provide ddc symlink in connector sysfs directory") I have used the drm-misc tree from next-20190731 for today. == Neil On 31/07/2019 18:58, Andrzej Pietrasiewicz wrote: > ddc local variable is passed to drm_connector_init_with_ddc() and should > be NULL if no ddc is available. > > Signed-off-by: Andrzej Pietrasiewicz > --- > drivers/gpu/drm/radeon/radeon_connectors.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c > b/drivers/gpu/drm/radeon/radeon_connectors.c > index b3ad8d890801..d11131d03ed6 100644 > --- a/drivers/gpu/drm/radeon/radeon_connectors.c > +++ b/drivers/gpu/drm/radeon/radeon_connectors.c > @@ -1870,7 +1870,7 @@ radeon_add_atom_connector(struct drm_device *dev, > struct radeon_connector_atom_dig *radeon_dig_connector; > struct drm_encoder *encoder; > struct radeon_encoder *radeon_encoder; > - struct i2c_adapter *ddc; > + struct i2c_adapter *ddc = NULL; > uint32_t subpixel_order = SubPixelNone; > bool shared_ddc = false; > bool is_dp_bridge = false; >
Re: [PATCH] Revert "drm/radeon: Provide ddc symlink in connector sysfs directory"
On 01/08/2019 14:01, Daniel Vetter wrote: > On Thu, Aug 1, 2019 at 1:53 PM Neil Armstrong wrote: >> >> This reverts commit bed7a2182de6833f5d0f990a656bffb1c6000c70. >> >> It causes the following build error: >> ../drm/radeon/radeon_connectors.c: In function 'radeon_add_legacy_connector': >> ../drm/radeon/radeon_connectors.c:2433:5: error: 'ddc' undeclared (first use >> in this function) >> ddc = _connector->ddc_bus->adapter; >> ^~~ >> >> Suggested-by: Daniel Vetter >> Signed-off-by: Neil Armstrong > > Also ddc isn't initialized to NULL in the other function, so doesn't > work too well there either. > > Acked-by: Daniel Vetter Applied, Thanks Neil > > Let's try again once the tree is back in shape. > -Daniel >> --- >> drivers/gpu/drm/radeon/radeon_connectors.c | 142 ++--- >> 1 file changed, 36 insertions(+), 106 deletions(-) >> >> diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c >> b/drivers/gpu/drm/radeon/radeon_connectors.c >> index b3ad8d890801..c60d1a44d22a 100644 >> --- a/drivers/gpu/drm/radeon/radeon_connectors.c >> +++ b/drivers/gpu/drm/radeon/radeon_connectors.c >> @@ -1870,7 +1870,6 @@ radeon_add_atom_connector(struct drm_device *dev, >> struct radeon_connector_atom_dig *radeon_dig_connector; >> struct drm_encoder *encoder; >> struct radeon_encoder *radeon_encoder; >> - struct i2c_adapter *ddc; >> uint32_t subpixel_order = SubPixelNone; >> bool shared_ddc = false; >> bool is_dp_bridge = false; >> @@ -1948,21 +1947,17 @@ radeon_add_atom_connector(struct drm_device *dev, >> radeon_connector->con_priv = radeon_dig_connector; >> if (i2c_bus->valid) { >> radeon_connector->ddc_bus = radeon_i2c_lookup(rdev, >> i2c_bus); >> - if (radeon_connector->ddc_bus) { >> + if (radeon_connector->ddc_bus) >> has_aux = true; >> - ddc = _connector->ddc_bus->adapter; >> - } else { >> + else >> DRM_ERROR("DP: Failed to assign ddc bus! >> Check dmesg for i2c errors.\n"); >> - } >> } >> switch (connector_type) { >> case DRM_MODE_CONNECTOR_VGA: >> case DRM_MODE_CONNECTOR_DVIA: >> default: >> - drm_connector_init_with_ddc(dev, >> _connector->base, >> - >> _dp_connector_funcs, >> - connector_type, >> - ddc); >> + drm_connector_init(dev, _connector->base, >> + _dp_connector_funcs, >> connector_type); >> drm_connector_helper_add(_connector->base, >> >> _dp_connector_helper_funcs); >> connector->interlace_allowed = true; >> @@ -1984,10 +1979,8 @@ radeon_add_atom_connector(struct drm_device *dev, >> case DRM_MODE_CONNECTOR_HDMIA: >> case DRM_MODE_CONNECTOR_HDMIB: >> case DRM_MODE_CONNECTOR_DisplayPort: >> - drm_connector_init_with_ddc(dev, >> _connector->base, >> - >> _dp_connector_funcs, >> - connector_type, >> - ddc); >> + drm_connector_init(dev, _connector->base, >> + _dp_connector_funcs, >> connector_type); >> drm_connector_helper_add(_connector->base, >> >> _dp_connector_helper_funcs); >> >> drm_object_attach_property(_connector->base.base, >> @@ -2034,10 +2027,8 @@ radeon_add_atom_connector(struct drm_device *dev, >> break; >> case DRM_MODE_CONNECTOR_LVDS: >> case DRM_MODE_CONNECTOR_eDP: >> - drm_connector_init_with_ddc(dev, >> _connector->base, >> -
[PATCH] Revert "drm/radeon: Provide ddc symlink in connector sysfs directory"
This reverts commit bed7a2182de6833f5d0f990a656bffb1c6000c70. It causes the following build error: ../drm/radeon/radeon_connectors.c: In function 'radeon_add_legacy_connector': ../drm/radeon/radeon_connectors.c:2433:5: error: 'ddc' undeclared (first use in this function) ddc = _connector->ddc_bus->adapter; ^~~ Suggested-by: Daniel Vetter Signed-off-by: Neil Armstrong --- drivers/gpu/drm/radeon/radeon_connectors.c | 142 ++--- 1 file changed, 36 insertions(+), 106 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c b/drivers/gpu/drm/radeon/radeon_connectors.c index b3ad8d890801..c60d1a44d22a 100644 --- a/drivers/gpu/drm/radeon/radeon_connectors.c +++ b/drivers/gpu/drm/radeon/radeon_connectors.c @@ -1870,7 +1870,6 @@ radeon_add_atom_connector(struct drm_device *dev, struct radeon_connector_atom_dig *radeon_dig_connector; struct drm_encoder *encoder; struct radeon_encoder *radeon_encoder; - struct i2c_adapter *ddc; uint32_t subpixel_order = SubPixelNone; bool shared_ddc = false; bool is_dp_bridge = false; @@ -1948,21 +1947,17 @@ radeon_add_atom_connector(struct drm_device *dev, radeon_connector->con_priv = radeon_dig_connector; if (i2c_bus->valid) { radeon_connector->ddc_bus = radeon_i2c_lookup(rdev, i2c_bus); - if (radeon_connector->ddc_bus) { + if (radeon_connector->ddc_bus) has_aux = true; - ddc = _connector->ddc_bus->adapter; - } else { + else DRM_ERROR("DP: Failed to assign ddc bus! Check dmesg for i2c errors.\n"); - } } switch (connector_type) { case DRM_MODE_CONNECTOR_VGA: case DRM_MODE_CONNECTOR_DVIA: default: - drm_connector_init_with_ddc(dev, _connector->base, - _dp_connector_funcs, - connector_type, - ddc); + drm_connector_init(dev, _connector->base, + _dp_connector_funcs, connector_type); drm_connector_helper_add(_connector->base, _dp_connector_helper_funcs); connector->interlace_allowed = true; @@ -1984,10 +1979,8 @@ radeon_add_atom_connector(struct drm_device *dev, case DRM_MODE_CONNECTOR_HDMIA: case DRM_MODE_CONNECTOR_HDMIB: case DRM_MODE_CONNECTOR_DisplayPort: - drm_connector_init_with_ddc(dev, _connector->base, - _dp_connector_funcs, - connector_type, - ddc); + drm_connector_init(dev, _connector->base, + _dp_connector_funcs, connector_type); drm_connector_helper_add(_connector->base, _dp_connector_helper_funcs); drm_object_attach_property(_connector->base.base, @@ -2034,10 +2027,8 @@ radeon_add_atom_connector(struct drm_device *dev, break; case DRM_MODE_CONNECTOR_LVDS: case DRM_MODE_CONNECTOR_eDP: - drm_connector_init_with_ddc(dev, _connector->base, - _lvds_bridge_connector_funcs, - connector_type, - ddc); + drm_connector_init(dev, _connector->base, + _lvds_bridge_connector_funcs, connector_type); drm_connector_helper_add(_connector->base, _dp_connector_helper_funcs); drm_object_attach_property(_connector->base.base, @@ -2051,18 +2042,13 @@ radeon_add_atom_connector(struct drm_device *dev, } else { switch (connector_type) { case DRM_MODE_CONNECTOR_VGA: + drm_connector_init(dev, _connector->base, _vga_connector_funcs, connector_type); + drm_connector_helper_add(_connector->base, _vga_connector_helper_funcs); if (i2c_bus->valid) { radeon_connector->ddc_bus = radeon_i2c_lookup(rdev, i2c_bus); if (!radeon_connect
Re: Review required [Was: Associate ddc adapters with connectors]
Hi Andrzej, On 31/07/2019 16:22, Neil Armstrong wrote: > On 31/07/2019 15:10, Andrzej Pietrasiewicz wrote: >> W dniu 31.07.2019 o 12:40, Sam Ravnborg pisze: >>> Hi Neil. >>> >>> On Wed, Jul 31, 2019 at 10:00:14AM +0200, Neil Armstrong wrote: >>>> Hi Sam, >>>> >>>> On 26/07/2019 20:55, Sam Ravnborg wrote: >>>>> Hi all. >>>>> >>>>> Andrzej have done a good job following up on feedback and this series is >>>>> now ready. >>>>> >>>>> We need ack on the patches touching the individual drivers before we can >>>>> proceed. >>>>> Please check your drivers and get back. >>>> >>>> I can apply all core and maintainer-acked patches for now : >>>> 1, 2, 7, 10, 11, 16, 17, 18, 19, 20, 21, 22, 23 >>>> >>>> and Andrzej can resend not applied patches with Yours and Emil's >>>> Reviewed-by, >>>> so we can wait a few more days to apply them. >>> >>> Sounds like a good plan. >>> Thanks for thaking care of this. >> >> When is it good time to resend patches 3, 4, 5, 6, 8, 9, 12, 13, 14, 15, 24 >> as a >> new series? > > I'll ping you when everything is applied, build-tested and pushed on > drm-misc-next I pushed 1, 2, 7, 10, 11, 16, 17, 18, 19, 20, 21, 22, 23 : bed7a2182de6 drm/radeon: Provide ddc symlink in connector sysfs directory 5b50fa2b35a4 drm/amdgpu: Provide ddc symlink in connector sysfs directory cfb444552926 drm/bridge: ti-tfp410: Provide ddc symlink in connector sysfs directory 9ebc4d2140ad drm/bridge: dw-hdmi: Provide ddc symlink in connector sysfs directory a4f9087e85de drm/bridge: dumb-vga-dac: Provide ddc symlink in connector sysfs directory 350fd554ee44 drm/ast: Provide ddc symlink in connector sysfs directory 9572ae176a10 drm/mgag200: Provide ddc symlink in connector sysfs directory 7058e76682d7 drm: sti: Provide ddc symlink in hdmi connector sysfs directory 2ae7eb372ed4 drm/imx: imx-tve: Provide ddc symlink in connector's sysfs be0ec35940bc drm/imx: imx-ldb: Provide ddc symlink in connector's sysfs 1e8f17855ff8 drm/sun4i: hdmi: Provide ddc symlink in sun4i hdmi connector sysfs directory 100163df4203 drm: Add drm_connector_init() variant with ddc e1a29c6c5955 drm: Add ddc link in sysfs created by drm_connector Neil > > Neil > >> >> Andrzej > ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: Review required [Was: Associate ddc adapters with connectors]
On 31/07/2019 15:10, Andrzej Pietrasiewicz wrote: > W dniu 31.07.2019 o 12:40, Sam Ravnborg pisze: >> Hi Neil. >> >> On Wed, Jul 31, 2019 at 10:00:14AM +0200, Neil Armstrong wrote: >>> Hi Sam, >>> >>> On 26/07/2019 20:55, Sam Ravnborg wrote: >>>> Hi all. >>>> >>>> Andrzej have done a good job following up on feedback and this series is >>>> now ready. >>>> >>>> We need ack on the patches touching the individual drivers before we can >>>> proceed. >>>> Please check your drivers and get back. >>> >>> I can apply all core and maintainer-acked patches for now : >>> 1, 2, 7, 10, 11, 16, 17, 18, 19, 20, 21, 22, 23 >>> >>> and Andrzej can resend not applied patches with Yours and Emil's >>> Reviewed-by, >>> so we can wait a few more days to apply them. >> >> Sounds like a good plan. >> Thanks for thaking care of this. > > When is it good time to resend patches 3, 4, 5, 6, 8, 9, 12, 13, 14, 15, 24 > as a > new series? I'll ping you when everything is applied, build-tested and pushed on drm-misc-next Neil > > Andrzej ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: Review required [Was: Associate ddc adapters with connectors]
Hi Sam, On 26/07/2019 20:55, Sam Ravnborg wrote: > Hi all. > > Andrzej have done a good job following up on feedback and this series is > now ready. > > We need ack on the patches touching the individual drivers before we can > proceed. > Please check your drivers and get back. I can apply all core and maintainer-acked patches for now : 1, 2, 7, 10, 11, 16, 17, 18, 19, 20, 21, 22, 23 and Andrzej can resend not applied patches with Yours and Emil's Reviewed-by, so we can wait a few more days to apply them. Neil > > Sam > >> Hi Andezej. >> >> On Fri, Jul 26, 2019 at 07:22:54PM +0200, Andrzej Pietrasiewicz wrote: >>> It is difficult for a user to know which of the i2c adapters is for which >>> drm connector. This series addresses this problem. >>> >>> The idea is to have a symbolic link in connector's sysfs directory, e.g.: >>> >>> ls -l /sys/class/drm/card0-HDMI-A-1/ddc >>> lrwxrwxrwx 1 root root 0 Jun 24 10:42 /sys/class/drm/card0-HDMI-A-1/ddc \ >>> -> ../../../../soc/1388.i2c/i2c-2 >>> >>> The user then knows that their card0-HDMI-A-1 uses i2c-2 and can e.g. run >>> ddcutil: >>> >>> ddcutil -b 2 getvcp 0x10 >>> VCP code 0x10 (Brightness): current value =90, max value = 100 >>> >>> The first patch in the series adds struct i2c_adapter pointer to struct >>> drm_connector. If the field is used by a particular driver, then an >>> appropriate symbolic link is created by the generic code, which is also >>> added >>> by this patch. >>> >>> Patch 2 adds a new variant of drm_connector_init(), see the changelog >>> below. >>> >>> Patches 3..24 are examples of how to convert a driver to this new scheme. >>> >> ... >>> >>> v5..v6: >>> >>> - improved subject line of patch 1 >>> - added kernel-doc for drm_connector_init_with_ddc() >>> - improved kernel-doc for the ddc field of struct drm_connector >>> - added Reviewed-by in patches 17 and 18 >>> - added Acked-by in patch 2 >>> - made the ownership of ddc i2c_adapter explicit in all patches, >>> this made the affected patches much simpler >> >> Looks good now. >> Patch 1 and 2 are: >> Reviewed-by: Sam Ravnborg >> >> The remaining patches are: >> Acked-by: Sam Ravnborg >> >> Sam >> ___ >> dri-devel mailing list >> dri-de...@lists.freedesktop.org >> https://lists.freedesktop.org/mailman/listinfo/dri-devel ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH v4 19/23] drm/bridge: dw-hdmi: Provide ddc symlink in connector sysfs directory
Hi, On 30/07/2019 19:30, Sam Ravnborg wrote: > Hi Neil. > >>> Signed-off-by: Andrzej Pietrasiewicz >>> --- >>> drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 40 +++ >>> 1 file changed, 20 insertions(+), 20 deletions(-) >>> > ... >> >> Reviewed-by: Neil Armstrong > > There is now a much simpler v6 of this patch. > Care to take a look and ack/r-b? I saw it too late, I reviewed the bridge patches, now I'll have a look at the whole patchset. Neil > > Sam > ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH v6 21/24] drm/bridge: ti-tfp410: Provide ddc symlink in connector sysfs directory
On 26/07/2019 19:23, Andrzej Pietrasiewicz wrote: > Use the ddc pointer provided by the generic connector. > > Signed-off-by: Andrzej Pietrasiewicz > --- > drivers/gpu/drm/bridge/ti-tfp410.c | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/bridge/ti-tfp410.c > b/drivers/gpu/drm/bridge/ti-tfp410.c > index dbf35c7bc85e..61cc2354ef1b 100644 > --- a/drivers/gpu/drm/bridge/ti-tfp410.c > +++ b/drivers/gpu/drm/bridge/ti-tfp410.c > @@ -134,8 +134,10 @@ static int tfp410_attach(struct drm_bridge *bridge) > > drm_connector_helper_add(>connector, >_con_helper_funcs); > - ret = drm_connector_init(bridge->dev, >connector, > - _con_funcs, dvi->connector_type); > + ret = drm_connector_init_with_ddc(bridge->dev, >connector, > + _con_funcs, > + dvi->connector_type, > + dvi->ddc); > if (ret) { > dev_err(dvi->dev, "drm_connector_init() failed: %d\n", ret); > return ret; > Reviewed-by: Neil Armstrong ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH v6 19/24] drm/bridge: dumb-vga-dac: Provide ddc symlink in connector sysfs directory
On 26/07/2019 19:23, Andrzej Pietrasiewicz wrote: > Use the ddc pointer provided by the generic connector. > > Signed-off-by: Andrzej Pietrasiewicz > --- > drivers/gpu/drm/bridge/dumb-vga-dac.c | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/bridge/dumb-vga-dac.c > b/drivers/gpu/drm/bridge/dumb-vga-dac.c > index d32885b906ae..8ef6539ae78a 100644 > --- a/drivers/gpu/drm/bridge/dumb-vga-dac.c > +++ b/drivers/gpu/drm/bridge/dumb-vga-dac.c > @@ -111,8 +111,10 @@ static int dumb_vga_attach(struct drm_bridge *bridge) > > drm_connector_helper_add(>connector, >_vga_con_helper_funcs); > - ret = drm_connector_init(bridge->dev, >connector, > - _vga_con_funcs, DRM_MODE_CONNECTOR_VGA); > + ret = drm_connector_init_with_ddc(bridge->dev, >connector, > + _vga_con_funcs, > + DRM_MODE_CONNECTOR_VGA, > + vga->ddc); > if (ret) { > DRM_ERROR("Failed to initialize connector\n"); > return ret; > Reviewed-by: Neil Armstrong ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH v4 20/23] drm/bridge: ti-tfp410: Provide ddc symlink in connector sysfs directory
On 11/07/2019 13:26, Andrzej Pietrasiewicz wrote: > Use the ddc pointer provided by the generic connector. > > Signed-off-by: Andrzej Pietrasiewicz > --- > drivers/gpu/drm/bridge/ti-tfp410.c | 19 +-- > 1 file changed, 9 insertions(+), 10 deletions(-) > > diff --git a/drivers/gpu/drm/bridge/ti-tfp410.c > b/drivers/gpu/drm/bridge/ti-tfp410.c > index dbf35c7bc85e..e55358f0a5ba 100644 > --- a/drivers/gpu/drm/bridge/ti-tfp410.c > +++ b/drivers/gpu/drm/bridge/ti-tfp410.c > @@ -26,7 +26,6 @@ struct tfp410 { > unsigned intconnector_type; > > u32 bus_format; > - struct i2c_adapter *ddc; > struct gpio_desc*hpd; > int hpd_irq; > struct delayed_work hpd_work; > @@ -55,10 +54,10 @@ static int tfp410_get_modes(struct drm_connector > *connector) > struct edid *edid; > int ret; > > - if (!dvi->ddc) > + if (!dvi->connector.ddc) > goto fallback; > > - edid = drm_get_edid(connector, dvi->ddc); > + edid = drm_get_edid(connector, dvi->connector.ddc); > if (!edid) { > DRM_INFO("EDID read failed. Fallback to standard modes\n"); > goto fallback; > @@ -98,8 +97,8 @@ tfp410_connector_detect(struct drm_connector *connector, > bool force) > return connector_status_disconnected; > } > > - if (dvi->ddc) { > - if (drm_probe_ddc(dvi->ddc)) > + if (dvi->connector.ddc) { > + if (drm_probe_ddc(dvi->connector.ddc)) > return connector_status_connected; > else > return connector_status_disconnected; > @@ -297,8 +296,8 @@ static int tfp410_get_connector_properties(struct tfp410 > *dvi) > if (!ddc_phandle) > goto fail; > > - dvi->ddc = of_get_i2c_adapter_by_node(ddc_phandle); > - if (dvi->ddc) > + dvi->connector.ddc = of_get_i2c_adapter_by_node(ddc_phandle); > + if (dvi->connector.ddc) > dev_info(dvi->dev, "Connector's ddc i2c bus found\n"); > else > ret = -EPROBE_DEFER; > @@ -367,7 +366,7 @@ static int tfp410_init(struct device *dev, bool i2c) > > return 0; > fail: > - i2c_put_adapter(dvi->ddc); > + i2c_put_adapter(dvi->connector.ddc); > if (dvi->hpd) > gpiod_put(dvi->hpd); > return ret; > @@ -382,8 +381,8 @@ static int tfp410_fini(struct device *dev) > > drm_bridge_remove(>bridge); > > - if (dvi->ddc) > - i2c_put_adapter(dvi->ddc); > + if (dvi->connector.ddc) > + i2c_put_adapter(dvi->connector.ddc); > if (dvi->hpd) > gpiod_put(dvi->hpd); > > Reviewed-by: Neil Armstrong ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH v4 19/23] drm/bridge: dw-hdmi: Provide ddc symlink in connector sysfs directory
ailed to read ddc node\n"); > return ERR_PTR(-EPROBE_DEFER); > } > @@ -2689,7 +2689,7 @@ __dw_hdmi_probe(struct platform_device *pdev, > hdmi_init_clk_regenerator(hdmi); > > /* If DDC bus is not specified, try to register HDMI I2C bus */ > - if (!hdmi->ddc) { > + if (!hdmi->connector.ddc) { > /* Look for (optional) stuff related to unwedging */ > hdmi->pinctrl = devm_pinctrl_get(dev); > if (!IS_ERR(hdmi->pinctrl)) { > @@ -2708,9 +2708,9 @@ __dw_hdmi_probe(struct platform_device *pdev, > } > } > > - hdmi->ddc = dw_hdmi_i2c_adapter(hdmi); > - if (IS_ERR(hdmi->ddc)) > - hdmi->ddc = NULL; > + hdmi->connector.ddc = dw_hdmi_i2c_adapter(hdmi); > + if (IS_ERR(hdmi->connector.ddc)) > + hdmi->connector.ddc = NULL; > } > > hdmi->bridge.driver_private = hdmi; > @@ -2776,7 +2776,7 @@ __dw_hdmi_probe(struct platform_device *pdev, > err_iahb: > if (hdmi->i2c) { > i2c_del_adapter(>i2c->adap); > - hdmi->ddc = NULL; > + hdmi->connector.ddc = NULL; > } > > if (hdmi->cec_notifier) > @@ -2788,7 +2788,7 @@ __dw_hdmi_probe(struct platform_device *pdev, > err_isfr: > clk_disable_unprepare(hdmi->isfr_clk); > err_res: > - i2c_put_adapter(hdmi->ddc); > + i2c_put_adapter(hdmi->connector.ddc); > > return ERR_PTR(ret); > } > @@ -2814,7 +2814,7 @@ static void __dw_hdmi_remove(struct dw_hdmi *hdmi) > if (hdmi->i2c) > i2c_del_adapter(>i2c->adap); > else > - i2c_put_adapter(hdmi->ddc); > + i2c_put_adapter(hdmi->connector.ddc); > } > > /* > - > Reviewed-by: Neil Armstrong ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH v4 18/23] drm/bridge: dumb-vga-dac: Provide ddc symlink in connector sysfs directory
On 11/07/2019 13:26, Andrzej Pietrasiewicz wrote: > Use the ddc pointer provided by the generic connector. > > Signed-off-by: Andrzej Pietrasiewicz > --- > drivers/gpu/drm/bridge/dumb-vga-dac.c | 19 +-- > 1 file changed, 9 insertions(+), 10 deletions(-) > > diff --git a/drivers/gpu/drm/bridge/dumb-vga-dac.c > b/drivers/gpu/drm/bridge/dumb-vga-dac.c > index d32885b906ae..b4cc3238400a 100644 > --- a/drivers/gpu/drm/bridge/dumb-vga-dac.c > +++ b/drivers/gpu/drm/bridge/dumb-vga-dac.c > @@ -20,7 +20,6 @@ struct dumb_vga { > struct drm_bridge bridge; > struct drm_connectorconnector; > > - struct i2c_adapter *ddc; > struct regulator*vdd; > }; > > @@ -42,10 +41,10 @@ static int dumb_vga_get_modes(struct drm_connector > *connector) > struct edid *edid; > int ret; > > - if (IS_ERR(vga->ddc)) > + if (IS_ERR(vga->connector.ddc)) > goto fallback; > > - edid = drm_get_edid(connector, vga->ddc); > + edid = drm_get_edid(connector, vga->connector.ddc); > if (!edid) { > DRM_INFO("EDID readout failed, falling back to standard > modes\n"); > goto fallback; > @@ -84,7 +83,7 @@ dumb_vga_connector_detect(struct drm_connector *connector, > bool force) >* wire the DDC pins, or the I2C bus might not be working at >* all. >*/ > - if (!IS_ERR(vga->ddc) && drm_probe_ddc(vga->ddc)) > + if (!IS_ERR(vga->connector.ddc) && drm_probe_ddc(vga->connector.ddc)) > return connector_status_connected; > > return connector_status_unknown; > @@ -190,14 +189,14 @@ static int dumb_vga_probe(struct platform_device *pdev) > dev_dbg(>dev, "No vdd regulator found: %d\n", ret); > } > > - vga->ddc = dumb_vga_retrieve_ddc(>dev); > - if (IS_ERR(vga->ddc)) { > - if (PTR_ERR(vga->ddc) == -ENODEV) { > + vga->connector.ddc = dumb_vga_retrieve_ddc(>dev); > + if (IS_ERR(vga->connector.ddc)) { > + if (PTR_ERR(vga->connector.ddc) == -ENODEV) { > dev_dbg(>dev, > "No i2c bus specified. Disabling EDID > readout\n"); > } else { > dev_err(>dev, "Couldn't retrieve i2c bus\n"); > - return PTR_ERR(vga->ddc); > + return PTR_ERR(vga->connector.ddc); > } > } > > @@ -216,8 +215,8 @@ static int dumb_vga_remove(struct platform_device *pdev) > > drm_bridge_remove(>bridge); > > - if (!IS_ERR(vga->ddc)) > - i2c_put_adapter(vga->ddc); > + if (!IS_ERR(vga->connector.ddc)) > + i2c_put_adapter(vga->connector.ddc); > > return 0; > } > Reviewed-by: Neil Armstrong ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Re: [PATCH] drm: Split out drm_probe_helper.h
| 2 +- > drivers/gpu/drm/bridge/ti-tfp410.c| 2 +- > drivers/gpu/drm/cirrus/cirrus_drv.c | 1 + > drivers/gpu/drm/cirrus/cirrus_mode.c | 1 + > drivers/gpu/drm/drm_atomic_helper.c | 1 - > drivers/gpu/drm/drm_dp_mst_topology.c | 2 +- > drivers/gpu/drm/drm_modeset_helper.c | 2 +- > drivers/gpu/drm/drm_probe_helper.c| 2 +- > drivers/gpu/drm/drm_simple_kms_helper.c | 2 +- > drivers/gpu/drm/etnaviv/etnaviv_drv.h | 1 - > drivers/gpu/drm/exynos/exynos_dp.c| 3 +- > drivers/gpu/drm/exynos/exynos_drm_crtc.c | 2 +- > drivers/gpu/drm/exynos/exynos_drm_dpi.c | 2 +- > drivers/gpu/drm/exynos/exynos_drm_drv.c | 2 +- > drivers/gpu/drm/exynos/exynos_drm_dsi.c | 2 +- > drivers/gpu/drm/exynos/exynos_drm_fb.c| 2 +- > drivers/gpu/drm/exynos/exynos_drm_fbdev.c | 2 +- > drivers/gpu/drm/exynos/exynos_drm_vidi.c | 2 +- > drivers/gpu/drm/exynos/exynos_hdmi.c | 2 +- > drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_crtc.c| 2 +- > drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 2 +- > drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_kms.c | 2 +- > drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_plane.c | 2 +- > drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_rgb.c | 2 +- > drivers/gpu/drm/gma500/psb_intel_drv.h| 1 + > .../gpu/drm/hisilicon/hibmc/hibmc_drm_de.c| 2 +- > .../gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c | 2 +- > .../gpu/drm/hisilicon/hibmc/hibmc_drm_fbdev.c | 2 +- > .../gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c | 2 +- > drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c | 2 +- > .../gpu/drm/hisilicon/kirin/kirin_drm_ade.c | 2 +- > .../gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 2 +- > drivers/gpu/drm/i2c/ch7006_priv.h | 1 + > drivers/gpu/drm/i2c/sil164_drv.c | 2 +- > drivers/gpu/drm/i2c/tda998x_drv.c | 2 +- > drivers/gpu/drm/i915/i915_debugfs.c | 3 +- > drivers/gpu/drm/i915/i915_drv.c | 2 +- > drivers/gpu/drm/i915/i915_gem.c | 2 + > drivers/gpu/drm/i915/i915_ioc32.c | 1 + > drivers/gpu/drm/i915/i915_irq.c | 2 + > drivers/gpu/drm/i915/i915_pci.c | 2 + > drivers/gpu/drm/i915/i915_trace.h | 2 + > drivers/gpu/drm/i915/intel_crt.c | 2 +- > drivers/gpu/drm/i915/intel_display.c | 2 +- > drivers/gpu/drm/i915/intel_dp.c | 2 +- > drivers/gpu/drm/i915/intel_dp_mst.c | 2 +- > drivers/gpu/drm/i915/intel_drv.h | 3 +- > drivers/gpu/drm/i915/intel_fbc.c | 2 + > drivers/gpu/drm/i915/intel_fbdev.c| 2 + > drivers/gpu/drm/i915/intel_lpe_audio.c| 1 + > drivers/gpu/drm/i915/intel_overlay.c | 2 + > drivers/gpu/drm/imx/dw_hdmi-imx.c | 2 +- > drivers/gpu/drm/imx/imx-drm-core.c| 2 +- > drivers/gpu/drm/imx/imx-ldb.c | 2 +- > drivers/gpu/drm/imx/imx-tve.c | 2 +- > drivers/gpu/drm/imx/ipuv3-crtc.c | 2 +- > drivers/gpu/drm/imx/parallel-display.c| 2 +- > drivers/gpu/drm/mediatek/mtk_dpi.c| 2 +- > drivers/gpu/drm/mediatek/mtk_drm_crtc.c | 2 +- > drivers/gpu/drm/mediatek/mtk_drm_drv.c| 2 +- > drivers/gpu/drm/mediatek/mtk_drm_fb.c | 2 +- > drivers/gpu/drm/mediatek/mtk_dsi.c| 2 +- > drivers/gpu/drm/mediatek/mtk_hdmi.c | 2 +- > drivers/gpu/drm/meson/meson_crtc.c| 2 +- > drivers/gpu/drm/meson/meson_drv.c | 2 +- > drivers/gpu/drm/meson/meson_dw_hdmi.c | 2 +- > drivers/gpu/drm/meson/meson_venc_cvbs.c | 2 +- For meson: Acked-by: Neil Armstrong > drivers/gpu/drm/mgag200/mgag200_mode.c| 1 + > drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 2 +- > drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 2 +- > drivers/gpu/drm/msm/disp/mdp4/mdp4_crtc.c | 2 +- > .../gpu/drm/msm/disp/mdp4/mdp4_dsi_encoder.c | 2 +- > .../gpu/drm/msm/disp/mdp4/mdp4_dtv_encoder.c | 2 +- > .../gpu/drm/msm/disp/mdp4/mdp4_lcdc_encoder.c | 2 +- > .../gpu/drm/msm/disp/mdp5/mdp5_cmd_encoder.c | 2 +- > drivers/gpu/drm/msm/disp/mdp5/mdp5_crtc.c | 2 +- > drivers/gpu/drm/msm/disp/mdp5/mdp5_encoder.c | 2 +- > drivers/gpu/drm/msm/msm_drv.h | 2 +- > drivers/gpu/drm/msm/msm_fb.c | 2 +- > drivers/gpu/drm/mxsfb/mxsfb_crtc.c| 2 +- > drivers/gpu/drm/mxsfb/mxsfb_drv.c | 2 +- > drivers/gpu/drm/mxsfb/mxsfb_out.c | 2 +- > drivers/gpu/drm/nouveau/dispnv04/tvnv17.c | 1 + > drivers/gpu/drm/nouveau/di