add lock to filesys