Skip to content
Snippets Groups Projects
Commit 4e7257c8 authored by Niccolò Rosadi's avatar Niccolò Rosadi
Browse files

[PATCH] drm/bridge: seco-sn65dsi86: Add retries for link training

This is a porting of the patch: https://github.com/nxp-imx/linux-imx/commit/137655d1ed353806b8591855b569efd090d84135#diff-b3bd3abc4d5a92f5ab51f7969161a7aa63e53cfb0db8a6c1be21fca7581bbf6dR109

On some panels hooked up to the ti-sn65dsi86 bridge chip we found that
link training was failing.  Specifically, we'd see:

  ti_sn65dsi86 2-002d: [drm:ti_sn_bridge_enable] *ERROR* Link training failed, link is off (-5)

The panel was hooked up to a logic analyzer and it was found that, as
part of link training, the bridge chip was writing a 0x1 to DPCD
address 00600h and the panel responded NACK.  As can be seen in header
files, the write of 0x1 to DPCD address 0x600h means we were trying to
write the value DP_SET_POWER_D0 to the register DP_SET_POWER.  The
panel vendor says that a NACK in this case is not unexpected and means
"not ready, try again".

In testing, we found that this panel would respond with a NACK in
about 1/25 times.  Adding the retry logic worked fine and the most
number of tries needed was 3.  Just to be safe, we'll add 10 tries
here and we'll add a little blurb to the logs if we ever need more
than 5.
parent fc455f70
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment