All of lore.kernel.org
 help / color / mirror / Atom feed
From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: dri-devel@lists.freedesktop.org
Subject: [BUG] EDID leaks kernel memory
Date: Sat, 11 Aug 2012 17:51:19 +0100	[thread overview]
Message-ID: <20120811165118.GB18957@n2100.arm.linux.org.uk> (raw)

Hi,

While looking at the kernel DRM code, I've noticed that in many places
we kmalloc() memory to store the raw EDID information, whether it be
from a DDC adapter, or loaded from firmware.

Nowhere can I find where this memory is freed.  It seems in several
places that we assign it into connector->display_info.raw_edid, and
next time we obtain EDID information, we re-kmalloc and overwrite this
pointer.

Note that some drivers do kfree() this memory themselves after blindly
setting connector->display_info.raw_edid to NULL...

Can someone please point me to where this memory is freed?  If not, I'll
cook up a patch to add some kfree's.

Thanks.

             reply	other threads:[~2012-08-11 16:51 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-11 16:51 Russell King - ARM Linux [this message]
2012-08-13 14:24 ` [BUG] EDID leaks kernel memory Daniel Vetter
2012-08-15  9:32   ` [PATCH 0/4] remove raw_edid, and fix related memory leaks Jani Nikula
2012-08-15  9:32     ` [PATCH 1/4] drm/i915: fix EDID memory leak in SDVO Jani Nikula
2012-08-15 22:45       ` Daniel Vetter
2012-08-15  9:32     ` [PATCH 2/4] drm/ast: fix EDID memory leak Jani Nikula
2012-08-15  9:32     ` [PATCH 3/4] drm/exynos: fix EDID memory leak in HDMI Jani Nikula
2012-08-22  4:21       ` InKi Dae
2012-08-15  9:32     ` [PATCH 4/4] drm: remove the raw_edid field from struct drm_display_info Jani Nikula
2012-08-22  5:18       ` InKi Dae

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120811165118.GB18957@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.