Whamcloud - gitweb
LU-709 build: clean up LC_FUNC_GRAB_CACHE_PAGE_NOWAIT_GFP
[fs/lustre-release.git] / lustre / include / linux / lustre_compat25.h
index 470b2b7..d2939b5 100644 (file)
@@ -28,9 +28,8 @@
 /*
  * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
  * Use is subject to license terms.
- */
-/*
- * Copyright (c) 2011 Whamcloud, Inc.
+ *
+ * Copyright (c) 2011, 2012, Whamcloud, Inc.
  */
 /*
  * This file is part of Lustre, http://www.lustre.org/
@@ -168,10 +167,6 @@ do {cfs_mutex_lock_nested(&(inode)->i_mutex, I_MUTEX_PARENT); } while(0)
 #define set_page_private(page, v) ((page)->private = (v))
 #endif
 
-#ifndef HAVE_GFP_T
-#define gfp_t int
-#endif
-
 #define lock_dentry(___dentry)          cfs_spin_lock(&(___dentry)->d_lock)
 #define unlock_dentry(___dentry)        cfs_spin_unlock(&(___dentry)->d_lock)
 
@@ -351,10 +346,6 @@ static inline int mapping_has_pages(struct address_space *mapping)
 #define DOWN_READ_I_ALLOC_SEM(i)  down_read(&(i)->i_alloc_sem)
 #define LASSERT_I_ALLOC_SEM_READ_LOCKED(i) LASSERT(down_write_trylock(&(i)->i_alloc_sem) == 0)
 
-#ifndef HAVE_GRAB_CACHE_PAGE_NOWAIT_GFP
-#define grab_cache_page_nowait_gfp(x, y, z) grab_cache_page_nowait((x), (y))
-#endif
-
 #include <linux/mpage.h>        /* for generic_writepages */
 #ifndef HAVE_FILEMAP_FDATAWRITE_RANGE
 #include <linux/backing-dev.h>  /* for mapping->backing_dev_info */
@@ -930,5 +921,11 @@ static inline int ll_quota_off(struct super_block *sb, int off, int remount)
 # define ext2_find_next_zero_bit  find_next_zero_bit_le
 #endif
 
+#ifdef ATTR_TIMES_SET
+# define TIMES_SET_FLAGS (ATTR_MTIME_SET | ATTR_ATIME_SET | ATTR_TIMES_SET)
+#else
+# define TIMES_SET_FLAGS (ATTR_MTIME_SET | ATTR_ATIME_SET)
+#endif
+
 #endif /* __KERNEL__ */
 #endif /* _COMPAT25_H */