aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu (follow)
AgeCommit message (Collapse)AuthorFilesLines
2025-09-05drm/xe/mcr: Make xe_gt_mcr_get_dss_steering() input gt a constHarish Chegondi2-2/+3
Make gt, input parameter to xe_gt_mcr_get_dss_steering(), a constant. This would allow xe_gt_mcr_get_dss_steering() to be called from functions that have gt as const to struct xe_gt. Cc: Lucas De Marchi <lucas.demarchi@intel.com> Reviewed-by: Matt Atwood <matthew.s.atwood@intel.com> Signed-off-by: Harish Chegondi <harish.chegondi@intel.com> Link: https://lore.kernel.org/r/9dc621a90880f62ac8e2951afea7952277f7eb0e.1756855529.git.harish.chegondi@intel.com Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
2025-09-05drm/panel: lvds: Remove unused members from main structureLiu Ying1-2/+0
Since commit 03fa454bb666 ("drm/panel: lvds: Simplify mode parsing"), the width and height members of struct panel_lvds are no longer used. Remove them. No functional change. Signed-off-by: Liu Ying <victor.liu@nxp.com> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org> Reviewed-by: Raphael Gallais-Pou <raphael.gallais-pou@foss.st.com> Link: https://lore.kernel.org/r/20250829-panel-lvds-remove-width-height-v1-1-acecf0c84dc4@nxp.com
2025-09-05drm/i915/alpm: Use actual lfps cycle and silence periods in wake timeJouni Högander1-7/+5
Currently we are using maximum lfps cycle and silence period times when calculating AUXLess wake time. Use actual values instead. Signed-off-by: Jouni Högander <jouni.hogander@intel.com> Reviewed-by: Animesh Manna <animesh.manna@intel.com> Link: https://lore.kernel.org/r/20250829053929.3585636-5-jouni.hogander@intel.com
2025-09-05drm/i915/alpm: Replace hardcoded LFPS cycle with proper calculationJouni Högander1-52/+38
Currently LFPS is hadcoded for different port clocks. Replace this with proper calculation. v2: replace hardcoded 20 with 2 * LFPS_CYCLE_COUNT Signed-off-by: Jouni Högander <jouni.hogander@intel.com> Reviewed-by: Animesh Manna <animesh.manna@intel.com> Link: https://lore.kernel.org/r/20250829053929.3585636-4-jouni.hogander@intel.com
2025-09-05drm/i915/alpm: Add own define for LFPS countJouni Högander1-1/+3
Add own define for LFPS count and use it for the configuration. This new define will be used for calculating ALPM parameters as well. Signed-off-by: Jouni Högander <jouni.hogander@intel.com> Reviewed-by: Animesh Manna <animesh.manna@intel.com> Link: https://lore.kernel.org/r/20250829053929.3585636-3-jouni.hogander@intel.com
2025-09-05drm/i915/alpm: Calculate silence periodJouni Högander1-20/+17
Calculate silence period instead of hardcoding it in switch case. Signed-off-by: Jouni Högander <jouni.hogander@intel.com> Reviewed-by: Animesh Manna <animesh.manna@intel.com> Link: https://lore.kernel.org/r/20250829053929.3585636-2-jouni.hogander@intel.com
2025-09-05Merge tag 'drm-misc-next-2025-09-04' of ↵Dave Airlie77-629/+3446
https://gitlab.freedesktop.org/drm/misc/kernel into drm-next drm-misc-next for v6.18: Cross-subsystem Changes: - Update a number of DT bindings for STM32MP25 Arm SoC Core Changes: gem: - Simplify locking for GPUVM panel-backlight-quirks: - Add additional quirks for EDID, DMI, brightness sched: - Fix race condition in trace code - Clean up sysfb: - Clean up Driver Changes: amdgpu: - Give kernel jobs a unique id for better tracing amdxdna: - Improve error reporting bridge: - Improve ref counting on bridge management - adv7511: Provide SPD and HDMI infoframes - it6505: Replace crypto_shash with sha() - synopsys: Add support for DW DPTX Controller plus DT bindings gud: - Replace simple-KMS pipe with regular atomic helpers imagination: - Improve power management - Add support for TH1520 GPU - Support Risc-V architectures ivpu: - Clean up nouveau: - Improve error reporting panthor: - Fail VM bind if BO has offset - Clean up rcar-du: - Make number of lanes configurable rockchip: - Add support for RK3588 DPTX output rocket: - Use kfree() and sizeof() correctly - Test DMA status - Clean up sitronix: - st7571-i2c: Add support for inverted displays and 2-bit grayscale - Clean up stm: - ltdc: Add support support for STM32MP257F-EV1 plus DT bindings tidss: - Convert to kernel's FIELD_ macros v3d: - Improve job management and locking Signed-off-by: Dave Airlie <airlied@redhat.com> From: Thomas Zimmermann <tzimmermann@suse.de> Link: https://lore.kernel.org/r/20250904090932.GA193997@linux.fritz.box
2025-09-05Merge tag 'amd-drm-fixes-6.17-2025-09-03' of ↵Dave Airlie15-28/+98
https://gitlab.freedesktop.org/agd5f/linux into drm-fixes amd-drm-fixes-6.17-2025-09-03: amdgpu: - UserQ fixes - MES 11 fix - eDP/LVDS fix - Fix non-DC audio clean up - Fix duplicate cursor issue - Fix error path in PSP init Signed-off-by: Dave Airlie <airlied@redhat.com> From: Alex Deucher <alexander.deucher@amd.com> Link: https://lore.kernel.org/r/20250903221656.251254-1-alexander.deucher@amd.com
2025-09-04rust: dma: add type alias for bindings::dma_addr_tDanilo Krummrich1-2/+2
Add a type alias for bindings::dma_addr_t (DmaAddress), such that we do not have to access bindings directly. Reviewed-by: Alice Ryhl <aliceryhl@google.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Reviewed-by: Lyude Paul <lyude@redhat.com> Suggested-by: Alice Ryhl <aliceryhl@google.com> Link: https://lore.kernel.org/r/20250828133323.53311-3-dakr@kernel.org Signed-off-by: Danilo Krummrich <dakr@kernel.org>
2025-09-04drm/xe/configfs: Don't expose survivability_mode if not applicableMichal Wajdeczko3-30/+7
The survivability_mode attribute is applicable only for DGFX and platforms newer than BATTLEMAGE. Use .is_visible() hook to hide this attribute when above conditions are not met. Remove code that was trying to fix such configuration during the runtime. Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Cc: Lucas De Marchi <lucas.demarchi@intel.com> Cc: Riana Tauro <riana.tauro@intel.com> Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com> Reviewed-by: Stuart Summers <stuart.summers@intel.com> Link: https://lore.kernel.org/r/20250902131744.5076-4-michal.wajdeczko@intel.com
2025-09-04drm/xe/configfs: Prepare to filter-out configfs attributesMichal Wajdeczko1-2/+18
Implement empty ops.is_visible hook to allow filtering-out any not supported attributes, as not all of them are applicable on all xe platforms. Since during creation of each new configfs directory we are looking for xe device descriptor to validate that xe driver supports given PCI device, store reference to that descriptor to allow later use while doing attribute filtering. Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Cc: Lucas De Marchi <lucas.demarchi@intel.com> Reviewed-by: Stuart Summers <stuart.summers@intel.com> Link: https://lore.kernel.org/r/20250902131744.5076-3-michal.wajdeczko@intel.com
2025-09-04drm/xe/configfs: Don't touch survivability_mode on finiMichal Wajdeczko1-1/+2
This is a user controlled configfs attribute, we should not modify that outside the configfs attr.store() implementation. Fixes: bc417e54e24b ("drm/xe: Enable configfs support for survivability mode") Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Cc: Lucas De Marchi <lucas.demarchi@intel.com> Cc: Riana Tauro <riana.tauro@intel.com> Reviewed-by: Stuart Summers <stuart.summers@intel.com> Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com> Link: https://lore.kernel.org/r/20250904103521.7130-1-michal.wajdeczko@intel.com
2025-09-04drm/bridge: cdns-dsi: Select VIDEOMODE_HELPERSNathan Chancellor1-0/+1
When no other driver selects CONFIG_VIDEOMODE_HELPERS but CONFIG_DRM_CDNS_DSI is enabled, there is a linker or modpost error: ERROR: modpost: "drm_display_mode_to_videomode" [drivers/gpu/drm/bridge/cadence/cdns-dsi.ko] undefined! Select VIDEOMODE_HELPERS to ensure that this helper function is available to the driver. Fixes: ce4bc5ca7c1d ("drm/bridge: cdns-dsi: Use video mode and clean up cdns_dsi_mode2cfg()") Signed-off-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Link: https://lore.kernel.org/r/20250821-cdns-videohelpers-v1-1-853e021908cf@kernel.org Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
2025-09-04drm/xe/guc: Set upper limit of H2G retries over CTBMichal Wajdeczko1-0/+10
The GuC communication protocol allows GuC to send NO_RESPONSE_RETRY reply message to indicate that due to some interim condition it can not handle incoming H2G request and the host shall resend it. But in some cases, due to errors, this unsatisfied condition might be final and this could lead to endless retries as it was recently seen on the CI: [drm] GT0: PF: VF1 FLR didn't finish in 5000 ms (-ETIMEDOUT) [drm] GT0: PF: VF1 resource sanitizing failed (-ETIMEDOUT) [drm] GT0: PF: VF1 FLR failed! [drm:guc_ct_send_recv [xe]] GT0: H2G action 0x5503 retrying: reason 0x0 [drm:guc_ct_send_recv [xe]] GT0: H2G action 0x5503 retrying: reason 0x0 [drm:guc_ct_send_recv [xe]] GT0: H2G action 0x5503 retrying: reason 0x0 [drm:guc_ct_send_recv [xe]] GT0: H2G action 0x5503 retrying: reason 0x0 To avoid such dangerous loops allow only limited number of retries (for now 50) and add some delays (n * 5ms) to slow down the rate of resending this repeated request. Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Cc: John Harrison <John.C.Harrison@Intel.com> Cc: Matthew Brost <matthew.brost@intel.com> Reviewed-by: Stuart Summers <stuart.summers@intel.com> Reviewed-by: Julia Filipchuk <julia.filipchuk@intel.com> Link: https://lore.kernel.org/r/20250903223330.6408-1-michal.wajdeczko@intel.com
2025-09-04change the calling conventions for vfs_parse_fs_string()Al Viro2-14/+4
Absolute majority of callers are passing the 4th argument equal to strlen() of the 3rd one. Drop the v_size argument, add vfs_parse_fs_qstr() for the cases that want independent length. Reviewed-by: Christian Brauner <brauner@kernel.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2025-09-04drm/panthor: validate group queue countChia-I Wu1-1/+1
A panthor group can have at most MAX_CS_PER_CSG panthor queues. Fixes: 4bdca11507928 ("drm/panthor: Add the driver frontend block") Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com> # v1 Reviewed-by: Steven Price <steven.price@arm.com> Signed-off-by: Steven Price <steven.price@arm.com> Link: https://lore.kernel.org/r/20250903192133.288477-1-olvaffe@gmail.com
2025-09-04drm/i915/pps: prefer poll_timeout_us() over read_poll_timeout()Jani Nikula1-5/+3
Unify on using poll_timeout_us() throughout instead of mixing with readx_poll_timeout(). Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/260fd455df743453f123d96fc01e7ca96a36f0fa.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/ddi: prefer poll_timeout_us() over readx_poll_timeout()Jani Nikula1-21/+11
Unify on using poll_timeout_us() throughout instead of mixing with readx_poll_timeout(). While the latter can be ever so slightly simpler, they are both complicated enough that it's better to unify on one approach only. While at it, better separate the handling of error returns from drm_dp_dpcd_readb() and the actual status byte. This is best achieved by inlining the read_fec_detected_status() function, and switching to drm_dp_dpcd_read_byte(). v2: Use drm_dp_dpcd_read_byte() (Imre) Cc: Imre Deak <imre.deak@intel.com> Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/63b10a36c7ab545c640b24bc8fc007ce2ea74623.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/opregion: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-4/+6
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 1 ms sleep instead. The timeout remains, being opregion defined, 50 ms by default, and 1500 ms at most. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/63db3a1e1db9e55a18ed322c55f2dffe511a10bb.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/lspcon: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-3/+10
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 5 ms sleep instead. The timeouts remain, being 400 ms or 800 ms, depending on the case. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/4065fa96c0ef6afd51a384f365761d2ca802256b.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/dsb: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-2/+8
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 100 us sleep instead. The timeout remains at 1 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/979eae02af1184b3756746ace61379dd1947a79b.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/tc: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-2/+14
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 200 us sleep for the 5 ms timeout, and 1000 us sleep for the 500 ms timeout. The timeouts remain the same. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/50cd06b61210f541d5bb52a36af2d8bf059dd3a1.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/vblank: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-1/+8
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 500 us sleep instead. The timeout remains at 100 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/162dff5862d3213304491a6d2eb31a57346b523e.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/dp: use generic poll_timeout_us() instead of wait_for() in link ↵Jani Nikula1-4/+13
training Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 500 us sleep instead. The timeout remains at 500 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/29ab4738758fe844dc1323c4a59d5d6bdcf87308.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/dp: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-10/+10
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 1 ms sleep instead. The timeouts remain, being 500 ms or 1000 ms depending on the case. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/83d3417d4e5af1db13eb4c6eaa48b5f9c12caeb4.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/power-well: use generic poll_timeout_us() instead of wait_for() for ↵Jani Nikula1-14/+15
VLV/CHV Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 500 us sleep instead. The timeout remains at 100 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/c644b7b5611a3c047ea5d3d52acd91830b2fa6b4.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/power-well: use generic poll_timeout_us() instead of wait_for() for ↵Jani Nikula1-4/+9
DKL PHY Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 100 us sleep instead. The timeout remains at 1 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/663c9edf4a98b09121d7200f8d734ebc829da85b.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/power: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-2/+5
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 100 us sleep instead. The timeout remains at 1 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/900680516b047ae32e3298b5cdbcede0393e0466.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/cdclk: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-17/+20
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 500 us sleep instead. The timeout remains at 50 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/6d50031411d5517508867d4b595ce90a2b44073b.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/wm: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-4/+12
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 500 us sleep instead. The timeout remains at 3 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/52c80860ea7b98e84f2386ed6cdd761f03190b1e.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/gmbus: use generic poll_timeout*() instead of wait_for*()Jani Nikula1-5/+8
Prefer generic poll helpers over i915 custom helpers. The "two tier" wait_for_us() + wait_for() combination appeared without much explanation in commit 4e6c2d58ba86 ("drm/i915: Take forcewake once for the entire GMBUS transaction"). Try to mimic roughly the same with the generic helpers. wait_for_us() with 10 us or shorter timeouts ends up in _wait_for_atomic(). Thus use poll_timeout_us_atomic() for the first try, with the same 2 us timeout and no sleep. For the fallback, the functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 500 us sleep instead. The timeout remains at 50 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/564b397352c53a1116519fb2d53050c0426bc0dc.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/dsi-pll: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-4/+7
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 500 us sleep instead. The timeout remains at 20 ms. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/476fcc5aad9e2ddbf6d8c14bd5ff5cbf071c5dca.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/dsi: use generic poll_timeout_us() instead of wait_for_us()Jani Nikula1-4/+14
Prefer generic poll helpers over i915 custom helpers. The sleep and timeout remain the same as for wait_for_us(). Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/02ebcd2864819b7eaf9cf455aa2b968980a2f671.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/hdcp: use generic poll_timeout_us() instead of wait_for()Jani Nikula1-7/+10
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of wait_for(), which used to be 10, 20, 40, ..., 640, and 1280 us. Use an arbitrary constant 100 us sleep instead. The timeout remains at 1 ms. While at it, use the last failing value for debug logging instead of reading it again. Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/2871a07337401c25ef3df44073c5e78fedc45e8e.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/hdcp: use generic poll_timeout_us() instead of __wait_for()Jani Nikula1-4/+4
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of __wait_for(), which used to be 1, 2, 4, ... 64, and 128 ms in this particular case. Use an arbitrary 100 ms sleep instead. The timeout remains at 5000 ms. Cc: Suraj Kandpal <suraj.kandpal@intel.com> Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/bfc9f941ec1628830644f1419d606e3d085aaba0.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/i915/hdmi: use generic poll_timeout_us() instead of __wait_for()Jani Nikula1-5/+5
Prefer generic poll helpers over i915 custom helpers. The functional change is losing the exponentially growing sleep of __wait_for(), which used to be 1, 2, 4, and 8 ms in this particular case. Use an arbitrary constant 4 ms sleep instead. The timeout remains, varying between 20 ms and 3000 ms. Cc: Suraj Kandpal <suraj.kandpal@intel.com> Reviewed-by: Jouni Högander <jouni.hogander@intel.com> Link: https://lore.kernel.org/r/fc3a67f9de0049f415a276bba1c11a4df97e01d6.1756383233.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2025-09-04drm/xe/debugfs: Move sa_info from gt to tile directoryMichal Wajdeczko5-31/+151
Our drm-based suballocator is implemented per-tile so it is better to show its debug information also per-tile debugfs directory, not under per-gt directory as it is done today. To allow adding more per-tile attributes, prepare necessary helper functions, like we already did for per-gt or per-uc attributes. Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> Cc: Lucas De Marchi <lucas.demarchi@intel.com> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Link: https://lore.kernel.org/r/20250829201106.1263-1-michal.wajdeczko@intel.com
2025-09-04drm/i915: use REG_BIT on FW_BLC_SELF_* macrosLuca Coelho1-3/+3
Use REG_BIT() instead of open coding the shift in the FW_BLC_SELF_* macro definitions to avoid potentially typing them as 'int'. For example, this happens when we pass them to _MASKED_BIT_ENABLE(), because of the typeof() construct there. When we pass 1 << 15 (the FW_BLC_SELF_EN macro), we get typeof(1 << 15), which is 'int'. Then the value becomes negative (-2147450880) and we try to assign it to a 'u32'. In practice this is not a problem though, because when we try to assign -2147450880 to the u32, that becomes 0x80008000, which was the intended result. Link: https://lore.kernel.org/intel-gfx/20250827111109.401604-1-luciano.coelho@intel.com/ Reviewed-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2025-09-04drm/ast: Put AST_DRAM_ constants into enum ast_dram_layoutThomas Zimmermann2-18/+19
The AST_DRAM_ constants belong together, so put them in an enum type. Rename type and variables to 'drm_layout', as there's already another DRAM type in the ast driver (AST_DDR2, AST_DDR3). v2: - avoid compiler warning with switch default (Dan) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://lore.kernel.org/r/20250826065032.344412-7-tzimmermann@suse.de
2025-09-04drm/ast: Move DRAM info next to its only userThomas Zimmermann3-88/+44
The only place in the ast driver that uses the DRAM type is the P2A DRAM initialization for Gen2 and Gen3 of the chip. Condense the code in ast_get_dram_info() to exactly this use case and move it into the Gen's custom source file. Remove the field dram_type from struct ast_device. The AST_DRAM_ constants are also used in Gen4 POST helpers, but independently from the dram_type field. No changes there. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://lore.kernel.org/r/20250826065032.344412-6-tzimmermann@suse.de
2025-09-04drm/ast: Remove unused SCU-MPLL and SCU-STRAP valuesThomas Zimmermann1-11/+2
The ast driver used SCU-MPLL and SCU-STRAP to compute the memory clock. Remove the now unused values. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://lore.kernel.org/r/20250826065032.344412-5-tzimmermann@suse.de
2025-09-04drm/ast: Remove unused mclk fieldThomas Zimmermann2-27/+0
The memory clock is not necessary for the driver. In default for AST2600 is event incorrect; should be 800 MHz. Remove it. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://lore.kernel.org/r/20250826065032.344412-4-tzimmermann@suse.de
2025-09-04drm/ast: Remove unused dram_bus_width fieldThomas Zimmermann2-7/+0
The DRAM bus width is not necessary for the driver. Remove it. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://lore.kernel.org/r/20250826065032.344412-3-tzimmermann@suse.de
2025-09-04drm/ast: Do not print DRAM infoThomas Zimmermann1-2/+0
Most of the information in the DRAM status output is irrelevant; some is even wrong. Only the DRAM type is used on some older models. Drop the output entirely. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://lore.kernel.org/r/20250826065032.344412-2-tzimmermann@suse.de
2025-09-04drm/sysfb: Remove double assignment to pointer crtc_stateColin Ian King1-2/+1
The declaration of pointer crtc_state includes an assignment to crtc_state. The double assignment of crtc_state is redundant and can be removed. Fixes: 061963cd9e5b ("drm/sysfb: Blit to CRTC destination format") Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Link: https://lore.kernel.org/r/20250903083106.2703580-1-colin.i.king@gmail.com
2025-09-04drm/xe/vm: Fix error handling in xe_vm_query_vmas_attrs_ioctl()Himal Prasad Ghimiray1-0/+2
copy_to_user() returns the number of bytes not copied on failure, not a negative error code. Update the logic to return -EFAULT instead of the number of bytes to correctly signal the error. Fixes: 418807860e94 ("drm/xe/uapi: Add UAPI for querying VMA count and memory attributes") Cc: Matthew Brost <matthew.brost@intel.com> Cc: Dan Carpenter <dan.carpenter@linaro.org> Reviewed-by: Tejas Upadhyay <tejas.upadhyay@intel.com> Link: https://lore.kernel.org/r/20250828104933.3839825-3-himal.prasad.ghimiray@intel.com Signed-off-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>
2025-09-04drm/xe: Fix indentation in xe_zap_ptes_in_madvise_rangeHimal Prasad Ghimiray1-6/+6
Fix misleading indentation around WRITE_ONCE in pte zap loop. No functional change intended. Fixes: ada7486c5668 ("drm/xe: Implement madvise ioctl for xe") Cc: Matthew Brost <matthew.brost@intel.com> Cc: Dan Carpenter <dan.carpenter@linaro.org> Reviewed-by: Tejas Upadhyay <tejas.upadhyay@intel.com> Link: https://lore.kernel.org/r/20250828104933.3839825-2-himal.prasad.ghimiray@intel.com Signed-off-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>
2025-09-04drm/bridge: it6505: Use SHA-1 library instead of crypto_shashEric Biggers2-33/+3
Instead of using the "sha1" crypto_shash, simply call the sha1() library function. This is simpler and faster. Signed-off-by: Eric Biggers <ebiggers@kernel.org> Reviewed-by: Chen-Yu Tsai <wenst@chromium.org> Link: https://patch.msgid.link/20250821175613.14717-1-ebiggers@kernel.org Signed-off-by: Chen-Yu Tsai <wenst@chromium.org>
2025-09-04Merge tag 'drm-xe-fixes-2025-09-03' of ↵Dave Airlie1-2/+1
https://gitlab.freedesktop.org/drm/xe/kernel into drm-fixes - Fix incorrect migration of backed-up object to VRAM (Thomas) Signed-off-by: Dave Airlie <airlied@redhat.com> From: Rodrigo Vivi <rodrigo.vivi@intel.com> Link: https://lore.kernel.org/r/aLiP26TiHkYxtBXL@intel.com
2025-09-04Merge tag 'drm-misc-fixes-2025-09-03' of ↵Dave Airlie9-13/+130
https://gitlab.freedesktop.org/drm/misc/kernel into drm-fixes Two nouveau interrupt handling fixes, one race fix for ivpu, a race fix for drm_sched, and a clock fix for ti-sn65dsi86. Signed-off-by: Dave Airlie <airlied@redhat.com> From: Maxime Ripard <mripard@redhat.com> Link: https://lore.kernel.org/r/qc2rd7bskgufjtyspbjflyjpswcnhyja6s7nm2yb67j7hezyey@yfn2w6n5trff