summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_log_priv.h
diff options
context:
space:
mode:
authorDave Jones <davej@redhat.com>2005-11-29 12:48:34 -0800
committerDave Jones <davej@redhat.com>2005-11-29 12:48:34 -0800
commitbe37bdbce7ceaacf4f20c6cc759efbe75ebd1196 (patch)
treef1a42fb5a4a17eea41d47d2c002fa303009f5523 /fs/xfs/xfs_log_priv.h
parent019a61b99338d0ac05de25317b85da88e7ec4b35 (diff)
parentd70aa5e4b54aa7e704c886838715ac8a45d5750f (diff)
downloadtalos-obmc-linux-be37bdbce7ceaacf4f20c6cc759efbe75ebd1196.tar.gz
talos-obmc-linux-be37bdbce7ceaacf4f20c6cc759efbe75ebd1196.zip
Merge ../linus
Diffstat (limited to 'fs/xfs/xfs_log_priv.h')
-rw-r--r--fs/xfs/xfs_log_priv.h36
1 files changed, 12 insertions, 24 deletions
diff --git a/fs/xfs/xfs_log_priv.h b/fs/xfs/xfs_log_priv.h
index 8f285149681f..4518b188ade6 100644
--- a/fs/xfs/xfs_log_priv.h
+++ b/fs/xfs/xfs_log_priv.h
@@ -494,10 +494,8 @@ typedef struct log {
#define XLOG_FORCED_SHUTDOWN(log) ((log)->l_flags & XLOG_IO_ERROR)
-#define XLOG_GRANT_SUB_SPACE(log,bytes,type) \
- xlog_grant_sub_space(log,bytes,type)
-static inline void xlog_grant_sub_space(struct log *log, int bytes, int type)
-{
+#define XLOG_GRANT_SUB_SPACE(log,bytes,type) \
+ { \
if (type == 'w') { \
(log)->l_grant_write_bytes -= (bytes); \
if ((log)->l_grant_write_bytes < 0) { \
@@ -511,13 +509,9 @@ static inline void xlog_grant_sub_space(struct log *log, int bytes, int type)
(log)->l_grant_reserve_cycle--; \
} \
} \
-}
-
-#define XLOG_GRANT_ADD_SPACE(log,bytes,type) \
- xlog_grant_add_space(log,bytes,type)
-static inline void
-xlog_grant_add_space(struct log *log, int bytes, int type)
-{
+ }
+#define XLOG_GRANT_ADD_SPACE(log,bytes,type) \
+ { \
if (type == 'w') { \
(log)->l_grant_write_bytes += (bytes); \
if ((log)->l_grant_write_bytes > (log)->l_logsize) { \
@@ -531,12 +525,9 @@ xlog_grant_add_space(struct log *log, int bytes, int type)
(log)->l_grant_reserve_cycle++; \
} \
} \
-}
-
-#define XLOG_INS_TICKETQ(q, tic) xlog_ins_ticketq(q, tic)
-static inline void
-xlog_ins_ticketq(struct xlog_ticket *q, struct xlog_ticket *tic)
-{ \
+ }
+#define XLOG_INS_TICKETQ(q, tic) \
+ { \
if (q) { \
(tic)->t_next = (q); \
(tic)->t_prev = (q)->t_prev; \
@@ -547,12 +538,9 @@ xlog_ins_ticketq(struct xlog_ticket *q, struct xlog_ticket *tic)
(q) = (tic); \
} \
(tic)->t_flags |= XLOG_TIC_IN_Q; \
-}
-
-#define XLOG_DEL_TICKETQ(q, tic) xlog_del_ticketq(q, tic)
-static inline void
-xlog_del_ticketq(struct xlog_ticket *q, struct xlog_ticket *tic)
-{ \
+ }
+#define XLOG_DEL_TICKETQ(q, tic) \
+ { \
if ((tic) == (tic)->t_next) { \
(q) = NULL; \
} else { \
@@ -562,7 +550,7 @@ xlog_del_ticketq(struct xlog_ticket *q, struct xlog_ticket *tic)
} \
(tic)->t_next = (tic)->t_prev = NULL; \
(tic)->t_flags &= ~XLOG_TIC_IN_Q; \
-}
+ }
/* common routines */
extern xfs_lsn_t xlog_assign_tail_lsn(struct xfs_mount *mp);
OpenPOWER on IntegriCloud