[Samba] Re: [patch 1/1 with proper signed-off] fs/smbfs/*: fix sparse warnings

Domen Puncer domen at coderock.org
Sun Mar 20 11:57:56 GMT 2005


Signed-off-by: Alexey Dobriyan <adobriyan at mail.ru>
Signed-off-by: Domen Puncer <domen at coderock.org>
---


 kj-domen/include/linux/smb_fs.h |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diff -puN include/linux/smb_fs.h~sparse-include_linux_smb_fs.h include/linux/smb_fs.h
--- kj/include/linux/smb_fs.h~sparse-include_linux_smb_fs.h	2005-03-20 12:11:30.000000000 +0100
+++ kj-domen/include/linux/smb_fs.h	2005-03-20 12:11:30.000000000 +0100
@@ -43,17 +43,17 @@ static inline struct smb_inode_info *SMB
 
 /* macro names are short for word, double-word, long value (?) */
 #define WVAL(buf,pos) \
-	(le16_to_cpu(get_unaligned((u16 *)((u8 *)(buf) + (pos)))))
+	(le16_to_cpu(get_unaligned((__le16 *)((u8 *)(buf) + (pos)))))
 #define DVAL(buf,pos) \
-	(le32_to_cpu(get_unaligned((u32 *)((u8 *)(buf) + (pos)))))
+	(le32_to_cpu(get_unaligned((__le32 *)((u8 *)(buf) + (pos)))))
 #define LVAL(buf,pos) \
-	(le64_to_cpu(get_unaligned((u64 *)((u8 *)(buf) + (pos)))))
+	(le64_to_cpu(get_unaligned((__le64 *)((u8 *)(buf) + (pos)))))
 #define WSET(buf,pos,val) \
-	put_unaligned(cpu_to_le16((u16)(val)), (u16 *)((u8 *)(buf) + (pos)))
+	put_unaligned(cpu_to_le16((u16)(val)), (__le16 *)((u8 *)(buf) + (pos)))
 #define DSET(buf,pos,val) \
-	put_unaligned(cpu_to_le32((u32)(val)), (u32 *)((u8 *)(buf) + (pos)))
+	put_unaligned(cpu_to_le32((u32)(val)), (__le32 *)((u8 *)(buf) + (pos)))
 #define LSET(buf,pos,val) \
-	put_unaligned(cpu_to_le64((u64)(val)), (u64 *)((u8 *)(buf) + (pos)))
+	put_unaligned(cpu_to_le64((u64)(val)), (__le64 *)((u8 *)(buf) + (pos)))
 
 /* where to find the base of the SMB packet proper */
 #define smb_base(buf) ((u8 *)(((u8 *)(buf))+4))
_


More information about the samba mailing list