1c2c66affSColin Finck #include "ext2fs.h"
2*aaeb131bSVincent Franchomme #ifdef __REACTOS__
3c2c66affSColin Finck #include "linux/ext4.h"
4*aaeb131bSVincent Franchomme #else
5*aaeb131bSVincent Franchomme #include "linux\ext4.h"
6*aaeb131bSVincent Franchomme #endif
7c2c66affSColin Finck 
8c2c66affSColin Finck static handle_t no_journal;
9c2c66affSColin Finck 
__ext4_journal_start_sb(void * icb,struct super_block * sb,unsigned int line,int type,int blocks,int rsv_blocks)10c2c66affSColin Finck handle_t *__ext4_journal_start_sb(void *icb, struct super_block *sb, unsigned int line,
11c2c66affSColin Finck 				  int type, int blocks, int rsv_blocks)
12c2c66affSColin Finck {
13c2c66affSColin Finck 	return &no_journal;
14c2c66affSColin Finck }
15c2c66affSColin Finck 
__ext4_journal_stop(const char * where,unsigned int line,void * icb,handle_t * handle)16c2c66affSColin Finck int __ext4_journal_stop(const char *where, unsigned int line, void *icb, handle_t *handle)
17c2c66affSColin Finck {
18c2c66affSColin Finck 	return 0;
19c2c66affSColin Finck }
20c2c66affSColin Finck 
ext4_journal_abort_handle(const char * caller,unsigned int line,const char * err_fn,struct buffer_head * bh,handle_t * handle,int err)21c2c66affSColin Finck void ext4_journal_abort_handle(const char *caller, unsigned int line,
22c2c66affSColin Finck 			       const char *err_fn, struct buffer_head *bh,
23c2c66affSColin Finck 			       handle_t *handle, int err)
24c2c66affSColin Finck {
25c2c66affSColin Finck }
26c2c66affSColin Finck 
__ext4_journal_get_write_access(const char * where,unsigned int line,void * icb,handle_t * handle,struct buffer_head * bh)27c2c66affSColin Finck int __ext4_journal_get_write_access(const char *where, unsigned int line,
28c2c66affSColin Finck 				    void *icb, handle_t *handle, struct buffer_head *bh)
29c2c66affSColin Finck {
30c2c66affSColin Finck 	int err = 0;
31c2c66affSColin Finck 	return err;
32c2c66affSColin Finck }
33c2c66affSColin Finck 
34c2c66affSColin Finck /*
35c2c66affSColin Finck  * The ext4 forget function must perform a revoke if we are freeing data
36c2c66affSColin Finck  * which has been journaled.  Metadata (eg. indirect blocks) must be
37c2c66affSColin Finck  * revoked in all cases.
38c2c66affSColin Finck  *
39c2c66affSColin Finck  * "bh" may be NULL: a metadata block may have been freed from memory
40c2c66affSColin Finck  * but there may still be a record of it in the journal, and that record
41c2c66affSColin Finck  * still needs to be revoked.
42c2c66affSColin Finck  *
43c2c66affSColin Finck  * If the handle isn't valid we're not journaling, but we still need to
44c2c66affSColin Finck  * call into ext4_journal_revoke() to put the buffer head.
45c2c66affSColin Finck  */
__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)46c2c66affSColin Finck int __ext4_forget(const char *where, unsigned int line, void *icb, handle_t *handle,
47c2c66affSColin Finck 		  int is_metadata, struct inode *inode,
48c2c66affSColin Finck 		  struct buffer_head *bh, ext4_fsblk_t blocknr)
49c2c66affSColin Finck {
50c2c66affSColin Finck 	int err = 0;
51c2c66affSColin Finck 	return err;
52c2c66affSColin Finck }
53c2c66affSColin Finck 
__ext4_journal_get_create_access(const char * where,unsigned int line,void * icb,handle_t * handle,struct buffer_head * bh)54c2c66affSColin Finck int __ext4_journal_get_create_access(const char *where, unsigned int line,
55c2c66affSColin Finck 				void *icb, handle_t *handle, struct buffer_head *bh)
56c2c66affSColin Finck {
57c2c66affSColin Finck 	int err = 0;
58c2c66affSColin Finck 	return err;
59c2c66affSColin Finck }
60c2c66affSColin Finck 
__ext4_handle_dirty_metadata(const char * where,unsigned int line,void * icb,handle_t * handle,struct inode * inode,struct buffer_head * bh)61c2c66affSColin Finck int __ext4_handle_dirty_metadata(const char *where, unsigned int line,
62c2c66affSColin Finck 				 void *icb, handle_t *handle, struct inode *inode,
63c2c66affSColin Finck 				 struct buffer_head *bh)
64c2c66affSColin Finck {
65c2c66affSColin Finck 	int err = 0;
66c2c66affSColin Finck 
67c2c66affSColin Finck 	extents_mark_buffer_dirty(bh);
68c2c66affSColin Finck 	return err;
69c2c66affSColin Finck }
70c2c66affSColin Finck 
__ext4_handle_dirty_super(const char * where,unsigned int line,handle_t * handle,struct super_block * sb)71c2c66affSColin Finck int __ext4_handle_dirty_super(const char *where, unsigned int line,
72c2c66affSColin Finck 			      handle_t *handle, struct super_block *sb)
73c2c66affSColin Finck {
74c2c66affSColin Finck     return 0;
75c2c66affSColin Finck }
76