]> git.karo-electronics.de Git - karo-tx-linux.git/commit
drm/radeon: Don't destroy I2C Bus Rec in radeon_ext_tmds_enc_destroy().
authorEgbert Eich <eich@suse.de>
Mon, 15 Oct 2012 06:21:39 +0000 (08:21 +0200)
committerBen Hutchings <ben@decadent.org.uk>
Tue, 30 Oct 2012 23:26:46 +0000 (23:26 +0000)
commitd77d5bae994ce63c5bec55484a0f1ba75ed18081
treece54fcaf6135a98d4da2e301edf4d14e0aaf3900
parentd2538f509271a60e57524a2a9fdc5e123ec41819
drm/radeon: Don't destroy I2C Bus Rec in radeon_ext_tmds_enc_destroy().

commit 082918471139b07964967cfe5f70230909c82ae1 upstream.

radeon_i2c_fini() walks thru the list of I2C bus recs rdev->i2c_bus[]
to destroy each of them.
radeon_ext_tmds_enc_destroy() however also has code to destroy it's
associated I2C bus rec which has been obtained by radeon_i2c_lookup()
and is therefore also in the i2c_bus[] list.
This causes a double free resulting in a kernel panic when unloading
the radeon driver.
Removing destroy code from radeon_ext_tmds_enc_destroy() fixes this
problem.

agd5f: fix compiler warning

Signed-off-by: Egbert Eich <eich@suse.de>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
drivers/gpu/drm/radeon/radeon_legacy_encoders.c