summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c
diff options
context:
space:
mode:
authorJason Gunthorpe <jgg@nvidia.com>2022-11-29 16:42:27 -0400
committerJason Gunthorpe <jgg@nvidia.com>2022-12-02 12:04:39 -0400
commit90337f526c98129b0b180fc52dc5f57d8e7a8614 (patch)
treed7458a03027cde56b8191f656dc5cdf1531a767d /drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c
parent169dd5c987e60e62aa5785b30d22ded2ae000286 (diff)
parentb7b275e60bcd5f89771e865a8239325f86d9927d (diff)
downloadlinux-90337f526c98129b0b180fc52dc5f57d8e7a8614.tar.bz2
Merge tag 'v6.1-rc7' into iommufd.git for-next
Resolve conflicts in drivers/vfio/vfio_main.c by using the iommfd version. The rc fix was done a different way when iommufd patches reworked this code. Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c')
-rw-r--r--drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c b/drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c
index 6fd38cdd68c0..525bc8881950 100644
--- a/drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c
+++ b/drivers/gpu/drm/amd/display/dc/gpio/hw_ddc.c
@@ -94,11 +94,14 @@ static enum gpio_result set_config(
* is required for detection of AUX mode */
if (hw_gpio->base.en != GPIO_DDC_LINE_VIP_PAD) {
if (!ddc_data_pd_en || !ddc_clk_pd_en) {
-
- REG_SET_2(gpio.MASK_reg, regval,
+ if (hw_gpio->base.en == GPIO_DDC_LINE_DDC_VGA) {
+ // bit 4 of mask has different usage in some cases
+ REG_SET(gpio.MASK_reg, regval, DC_GPIO_DDC1DATA_PD_EN, 1);
+ } else {
+ REG_SET_2(gpio.MASK_reg, regval,
DC_GPIO_DDC1DATA_PD_EN, 1,
DC_GPIO_DDC1CLK_PD_EN, 1);
-
+ }
if (config_data->type ==
GPIO_CONFIG_TYPE_I2C_AUX_DUAL_MODE)
msleep(3);