I had the same problem and I could not solve it either.
The problem is easily seen if you disconnect and reconnect the camera to Analog Camera Adapter several times while a loopback or record pipeline is running.
Let me explain it more to recreate the problem.
1- Run the following gstreamer pipeline to display a video loopback.
gst-launch-1.0 imxv4l2videosrc ! autovideosink
2- Disconnect the camera from Analog Camera Adapter and reconnect it again several times. Most if the time you see that the image is not synced vertically. It starts scrolling or rolling downwards until it reaches the correct vertical position. Then it stops and it never happens again, until you disconnect/reconnect the input video connection.
Check these images:
I searched a lot but I could not find a good answer for this problem.
The most relevant thing I found was this link: Transient vertical sync problem at CSI input
Any idea or trick to solve it would be highly appreciated.