diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2009-11-23 17:39:28 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2009-12-07 19:22:41 -0500 |
commit | 6a93cb250a60af1bb7b4070949f8546a2fdc52ef (patch) | |
tree | 2c734dcc0a4c39ec5c626b17912845eae1448828 /drivers/gpu/drm/radeon/radeon_mode.h | |
parent | 1a66c95a64c9ae0bc8382254f544b24b23f498ec (diff) |
drm/radeon/kms: i2c reorg
- keep the atom i2c id in the i2c rec
- fix gpio regs for GPIO and MDGPIO on pre-avivo chips
- track whether the i2c line is hw capable
- track whether the i2c line uses the multimedia i2c block
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_mode.h')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_mode.h | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_mode.h b/drivers/gpu/drm/radeon/radeon_mode.h index 166f75395f52..1964afb94dbc 100644 --- a/drivers/gpu/drm/radeon/radeon_mode.h +++ b/drivers/gpu/drm/radeon/radeon_mode.h | |||
@@ -106,6 +106,13 @@ enum radeon_tv_std { | |||
106 | */ | 106 | */ |
107 | struct radeon_i2c_bus_rec { | 107 | struct radeon_i2c_bus_rec { |
108 | bool valid; | 108 | bool valid; |
109 | /* id used by atom */ | ||
110 | uint8_t i2c_id; | ||
111 | /* can be used with hw i2c engine */ | ||
112 | bool hw_capable; | ||
113 | /* uses multi-media i2c engine */ | ||
114 | bool mm_i2c; | ||
115 | /* regs and bits */ | ||
109 | uint32_t mask_clk_reg; | 116 | uint32_t mask_clk_reg; |
110 | uint32_t mask_data_reg; | 117 | uint32_t mask_data_reg; |
111 | uint32_t a_clk_reg; | 118 | uint32_t a_clk_reg; |
@@ -172,7 +179,6 @@ struct radeon_i2c_chan { | |||
172 | struct i2c_algo_bit_data bit; | 179 | struct i2c_algo_bit_data bit; |
173 | } algo; | 180 | } algo; |
174 | struct radeon_i2c_bus_rec rec; | 181 | struct radeon_i2c_bus_rec rec; |
175 | uint8_t i2c_id; | ||
176 | }; | 182 | }; |
177 | 183 | ||
178 | /* mostly for macs, but really any system without connector tables */ | 184 | /* mostly for macs, but really any system without connector tables */ |
@@ -333,7 +339,6 @@ struct radeon_encoder { | |||
333 | struct radeon_connector_atom_dig { | 339 | struct radeon_connector_atom_dig { |
334 | uint32_t igp_lane_info; | 340 | uint32_t igp_lane_info; |
335 | bool linkb; | 341 | bool linkb; |
336 | uint16_t uc_i2c_id; | ||
337 | struct radeon_i2c_chan *dp_i2c_bus; | 342 | struct radeon_i2c_chan *dp_i2c_bus; |
338 | u8 dpcd[8]; | 343 | u8 dpcd[8]; |
339 | }; | 344 | }; |
@@ -352,8 +357,6 @@ struct radeon_connector { | |||
352 | void *con_priv; | 357 | void *con_priv; |
353 | bool dac_load_detect; | 358 | bool dac_load_detect; |
354 | uint16_t connector_object_id; | 359 | uint16_t connector_object_id; |
355 | /* need to keep this for display port */ | ||
356 | // | ||
357 | }; | 360 | }; |
358 | 361 | ||
359 | struct radeon_framebuffer { | 362 | struct radeon_framebuffer { |
@@ -362,12 +365,13 @@ struct radeon_framebuffer { | |||
362 | }; | 365 | }; |
363 | 366 | ||
364 | extern int radeon_dp_getsinktype(struct radeon_connector *radeon_connector); | 367 | extern int radeon_dp_getsinktype(struct radeon_connector *radeon_connector); |
365 | extern void radeon_dp_getdpcd(struct radeon_connector *connector); | 368 | extern void radeon_dp_getdpcd(struct radeon_connector *radeon_connector); |
366 | extern int radeon_dp_i2c_aux_ch(struct i2c_adapter *adapter, int mode, | 369 | extern int radeon_dp_i2c_aux_ch(struct i2c_adapter *adapter, int mode, |
367 | uint8_t write_byte, uint8_t *read_byte); | 370 | uint8_t write_byte, uint8_t *read_byte); |
368 | 371 | ||
369 | extern struct radeon_i2c_chan *radeon_i2c_create_dp(struct drm_device *dev, | 372 | extern struct radeon_i2c_chan *radeon_i2c_create_dp(struct drm_device *dev, |
370 | const char *name, bool dp, u8 i2c_id); | 373 | struct radeon_i2c_bus_rec *rec, |
374 | const char *name); | ||
371 | extern struct radeon_i2c_chan *radeon_i2c_create(struct drm_device *dev, | 375 | extern struct radeon_i2c_chan *radeon_i2c_create(struct drm_device *dev, |
372 | struct radeon_i2c_bus_rec *rec, | 376 | struct radeon_i2c_bus_rec *rec, |
373 | const char *name); | 377 | const char *name); |