aboutsummaryrefslogtreecommitdiffstats
path: root/fs/gfs2/util.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs/gfs2/util.h')
-rw-r--r--fs/gfs2/util.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/fs/gfs2/util.h b/fs/gfs2/util.h
index 60b370365eea..204fdb81e34d 100644
--- a/fs/gfs2/util.h
+++ b/fs/gfs2/util.h
@@ -82,7 +82,7 @@ static inline int gfs2_meta_check_i(struct gfs2_sbd *sdp,
82 char *file, unsigned int line) 82 char *file, unsigned int line)
83{ 83{
84 struct gfs2_meta_header *mh = (struct gfs2_meta_header *)bh->b_data; 84 struct gfs2_meta_header *mh = (struct gfs2_meta_header *)bh->b_data;
85 uint32_t magic = mh->mh_magic; 85 u32 magic = mh->mh_magic;
86 magic = be32_to_cpu(magic); 86 magic = be32_to_cpu(magic);
87 if (unlikely(magic != GFS2_MAGIC)) 87 if (unlikely(magic != GFS2_MAGIC))
88 return gfs2_meta_check_ii(sdp, bh, "magic number", function, 88 return gfs2_meta_check_ii(sdp, bh, "magic number", function,
@@ -95,19 +95,19 @@ gfs2_meta_check_i((sdp), (bh), __FUNCTION__, __FILE__, __LINE__)
95 95
96 96
97int gfs2_metatype_check_ii(struct gfs2_sbd *sdp, struct buffer_head *bh, 97int gfs2_metatype_check_ii(struct gfs2_sbd *sdp, struct buffer_head *bh,
98 uint16_t type, uint16_t t, 98 u16 type, u16 t,
99 const char *function, 99 const char *function,
100 char *file, unsigned int line); 100 char *file, unsigned int line);
101 101
102static inline int gfs2_metatype_check_i(struct gfs2_sbd *sdp, 102static inline int gfs2_metatype_check_i(struct gfs2_sbd *sdp,
103 struct buffer_head *bh, 103 struct buffer_head *bh,
104 uint16_t type, 104 u16 type,
105 const char *function, 105 const char *function,
106 char *file, unsigned int line) 106 char *file, unsigned int line)
107{ 107{
108 struct gfs2_meta_header *mh = (struct gfs2_meta_header *)bh->b_data; 108 struct gfs2_meta_header *mh = (struct gfs2_meta_header *)bh->b_data;
109 uint32_t magic = mh->mh_magic; 109 u32 magic = mh->mh_magic;
110 uint16_t t = be32_to_cpu(mh->mh_type); 110 u16 t = be32_to_cpu(mh->mh_type);
111 magic = be32_to_cpu(magic); 111 magic = be32_to_cpu(magic);
112 if (unlikely(magic != GFS2_MAGIC)) 112 if (unlikely(magic != GFS2_MAGIC))
113 return gfs2_meta_check_ii(sdp, bh, "magic number", function, 113 return gfs2_meta_check_ii(sdp, bh, "magic number", function,
@@ -121,8 +121,8 @@ static inline int gfs2_metatype_check_i(struct gfs2_sbd *sdp,
121#define gfs2_metatype_check(sdp, bh, type) \ 121#define gfs2_metatype_check(sdp, bh, type) \
122gfs2_metatype_check_i((sdp), (bh), (type), __FUNCTION__, __FILE__, __LINE__) 122gfs2_metatype_check_i((sdp), (bh), (type), __FUNCTION__, __FILE__, __LINE__)
123 123
124static inline void gfs2_metatype_set(struct buffer_head *bh, uint16_t type, 124static inline void gfs2_metatype_set(struct buffer_head *bh, u16 type,
125 uint16_t format) 125 u16 format)
126{ 126{
127 struct gfs2_meta_header *mh; 127 struct gfs2_meta_header *mh;
128 mh = (struct gfs2_meta_header *)bh->b_data; 128 mh = (struct gfs2_meta_header *)bh->b_data;