Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
b=23072 avoid duplicate cfs_size_round declarations
[fs/lustre-release.git]
/
lustre
/
include
/
lustre
/
lustre_user.h
diff --git
a/lustre/include/lustre/lustre_user.h
b/lustre/include/lustre/lustre_user.h
index
4ea95a9
..
14dff87
100644
(file)
--- a/
lustre/include/lustre/lustre_user.h
+++ b/
lustre/include/lustre/lustre_user.h
@@
-828,22
+828,30
@@
struct hsm_action_list {
boundaries. See hai_zero */
} __attribute__((packed));
boundaries. See hai_zero */
} __attribute__((packed));
+#ifndef HAVE_CFS_SIZE_ROUND
+static inline int cfs_size_round (int val)
+{
+ return (val + 7) & (~0x7);
+}
+#define HAVE_CFS_SIZE_ROUND
+#endif
+
/* Return pointer to first hai in action list */
/* Return pointer to first hai in action list */
-static
__inline__
struct hsm_action_item * hai_zero(struct hsm_action_list *hal)
+static
inline
struct hsm_action_item * hai_zero(struct hsm_action_list *hal)
{
return (struct hsm_action_item *)(hal->hal_fsname +
cfs_size_round(strlen(hal-> \
hal_fsname)));
}
/* Return pointer to next hai */
{
return (struct hsm_action_item *)(hal->hal_fsname +
cfs_size_round(strlen(hal-> \
hal_fsname)));
}
/* Return pointer to next hai */
-static
__inline__
struct hsm_action_item * hai_next(struct hsm_action_item *hai)
+static
inline
struct hsm_action_item * hai_next(struct hsm_action_item *hai)
{
return (struct hsm_action_item *)((char *)hai +
cfs_size_round(hai->hai_len));
}
/* Return size of an hsm_action_list */
{
return (struct hsm_action_item *)((char *)hai +
cfs_size_round(hai->hai_len));
}
/* Return size of an hsm_action_list */
-static
__inline__
int hal_size(struct hsm_action_list *hal)
+static
inline
int hal_size(struct hsm_action_list *hal)
{
int i, sz;
struct hsm_action_item *hai;
{
int i, sz;
struct hsm_action_item *hai;