file_path_has_perm
if (file_path_has_perm(cred, file, FILE__READ | FILE__WRITE))
return file_path_has_perm(file->f_cred, file, open_file_to_av(file));