diff options
author | James_Chao <james_chao@asus.corp-partner.google.com> | 2019-03-05 12:12:53 +0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2019-05-07 17:22:40 -0700 |
commit | 4d7176961b5e2409a84786511076fe5147ccda71 (patch) | |
tree | 81d785b470b4e7979f30c7487697a9a55bfff207 /board/ampton | |
parent | 1c228d234fc939692bd054cf09058d2b7073d2fe (diff) | |
download | chrome-ec-4d7176961b5e2409a84786511076fe5147ccda71.tar.gz |
ampton: tune the dp mux to improve external monitor compatibility
When the ampton connected to external monitor Viewsonic VX2880,
it can't display normally. We need to tune the mux:
1. modulate DP equalization setting : 12.8dB > 3.6dB
2. modulate Vswing: 15%
BUG=b:131113883
BRANCH=octopus
TEST=Check the monitor VX2880 can display normally.
Change-Id: Id8d32b41b4fdde4799a54e0081b5ddadf3534fba
Reviewed-on: https://chromium-review.googlesource.com/1575886
Commit-Ready: Diana Z <dzigterman@chromium.org>
Tested-by: Justin TerAvest <teravest@chromium.org>
Reviewed-by: Justin TerAvest <teravest@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'board/ampton')
-rw-r--r-- | board/ampton/board.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/board/ampton/board.c b/board/ampton/board.c index d2746ca980..08cb017489 100644 --- a/board/ampton/board.c +++ b/board/ampton/board.c @@ -66,6 +66,8 @@ int ppc_get_alert_status(int port) #define USB_PD_PORT_ITE_0 0 #define USB_PD_PORT_ITE_1 1 +static int tune_mux(int port); + struct usb_mux ampton_usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { [USB_PD_PORT_ITE_0] = { /* Use PS8751 as mux only */ @@ -74,6 +76,7 @@ struct usb_mux ampton_usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { .flags = USB_MUX_FLAG_NOT_TCPC, .driver = &ps8xxx_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, + .board_init = &tune_mux, }, [USB_PD_PORT_ITE_1] = { /* Use PS8751 as mux only */ @@ -82,9 +85,22 @@ struct usb_mux ampton_usb_muxes[CONFIG_USB_PD_PORT_COUNT] = { .flags = USB_MUX_FLAG_NOT_TCPC, .driver = &ps8xxx_usb_mux_driver, .hpd_update = &ps8xxx_tcpc_update_hpd_status, + .board_init = &tune_mux, } }; +/* Some external monitors can't display content normally (eg. ViewSonic VX2880). + * We need to turn the mux for monitors to function normally. + */ +static int tune_mux(int port) +{ + /* Auto EQ disabled, compensate for channel lost up to 3.6dB */ + mux_write(port, PS8XXX_REG_MUX_DP_EQ_CONFIGURATION, 0x98); + /* DP output swing adjustment +15% */ + mux_write(port, PS8XXX_REG_MUX_DP_OUTPUT_CONFIGURATION, 0xc0); + + return EC_SUCCESS; +} /******************************************************************************/ /* ADC channels */ const struct adc_t adc_channels[] = { |