summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2025-03-20drm/bridge: ti-sn65dsi86: Remove drm_encoder->crtc useMaxime Ripard1-17/+38
The TI sn65dsi86 driver follows the drm_encoder->crtc pointer that is deprecated and shouldn't be used by atomic drivers. Fortunately, the atomic hooks provide the drm_atomic_state and we can access our current CRTC from that, going from the bridge to its encoder, to its connector, and to its CRTC. This bridge driver uses the atomic hooks already, but dereferences the drm_encoder->crtc pointer in functions that don't have access to it. Let's rework the driver to pass the state where needed, and remove the need for the drm_encoder->crtc dereference. Reviewed-by: Douglas Anderson <dianders@chromium.org> Tested-by: Douglas Anderson <dianders@chromium.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-16-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: tc358768: Convert to atomic helpersMaxime Ripard1-9/+19
The tc358768 driver follows the drm_encoder->crtc pointer that is deprecated and shouldn't be used by atomic drivers. Fortunately, the atomic hooks provide the drm_atomic_state and we can access our current CRTC from that, going from the bridge to its encoder, to its connector, and to its CRTC. Let's convert this bridge driver to atomic so we can get rid of the drm_encoder->crtc dereference. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-15-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: tc358768: Stop disabling when failing to enableMaxime Ripard1-8/+2
The tc358768 bridge driver, if enabling it fails, tries to disable it. This is pretty uncommon in bridge drivers, and also stands in the way for further reworks. Worse, since pre_enable and enable aren't expected to fail, disable and post_disable might be called twice: once to handle the failure, and once to actually disable the bridge. Since post_disable uses regulators and clocks, this would lead to enable count imbalances. In order to prevent that imbalance, and to allow further reworks, let's drop the calls to disable and post_disable, but keep the warning to let users know about what's going on. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-14-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: tc358775: Switch to atomic commitMaxime Ripard1-23/+19
The tc358775 driver follows the drm_encoder->crtc pointer that is deprecated and shouldn't be used by atomic drivers. Fortunately, the atomic hooks provide the drm_atomic_state and we can access our current CRTC from that, going from the bridge to its encoder, to its connector, and to its CRTC. Let's convert this bridge driver to atomic so we can get rid of the drm_encoder->crtc dereference. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-13-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: cdns-csi: Switch to atomic helpersMaxime Ripard1-9/+22
The Cadence DSI driver follows the drm_encoder->crtc pointer that is deprecated and shouldn't be used by atomic drivers. Fortunately, the atomic hooks provide the drm_atomic_state and we can access our current CRTC from that, going from the bridge to its encoder, to its connector, and to its CRTC. Let's convert this bridge driver to atomic so we can get rid of the drm_encoder->crtc dereference. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-12-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: Introduce drm_bridge_is_atomic() helperMaxime Ripard1-2/+7
We test for whether the bridge is atomic in several places in the source code, so let's consolidate them. Suggested-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-11-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: ti-sn65dsi83: Switch to drm_bridge_helper_reset_crtcMaxime Ripard1-17/+11
Now that we have a helper for bridge drivers to call to reset the output pipeline, let's use it. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Herve Codina <herve.codina@bootlin.com> Tested-by: Herve Codina <herve.codina@bootlin.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-10-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/tests: bridge: Provide tests for drm_bridge_helper_reset_crtcMaxime Ripard1-1/+208
Let's provide a bunch of kunit tests to make sure drm_bridge_helper_reset_crtc() works as expected. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-9-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: Add helper to reset bridge pipelineMaxime Ripard4-0/+74
Let's provide an helper to make it easier for bridge drivers to power-cycle their bridge. In order to avoid a circular dependency between that new helper and drm_atomic_helper_reset_crtc(), this new helper will be in a drm_bridge_helper.c file to follow the pattern we have for other objects. Reviewed-by: Herve Codina <herve.codina@bootlin.com> Reviewed-by: Simona Vetter <simona.vetter@ffwll.ch> Tested-by: Herve Codina <herve.codina@bootlin.com> Co-developed-by: Simona Vetter <simona.vetter@intel.com> Signed-off-by: Simona Vetter <simona.vetter@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-8-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/tests: Create tests for drm_atomicMaxime Ripard2-0/+154
We don't have a set of kunit tests for the functions under drm_atomic.h. Let's use the introduction of drm_atomic_get_connector_for_encoder() to create some tests for it and thus create that set. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-7-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/tests: hdmi_state_helpers: Switch to new helperMaxime Ripard1-66/+92
We introduced a new helper that supersedes the light_up_connector() function in drm_hdmi_state_helper_test, so let's convert all our tests to it. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-6-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/tests: helpers: Create new helper to enable outputMaxime Ripard2-0/+69
We'll need the HDMI state tests light_up_connector() function in more tests, so let's promote it to a helper. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-5-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/atomic: Introduce helper to lookup connector by encoderMaxime Ripard2-0/+62
With the bridges switching over to drm_bridge_connector, the direct association between a bridge driver and its connector was lost. This is mitigated for atomic bridge drivers by the fact you can access the encoder, and then call drm_atomic_get_old_connector_for_encoder() or drm_atomic_get_new_connector_for_encoder() with drm_atomic_state. This was also made easier by providing drm_atomic_state directly to all atomic hooks bridges can implement. However, bridge drivers don't have a way to access drm_atomic_state outside of the modeset path, like from the hotplug interrupt path or any interrupt handler. Let's introduce a function to retrieve the connector currently assigned to an encoder, without using drm_atomic_state, to make these drivers' life easier. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Simona Vetter <simona.vetter@ffwll.ch> Tested-by: Herve Codina <herve.codina@bootlin.com> Co-developed-by: Simona Vetter <simona.vetter@intel.com> Signed-off-by: Simona Vetter <simona.vetter@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-4-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/tests: Add kunit tests for bridgesMaxime Ripard3-0/+212
None of the drm_bridge function have kunit tests so far. Let's change that, starting with drm_bridge_get_current_state(). Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-3-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: Provide a helper to retrieve current bridge stateMaxime Ripard1-0/+32
The current bridge state is accessible from the drm_bridge structure, but since it's fairly indirect it's not easy to figure out. Provide a helper to retrieve it. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-2-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20drm/bridge: Add encoder parameter to drm_bridge_funcs.attachMaxime Ripard83-95/+172
The drm_bridge structure contains an encoder pointer that is widely used by bridge drivers. This pattern is largely documented as deprecated in other KMS entities for atomic drivers. However, one of the main use of that pointer is done in attach to just call drm_bridge_attach on the next bridge to add it to the bridge list. While this dereferences the bridge->encoder pointer, it's effectively the same encoder the bridge was being attached to. We can make it more explicit by adding the encoder the bridge is attached to to the list of attach parameters. This also removes the need to dereference bridge->encoder in most drivers. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250313-bridge-connector-v6-1-511c54a604fb@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-20MAINTAINERS: update Microchip's Atmel-HLCDC driver maintainersManikandan Muralidharan1-2/+2
Drop Sam Ravnborg and Boris Brezillon as they are no longer interested in maintaining the drivers. Add myself and Dharma Balasubiramani as the Maintainer and co-maintainer for Microchip's Atmel-HLCDC driver. Thanks for their work. Signed-off-by: Manikandan Muralidharan <manikandan.m@microchip.com> Acked-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Boris Brezillon <boris.brezillon@collabora.com> Acked-by: Nicolas Ferre <nicolas.ferre@microchip.com> Link: https://patchwork.freedesktop.org/patch/msgid/20240620095856.777390-1-manikandan.m@microchip.com Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
2025-03-19Documentation: vgaarbiter: Fix grammarPranav Tyagi1-3/+3
Correct grammar issues: - Fix "co-exist" subject-verb agreement - Correct plural form of "server" in context of more than one legacy devices - Use passive mood for intro sentence of libpciaccess section Signed-off-by: Pranav Tyagi <pranav.tyagi03@gmail.com> Reviewed-by: Bagas Sanjaya <bagasdotme@gmail.com> Link: https://lore.kernel.org/r/20250220164946.18007-1-pranav.tyagi03@gmail.com [Bagas: massage commit message] Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250318041249.20786-2-bagasdotme@gmail.com Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-19drm/vmwgfx: Switch to exclusively using GEM referencesIan Forbes10-38/+18
Currently we use a combination of TTM and GEM reference counting which is cumbersome. TTM references are used for kernel internal BOs and operations like validation. Simply switching the ttm_bo_(get|put) calls to their GEM equivalents is insufficient as not all BOs are GEM BOs so we must set the GEM vtable for all BOs even if they are not exposed to userspace. Suggested-by: Christian König <christian.koenig@amd.com> Signed-off-by: Ian Forbes <ian.forbes@broadcom.com> Reviewed-by: Zack Rusin <zack.rusin@broadcom.com> Signed-off-by: Zack Rusin <zack.rusin@broadcom.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250131200321.193939-1-ian.forbes@broadcom.com
2025-03-19drm/vmwgfx: Fix dumb buffer leakIan Forbes3-9/+17
Dumb buffers were not being freed because the GEM reference that was acquired in gb_surface_define was not dropped like it is in the 2D case. Dropping this ref uncovered a few additional issues with freeing the resources associated with dirty tracking in vmw_bo_free/release. Additionally the TTM object associated with the surface were also leaking which meant that when the ttm_object_file was closed at process exit the destructor unreferenced an already destroyed surface. The solution is to remove the destructor from the vmw_user_surface associated with the dumb_buffer and immediately unreferencing the TTM object which his removes it from the ttm_object_file. This also allows the early return in vmw_user_surface_base_release for the dumb buffer case to be removed as it should no longer occur. The chain of references now has the GEM handle(s) owning the dumb buffer. The GEM handles have a singular GEM reference to the vmw_bo which is dropped when all handles are closed. When the GEM reference count hits zero the vmw_bo is freed which then unreferences the surface via vmw_resource_release in vmw_bo_release. Fixes: d6667f0ddf46 ("drm/vmwgfx: Fix handling of dumb buffers") Signed-off-by: Ian Forbes <ian.forbes@broadcom.com> Reviewed-by: Zack Rusin <zack.rusin@broadcom.com> Signed-off-by: Zack Rusin <zack.rusin@broadcom.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250123204424.836896-1-ian.forbes@broadcom.com
2025-03-15drm: panel-orientation-quirks: Add ZOTAC Gaming ZoneVicki Pfau1-0/+6
Add a panel orientation quirk for the ZOTAC Gaming Zone handheld gaming device. Signed-off-by: Vicki Pfau <vi@endrift.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250313211643.860786-2-vi@endrift.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
2025-03-14accel/qaic: Remove redundant 'flush_workqueue()' callsChen Ni1-2/+0
'destroy_workqueue()' already drains the queue before destroying it, so there is no need to flush it explicitly. Remove the redundant 'flush_workqueue()' calls. This was generated with coccinelle: @@ expression E; @@ - flush_workqueue(E); destroy_workqueue(E); Signed-off-by: Chen Ni <nichen@iscas.ac.cn> Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com> Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250312073404.1429992-1-nichen@iscas.ac.cn
2025-03-14drm: add modifiers for Apple GPU layoutsAlyssa Rosenzweig1-0/+45
Apple GPUs support non-linear "GPU-tiled" image layouts. Add modifiers for these layouts. Mesa requires these modifiers to share non-linear buffers across processes, but no other userspace or kernel support is required/expected. These layouts are notably not used for interchange across hardware blocks (e.g. with the display controller). There are other layouts for that but we don't support them either in userspace or kernelspace yet (even downstream), so we don't add modifiers here. Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com> Reviewed-by: Sven Peter <sven@svenpeter.dev> Link: https://patchwork.freedesktop.org/patch/msgid/20250310-apple-twiddled-modifiers-v4-1-1ccac9544808@rosenzweig.io Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
2025-03-14drm/sched: Clarify docu concerning drm_sched_job_arm()Philipp Stanner1-6/+18
The documentation for drm_sched_job_arm() and especially drm_sched_job_cleanup() does not make it very clear why drm_sched_job_arm() is a point of no return, which it indeed is. Make the nature of drm_sched_job_arm() in the docu as clear as possible. Suggested-by: Christian König <christian.koenig@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Philipp Stanner <phasta@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250313093053.65001-2-phasta@kernel.org
2025-03-14drm/display: hdmi: Mention Infoframes testing with edid-decodeMaxime Ripard1-0/+271
edid-decode gained recently support to check that infoframes are compliant and match the EDID the monitor exposes. Since the HDMI helpers provide those infoframes in debugfs, it makes it easy to check from userspace that the drivers (and helpers) behave properly. Let's document it. Cc: Hans Verkuil <hverkuil@xs4all.nl> Reviewed-by: Hans Verkuil <hverkuil@xs4all.nl> Link: https://patchwork.freedesktop.org/patch/msgid/20250312-drm-hdmi-state-docs-v2-2-6352a5d68d5b@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-14drm/display: hdmi: Create documentation sectionMaxime Ripard2-0/+36
We have had documentation for the public functions in the HDMI helpers, but those were never referenced anywhere and thus not compiled as part of the doc. Let's add a section. Reviewed-by: Dmitry Baryshkov <lumag@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250312-drm-hdmi-state-docs-v2-1-6352a5d68d5b@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2025-03-14drm/ttm/tests: fix incorrect assert in ttm_bo_unreserve_bulk()Qasim Ijaz1-1/+1
In the ttm_bo_unreserve_bulk() test function, resv is allocated using kunit_kzalloc(), but the subsequent assertion mistakenly verifies the ttm_dev pointer instead of the resv pointer. Fix the assertion to properly verify the resv pointer. Signed-off-by: Qasim Ijaz <qasdev00@gmail.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250313161424.10688-1-qasdev00@gmail.com Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Christian König <christian.koenig@amd.com>
2025-03-13drm/client: s/unsigned int i/int i/Ville Syrjälä1-3/+3
Replace the 'unsigned int i' footguns with plain old signed int. Avoids accidents if/when someone decides they need to iterate backwards. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228211454.8138-9-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com>
2025-03-13drm/client: Move variables to tighter scopeVille Syrjälä1-15/+18
Bunch of variables are only needed inside loops and whatnot. Move them to a tighter scope to make the code less confusing. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228211454.8138-8-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com>
2025-03-13drm/client: s/new_crtc/crtc/Ville Syrjälä1-6/+6
Rename the 'new_crtc' variable to just 'crtc' in drm_client_firmware_config(). We don't call any of the other stuff in here new or old so this feels out of place. v2: Rebase Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228211454.8138-7-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com>
2025-03-13drm/client: Stop using the legacy crtc->modeVille Syrjälä1-12/+1
crtc->mode is legacy junk and shouldn't really be used with atomic drivers. Most (all?) atomic drivers do end up still calling drm_atomic_helper_update_legacy_modeset_state() at some point, so crtc->mode does still get populated, and this does work for now. But now that the modes[] lifetime issues have been sorted out we can just switch over to the proper crtc->state->mode. v2: Rebase Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228211454.8138-6-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com>
2025-03-13drm/client: Make copies of modesVille Syrjälä1-15/+47
drm_client_firmware_config() is currently picking up the current mode of the crtc via the legacy crtc->mode, which is not supposed to be used by atomic drivers at all. We can't simply switch over to the proper crtc->state->mode because we drop the crtc->mutex (which protects crtc->state) before the mode gets used. The most straightforward solution to extend the lifetime of modes[] seem to be to make full copies of the modes. And with this we can undo also commit 3eadd887dbac ("drm/client:Fully protect modes[] with dev->mode_config.mutex") as the lifetime of modes[] no longer has anything to do with that lock. v2: Don't try to copy NULL modes v3: Keep storing pointers and use drm_mode_{duplicate,destroy}() Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228211454.8138-5-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com>
2025-03-13drm/client: Streamline mode selection debugsVille Syrjälä1-37/+33
Get rid of all the redundant debugs and just wait until the end to print which mode (and of which type) we picked. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228211454.8138-4-ville.syrjala@linux.intel.com
2025-03-13drm/client: Use array notation for function argumentsVille Syrjälä1-21/+21
Use the array notation rather that the pointer notation for function arguments. This makes it clear to the reader that we are in fact dealing with an array rather than a single pointer. Functionally the two are equivalent. Reviewed-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228211454.8138-3-ville.syrjala@linux.intel.com
2025-03-13drm/client: Constify modesVille Syrjälä2-19/+23
The modes used by the client code live on the connectors' mode lists, which are not owned by the client code, and thus it has no business modifying the modes. Mark the modes const to make that fact abundantly clear. v2: Fix up the kunit test Reviewed-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250303093847.7698-1-ville.syrjala@linux.intel.com
2025-03-12drm/ci: fix merge request rulesVignesh Raman1-15/+4
Merge request pipelines were only created when changes were made to drivers/gpu/drm/ci/, causing MRs that didn't touch this path to break. Fix MR pipeline rules to trigger jobs for all changes. Run jobs automatically for marge-bot and scheduled pipelines, but in all other cases run manually. Also remove CI_PROJECT_NAMESPACE checks specific to mesa. Fixes: df54f04f2020 ("drm/ci: update gitlab rules") Signed-off-by: Vignesh Raman <vignesh.raman@collabora.com> Reviewed-by: Daniel Stone <daniels@collabora.com> Signed-off-by: Helen Koike <helen.fornazier@gmail.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250228132620.556079-1-vignesh.raman@collabora.com
2025-03-12drm: xlnx: zynqmp_dpsub: fix Kconfig dependencies for ASoCArnd Bergmann1-0/+1
The new audio code fails to build when sounds support is in a loadable module but the GPU driver is built-in: x86_64-linux-ld: zynqmp_dp_audio.c:(.text+0x6a8): undefined reference to `devm_snd_soc_register_card' x86_64-linux-ld: drivers/gpu/drm/xlnx/zynqmp_dp_audio.o:(.rodata+0x1bc): undefined reference to `snd_soc_info_volsw' x86_64-linux-ld: drivers/gpu/drm/xlnx/zynqmp_dp_audio.o:(.rodata+0x1f0): undefined reference to `snd_soc_get_volsw' x86_64-linux-ld: drivers/gpu/drm/xlnx/zynqmp_dp_audio.o:(.rodata+0x1f4): undefined reference to `snd_soc_put_volsw' Change the Kconfig dependency to disallow the sound support in this configuration. Fixes: 3ec5c1579305 ("drm: xlnx: zynqmp_dpsub: Add DP audio support") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250227132036.1136600-1-arnd@kernel.org
2025-03-12drm/sched: revert "drm_sched_job_cleanup(): correct false doc"Christian König1-7/+5
This reverts commit 44d2f310f008613c1dbe5e234c2cf2be90cbbfab. The function drm_sched_job_arm() is indeed the point of no return. The background is that it is nearly impossible for the driver to correctly retract the fence and signal it in the order enforced by the dma_fence framework. The code in drm_sched_job_cleanup() is for the purpose to cleanup after the job was armed through drm_sched_job_arm() *and* processed by the scheduler. We can certainly improve the documentation, but removing the warning is clearly not a good idea. Signed-off-by: Christian König <christian.koenig@amd.com> Signed-off-by: Philipp Stanner <phasta@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250312134400.2176393-1-christian.koenig@amd.com
2025-03-12drm/debugfs: add top-level 'bridges' file showing all added bridgesLuca Ceresoli3-22/+53
The global bridges_list holding all the bridges between drm_bridge_add() and drm_bridge_remove() cannot be inspected via debugfs. Add a file showing it. To avoid code duplication, move the code printing a bridge info to a common function. Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250226-drm-debugfs-show-all-bridges-v8-2-bb511cc49d83@bootlin.com Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>
2025-03-12drm/bridge: move bridges_show logic from drm_debugfs.cLuca Ceresoli3-37/+45
In preparation to expose more info about bridges in debugfs, which will require more insight into drm_bridge data structures, move the bridges_show code to drm_bridge.c. Suggested-by: Jani Nikula <jani.nikula@linux.intel.com> Suggested-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250226-drm-debugfs-show-all-bridges-v8-1-bb511cc49d83@bootlin.com Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>
2025-03-12drm/panel: simple: Add POWERTIP PH128800T004-ZZA01 panel entryAntonin Godard1-0/+29
Add support for the POWERTIP PH128800T004-ZZA01 10.1" (1280x800) LCD-TFT panel. Its panel description is very much like the POWERTIP PH128800T006-ZHC01 configured below this one, only its timings are different. Signed-off-by: Antonin Godard <antonin.godard@bootlin.com> Reviewed-by: Dmitry Baryshkov <lumag@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250311-add-powertip-ph128800t004-v1-2-7f95e6984cea@bootlin.com Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>
2025-03-12dt-bindings: display: simple: Add POWERTIP PH128800T004-ZZA01 panelAntonin Godard1-0/+2
Add POWERTIP PH128800T004-ZZA01 10.1" LCD-TFT LVDS panel compatible string. Signed-off-by: Antonin Godard <antonin.godard@bootlin.com> Acked-by: "Rob Herring (Arm)" <robh@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250311-add-powertip-ph128800t004-v1-1-7f95e6984cea@bootlin.com Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>
2025-03-12drm/mxsfb: Remove generic DRM drivers in probe functionDario Binacchi1-0/+10
Use aperture helpers to remove all generic graphics drivers before loading mxsfb. Makes mxsfb compatible with simpledrm. Co-developed-by: Michael Trimarchi <michael@amarulasolutions.com> Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com> Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com> Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Link: https://patchwork.freedesktop.org/patch/msgid/20250305140929.174398-1-dario.binacchi@amarulasolutions.com
2025-03-12drm/udl: Set struct drm_device.dma_devThomas Zimmermann3-25/+7
Set the dma_dev field provided by the DRM device. Required for PRIME dma-buf import. Remove the driver's implementation. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250307080836.42848-6-tzimmermann@suse.de
2025-03-12drm/gud: Set struct drm_device.dma_devThomas Zimmermann2-25/+9
Set the dma_dev field provided by the DRM device. Required for PRIME dma-buf import. Remove the driver's implementation. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250307080836.42848-5-tzimmermann@suse.de
2025-03-12drm/gm12u320: Set struct drm_device.dma_devThomas Zimmermann1-33/+13
Set the dma_dev field provided by the DRM device. Required for PRIME dma-buf import. Remove the driver's implementation. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250307080836.42848-4-tzimmermann@suse.de
2025-03-12drm/appletbdrm: Set struct drm_device.dma_devThomas Zimmermann1-17/+10
Set the dma_dev field provided by the DRM device. Required for PRIME dma-buf import. Remove the driver's implementation. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Tested-by: Aditya Garg <gargaditya08@live.com> Reviewed-by: Aditya Garg <gargaditya08@live.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250307080836.42848-3-tzimmermann@suse.de
2025-03-12drm/prime: Support dedicated DMA device for dma-buf importsThomas Zimmermann3-1/+63
Importing dma-bufs via PRIME requires a DMA-capable device. Devices on peripheral busses, such as USB, often cannot perform DMA by themselves. Without DMA-capable device PRIME import fails. DRM drivers for USB devices already use a separate DMA device for dma-buf imports. Make the mechanism generally available. Besides the case of USB, there are embedded DRM devices without DMA capability. DMA is performed by a separate controller. DRM drivers should set this accordingly. Add the field dma_dev to struct drm_device to refer to the device's DMA device. For USB this should be the USB controller. Use dma_dev in the PRIME import helpers, if set. v2: - acquire internal reference on dma_dev (Jani) - add DMA-controller usecase to docs (Maxime) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Maxime Ripard <mripard@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250307080836.42848-2-tzimmermann@suse.de
2025-03-12drm/ast: cursor: Drop page alignmentThomas Zimmermann1-1/+1
The cursor scanout address requires alignment to a multiple of 8, but does not require page alignment. Change the offset calculation accordingly. Frees up a few more bytes for the primary framebuffer. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250305163207.267650-8-tzimmermann@suse.de
2025-03-12drm/ast: Remove vram_fb_available from struct ast_deviceThomas Zimmermann3-19/+4
Helpers compute the offset and size of the available framebuffer memory. Remove the obsolete field vram_fb_available from struct ast_device. Also define the cursor-signature size next to its only user. v2: - initialize plane size Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250305163207.267650-7-tzimmermann@suse.de