ReactOS  0.4.14-dev-599-g2d4d3f5
ext4_jbd2.h
Go to the documentation of this file.
1 #ifndef _EXT4_JBD2_H
2 #define _EXT4_JBD2_H
3 
4 /*
5  * Wrapper functions with which ext4 calls into JBD.
6  */
7 void ext4_journal_abort_handle(const char *caller, unsigned int line,
8  const char *err_fn, struct buffer_head *bh,
9  handle_t *handle, int err);
10 
11 int __ext4_handle_dirty_super(const char *where, unsigned int line,
12  handle_t *handle, struct super_block *sb);
13 
14 int __ext4_journal_get_write_access(const char *where, unsigned int line,
15  void *icb, handle_t *handle, struct buffer_head *bh);
16 
17 int __ext4_forget(const char *where, unsigned int line, void *icb, handle_t *handle,
18  int is_metadata, struct inode *inode,
19  struct buffer_head *bh, ext4_fsblk_t blocknr);
20 
21 int __ext4_journal_get_create_access(const char *where, unsigned int line,
22  void *icb, handle_t *handle, struct buffer_head *bh);
23 
24 int __ext4_handle_dirty_metadata(const char *where, unsigned int line,
25  void *icb, handle_t *handle, struct inode *inode,
26  struct buffer_head *bh);
27 
28 #define ext4_journal_get_write_access(handle, icb, bh) \
29  __ext4_journal_get_write_access("", __LINE__, (icb), (handle), (bh))
30 #define ext4_forget(handle, icb, is_metadata, inode, bh, block_nr) \
31  __ext4_forget("", __LINE__, (icb), (handle), (is_metadata), (inode), \
32  (bh), (block_nr))
33 #define ext4_journal_get_create_access(handle, icb, bh) \
34  __ext4_journal_get_create_access("", __LINE__, (icb), (handle), (bh))
35 #define ext4_handle_dirty_metadata(handle, icb, inode, bh) \
36  __ext4_handle_dirty_metadata("", __LINE__, (icb), (handle), (inode), \
37  (bh))
38 
39 handle_t *__ext4_journal_start_sb(void *icb, struct super_block *sb, unsigned int line,
40  int type, int blocks, int rsv_blocks);
41 int __ext4_journal_stop(const char *where, unsigned int line, void *icb, handle_t *handle);
42 
43 #define ext4_journal_start_sb(icb, sb, type, nblocks) \
44  __ext4_journal_start_sb((icb), (sb), __LINE__, (type), (nblocks), 0)
45 
46 #define ext4_journal_start(icb, inode, type, nblocks) \
47  __ext4_journal_start((icb), (inode), __LINE__, (type), (nblocks), 0)
48 
49 static inline handle_t *__ext4_journal_start(void *icb, struct inode *inode,
50  unsigned int line, int type,
51  int blocks, int rsv_blocks)
52 {
54  rsv_blocks);
55 }
56 
57 #define ext4_journal_stop(icb, handle) \
58  __ext4_journal_stop("", __LINE__, (icb), (handle))
59 
60 static inline int ext4_journal_extend(void *icb, handle_t *handle, int nblocks)
61 {
62  return 0;
63 }
64 
65 #endif
superblock * sb
Definition: btrfs.c:4137
int __ext4_handle_dirty_super(const char *where, unsigned int line, handle_t *handle, struct super_block *sb)
Definition: ext4_jbd2.c:67
Definition: fs.h:64
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
int __ext4_forget(const char *where, unsigned int line, void *icb, handle_t *handle, int is_metadata, struct inode *inode, struct buffer_head *bh, ext4_fsblk_t blocknr)
Definition: ext4_jbd2.c:42
unsigned long long ext4_fsblk_t
Definition: ext3_fs_i.h:27
Definition: fs.h:78
int __ext4_journal_get_create_access(const char *where, unsigned int line, void *icb, handle_t *handle, struct buffer_head *bh)
Definition: ext4_jbd2.c:50
handle_t * __ext4_journal_start_sb(void *icb, struct super_block *sb, unsigned int line, int type, int blocks, int rsv_blocks)
Definition: ext4_jbd2.c:6
Definition: parser.c:48
static int blocks
Definition: mkdosfs.c:527
int __ext4_journal_stop(const char *where, unsigned int line, void *icb, handle_t *handle)
Definition: ext4_jbd2.c:12
static int ext4_journal_extend(void *icb, handle_t *handle, int nblocks)
Definition: ext4_jbd2.h:60
int __ext4_handle_dirty_metadata(const char *where, unsigned int line, void *icb, handle_t *handle, struct inode *inode, struct buffer_head *bh)
Definition: ext4_jbd2.c:57
static handle_t * __ext4_journal_start(void *icb, struct inode *inode, unsigned int line, int type, int blocks, int rsv_blocks)
Definition: ext4_jbd2.h:49
#define err(...)
int __ext4_journal_get_write_access(const char *where, unsigned int line, void *icb, handle_t *handle, struct buffer_head *bh)
Definition: ext4_jbd2.c:23
struct super_block * i_sb
Definition: fs.h:96
void ext4_journal_abort_handle(const char *caller, unsigned int line, const char *err_fn, struct buffer_head *bh, handle_t *handle, int err)
Definition: ext4_jbd2.c:17