The patch titled pageflags: introduce macros to generate page flag functions has been removed from the -mm tree. Its filename was pageflags-introduce-macros-to-generate-page-flag-functions.patch This patch was dropped because it was merged into mainline or a subsystem tree The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: pageflags: introduce macros to generate page flag functions From: Christoph Lameter <clameter@xxxxxxx> Introduce a set of macros that generate functions to handle page flags. A page flag function group typically starts with either SETPAGEFLAG(<part of function name>,<part of PG_ flagname>) to create a set of page flag operations that are atomic. Or __SETPAGEFLAG(<part of function name>,<part of PG_ flagname) to create a set of page flag operations that are not atomic. Then additional operations can be added using the following macros TESTSCFLAG Create additional atomic test-and-set and test-and-clear functions TESTSETFLAG Create additional test and set function TESTCLEARFLAG Create additional test and clear function SETPAGEFLAG Create additional atomic set function CLEARPAGEFLAG Create additional atomic clear function __TESTPAGEFLAG Create additional non atomic set function __SETPAGEFLAG Create additional non atomic clear function Signed-off-by: Christoph Lameter <clameter@xxxxxxx> Cc: Andy Whitcroft <apw@xxxxxxxxxxxx> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx> Cc: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx> Cc: Rik van Riel <riel@xxxxxxxxxx> Cc: Mel Gorman <mel@xxxxxxxxx> Cc: Jeremy Fitzhardinge <jeremy@xxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- include/linux/page-flags.h | 41 +++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff -puN include/linux/page-flags.h~pageflags-introduce-macros-to-generate-page-flag-functions include/linux/page-flags.h --- a/include/linux/page-flags.h~pageflags-introduce-macros-to-generate-page-flag-functions +++ a/include/linux/page-flags.h @@ -109,6 +109,47 @@ enum pageflags { #ifndef __GENERATING_BOUNDS_H /* + * Macros to create function definitions for page flags + */ +#define TESTPAGEFLAG(uname, lname) \ +static inline int Page##uname(struct page *page) \ + { return test_bit(PG_##lname, &page->flags); } + +#define SETPAGEFLAG(uname, lname) \ +static inline void SetPage##uname(struct page *page) \ + { set_bit(PG_##lname, &page->flags); } + +#define CLEARPAGEFLAG(uname, lname) \ +static inline void ClearPage##uname(struct page *page) \ + { clear_bit(PG_##lname, &page->flags); } + +#define __SETPAGEFLAG(uname, lname) \ +static inline void __SetPage##uname(struct page *page) \ + { __set_bit(PG_##lname, &page->flags); } + +#define __CLEARPAGEFLAG(uname, lname) \ +static inline void __ClearPage##uname(struct page *page) \ + { __clear_bit(PG_##lname, &page->flags); } + +#define TESTSETFLAG(uname, lname) \ +static inline int TestSetPage##uname(struct page *page) \ + { return test_and_set_bit(PG_##lname, &page->flags); } + +#define TESTCLEARFLAG(uname, lname) \ +static inline int TestClearPage##uname(struct page *page) \ + { return test_and_clear_bit(PG_##lname, &page->flags); } + + +#define PAGEFLAG(uname, lname) TESTPAGEFLAG(uname, lname) \ + SETPAGEFLAG(uname, lname) CLEARPAGEFLAG(uname, lname) + +#define __PAGEFLAG(uname, lname) TESTPAGEFLAG(uname, lname) \ + __SETPAGEFLAG(uname, lname) __CLEARPAGEFLAG(uname, lname) + +#define TESTSCFLAG(uname, lname) \ + TESTSETFLAG(uname, lname) TESTCLEARFLAG(uname, lname) + +/* * Manipulation of page state flags */ #define PageLocked(page) \ _ Patches currently in -mm which might be from clameter@xxxxxxx are origin.patch git-unionfs.patch git-pekka.patch page-allcoator-smarter-retry-of-costly-order-allocations.patch page-allocator-explicitly-retry-hugepage-allocations.patch ipc-add-definitions-of-ushort_max-and-others.patch mm-add-nr_writeback_temp-counter.patch remove-div_long_long_rem.patch slab-add-a-flag-to-prevent-debug_free-checks-on-a-kmem_cache.patch add-kbuildh-that-contains-common-definitions-for-kbuild-users.patch x86-use-kbuildh.patch mips-use-kbuildh-instead-of-macros-in-asm-offsetsc.patch alpha-use-kbuildh-instead-of-macros-in-asm-offsetsc.patch ia64-use-kbuildh-macros-instead-of-defining-macros-in-asm-offsetsc.patch arm-use-kbuildh-instead-of-macros-in-asm-offsetsc.patch xtensa-use-kbuildh-macros-instead-of-defining-them-in-asm-offsetsc.patch sparc-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch avr32-use-kbuildh-macros-instead-of-defining-macros-in-asm-offsetsc.patch blackfin-use-kbuildh-instead-of-defining-macros-in-asm-macrosc.patch frv-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch h8300-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch m68k-m68kmmu-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch mn10300-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch parisc-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch ppc-powerpc-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch s390-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch s390-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc-update.patch sh-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch v850-use-kbuildh-instead-of-defining-macros-in-asm-offsetsc.patch reiser4.patch reiser4-portion-of-zero_user-cleanup-patch.patch page-owner-tracking-leak-detector.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html