]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/i915/pcode: drop fast wait from snb_pcode_write_timeout()
authorJani Nikula <jani.nikula@intel.com>
Mon, 23 Jun 2025 11:43:44 +0000 (14:43 +0300)
committerJani Nikula <jani.nikula@intel.com>
Mon, 23 Jun 2025 18:45:16 +0000 (21:45 +0300)
commitab3ef56f58c21220dd131195385de212861a3f53
tree9042dcdf7197dcfb3802d4436f3df647dc4b9cd6
parentcf899c0777b8d780dd6f82317bbe561deb6c7d1c
drm/i915/pcode: drop fast wait from snb_pcode_write_timeout()

Only use the ms granularity wait in snb_pcode_write_timeout(), primarily
to better align with the xe driver, which also only has the millisecond
wait.

Use an arbitrary 250 us fast wait before the specified ms wait, and have
snb_pcode_write() default to 1 ms.

This means snb_pcode_write() and snb_pcode_write_timeout() will always
be sleeping functions. There should not be any atomic users for pcode
writes though, and any display code using pcode via xe has already been
non-atomic. The uncore wait will do a might_sleep() annotation that
should catch any problems.

Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://lore.kernel.org/r/ba86280f53cea2d020308db35f1ecbd615d07d8a.1750678991.git.jani.nikula@intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/display/intel_cdclk.c
drivers/gpu/drm/i915/display/intel_display_power_well.c
drivers/gpu/drm/i915/intel_pcode.c
drivers/gpu/drm/i915/intel_pcode.h
drivers/gpu/drm/xe/compat-i915-headers/intel_pcode.h