]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/gfs2/eattr.h
Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
[linux-2.6-omap-h63xx.git] / fs / gfs2 / eattr.h
index cb7c2d846765db35a0dbae0aa0f252dbb18cbb6f..c82dbe01d7137f07d7bc1a90b59bb2ac22f5dd30 100644 (file)
@@ -19,7 +19,7 @@ struct iattr;
 #define GFS2_EA_SIZE(ea) \
 ALIGN(sizeof(struct gfs2_ea_header) + (ea)->ea_name_len + \
       ((GFS2_EA_IS_STUFFED(ea)) ? GFS2_EA_DATA_LEN(ea) : \
-                                  (sizeof(u64) * (ea)->ea_num_ptrs)), 8)
+                                  (sizeof(__be64) * (ea)->ea_num_ptrs)), 8)
 
 #define GFS2_EA_IS_STUFFED(ea) (!(ea)->ea_num_ptrs)
 #define GFS2_EA_IS_LAST(ea) ((ea)->ea_flags & GFS2_EAFLAG_LAST)
@@ -29,13 +29,13 @@ ALIGN(sizeof(struct gfs2_ea_header) + (er)->er_name_len + (er)->er_data_len, 8)
 
 #define GFS2_EAREQ_SIZE_UNSTUFFED(sdp, er) \
 ALIGN(sizeof(struct gfs2_ea_header) + (er)->er_name_len + \
-      sizeof(u64) * DIV_ROUND_UP((er)->er_data_len, (sdp)->sd_jbsize), 8)
+      sizeof(__be64) * DIV_ROUND_UP((er)->er_data_len, (sdp)->sd_jbsize), 8)
 
 #define GFS2_EA2NAME(ea) ((char *)((struct gfs2_ea_header *)(ea) + 1))
 #define GFS2_EA2DATA(ea) (GFS2_EA2NAME(ea) + (ea)->ea_name_len)
 
 #define GFS2_EA2DATAPTRS(ea) \
-((u64 *)(GFS2_EA2NAME(ea) + ALIGN((ea)->ea_name_len, 8)))
+((__be64 *)(GFS2_EA2NAME(ea) + ALIGN((ea)->ea_name_len, 8)))
 
 #define GFS2_EA2NEXT(ea) \
 ((struct gfs2_ea_header *)((char *)(ea) + GFS2_EA_REC_LEN(ea)))
@@ -46,7 +46,7 @@ ALIGN(sizeof(struct gfs2_ea_header) + (er)->er_name_len + \
 #define GFS2_ERF_MODE 0x80000000
 
 struct gfs2_ea_request {
-       char *er_name;
+       const char *er_name;
        char *er_data;
        unsigned int er_name_len;
        unsigned int er_data_len;
@@ -87,13 +87,13 @@ static inline unsigned int gfs2_ea_strlen(struct gfs2_ea_header *ea)
 {
        switch (ea->ea_type) {
        case GFS2_EATYPE_USR:
-               return (5 + (ea->ea_name_len + 1));
+               return 5 + ea->ea_name_len + 1;
        case GFS2_EATYPE_SYS:
-               return (7 + (ea->ea_name_len + 1));
+               return 7 + ea->ea_name_len + 1;
        case GFS2_EATYPE_SECURITY:
-               return (9 + (ea->ea_name_len + 1));
+               return 9 + ea->ea_name_len + 1;
        default:
-               return (0);
+               return 0;
        }
 }