locks: protect most of the file_lock handling with i_lock