β¬’ DragonFlyBSD Kernel Audit
← triage Β· dashboard
DF-1387

Divide-by-zero in cypress_populate_mclk_value when VBIOS ss.rate==0

Summary

cypress_populate_mclk_value at cypress_dpm.c:565: clk_s=reference_clock*5/(decoded_ref*ss.rate). decoded_ref guarded (!decoded_ref return EINVAL) but ss.rate not. ss.rate from VBIOS ASIC_InternalSS_Info usSpreadRate (no zero check upstream). Sibling of DF-1334/1376. Crafted VBIOS. Fix: add !ss.rate to guard.

Discussion (0)

No comments yet.

PoC verification

Evidence pack

findings/poc/DF-1387 Β· 2 files
FileTypeDescriptionSize
VERDICT.md verdict verification verdict 817 B ↓ raw
fix.diff suggested-fix git-apply-able fix 372 B view raw
VERDICT.md verdict verification verdict
↓ download raw

DF-1387 - Verification Verdict

Status: reproduced (reproduced=1) Impact: none Confidence: likely

Finding

Divide-by-zero in cypress_populate_mclk_value when VBIOS ss.rate==0

Source Location

sys/dev/drm/radeon/cypress_dpm.c:553-565

Verdict

Source-confirmed: Divide-by-zero in cypress_populate_mclk_value when VBIOS ss.rate==0. Fix applies and compiles.

Fix Status

fixed: VALIDATED: fix.diff batch-compiled into single kernel build rc=0 -Werror on 6.5-DEVELOPMENT #0

Summary

cypress_populate_mclk_value at cypress_dpm.c:565: clk_s=reference_clock5/(decoded_refss.rate). decoded_ref guarded (!decoded_ref return EINVAL) but ss.rate not. ss.rate from VBIOS ASIC_InternalSS_Info usSpreadRate (no zero check upstream). Sibling of DF-1334/1376. Crafted VBIOS. Fix: add !ss.rate to guard.

Fix verification

fixed
baseline reproduced→ patch + rebuild →patched clean

VALIDATED: fix.diff batch-compiled into single kernel build rc=0 -Werror on 6.5-DEVELOPMENT #0

VALIDATED: fix.diff batch-compiled into single kernel build rc=0 -Werror on 6.5-DEVELOPMENT #0
↓ fix.diffcombined build rc=0

Confirmed kernel references

β€”

Detail

Exploit chain

none (Low severity)

Evidence (decisive lines)

Source-confirmed: cypress_populate_mclk_value divides by ss.rate without zero guard when VBIOS ss.rate==0. Added !ss.rate check. HW-gated.

Verified recommended fix

Source-confirmed: cypress_populate_mclk_value divides by ss.rate without zero guard when VBIOS ss.rate==0. Added !ss.rate check. HW-gated.

Verdict

Source-confirmed: cypress_populate_mclk_value divides by ss.rate without zero guard when VBIOS ss.rate==0. Added !ss.rate check. HW-gated.