mirror of
https://git.yoctoproject.org/meta-ti
synced 2026-07-16 22:38:04 +00:00
2177f80076
Duplicate patches between PSP and 3.2.17 have been dropped from the 3.2.17 series Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
46 lines
1.4 KiB
Diff
46 lines
1.4 KiB
Diff
From 3257f4da731bb45c2117beda34ed3202df1c74e4 Mon Sep 17 00:00:00 2001
|
|
From: Al Viro <viro@zeniv.linux.org.uk>
|
|
Date: Fri, 13 Apr 2012 13:49:47 -0400
|
|
Subject: [PATCH 055/165] lockd: fix the endianness bug
|
|
|
|
commit e847469bf77a1d339274074ed068d461f0c872bc upstream.
|
|
|
|
comparing be32 values for < is not doing the right thing...
|
|
|
|
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
|
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
---
|
|
fs/lockd/clnt4xdr.c | 2 +-
|
|
fs/lockd/clntxdr.c | 2 +-
|
|
2 files changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/fs/lockd/clnt4xdr.c b/fs/lockd/clnt4xdr.c
|
|
index f848b52..046bb77 100644
|
|
--- a/fs/lockd/clnt4xdr.c
|
|
+++ b/fs/lockd/clnt4xdr.c
|
|
@@ -241,7 +241,7 @@ static int decode_nlm4_stat(struct xdr_stream *xdr, __be32 *stat)
|
|
p = xdr_inline_decode(xdr, 4);
|
|
if (unlikely(p == NULL))
|
|
goto out_overflow;
|
|
- if (unlikely(*p > nlm4_failed))
|
|
+ if (unlikely(ntohl(*p) > ntohl(nlm4_failed)))
|
|
goto out_bad_xdr;
|
|
*stat = *p;
|
|
return 0;
|
|
diff --git a/fs/lockd/clntxdr.c b/fs/lockd/clntxdr.c
|
|
index 180ac34..36057ce 100644
|
|
--- a/fs/lockd/clntxdr.c
|
|
+++ b/fs/lockd/clntxdr.c
|
|
@@ -236,7 +236,7 @@ static int decode_nlm_stat(struct xdr_stream *xdr,
|
|
p = xdr_inline_decode(xdr, 4);
|
|
if (unlikely(p == NULL))
|
|
goto out_overflow;
|
|
- if (unlikely(*p > nlm_lck_denied_grace_period))
|
|
+ if (unlikely(ntohl(*p) > ntohl(nlm_lck_denied_grace_period)))
|
|
goto out_enum;
|
|
*stat = *p;
|
|
return 0;
|
|
--
|
|
1.7.7.6
|
|
|