ceph: removed duplicated #includes
[safe/jmp/linux-2.6] / fs / xfs / xfs_dmapi.h
index 988cf44..2813cdd 100644 (file)
@@ -18,7 +18,6 @@
 #ifndef __XFS_DMAPI_H__
 #define __XFS_DMAPI_H__
 
-#include <linux/version.h>
 /*     Values used to define the on-disk version of dm_attrname_t. All
  *     on-disk attribute names start with the 8-byte string "SGI_DMI_".
  *
@@ -67,11 +66,15 @@ typedef enum {
 #define HAVE_DM_RIGHT_T
 
 /* Defines for determining if an event message should be sent. */
+#ifdef HAVE_DMAPI
 #define        DM_EVENT_ENABLED(ip, event) ( \
-       unlikely (XFS_MTOVFS((ip)->i_mount)->vfs_flag & VFS_DMI) && \
+       unlikely ((ip)->i_mount->m_flags & XFS_MOUNT_DMAPI) && \
                ( ((ip)->i_d.di_dmevmask & (1 << event)) || \
                  ((ip)->i_mount->m_dmevmask & (1 << event)) ) \
        )
+#else
+#define DM_EVENT_ENABLED(ip, event)    (0)
+#endif
 
 #define DM_XFS_VALID_FS_EVENTS         ( \
        (1 << DM_EVENT_PREUNMOUNT)      | \
@@ -162,9 +165,6 @@ typedef enum {
 
 #define FILP_DELAY_FLAG(filp) ((filp->f_flags&(O_NDELAY|O_NONBLOCK)) ? \
                        DM_FLAGS_NDELAY : 0)
-#define AT_DELAY_FLAG(f) ((f&ATTR_NONBLOCK) ? DM_FLAGS_NDELAY : 0)
-
-
-extern struct bhv_module_vfsops xfs_dmops;
+#define AT_DELAY_FLAG(f) ((f & XFS_ATTR_NONBLOCK) ? DM_FLAGS_NDELAY : 0)
 
 #endif  /* __XFS_DMAPI_H__ */