mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 07:03:09 -04:00
exfat: remove useless directory scan in exfat_add_entry()
There is nothing in directory just created, so there is no need to scan. Signed-off-by: Tetsuhiro Kohada <kohada.t2@gmail.com> Acked-by: Sungjong Seo <sj1557.seo@samsung.com> Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com>
This commit is contained in:
parent
fc672306f6
commit
d1441494cd
1 changed files with 1 additions and 10 deletions
11
namei.c
11
namei.c
|
|
@ -557,19 +557,10 @@ static int exfat_add_entry(struct inode *inode, const char *path,
|
|||
info->size = 0;
|
||||
info->num_subdirs = 0;
|
||||
} else {
|
||||
int count;
|
||||
struct exfat_chain cdir;
|
||||
|
||||
info->attr = ATTR_SUBDIR;
|
||||
info->start_clu = start_clu;
|
||||
info->size = clu_size;
|
||||
|
||||
exfat_chain_set(&cdir, info->start_clu,
|
||||
EXFAT_B_TO_CLU(info->size, sbi), info->flags);
|
||||
count = exfat_count_dir_entries(sb, &cdir);
|
||||
if (count < 0)
|
||||
return -EIO;
|
||||
info->num_subdirs = count + EXFAT_MIN_SUBDIR;
|
||||
info->num_subdirs = EXFAT_MIN_SUBDIR;
|
||||
}
|
||||
memset(&info->crtime, 0, sizeof(info->crtime));
|
||||
memset(&info->mtime, 0, sizeof(info->mtime));
|
||||
|
|
|
|||
Loading…
Reference in a new issue