fix ota stop fc and code cleanup

Change-Id: Ic65a490a34d5bc1a15a51e1e409da45b22344f8b