aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon
diff options
context:
space:
mode:
authorAlex Deucher <alexander.deucher@amd.com>2012-04-10 12:14:27 -0400
committerLuis Henriques <luis.henriques@canonical.com>2012-05-01 06:00:01 -0400
commit257a4c13192e6d9c0a1492366cef065b3e02413a (patch)
tree90fd799294570c1f8767ef25ec1ebfcb3aa77878 /drivers/gpu/drm/radeon
parent4523aa6f2a3d91c026b0714f5ac4314423370f25 (diff)
drm/radeon: only add the mm i2c bus if the hw_i2c module param is set
BugLink: http://bugs.launchpad.net/bugs/987283 commit 46783150a6552f9513f08e62cfcc07125d6e502b upstream. It seems it can corrupt the monitor EDID in certain cases on certain boards when running sensors detect. It's rarely used anyway outside of AIW boards. http://lists.lm-sensors.org/pipermail/lm-sensors/2012-April/035847.html http://lists.freedesktop.org/archives/xorg/2011-January/052239.html Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Diffstat (limited to 'drivers/gpu/drm/radeon')
-rw-r--r--drivers/gpu/drm/radeon/radeon_i2c.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_i2c.c b/drivers/gpu/drm/radeon/radeon_i2c.c
index 6c111c1fa3f..c90425c439d 100644
--- a/drivers/gpu/drm/radeon/radeon_i2c.c
+++ b/drivers/gpu/drm/radeon/radeon_i2c.c
@@ -898,6 +898,10 @@ struct radeon_i2c_chan *radeon_i2c_create(struct drm_device *dev,
898 struct radeon_i2c_chan *i2c; 898 struct radeon_i2c_chan *i2c;
899 int ret; 899 int ret;
900 900
901 /* don't add the mm_i2c bus unless hw_i2c is enabled */
902 if (rec->mm_i2c && (radeon_hw_i2c == 0))
903 return NULL;
904
901 i2c = kzalloc(sizeof(struct radeon_i2c_chan), GFP_KERNEL); 905 i2c = kzalloc(sizeof(struct radeon_i2c_chan), GFP_KERNEL);
902 if (i2c == NULL) 906 if (i2c == NULL)
903 return NULL; 907 return NULL;