Merge tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso...
authorLinus Torvalds <torvalds@linux-foundation.org>
Thu, 14 Nov 2013 08:19:58 +0000 (17:19 +0900)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 14 Nov 2013 08:19:58 +0000 (17:19 +0900)
Pull ext4 changes from Ted Ts'o:
 "Ext4 updates for 3.13.  Mostly bug fixes and cleanups"

* tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4:
  ext4: add prototypes for macro-generated functions
  ext4: return non-zero st_blocks for inline data
  ext4: use prandom_u32() instead of get_random_bytes()
  ext4: remove unreachable code after ext4_can_extents_be_merged()
  ext4: remove unreachable code in ext4_can_extents_be_merged()
  ext4: avoid bh leak in retry path of ext4_expand_extra_isize_ea()
  ext4: don't count free clusters from a corrupt block group
  ext4: fix FITRIM in no journal mode
  ext4: drop set but otherwise unused variable from ext4_add_dirent_to_inline()
  ext4: change ext4_read_inline_dir() to return 0 on success
  ext4: pair trace_ext4_writepages & trace_ext4_writepages_result
  ext4: add ratelimiting to ext4 messages
  ext4: fix performance regression in ext4_writepages
  ext4: fixup kerndoc annotation of mpage_map_and_submit_extent()
  ext4: fix assertion in ext4_add_complete_io()

1  2 
fs/ext4/ext4.h

diff --combined fs/ext4/ext4.h
@@@ -29,6 -29,7 +29,7 @@@
  #include <linux/wait.h>
  #include <linux/blockgroup_lock.h>
  #include <linux/percpu_counter.h>
+ #include <linux/ratelimit.h>
  #include <crypto/hash.h>
  #ifdef __KERNEL__
  #include <linux/compat.h>
@@@ -1314,6 -1315,11 +1315,11 @@@ struct ext4_sb_info 
        unsigned long s_es_last_sorted;
        struct percpu_counter s_extent_cache_cnt;
        spinlock_t s_es_lru_lock ____cacheline_aligned_in_smp;
+       /* Ratelimit ext4 messages. */
+       struct ratelimit_state s_err_ratelimit_state;
+       struct ratelimit_state s_warning_ratelimit_state;
+       struct ratelimit_state s_msg_ratelimit_state;
  };
  
  static inline struct ext4_sb_info *EXT4_SB(struct super_block *sb)
@@@ -1396,7 -1402,18 +1402,18 @@@ static inline void ext4_clear_inode_##n
        clear_bit(bit + (offset), &EXT4_I(inode)->i_##field);           \
  }
  
+ /* Add these declarations here only so that these functions can be
+  * found by name.  Otherwise, they are very hard to locate. */
+ static inline int ext4_test_inode_flag(struct inode *inode, int bit);
+ static inline void ext4_set_inode_flag(struct inode *inode, int bit);
+ static inline void ext4_clear_inode_flag(struct inode *inode, int bit);
  EXT4_INODE_BIT_FNS(flag, flags, 0)
+ /* Add these declarations here only so that these functions can be
+  * found by name.  Otherwise, they are very hard to locate. */
+ static inline int ext4_test_inode_state(struct inode *inode, int bit);
+ static inline void ext4_set_inode_state(struct inode *inode, int bit);
+ static inline void ext4_clear_inode_state(struct inode *inode, int bit);
  #if (BITS_PER_LONG < 64)
  EXT4_INODE_BIT_FNS(state, state_flags, 0)
  
@@@ -2734,6 -2751,8 +2751,6 @@@ extern void ext4_double_down_write_data
                                            struct inode *second);
  extern void ext4_double_up_write_data_sem(struct inode *orig_inode,
                                          struct inode *donor_inode);
 -void ext4_inode_double_lock(struct inode *inode1, struct inode *inode2);
 -void ext4_inode_double_unlock(struct inode *inode1, struct inode *inode2);
  extern int ext4_move_extents(struct file *o_filp, struct file *d_filp,
                             __u64 start_orig, __u64 start_donor,
                             __u64 len, __u64 *moved_len);