X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=lustre%2Finclude%2Flinux%2Flustre_compat25.h;h=cd610806812bc6dc08a145a084c83bad4e9afd6b;hb=4275694704e0fb82cd6980bec082cf358df0654c;hp=d5b97fdc8ecb851f19f81e410dec82dcc7ef5397;hpb=d2d56f38da01001c92a09afc6b52b5acbd9bc13c;p=fs%2Flustre-release.git diff --git a/lustre/include/linux/lustre_compat25.h b/lustre/include/linux/lustre_compat25.h index d5b97fd..cd61080 100644 --- a/lustre/include/linux/lustre_compat25.h +++ b/lustre/include/linux/lustre_compat25.h @@ -65,7 +65,11 @@ static inline void ll_set_fs_pwd(struct fs_struct *fs, struct vfsmount *mnt, #define ll_set_fs_pwd set_fs_pwd #endif /* HAVE_SET_FS_PWD */ -#define ATTR_BLOCKS 0x4000 +/* + * set ATTR_BLOCKS to a high value to avoid any risk of collision with other + * ATTR_* attributes (see bug 13828) + */ +#define ATTR_BLOCKS (1 << 27) #if HAVE_INODE_I_MUTEX #define UNLOCK_INODE_MUTEX(inode) do {mutex_unlock(&(inode)->i_mutex); } while(0) @@ -123,8 +127,6 @@ void groups_free(struct group_info *ginfo); #define gfp_t int #endif -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0) - #define lock_dentry(___dentry) spin_lock(&(___dentry)->d_lock) #define unlock_dentry(___dentry) spin_unlock(&(___dentry)->d_lock) @@ -203,7 +205,7 @@ static inline int cleanup_group_info(void) #include -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,11) +#ifndef HAVE___D_REHASH #define __d_rehash(dentry, lock) d_rehash_cond(dentry, lock) #endif @@ -218,8 +220,6 @@ static inline int cleanup_group_info(void) #define CheckWriteback(page, cmd) \ (!(!PageWriteback(page) && cmd == OBD_BRW_WRITE)) -#endif - #ifdef HAVE_PAGE_LIST static inline int mapping_has_pages(struct address_space *mapping) {