X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=include%2Flinux%2Fsched%2Fmm.h;fp=include%2Flinux%2Fsched%2Fmm.h;h=0000000000000000000000000000000000000000;hb=f5baaf48e3e82b1caf9f5cd1207d4d6feba3a2e5;hp=03feda7ab1defe0d03c9dce745df7a52f311d3c7;hpb=fb35dbfdc5a9446fbb856dae5542b23963e28b89;p=bcachefs-tools-debian diff --git a/include/linux/sched/mm.h b/include/linux/sched/mm.h deleted file mode 100644 index 03feda7..0000000 --- a/include/linux/sched/mm.h +++ /dev/null @@ -1,31 +0,0 @@ -#ifndef _LINUX_SCHED_MM_H -#define _LINUX_SCHED_MM_H - -#define PF_MEMALLOC 0x00000800 /* Allocating memory */ -#define PF_MEMALLOC_NOFS 0x00040000 /* All allocation requests will inherit GFP_NOFS */ - -static inline unsigned int memalloc_nofs_save(void) -{ - unsigned int flags = current->flags & PF_MEMALLOC_NOFS; - current->flags |= PF_MEMALLOC_NOFS; - return flags; -} - -static inline void memalloc_nofs_restore(unsigned int flags) -{ - current->flags = (current->flags & ~PF_MEMALLOC_NOFS) | flags; -} - -static inline unsigned int memalloc_noreclaim_save(void) -{ - unsigned int flags = current->flags & PF_MEMALLOC; - current->flags |= PF_MEMALLOC; - return flags; -} - -static inline void memalloc_noreclaim_restore(unsigned int flags) -{ - current->flags = (current->flags & ~PF_MEMALLOC) | flags; -} - -#endif /* _LINUX_SCHED_MM_H */