Details : Remove 2.5.0 check from dcache.c dir.c file.c llite_internal.h
llite_lib.c llite_mmap.c lproc_llite.c namei.c rw.c symlink.c
llite subsystem.
+ Remove 2.5.0 check from handler.c lproc_mds.c mds_fs.c
+ mds_internal.h mds_lib.c mds_open.c mds_reint.c mds_xattr.c
+ in mds subsystem.
--------------------------------------------------------------------------------
#include <linux/random.h>
#include <linux/fs.h>
#include <linux/jbd.h>
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))
-# include <linux/smp_lock.h>
-# include <linux/buffer_head.h>
-# include <linux/workqueue.h>
-# include <linux/mount.h>
-#else
-# include <linux/locks.h>
-#endif
+#include <linux/smp_lock.h>
+#include <linux/buffer_head.h>
+#include <linux/workqueue.h>
+#include <linux/mount.h>
#include <linux/lustre_acl.h>
#include <obd_class.h>
if (!inode->i_op || !inode->i_op->getxattr)
GOTO(out, 0);
- lock_24kernel();
rc = inode->i_op->getxattr(&de, MDS_XATTR_NAME_ACL_ACCESS,
lustre_msg_buf(repmsg, repoff, buflen),
buflen);
- unlock_24kernel();
if (rc >= 0)
repbody->aclsize = rc;
size[bufcount] = 0;
if (inode->i_op && inode->i_op->getxattr) {
- lock_24kernel();
rc = inode->i_op->getxattr(&de, MDS_XATTR_NAME_ACL_ACCESS,
NULL, 0);
- unlock_24kernel();
if (rc < 0) {
if (rc != -ENODATA) {
#define DEBUG_SUBSYSTEM S_CLASS
#include <linux/version.h>
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))
#include <asm/statfs.h>
-#endif
#include <obd.h>
#include <obd_class.h>
#include <lprocfs_status.h>
#include <linux/version.h>
#include <linux/sched.h>
#include <lustre_quota.h>
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))
#include <linux/mount.h>
-#endif
#include <lustre_mds.h>
#include <obd_class.h>
#include <obd_support.h>
#ifdef __KERNEL__
/* Open counts for files. No longer atomic, must hold inode->i_sem */
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))
# define mds_inode_oatomic(inode) ((inode)->i_cindex)
-#else
-# define mds_inode_oatomic(inode) ((inode)->i_attr_flags)
-#endif
#ifdef HAVE_I_ALLOC_SEM
#define MDS_UP_READ_ORPHAN_SEM(i) UP_READ_I_ALLOC_SEM(i)
#include <linux/stat.h>
#include <linux/errno.h>
#include <linux/version.h>
-#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
-# include <linux/locks.h> // for wait_on_buffer
-#else
-# include <linux/buffer_head.h> // for wait_on_buffer
-#endif
+#include <linux/buffer_head.h> // for wait_on_buffer
#include <linux/unistd.h>
#include <asm/system.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/version.h>
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))
-# include <linux/buffer_head.h>
-# include <linux/workqueue.h>
-#else
-# include <linux/locks.h>
-#endif
+#include <linux/buffer_head.h>
+#include <linux/workqueue.h>
#include <obd_class.h>
#include <obd_lov.h>
OBD_FAIL_WRITE(OBD_FAIL_MDS_REINT_RENAME_WRITE,
de_srcdir->d_inode->i_sb);
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
/* Check if we are moving old entry into its child. 2.6 does not
check for this in vfs_rename() anymore */
if (is_subdir(de_new, de_old))
GOTO(cleanup, rc = -EINVAL);
-#endif
lmm = lustre_msg_buf(req->rq_repmsg, offset + 1, 0);
handle = fsfilt_start_log(obd, de_tgtdir->d_inode, FSFILT_OP_RENAME,
DEBUG_REQ(D_INODE, req, "getxattr %s", xattr_name);
if (inode->i_op && inode->i_op->getxattr) {
- lock_24kernel();
rc = inode->i_op->getxattr(dentry, xattr_name,
buf, buflen);
- unlock_24kernel();
}
if (rc < 0 && rc != -ENODATA && rc != -EOPNOTSUPP &&
DEBUG_REQ(D_INODE, req, "listxattr");
if (inode->i_op && inode->i_op->listxattr) {
- lock_24kernel();
rc = inode->i_op->listxattr(dentry, buf, buflen);
- unlock_24kernel();
}
if (rc < 0)
CDEBUG(D_OTHER, "listxattr failed: %d\n", rc);
REQ_REC_OFF+2, xattrlen);
LOCK_INODE_MUTEX(inode);
- lock_24kernel();
rc = inode->i_op->setxattr(de, xattr_name, xattr,
xattrlen, body->flags);
- unlock_24kernel();
UNLOCK_INODE_MUTEX(inode);
}
} else if (body->valid & OBD_MD_FLXATTRRM) {
if (inode->i_op && inode->i_op->removexattr) {
LOCK_INODE_MUTEX(inode);
- lock_24kernel();
rc = inode->i_op->removexattr(de, xattr_name);
- unlock_24kernel();
UNLOCK_INODE_MUTEX(inode);
}
} else {