summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/bridge/synopsys
AgeCommit message (Collapse)Author
14 daysdrm/bridge: dw-hdmi-qp: Drop unused .setup_hpd() phy opCristian Ciocaltea
With the transition to .{enable|disable}_hpd() phy ops complete in both the bridge and platform drivers, .setup_hpd() has no remaining callers. Drop it. Tested-by: Maud Spierings <maud_spierings@hotmail.com> Tested-by: Diederik de Haas <diederik@cknow-tech.com> # NanoPC-T6 LTS, Rock 5B Tested-by: Robin Räber <robin.raebi@gmail.com> Tested-by: Igor Paunovic <royalnet026@gmail.com> # RK3588 Orange Pi 5 Plus, dual HDMI Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20261005-dw-hdmi-qp-scramb-v12-16-195157ba0b40@collabora.com
14 daysdrm/bridge: dw-hdmi-qp: Provide dw_hdmi_qp_hpd_notify() helperCristian Ciocaltea
Export dw_hdmi_qp_hpd_notify() for platform drivers to report hot-plug detection events. Unlike drm_helper_hpd_irq_event() which polls all connectors, this helper targets only the affected connector and ensures .detect_ctx() is invoked on reconnection events to trigger SCDC state recovery. Track the connector in use in curr_conn, set and cleared by the atomic enable/disable hooks. Since the helper runs asynchronously from IRQ/work context, hold a reference on that connector for as long as the bridge is enabled, so that the pointer is always safe to dereference. Otherwise validity would rest on the platform glue quiescing HPD before the DRM-managed connector is freed during teardown, risking a use-after-free on a late HPD event. The helper must take its own temporary reference while running, because the long-lived reference above only guarantees the pointer is valid at the time it is read, not that the connector survives a concurrent atomic_disable dropping that reference while the helper is still using it. Moreover, reading the pointer and acquiring the temporary reference must be atomic with respect to atomic_disable, otherwise a window exists where drm_connector_get() is called on a connector whose refcount already reached zero, hence guard curr_conn with a mutex for this purpose. Holding the mutex across the whole helper instead is not an option, as it takes modeset locks while atomic_disable is called with them held. Also note that this helper may sleep, so it must only be called from a threaded HPD interrupt handler or a work function. Tested-by: Maud Spierings <maud_spierings@hotmail.com> Tested-by: Diederik de Haas <diederik@cknow-tech.com> # NanoPC-T6 LTS, Rock 5B Tested-by: Robin Räber <robin.raebi@gmail.com> Tested-by: Igor Paunovic <royalnet026@gmail.com> # RK3588 Orange Pi 5 Plus, dual HDMI Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20261005-dw-hdmi-qp-scramb-v12-5-195157ba0b40@collabora.com
14 daysdrm/bridge: dw-hdmi-qp: Add HDMI 2.0 scrambling supportCristian Ciocaltea
Add support for SCDC scrambling and the high TMDS clock ratio required by HDMI 2.0 modes with TMDS character rates above 340 MHz, such as 4K@60Hz. Hook the bridge into the DRM HDMI connector scrambling helpers so the sink-side SCDC state and the controller scrambler are updated together as part of the atomic enable and disable paths. This allows the driver to advertise HDMI 2.0 support when HPD is available. Keep no-HPD configurations limited to HDMI 1.4, since SCDC access requires a connected HDMI sink. Modes above the HDMI 2.0 600 MHz TMDS character-rate limit are now implicitly rejected by the DRM HDMI connector/bridge infrastructure, making the dw_hdmi_qp_bridge_tmds_char_rate_valid() callback redundant. Drop it. Tested-by: Maud Spierings <maud_spierings@hotmail.com> Tested-by: Diederik de Haas <diederik@cknow-tech.com> # NanoPC-T6 LTS, Rock 5B Tested-by: Robin Räber <robin.raebi@gmail.com> Tested-by: Igor Paunovic <royalnet026@gmail.com> # RK3588 Orange Pi 5 Plus, dual HDMI Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20261005-dw-hdmi-qp-scramb-v12-4-195157ba0b40@collabora.com
14 daysdrm/bridge: dw-hdmi-qp: Remove unused workqueue include and defineCristian Ciocaltea
linux/workqueue.h is no longer needed, and SCRAMB_POLL_DELAY_MS is unused. Remove them. Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20261005-dw-hdmi-qp-scramb-v12-3-195157ba0b40@collabora.com
14 daysdrm/bridge: dw-hdmi-qp: Provide .{enable,disable}_hpd() PHY opsCristian Ciocaltea
Implement the .hpd_enable() and .hpd_disable() bridge callbacks and extend dw_hdmi_qp_phy_ops with corresponding hooks. This enables the DRM core to control when HPD interrupts are armed, which is needed to prevent premature interrupt delivery before the connector is fully initialized, and to properly quiesce HPD during suspend. Tested-by: Maud Spierings <maud_spierings@hotmail.com> Tested-by: Diederik de Haas <diederik@cknow-tech.com> # NanoPC-T6 LTS, Rock 5B Tested-by: Robin Räber <robin.raebi@gmail.com> Tested-by: Igor Paunovic <royalnet026@gmail.com> # RK3588 Orange Pi 5 Plus, dual HDMI Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20261005-dw-hdmi-qp-scramb-v12-2-195157ba0b40@collabora.com
14 daysdrm/bridge: dw-hdmi-qp: Demote i2c bus error messages to debug levelCristian Ciocaltea
A NACK or timeout on the DDC bus is a normal condition when the sink is absent or unpowered. Some displays keep HPD asserted and the EDID EEPROM readable while in standby, but leave the SCDC slave unpowered. This results in i2c-related error messages on every boot during scrambling setup, even though the condition is handled gracefully and the SCDC configuration is restored on the next hotplug event. Log the i2c bus level failures with dev_dbg_ratelimited() instead, matching the silent behaviour of the non-QP dw-hdmi i2c bus algorithm. The DDC users already report failures at the appropriate level, e.g. the SCDC helpers via drm_scdc_dbg(). This also makes the no-hpd special casing of the read path messages redundant, so drop it. Reported-by: Diederik de Haas <diederik@cknow-tech.com> Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Tested-by: Diederik de Haas <diederik@cknow-tech.com> # NanoPC-T6 LTS Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20261005-dw-hdmi-qp-scramb-v12-1-195157ba0b40@collabora.com
2026-10-01drm/bridge: dw-mipi-dsi2: stop using deprecated devm_drm_of_get_bridge()Luca Ceresoli
devm_drm_of_get_bridge() is deprecated, switch to of_drm_get_bridge_by_endpoint(). As of_drm_get_bridge_by_endpoint() returns a refcounted bridge, ensure it is put by using bridge.next_bridge. Reviewed-by: Paul Cercueil <paul.cercueil@bootlin.com> Link: https://patch.msgid.link/20260929-drm-fix-of_get_bridge-build-regression-v2-4-6da431d8f180@bootlin.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-10-01drm/bridge: dw-mipi-dsi: stop using deprecated devm_drm_of_get_bridge()Luca Ceresoli
devm_drm_of_get_bridge() is deprecated, switch to of_drm_get_bridge_by_endpoint(). As of_drm_get_bridge_by_endpoint() returns a refcounted bridge, ensure it is put by using bridge.next_bridge. Fixes build failure when CONFIG_OF is disabled. Fixes: aa8a8c7e4641 ("drm/bridge: panel: move all code to drm_panel.c") Reported-by: Arnd Bergmann <arnd@kernel.org> Closes: https://lore.kernel.org/r/20260928161605.2271412-1-arnd@kernel.org Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202609291109.9RGna4XZ-lkp@intel.com/ Link: https://lore.kernel.org/r/20260928161605.2271412-1-arnd@kernel.org Link: https://lore.kernel.org/oe-kbuild-all/202609291109.9RGna4XZ-lkp@intel.com/ Reviewed-by: Paul Cercueil <paul.cercueil@bootlin.com> Link: https://patch.msgid.link/20260929-drm-fix-of_get_bridge-build-regression-v2-3-6da431d8f180@bootlin.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-09-03drm/bridge: dw-hdmi-qp: use drm_hdmi_acr_get_n_cts() helper for audio N/CTSSimon Wright
dw_hdmi_qp_set_sample_rate() open-coded its own N and CTS lookup tables and search/compute helpers, but it lacked the out-of-table CTS fallback needed by strict HDMI sinks at TMDS rates not in the table. The original LG G3 OLED audio mute (linux-rockchip 070633) was caused by dw_hdmi_qp_find_cts() returning 0 at 185.625 MHz, leaving AUDPKT_ACR_CTS_OVR_EN clear and falling back to the controller's internal CTS auto-measurement, which produces incorrect timing on the wire at out-of-table rates. The shared drm_hdmi_acr_get_n_cts() helper in drivers/gpu/drm/display/drm_hdmi_helper.c already implements the correct behaviour: it has the HDMI 1.4b spec N/CTS tables, and for TMDS rates not in the table it computes CTS = (TMDS * N) / (128 * Fs) inline (the canonical HDMI spec formula). It is already used by drivers/gpu/drm/msm/hdmi/hdmi_audio.c. Convert dw_hdmi_qp_set_sample_rate() to call the helper. This removes ~200 lines of open-coded tables and search functions (dw_hdmi_qp_find_n, _compute_n, _find_cts, _audio_math_diff, _match_tmds_n_table, common_tmds_n_table[], common_tmds_cts_table[]) and fixes the strict-sink audio mute as a side effect of using the helper's complete N+CTS path. Tested on R76S (RK3576) running Linux 7.0.1, against the LG G3 OLED (the sink that originally reported the mute in linux-rockchip 070633) at four TMDS rates spanning HDMI 1.4 and HDMI 2.0: TMDS Mode Audio with v3 148.5 MHz 1080p60 8-bit plays 185.625 MHz 1080p60 10-bit plays 297 MHz 1080p100 8-bit plays 594 MHz 3840p60 8-bit plays Without this change, the LG G3 mutes audio at 185.625, 297, and 594 MHz (every rate outside dw-hdmi-qp's open-coded CTS table, which contained only 148.5 MHz and below). With this change, drm_hdmi_acr_get_n_cts() supplies the correct CTS at every rate -- table-canonical at 148.5 / 297 / 594 MHz, and computed via the HDMI 1.4b formula at 185.625 MHz. The 148.5 MHz row is a regression check confirming the in-table path is unchanged. The Kogan KALED43XU9210STA (a permissive HDMI 2.0 sink that plays audio at all rates with or without this change) was used as a no-regression control: audio plays at 594 MHz with v3 loaded. The open-coded N table in dw-hdmi-qp included optimised N values for some TMDS rates that are not in the helper's table (e.g. various non-CEA rates between 28-162 MHz). For those rates the helper's fallback returns N = 128 * Fs / 1000, which is the same value dw_hdmi_qp_compute_n() returned when no table optimisation was needed; no audio regression has been observed at the rates tested above. Reported-by: Simon Wright <simon@symple.nz> Closes: https://lore.kernel.org/linux-rockchip/ME3P282MB21960D9D68BFF520316BDFCEA83E2@ME3P282MB2196.AUSP282.PROD.OUTLOOK.COM/ Suggested-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Suggested-by: Jonas Karlman <jonas@kwiboo.se> Assisted-by: Claude:claude-opus-4-7 Signed-off-by: Simon Wright <simon@symple.nz> Tested-by: Igor Paunovic <royalnet026@gmail.com> # RK3588 Orange Pi 5 Plus, both HDMI controllers Tested-by: Christian Hewitt <christianshewitt@gmail.com> Reviewed-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Tested-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/86fcf349-0a7a-4618-9001-612371b0f71b@symple.nz
2026-09-02drm: bridge: dw_hdmi: Fix constant truncation warning on phy_maskSean Chang
In dw_hdmi_probe(), casting the bitwise complement of (HDMI_PHY_HPD | HDMI_PHY_RX_SENSE) directly to u8 triggers a compiler warning (-Wconstant-conversion). Due to C integer promotion rules, the bitwise OR and bitwise NOT are evaluated as 32-bit signed integers, producing 0xFFFFFF0D before being cast down to u8. Fix this by explicitly masking the inverted 32-bit result with 0xFF to keep only the lower byte and prevent implicit upper-bit truncation. Signed-off-by: Sean Chang <seanwascoding@gmail.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patch.msgid.link/20260819151216.56833-1-seanwascoding@gmail.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-08-13drm/bridge: synopsys: dw-dp: Remove redundant dev_err_probe()Pan Chuang
Since commit 55b48e23f5c4 ("genirq/devres: Add error handling in devm_request_*_irq()"), devm_request_threaded_irq() automatically logs detailed error messages on failure. Remove the now-redundant driver-specific dev_err_probe() call. Signed-off-by: Pan Chuang <panchuang@vivo.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patch.msgid.link/20260723131649.134127-6-panchuang@vivo.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-08-05drm/bridge: remove unneeded 'fast_io' parameter in regmap_configWolfram Sang
When using MMIO with regmap, fast_io is implied. No need to set it again. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patch.msgid.link/20260705163536.1850-6-wsa+renesas@sang-engineering.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-07-27drm/bridge: dw-hdmi: fix i2c adapter leak on probe failureJohan Hovold
Make sure to drop the i2c adapter device and module references before returning when detecting a malformed devicetree during probe. Fixes: 80e2f97968b5 ("drm: bridge: dw-hdmi: Switch to regmap for register access") Cc: stable@vger.kernel.org # 4.12 Cc: Neil Armstrong <neil.armstrong@linaro.org> Signed-off-by: Johan Hovold <johan@kernel.org> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Link: https://patch.msgid.link/20260717090819.1630965-1-johan@kernel.org Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-06-22drm/bridge: dw-mipi-dsi2: Switch to atomic_create_stateMaxime Ripard
The drm_bridge_funcs.atomic_reset callback and its drm_atomic_helper_bridge_reset() helper are deprecated. Switch to the atomic_create_state callback and its drm_atomic_helper_bridge_create_state() counterpart. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> # imx8mp + sn65dsi84 + bridge hotplug Link: https://patch.msgid.link/20260619-drm-no-more-bridge-reset-v3-37-ff399263111b@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-06-22drm/bridge: dw-mipi-dsi: Switch to atomic_create_stateMaxime Ripard
The drm_bridge_funcs.atomic_reset callback and its drm_atomic_helper_bridge_reset() helper are deprecated. Switch to the atomic_create_state callback and its drm_atomic_helper_bridge_create_state() counterpart. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> # imx8mp + sn65dsi84 + bridge hotplug Link: https://patch.msgid.link/20260619-drm-no-more-bridge-reset-v3-36-ff399263111b@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-06-22drm/bridge: dw-hdmi: Switch to atomic_create_stateMaxime Ripard
The drm_bridge_funcs.atomic_reset callback and its drm_atomic_helper_bridge_reset() helper are deprecated. Switch to the atomic_create_state callback and its drm_atomic_helper_bridge_create_state() counterpart. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> # imx8mp + sn65dsi84 + bridge hotplug Link: https://patch.msgid.link/20260619-drm-no-more-bridge-reset-v3-35-ff399263111b@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-06-22drm/bridge: dw-hdmi-qp: Switch to atomic_create_stateMaxime Ripard
The drm_bridge_funcs.atomic_reset callback and its drm_atomic_helper_bridge_reset() helper are deprecated. Switch to the atomic_create_state callback and its drm_atomic_helper_bridge_create_state() counterpart. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> # imx8mp + sn65dsi84 + bridge hotplug Link: https://patch.msgid.link/20260619-drm-no-more-bridge-reset-v3-34-ff399263111b@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-06-22drm/bridge: dw-dp: Switch to atomic_create_stateMaxime Ripard
The drm_bridge_funcs.atomic_reset callback and its drm_atomic_helper_bridge_reset() helper are deprecated. Switch to the atomic_create_state callback and its drm_atomic_helper_bridge_create_state() counterpart. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> # imx8mp + sn65dsi84 + bridge hotplug Link: https://patch.msgid.link/20260619-drm-no-more-bridge-reset-v3-33-ff399263111b@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-06-09drm/bridge: dw-hdmi-qp: Use common HDMI output bus fmts helperNicolas Frattaroli
Make use of the common drm_bridge_funcs.atomic_get_output_bus_fmts helper for HDMI bridge connectors. This allows dw-hdmi-qp HDMI bridges to participate in recursive bus format selection in a meaningful way. Reviewed-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Daniel Stone <daniel@fooishbar.org> Signed-off-by: Nicolas Frattaroli <nicolas.frattaroli@collabora.com> Link: https://patch.msgid.link/20260609-color-format-v17-15-35739b5782cc@collabora.com Signed-off-by: Daniel Stone <daniels@collabora.com>
2026-06-02drm/bridge: synopsys: dw-dp: Support unregistering the AUX channelCristian Ciocaltea
The DisplayPort AUX channel gets initialized and registered during dw_dp_bind(), but it is never unregistered, which may lead to resource leaks and/or use-after-free. Add the missing dw_dp_unbind() function to allow the users of the library to handle the required cleanup, i.e. unregister the AUX adapter. Fixes: 86eecc3a9c2e ("drm/bridge: synopsys: Add DW DPTX Controller support library") Reviewed-by: Andy Yan <andy.yan@rock-chips.com> Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20260601-drm-rk-fixes-v4-1-c3f3f123e1da@collabora.com
2026-05-21drm/bridge: dw-hdmi-qp: Use the common TMDS char rate constantJavier Martinez Canillas
Replace the driver local HDMI14_MAX_TMDSCLK define with the shared constant defined in the <linux/hdmi.h> header. The local define incorrectly referenced HDMI 1.4, but the 340 MHz maximum TMDS character rate was actually introduced in HDMI 1.3. Suggested-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Reviewed-by: Maxime Ripard <mripard@kernel.org> Link: https://patch.msgid.link/20260520144424.1633354-4-javierm@redhat.com Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
2026-05-21drm/bridge: dw-hdmi: Use the common TMDS char rate constantJavier Martinez Canillas
Replace the driver local HDMI14_MAX_TMDSCLK define with the shared constant defined in the <linux/hdmi.h> header. The local define incorrectly referenced HDMI 1.4, but the 340 MHz maximum TMDS character rate was actually introduced in HDMI 1.3. Suggested-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org> Reviewed-by: Maxime Ripard <mripard@kernel.org> Link: https://patch.msgid.link/20260520144424.1633354-3-javierm@redhat.com Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
2026-05-06Merge tag 'drm-misc-next-2026-04-20' of ↵Dave Airlie
https://gitlab.freedesktop.org/drm/misc/kernel into drm-next drm-misc-next for v7.1-rc1: UAPI Changes: - Expose per-client BO memory usage via fdinfo in amdxdna. (Hou) - Change the default priority of drm scheduler to fair. (Tvrtko) Cross-subsystem Changes: - Revert hugetlb support in udmabuf. (Gunthorpe) - Fix error in udmabuf with CONFIG_DMA_API_DEBUG(/ _SG). (Gavrilov) - Add Docbook for DRM_IOCTL_SYNCOBJ_EVENTFD, (Ser) clarify drm_bridge_get/put. (Tvrtko) - Change signature of drm_connector_attach_hdr_output_metadata_property. (Canal) - Use IOVA allocations in gpusvm and pagemap APIs. (Brost) - Fix tracepoints vs dma-fence lifetime. (Tvrtko) - Convert st-dma*.c tests to use kunit. (Gunthorpe) Core Changes: - Deduplicate counter and timestamp retrieval in vblank code. (Ville) - Parse AMD VSDB v3 in CTA extension blocks, and use it in amdgpu. (Chen) - Prevent bridge and encoder chain changes at inopportune times. (Ceresoli) - Map the run queue 1:1 to the drm scheduler. (Tvrtko) Driver Changes: - Assorted bugfixes and (documentation) updates to rockchip, bridge/synopsis, panfrost, tidss, accel/qaic, tilcdc, vc4, ast, imagination, panthor, renesas, accel/amdxdna, msxfb, bridge/imx8mp, nouveau. bridge/analogix_dp, bridge/exynos_dp, omap. - Add support for CSW PNB601LS1-2, LGD LP116WHA-SPB1, panels. - Add support for a lot of waveshare panels (Baryshkov) - Support for AIE4 devices in accel/wamdxdna. (Zhang) - Enable support for GEM shrinking in panthor. (Goel/Brezillon) - Runtime Power Management is added to v3d. (Canal) - Allow panel probing and use the panel bridge helper in analogix_dp. (Ding) - Support XRGB1555 and C8 in mgag and XRGB1555 in ast. (Zimmermann) From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: https://patch.msgid.link/bf31b1a1-951b-4f60-b226-22e8c083697d@linux.intel.com Signed-off-by: Dave Airlie <airlied@redhat.com>
2026-05-04drm: Rename struct drm_atomic_state to drm_atomic_commitMaxime Ripard
The KMS framework uses two slightly different definitions for the state concept. For a given object (plane, CRTC, encoder, etc., so drm_$OBJECT_state), the state is the entire state of that object. However, at the device level, drm_atomic_state refers to a state update for a limited number of objects. Thus, drm_atomic_state isn't the entire device state, but only the full state of some objects in that device. This has been an endless source of confusion and thus bugs. We can rename the drm_atomic_state structure to drm_atomic_commit to make it less confusing. This patch was created using: rg -l drm_atomic_state | \ xargs sed -i 's/drm_atomic_state/drm_atomic_commit/g; s/drm_atomic_commit_helper/drm_atomic_state_helper/g' mv drivers/gpu/drm/tests/drm_atomic_state_test.c drivers/gpu/drm/tests/drm_atomic_commit_test.c Acked-by: Simona Vetter <simona.vetter@ffwll.ch> Acked-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Maxime Ripard <mripard@kernel.org> Signed-off-by: Dave Airlie <airlied@redhat.com> Link: https://patch.msgid.link/20260427-drm-drm-atomic-update-v4-1-c0e713bfdf25@kernel.org
2026-04-24Merge tag 'drm-fixes-2026-04-24' of https://gitlab.freedesktop.org/drm/kernelLinus Torvalds
Pull more drm fixes from Dave Airlie: "These are the regular fixes that have built up over last couple of weeks, all pretty minor and spread all over. atomic: - raise the vblank timeout to avoid it on virtual drivers - fix colorop duplication bridge: - stm_lvds: state check fix - dw-mipi-dsi: bridge reference leak fix panel: - visionx-rm69299: init fix dma-fence: - fix sparse warning dma-buf: - UAF fix panthor: - mapping fix arcgpu: - device_node reference leak fix nouveau: - memory leak in error path fix - overflow in reloc path for old hw fix hv: - Kconfig fix v3d: - infinite loop fix" * tag 'drm-fixes-2026-04-24' of https://gitlab.freedesktop.org/drm/kernel: drm/nouveau: fix u32 overflow in pushbuf reloc bounds check MAINTAINERS: split hisilicon maintenance and add Yongbang Shi for hibmc-drm matainers drm/v3d: Reject empty multisync extension to prevent infinite loop drm/panel: visionox-rm69299: Make use of prepare_prev_first drm/drm_atomic: duplicate colorop states if plane color pipeline in use drm/nouveau: fix nvkm_device leak on aperture removal failure hv: Select CONFIG_SYSFB only for CONFIG_HYPERV_VMBUS dma-fence: Silence sparse warning in dma_fence_describe drm/bridge: dw-mipi-dsi: Fix bridge leak when host attach fails drm/arcpgu: fix device node leak drm/panthor: Fix outdated function documentation drm/panthor: Extend VM locked region for remap case to be a superset dma-buf: fix UAF in dma_buf_put() tracepoint drm/bridge: stm_lvds: Do not fail atomic_check on disabled connector drm/atomic: Increase timeout in drm_atomic_helper_wait_for_vblanks()
2026-04-14drm/bridge: dw-hdmi: move next_bridge lookup to attach timeLuca Ceresoli
This driver looks up the next_bridge at probe time and stores it in hdmi->bridge.next_bridge, but only uses the stored value when attaching, and only in the DRM_BRIDGE_ATTACH_NO_CONNECTOR case. This will be problematic with an upcoming change, adding an hdmi-connector using a device tree overlay when not present. That change is in turn necessary to migrate the i.MX LCDIF driver to the bridge-connector. The problem is that, adding the hdmi-connector via an overlay, devlink considers hdmi-connector a consumer of the dw-hdmi device, generating a chicken-egg problem: * hdmi-connector probe won't be tried until dw-hdmi is probed (devlink) * dw-hdmi probe will defer until it finds the next_bridge (the hdmi-connector wrapper bridge) In preparation for those changes, move the next_bridge lookup from probe to attach, when it is actually used. This allows dw-hdmi to probe, so that the hdmi-connector can probe as well. Also avoid storing the pointer in hdmi->bridge.next_bridge: the value is computed when needed, thus a local variable is enough. Finally, this also allows to slightly improve the code by not doing any DT lookup in the !DRM_BRIDGE_ATTACH_NO_CONNECTOR case. Tested-by: Martyn Welch <martyn.welch@collabora.com> Tested-by: Alexander Stein <alexander.stein@ew.tq-group.com> # TQMa8MPxL/MBa8MPxL Acked-by: Liu Ying <victor.liu@nxp.com> Tested-by: Damon Ding <damon.ding@rock-chips.com> # rk3399 Link: https://patch.msgid.link/20260407-drm-lcdif-dbanc-v4-7-247a16e61ef9@bootlin.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-04-14drm/bridge: dw-hdmi: warn on unsupported attach combinationLuca Ceresoli
dw-hdmi can operate in two different modes, depending on the platform data as set by the driver: A. hdmi->plat_data->output_port = 0: the HDMI output (port@1) in device tree is not used B. hdmi->plat_data->output_port = 1: the HDMI output (port@1) is parsed to find the next bridge Only case B is supported when the DRM_BRIDGE_ATTACH_NO_CONNECTOR flag is passed to the attach callback. Emit a warning when this is violated. Also return -EINVAL which would be returned by drm_bridge_attach() right after anyway. Reviewed-by: Liu Ying <victor.liu@nxp.com> Tested-by: Martyn Welch <martyn.welch@collabora.com> Tested-by: Alexander Stein <alexander.stein@ew.tq-group.com> # TQMa8MPxL/MBa8MPxL Tested-by: Damon Ding <damon.ding@rock-chips.com> # rk3399 Link: https://patch.msgid.link/20260407-drm-lcdif-dbanc-v4-6-247a16e61ef9@bootlin.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-04-14drm/bridge: dw-mipi-dsi: Fix bridge leak when host attach failsOsama Abdelkader
dw_mipi_dsi_host_attach() and dw_mipi_dsi2_host_attach() call drm_bridge_add() before pdata->host_ops->attach(). If attach fails, the bridge stayed registered without drm_bridge_remove(), leaking the bridge reference and leaving the device on the global bridge list. Fixes: 90910a651123 ("drm/bridge/synopsys: dsi: add ability to have glue-specific attach and detach") Fixes: 0d6d86253fef ("drm/bridge/synopsys: Add MIPI DSI2 host controller bridge") Signed-off-by: Osama Abdelkader <osama.abdelkader@gmail.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patch.msgid.link/20260403145208.15890-1-osama.abdelkader@gmail.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-03-26drm/bridge: synopsys: dw-dp: Drop useless memory allocationCristian Ciocaltea
The bridge gets allocated and initialized implicitly via the devm_drm_bridge_alloc() helper in dw_dp_bind(). However, this is preceded by an explicit allocation for the same dw_dp struct, which is never used anywhere as the return from devm_kzalloc() gets immediately overwritten by the aforementioned helper. Get rid of the unnecessary and confusing memory allocation. Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20260310-drm-rk-fixes-v2-8-645ecfb43f49@collabora.com
2026-03-24drm/bridge: synopsys: dw-hdmi: Convert to drm_output_color_formatMaxime Ripard
Now that we introduced a new drm_output_color_format enum to represent what DRM_COLOR_FORMAT_* bits were representing, we can switch to the new enum. The main difference is that while DRM_COLOR_FORMAT_ was a bitmask, drm_output_color_format is a proper enum. However, the enum was done is such a way than DRM_COLOR_FORMAT_X = BIT(DRM_OUTPUT_COLOR_FORMAT_X) so the transitition is easier. The only thing we need to consider is if the original code meant to use that value as a bitmask, in which case we do need to keep the bit shift, or as a discriminant in which case we don't. Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Link: https://lore.kernel.org/r/20260305-drm-rework-color-formats-v3-9-f3935f6db579@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-03-24drm/bridge: synopsys: dw-dp: Convert to drm_output_color_formatMaxime Ripard
Now that we introduced a new drm_output_color_format enum to represent what DRM_COLOR_FORMAT_* bits were representing, we can switch to the new enum. The main difference is that while DRM_COLOR_FORMAT_ was a bitmask, drm_output_color_format is a proper enum. However, the enum was done is such a way than DRM_COLOR_FORMAT_X = BIT(DRM_OUTPUT_COLOR_FORMAT_X) so the transitition is easier. The only thing we need to consider is if the original code meant to use that value as a bitmask, in which case we do need to keep the bit shift, or as a discriminant in which case we don't. Acked-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Link: https://lore.kernel.org/r/20260305-drm-rework-color-formats-v3-8-f3935f6db579@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-03-17drm/bridge: dw-hdmi-qp: fix multi-channel audio outputJonas Karlman
Channel Allocation (PB4) and Level Shift Information (PB5) are configured with values from PB1 and PB2 due to the wrong offset being used. This results in missing audio channels or incorrect speaker placement when playing multi-channel audio. Use the correct offset to fix multi-channel audio output. Fixes: fd0141d1a8a2 ("drm/bridge: synopsys: Add audio support for dw-hdmi-qp") Reported-by: Christian Hewitt <christianshewitt@gmail.com> Signed-off-by: Jonas Karlman <jonas@kwiboo.se> Signed-off-by: Christian Hewitt <christianshewitt@gmail.com> Reviewed-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Link: https://patch.msgid.link/20260228112822.4056354-1-christianshewitt@gmail.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-03-02Merge tag 'drm-misc-next-2026-02-26' of ↵Dave Airlie
https://gitlab.freedesktop.org/drm/misc/kernel into drm-next drm-misc-next for v7.1: UAPI Changes: connector: - Add panel_type property fourcc: - Add ARM interleaved 64k modifier nouveau: - Query Z-Cull info with DRM_IOCTL_NOUVEAU_GET_ZCULL_INFO Cross-subsystem Changes: coreboot: - Clean up coreboot framebuffer support dma-buf: - Provide revoke mechanism for shared buffers - Rename move_notify callback to invalidate_mappings and update users. - Always enable move_notify - Support dma_fence_was_initialized() test - Protect dma_fence_ops by RCU and improve locking - Fix sparse warnings Core Changes: atomic: - Allocate drm_private_state via callback and convert drivers atomic-helper: - Use system_percpu_wq buddy: - Make buddy allocator available to all DRM drivers - Document flags and structures colorop: - Add destroy helper and convert drivers fbdev-emulation: - Clean up gem: - Fix drm_gem_objects_lookup() error cleanup Driver Changes: amdgpu: - Set panel_type to OELD for eDP atmel-hlcdc: - Support sana5d65 LCD controller bridge: - anx7625: Support USB-C plus DT bindings - connector: Fix EDID detection - dw-hdmi-qp: Support Vendor-Specfic and SDP Infoframes; improve others - fsl-ldb: Fix visual artifacts plus related DT property 'enable-termination-resistor' - imx8qxp-pixel-link: Improve bridge reference handling - lt9611: Support Port-B-only input plus DT bindings - tda998x: Support DRM_BRIDGE_ATTACH_NO_CONNECTOR; Clean up - Support TH1520 HDMI plus DT bindings - Clean up imagination: - Clean up komeda: - Fix integer overflow in AFBC checks mcde: - Improve bridge handling nouveau: - Provide Z-cull info to user space - gsp: Support GA100 - Shutdown on PCI device shutdown - Clean up panel: - panel-jdi-lt070me05000: Use mipi-dsi multi functions - panel-edp: Support Add AUO B116XAT04.1 (HW: 1A); Support CMN N116BCL-EAK (C2); Support FriendlyELEC plus DT changes - Fix Kconfig dependencies panthor: - Add tracepoints for power and IRQs rcar-du: - dsi: fix VCLK calculation rockchip: - vop2: Use drm_ logging functions - Support DisplayPort on RK3576 sysfb: - corebootdrm: Support system framebuffer on coreboot firmware; detect orientation - Clean up pixel-format lookup sun4i: - Clean up tilcdc: - Use DT bindings scheme - Use managed DRM interfaces - Support DRM_BRIDGE_ATTACH_NO_CONNECTOR - Clean up a lot of obsolete code v3d: - Clean up vc4: - Use system_percpu_wq - Clean up verisilicon: - Support DC8200 plus DT bindings virtgpu: - Support PRIME imports with enabled 3D Signed-off-by: Dave Airlie <airlied@redhat.com> From: Thomas Zimmermann <tzimmermann@suse.de> Link: https://patch.msgid.link/20260226143615.GA47200@linux.fritz.box
2026-02-23Merge drm/drm-next into drm-misc-nextMaxime Ripard
Let's merge 7.0-rc1 to start the new drm-misc-next window Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-02-23Merge drm/drm-fixes into drm-misc-fixesMaxime Ripard
7.0-rc1 was just released, let's merge it to kick the new release cycle. Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-02-21Convert 'alloc_obj' family to use the new default GFP_KERNEL argumentLinus Torvalds
This was done entirely with mindless brute force, using git grep -l '\<k[vmz]*alloc_objs*(.*, GFP_KERNEL)' | xargs sed -i 's/\(alloc_objs*(.*\), GFP_KERNEL)/\1)/' to convert the new alloc_obj() users that had a simple GFP_KERNEL argument to just drop that argument. Note that due to the extreme simplicity of the scripting, any slightly more complex cases spread over multiple lines would not be triggered: they definitely exist, but this covers the vast bulk of the cases, and the resulting diff is also then easier to check automatically. For the same reason the 'flex' versions will be done as a separate conversion. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-02-21drm/bridge: synopsys: dw-dp: Make i2s/spdif clk optionalAndy Yan
The i2s/spdif clk are mandatory for rk3588, but not used for the upcoming rk3576, so make it optional here. Signed-off-by: Andy Yan <andy.yan@rock-chips.com> Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.com> Tested-by: Sebastian Reichel <sebastian.reichel@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20260206010421.443605-4-andyshrk@163.com
2026-02-21drm/bridge: synopsys: dw-dp: Set pixel mode by platform dataAndy Yan
In the implementation and integration of the SoC, the DW DisplayPort hardware block can be configured to work in single, dual, quad pixel mode on differnt platforms, so make the pixel mode set by plat_data to support the upcoming rk3576 variant. Signed-off-by: Andy Yan <andy.yan@rock-chips.com> Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.com> Tested-by: Sebastian Reichel <sebastian.reichel@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patch.msgid.link/20260206010421.443605-3-andyshrk@163.com
2026-02-21treewide: Replace kmalloc with kmalloc_obj for non-scalar typesKees Cook
This is the result of running the Coccinelle script from scripts/coccinelle/api/kmalloc_objs.cocci. The script is designed to avoid scalar types (which need careful case-by-case checking), and instead replace kmalloc-family calls that allocate struct or union object instances: Single allocations: kmalloc(sizeof(TYPE), ...) are replaced with: kmalloc_obj(TYPE, ...) Array allocations: kmalloc_array(COUNT, sizeof(TYPE), ...) are replaced with: kmalloc_objs(TYPE, COUNT, ...) Flex array allocations: kmalloc(struct_size(PTR, FAM, COUNT), ...) are replaced with: kmalloc_flex(*PTR, FAM, COUNT, ...) (where TYPE may also be *VAR) The resulting allocations no longer return "void *", instead returning "TYPE *". Signed-off-by: Kees Cook <kees@kernel.org>
2026-02-20drm/bridge: synopsys: dw-dp: Check return value of devm_drm_bridge_add() in ↵Chen Ni
dw_dp_bind() Return the value of devm_drm_bridge_add() in order to propagate the error properly, if it fails due to resource allocation failure or bridge registration failure. This ensures that the bind function fails safely rather than proceeding with a potentially incomplete bridge setup. Fixes: b726970486d8 ("drm/bridge: synopsys: dw-dp: add bridge before attaching") Signed-off-by: Chen Ni <nichen@iscas.ac.cn> Reviewed-by: Andy Yan <andyshrk@163.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patch.msgid.link/20260206040621.4095517-1-nichen@iscas.ac.cn Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-02-05Merge drm/drm-next into drm-misc-nextThomas Zimmermann
Backmerging to get bug fixes from v6.19-rc7. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
2026-01-30drm/bridge: dw-hdmi-qp: Rework Audio InfoFrame handlerCristian Ciocaltea
Make use of the recently introduced dw_hdmi_qp_write_infoframe() helper to simplify the writing of the Audio InfoFrame packet header and body registers. Additionally, discard the redundant static values identifying the frame version and length. Moreover, since now having dedicated callbacks per InfoFrame type, move the implementation to dw_hdmi_qp_bridge_write_audio_infoframe() and drop dw_hdmi_qp_config_audio_infoframe(). Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Daniel Stone <daniels@collabora.com> Link: https://patch.msgid.link/20260129-dw-hdmi-qp-iframe-v2-5-0157ad05232c@collabora.com Signed-off-by: Daniel Stone <daniels@collabora.com>
2026-01-30drm/bridge: dw-hdmi-qp: Rework DRM InfoFrame handlerCristian Ciocaltea
Make use of the recently introduced dw_hdmi_qp_write_infoframe() helper to simplify the writing of the Dynamic Range and Mastering (DRM) InfoFrame packet header and body registers. Moreover, since now having dedicated callbacks per InfoFrame type, move the implementation to dw_hdmi_qp_bridge_write_hdr_drm_infoframe() and drop dw_hdmi_qp_config_drm_infoframe(). While at it, also discard the unnecessary infoframe size verification, as well as the redundant disabling of the packet transmission (already done by the explicit call to the clear callback). Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Daniel Stone <daniels@collabora.com> Link: https://patch.msgid.link/20260129-dw-hdmi-qp-iframe-v2-4-0157ad05232c@collabora.com Signed-off-by: Daniel Stone <daniels@collabora.com>
2026-01-30drm/bridge: dw-hdmi-qp: Rework AVI InfoFrame handlerCristian Ciocaltea
Make use of the recently introduced dw_hdmi_qp_write_infoframe() helper to simplify the writing of the Auxiliary Video InfoFrame (AVI) packet header and body registers. Moreover, since now having dedicated callbacks per InfoFrame type, move the implementation to dw_hdmi_qp_bridge_write_avi_infoframe() and drop dw_hdmi_qp_config_avi_infoframe(). While at it, also discard the superfluous infoframe size verification. Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Daniel Stone <daniels@collabora.com> Link: https://patch.msgid.link/20260129-dw-hdmi-qp-iframe-v2-3-0157ad05232c@collabora.com Signed-off-by: Daniel Stone <daniels@collabora.com>
2026-01-30drm/bridge: dw-hdmi-qp: Provide SPD InfoFrameCristian Ciocaltea
The hardware is capable of sending Source Product Description (SPD) InfoFrames, hence enable the missing support. Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Daniel Stone <daniels@collabora.com> Link: https://patch.msgid.link/20260129-dw-hdmi-qp-iframe-v2-2-0157ad05232c@collabora.com Signed-off-by: Daniel Stone <daniels@collabora.com>
2026-01-30drm/bridge: dw-hdmi-qp: Provide HDMI Vendor Specific InfoFrameCristian Ciocaltea
Since commit b626b1a1c9cc ("drm/bridge: refactor HDMI InfoFrame callbacks"), the following warning is generated: [ 13.654149] rockchip-drm display-subsystem: [drm] HDMI VSI not supported Add the missing support for sending HDMI Vendor-Specific Infoframes. Additionally, introduce dw_hdmi_qp_write_{pkt|infoframe}() helpers, as a prerequisite to rework all dw_hdmi_qp_bridge_write_*_infoframe() callbacks and get rid of some boilerplate code. Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Daniel Stone <daniels@collabora.com> Link: https://patch.msgid.link/20260129-dw-hdmi-qp-iframe-v2-1-0157ad05232c@collabora.com Signed-off-by: Daniel Stone <daniels@collabora.com>
2026-01-28BackMerge tag 'v6.19-rc7' into drm-nextDave Airlie
Linux 6.19-rc7 This is needed for msm and rust trees. Signed-off-by: Dave Airlie <airlied@redhat.com>
2026-01-21drm/bridge: dw-hdmi: convert to of_drm_find_and_get_bridge()Luca Ceresoli
of_drm_find_bridge() is deprecated. Move to its replacement of_drm_find_and_get_bridge() which gets a bridge reference, and ensure it is put when done by using the drm_bridge::next_bridge pointer. Acked-by: Maxime Ripard <mripard@kernel.org> Link: https://patch.msgid.link/20260109-drm-bridge-alloc-getput-drm_of_find_bridge-3-v2-1-8d7a3dbacdf4@bootlin.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-01-20drm/bridge: synopsys: dw-dp: fix error paths of dw_dp_bindOsama Abdelkader
Fix several issues in dw_dp_bind() error handling: 1. Missing return after drm_bridge_attach() failure - the function continued execution instead of returning an error. 2. Resource leak: drm_dp_aux_register() is not a devm function, so drm_dp_aux_unregister() must be called on all error paths after aux registration succeeds. This affects errors from: - drm_bridge_attach() - phy_init() - devm_add_action_or_reset() - platform_get_irq() - devm_request_threaded_irq() 3. Bug fix: platform_get_irq() returns the IRQ number or a negative error code, but the error path was returning ERR_PTR(ret) instead of ERR_PTR(dp->irq). Use a goto label for cleanup to ensure consistent error handling. Fixes: 86eecc3a9c2e ("drm/bridge: synopsys: Add DW DPTX Controller support library") Cc: stable@vger.kernel.org Signed-off-by: Osama Abdelkader <osama.abdelkader@gmail.com> Reviewed-by: Louis Chauvet <louis.chauvet@bootlin.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patch.msgid.link/20260102155553.13243-1-osama.abdelkader@gmail.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-01-19drm/bridge: refactor HDMI InfoFrame callbacksDmitry Baryshkov
Having only a single set of callbacks, hdmi_clear_infoframe and hdmi_write_infoframe, bridge drivers don't have an easy way to signal to the DRM framework, which InfoFrames are actually supported by the hardware and by the driver and which are not. Also, it makes it extremely easy for HDMI bridge drivers to skip implementing the seemingly required InfoFrames (e.g. HDMI VSI). Last, but not least, those callbacks take a single 'type' parameter, which makes it impossible to implement support for multiple VSIs (which will be required once we start working on HDMI Forum VSI). Split the callbacks into a per-InfoFrame-kind pairs, letting the bridge drivers actually signal supported features. The implementation follows the overall drm_bridge design, where the bridge has a single drm_bridge_funcs implementation and signals, which functions are to be called using the drm_bridge->ops flags. The AVI and HDMI VSI are assumed to be required for a normal HDMI operation (with the drivers getting a drm_warn_once() stub implementation if one is missing). The Audio InfoFrame is handled by the existing DRM_BRIDGE_OP_HDMI_AUDIO, while the SPD and HDR DRM InfoFrames got new drm_bridge_ops values. Acked-by: Maxime Ripard <mripard@kernel.org> Link: https://patch.msgid.link/20260107-limit-infoframes-2-v4-5-213d0d3bd490@oss.qualcomm.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>