[PATCH] selinux: endian notations
This patch adds endian notations to the SELinux code.
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
diff --git a/security/selinux/ss/avtab.c b/security/selinux/ss/avtab.c
index 2e71af6..dde094f 100644
--- a/security/selinux/ss/avtab.c
+++ b/security/selinux/ss/avtab.c
@@ -297,8 +297,10 @@
struct avtab_datum *d, void *p),
void *p)
{
- u16 buf16[4], enabled;
- u32 buf32[7], items, items2, val;
+ __le16 buf16[4];
+ u16 enabled;
+ __le32 buf32[7];
+ u32 items, items2, val;
struct avtab_key key;
struct avtab_datum datum;
int i, rc;
@@ -403,7 +405,7 @@
int avtab_read(struct avtab *a, void *fp, u32 vers)
{
int rc;
- u32 buf[1];
+ __le32 buf[1];
u32 nel, i;