Convert FFS_NOTFOUND to -ENOENT Signed-off-by: Valdis Kletnieks <Valdis.Kletnieks@xxxxxx> --- drivers/staging/exfat/exfat.h | 1 - drivers/staging/exfat/exfat_super.c | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/staging/exfat/exfat.h b/drivers/staging/exfat/exfat.h index 4aca4ae44a98..1d82de4e1a5c 100644 --- a/drivers/staging/exfat/exfat.h +++ b/drivers/staging/exfat/exfat.h @@ -216,7 +216,6 @@ static inline u16 get_row_index(u16 i) #define FFS_SEMAPHOREERR 6 #define FFS_INVALIDPATH 7 #define FFS_INVALIDFID 8 -#define FFS_NOTFOUND 9 #define FFS_FILEEXIST 10 #define FFS_PERMISSIONERR 11 #define FFS_NOTOPENED 12 diff --git a/drivers/staging/exfat/exfat_super.c b/drivers/staging/exfat/exfat_super.c index 273fe2310e76..50fc097ded69 100644 --- a/drivers/staging/exfat/exfat_super.c +++ b/drivers/staging/exfat/exfat_super.c @@ -572,7 +572,7 @@ static int ffsLookupFile(struct inode *inode, char *path, struct file_id_t *fid) dentry = p_fs->fs_func->find_dir_entry(sb, &dir, &uni_name, num_entries, &dos_name, TYPE_ALL); if (dentry < -1) { - ret = FFS_NOTFOUND; + ret = -ENOENT; goto out; } @@ -2695,7 +2695,7 @@ static int exfat_rmdir(struct inode *dir, struct dentry *dentry) err = -EINVAL; else if (err == FFS_FILEEXIST) err = -ENOTEMPTY; - else if (err == FFS_NOTFOUND) + else if (err == -ENOENT) err = -ENOENT; else if (err == FFS_DIRBUSY) err = -EBUSY; @@ -2752,7 +2752,7 @@ static int exfat_rename(struct inode *old_dir, struct dentry *old_dentry, err = -EINVAL; else if (err == FFS_FILEEXIST) err = -EEXIST; - else if (err == FFS_NOTFOUND) + else if (err == -ENOENT) err = -ENOENT; else if (err == -ENOSPC) err = -ENOSPC; -- 2.23.0