[PATCH openEuler-1.0-LTS 4/5] md: protect md_unregister_thread from reentrancy