⬢ DragonFlyBSD Kernel Audit
DF-4679 / fix.diff
← back to finding ↓ download raw
--- a/sys/dev/drm/i915/i915_gem_stolen.c
+++ b/sys/dev/drm/i915/i915_gem_stolen.c
@@ -472,7 +472,7 @@
 	 * stolen region and *never* at the bottom. If we see !reserved_base,
 	 * it likely means we failed to read the registers correctly.
 	 */
-	if (!reserved_base) {
+	if (!reserved_base || reserved_base > stolen_top) {
 		DRM_ERROR("inconsistent reservation %pa + %pa; ignoring\n",
 			  &reserved_base, &reserved_size);
 		reserved_base = stolen_top;