Thomas Gleixner | 7336d0e | 2019-05-31 01:09:56 -0700 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
David Teigland | b3b94fa | 2006-01-16 16:50:04 +0000 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (C) Sistina Software, Inc. 1997-2003 All rights reserved. |
Steven Whitehouse | 3a8a9a1 | 2006-05-18 15:09:15 -0400 | [diff] [blame] | 4 | * Copyright (C) 2004-2006 Red Hat, Inc. All rights reserved. |
David Teigland | b3b94fa | 2006-01-16 16:50:04 +0000 | [diff] [blame] | 5 | */ |
| 6 | |
| 7 | #ifndef __RECOVERY_DOT_H__ |
| 8 | #define __RECOVERY_DOT_H__ |
| 9 | |
Steven Whitehouse | f2f7ba5 | 2006-09-05 10:39:21 -0400 | [diff] [blame] | 10 | #include "incore.h" |
| 11 | |
Tejun Heo | 6ecd7c2 | 2010-07-20 22:09:02 +0200 | [diff] [blame] | 12 | extern struct workqueue_struct *gfs_recovery_wq; |
| 13 | |
Bob Peterson | 7c70b89 | 2019-03-25 09:34:19 -0600 | [diff] [blame] | 14 | static inline void gfs2_replay_incr_blk(struct gfs2_jdesc *jd, u32 *blk) |
David Teigland | b3b94fa | 2006-01-16 16:50:04 +0000 | [diff] [blame] | 15 | { |
Bob Peterson | e1cb6be | 2016-07-21 13:02:44 -0500 | [diff] [blame] | 16 | if (++*blk == jd->jd_blocks) |
David Teigland | b3b94fa | 2006-01-16 16:50:04 +0000 | [diff] [blame] | 17 | *blk = 0; |
| 18 | } |
| 19 | |
Steven Whitehouse | 9ac1b4d | 2008-11-19 10:08:22 +0000 | [diff] [blame] | 20 | extern int gfs2_replay_read_block(struct gfs2_jdesc *jd, unsigned int blk, |
David Teigland | b3b94fa | 2006-01-16 16:50:04 +0000 | [diff] [blame] | 21 | struct buffer_head **bh); |
| 22 | |
Bob Peterson | a17d758b | 2014-03-06 17:19:15 -0500 | [diff] [blame] | 23 | extern int gfs2_revoke_add(struct gfs2_jdesc *jd, u64 blkno, unsigned int where); |
| 24 | extern int gfs2_revoke_check(struct gfs2_jdesc *jd, u64 blkno, unsigned int where); |
| 25 | extern void gfs2_revoke_clean(struct gfs2_jdesc *jd); |
David Teigland | b3b94fa | 2006-01-16 16:50:04 +0000 | [diff] [blame] | 26 | |
Tejun Heo | 6ecd7c2 | 2010-07-20 22:09:02 +0200 | [diff] [blame] | 27 | extern int gfs2_recover_journal(struct gfs2_jdesc *gfs2_jd, bool wait); |
| 28 | extern void gfs2_recover_func(struct work_struct *work); |
Abhi Das | 40e0e61 | 2018-11-09 09:54:18 -0600 | [diff] [blame] | 29 | extern int __get_log_header(struct gfs2_sbd *sdp, |
| 30 | const struct gfs2_log_header *lh, unsigned int blkno, |
| 31 | struct gfs2_log_header_host *head); |
David Teigland | b3b94fa | 2006-01-16 16:50:04 +0000 | [diff] [blame] | 32 | |
| 33 | #endif /* __RECOVERY_DOT_H__ */ |
| 34 | |