All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] Add validation for DMC firmware header parsing
@ 2026-09-07 10:37 Dibin Moolakadan Subrahmanian
  2026-09-07 10:37 ` [PATCH v2 1/2] drm/i915/dmc: Add sanity check for DMC load address Dibin Moolakadan Subrahmanian
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Dibin Moolakadan Subrahmanian @ 2026-09-07 10:37 UTC (permalink / raw)
  To: intel-gfx, intel-xe; +Cc: mitulkumar.ajitkumar.golani, jani.nikula

The DMC firmware parser does not validate the firmware load address
stored in version 3 headers before it is used by dmc_load_program().

The firmware size conversion from dwords to bytes can overflow while
calculating the payload size.

Fix both by validating the firmware load address against the expected
range and using check_mul_overflow() for the firmware size conversion.

v2:
Added Fixes tag in commit messages for both patches.

Dibin Moolakadan Subrahmanian (2):
  drm/i915/dmc: Add sanity check for DMC load address
  drm/i915/dmc: Prevent fw_size multiplication overflow

 drivers/gpu/drm/i915/display/intel_dmc.c      | 84 ++++++++++++++++---
 drivers/gpu/drm/i915/display/intel_dmc_regs.h | 12 +++
 2 files changed, 85 insertions(+), 11 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2026-09-07 14:35 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-07 10:37 [PATCH v2 0/2] Add validation for DMC firmware header parsing Dibin Moolakadan Subrahmanian
2026-09-07 10:37 ` [PATCH v2 1/2] drm/i915/dmc: Add sanity check for DMC load address Dibin Moolakadan Subrahmanian
2026-09-07 10:51   ` sashiko-bot
2026-09-07 10:37 ` [PATCH v2 2/2] drm/i915/dmc: Prevent fw_size multiplication overflow Dibin Moolakadan Subrahmanian
2026-09-07 10:45   ` sashiko-bot
2026-09-07 11:37 ` ✗ CI.checkpatch: warning for Add validation for DMC firmware header parsing (rev2) Patchwork
2026-09-07 11:39 ` ✓ CI.KUnit: success " Patchwork
2026-09-07 12:27 ` ✓ Xe.CI.BAT: " Patchwork
2026-09-07 12:47 ` ✓ i915.CI.BAT: success for Add validation for DMC firmware header parsing (rev3) Patchwork
2026-09-07 14:35 ` ✗ Xe.CI.FULL: failure for Add validation for DMC firmware header parsing (rev2) Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.