]> git.baikalelectronics.ru Git - kernel.git/commit
gpu: host1x: mipi: Split tegra_mipi_calibrate() and tegra_mipi_wait()
authorSowjanya Komatineni <skomatineni@nvidia.com>
Wed, 15 Jul 2020 04:20:53 +0000 (21:20 -0700)
committerThierry Reding <treding@nvidia.com>
Fri, 17 Jul 2020 14:06:14 +0000 (16:06 +0200)
commit9e6571e0137d47084a7a39ade3a8caf13fc72a4d
tree7e15c2de1f2ef281f1e7bd1d72cbb3f9afe332f7
parent2796afbbbda294acf131ff6658ce69122b84f3e6
gpu: host1x: mipi: Split tegra_mipi_calibrate() and tegra_mipi_wait()

SW can trigger MIPI pads calibration any time after power on
but calibration results will be latched and applied to the pads
by MIPI CAL unit only when the link is in LP-11 state and then
status register will be updated.

For CSI, trigger of pads calibration happen during CSI stream
enable where CSI receiver is kept ready prior to sensor or CSI
transmitter stream start.

So, pads may not be in LP-11 at this time and waiting for the
calibration to be done immediate after calibration start will
result in timeout.

This patch splits tegra_mipi_calibrate() and tegra_mipi_wait()
so triggering for calibration and waiting for it to complete can
happen at different stages.

Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
drivers/gpu/drm/tegra/dsi.c
drivers/gpu/host1x/mipi.c
include/linux/host1x.h