Details
-
Bug
-
Resolution: Fixed
-
Minor
-
None
-
3
-
13020
Description
In lmv_placement_policy() lum is already in little endian. Thus the gets and sets to lum_stripe_offset should use le32_to_cpu() and cpu_to_le32(). This was found by rewriting the definition of lmv_user_md to use the __leXX typedefs rather than __uXX and running sparse.
We should also rewrite lmv_user_md using the __leXX typedefs.
/root/lustre-release/lustre/lmv/lmv_obd.c:1359:30: warning: incorrect type in assignment (different base types) /root/lustre-release/lustre/lmv/lmv_obd.c:1359:30: expected unsigned int [unsigned] [usertype] <noident> /root/lustre-release/lustre/lmv/lmv_obd.c:1359:30: got restricted __le32 [usertype] lum_stripe_offset /root/lustre-release/lustre/lmv/lmv_obd.c:1364:48: expected restricted __le32 [usertype] lum_stripe_offset /root/lustre-release/lustre/lmv/lmv_obd.c:1364:48: got unsigned int [unsigned] [usertype] op_mds