Skip to contentSkip to conversation

fs/ntfs3: Remove unused function 'attr_must_be_resident'

PATCH New linshengwang 1 participant 1 message Jun 13, 2022 NTFS3 filesystem

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fs/ntfs3: Remove unused function 'attr_must_be_resident'

From: Lin Shengwang <[email protected]>

It is introduced by commit be71b5cba2e6 ("fs/ntfs3:
Add attrib operations"), but never used, so remove it.

---
 fs/ntfs3/attrib.c | 27 ---------------------------
 1 file changed, 27 deletions(-)
fs/ntfs3/attrib.c +0 -27
index fc0623b029e6..3df0c3f5ec72 100644
@@ -54,33 +54,6 @@ static inline u64 get_pre_allocated(u64 size)
 	return ret;
 }
 
-/*
- * attr_must_be_resident
- *
- * Return: True if attribute must be resident.
- */
-static inline bool attr_must_be_resident(struct ntfs_sb_info *sbi,
-					 enum ATTR_TYPE type)
-{
-	const struct ATTR_DEF_ENTRY *de;
-
-	switch (type) {
-	case ATTR_STD:
-	case ATTR_NAME:
-	case ATTR_ID:
-	case ATTR_LABEL:
-	case ATTR_VOL_INFO:
-	case ATTR_ROOT:
-	case ATTR_EA_INFO:
-		return true;
-	default:
-		de = ntfs_query_def(sbi, type);
-		if (de && (de->flags & NTFS_ATTR_MUST_BE_RESIDENT))
-			return true;
-		return false;
-	}
-}
-
 /*
  * attr_load_runs - Load all runs stored in @attr.
  */

--
2.17.1