Răsfoiți Sursa

drm/nouveau: we can't free ACPI EDID, so make a copy that we can

The rest of the connector code assumes we can kfree() the EDID pointer.
This causes things to blow up with the ACPI EDID pointer we get
passed.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Ben Skeggs 15 ani în urmă
părinte
comite
24b102d348
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      drivers/gpu/drm/nouveau/nouveau_acpi.c

+ 1 - 1
drivers/gpu/drm/nouveau/nouveau_acpi.c

@@ -292,6 +292,6 @@ nouveau_acpi_edid(struct drm_device *dev, struct drm_connector *connector)
 	if (ret < 0)
 	if (ret < 0)
 		return ret;
 		return ret;
 
 
-	nv_connector->edid = edid;
+	nv_connector->edid = kmemdup(edid, EDID_LENGTH, GFP_KERNEL);
 	return 0;
 	return 0;
 }
 }