summaryrefslogtreecommitdiff
path: root/include/linux/shm.h
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2024-04-09 10:41:33 +0200
committerChristian Brauner <brauner@kernel.org>2024-04-09 10:53:44 +0200
commit886b94d25a8eba4c42634dddc3cbfd6391a24d25 (patch)
treea40576d9af9ec4675b25920683f2cb2f80c521ac /include/linux/shm.h
parent629171657a2864d819a3bbecabe0a5e001d05c7a (diff)
downloadlinux-886b94d25a8eba4c42634dddc3cbfd6391a24d25.tar.gz
linux-886b94d25a8eba4c42634dddc3cbfd6391a24d25.tar.bz2
linux-886b94d25a8eba4c42634dddc3cbfd6391a24d25.zip
fs: Add FOP_HUGE_PAGES
Instead of checking for specific file_operations, add a bit to file_operations which denotes a file that only contain hugetlb pages. This lets us make hugetlbfs_file_operations static, and removes is_file_shm_hugepages() completely. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Link: https://lore.kernel.org/r/20240407201122.3783877-1-willy@infradead.org Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'include/linux/shm.h')
-rw-r--r--include/linux/shm.h5
1 files changed, 0 insertions, 5 deletions
diff --git a/include/linux/shm.h b/include/linux/shm.h
index c55bef0538e5..1d3d3ae958fb 100644
--- a/include/linux/shm.h
+++ b/include/linux/shm.h
@@ -16,7 +16,6 @@ struct sysv_shm {
long do_shmat(int shmid, char __user *shmaddr, int shmflg, unsigned long *addr,
unsigned long shmlba);
-bool is_file_shm_hugepages(struct file *file);
void exit_shm(struct task_struct *task);
#define shm_init_task(task) INIT_LIST_HEAD(&(task)->sysvshm.shm_clist)
#else
@@ -30,10 +29,6 @@ static inline long do_shmat(int shmid, char __user *shmaddr,
{
return -ENOSYS;
}
-static inline bool is_file_shm_hugepages(struct file *file)
-{
- return false;
-}
static inline void exit_shm(struct task_struct *task)
{
}