Usually if the focusing of an smartphone camera doesn't work, when we disassemble and shake the camera lens, it starts working, in this video showing how to repair and how to replace back main camera of xiaomi redmi note 8 pro smart phone.
Link for camera:
https://www.maxbhi.com/replacement-ba...
Take care and do the reparation on your own risk.
Thank you for watching, have a GOODTIME.