[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210920163922.738362939@linuxfoundation.org>
Date: Mon, 20 Sep 2021 18:42:51 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
stable@...r.kernel.org, John Stultz <john.stultz@...aro.org>,
Dan Carpenter <dan.carpenter@...cle.com>,
Srinivas Kandagatla <srinivas.kandagatla@...aro.org>,
"David S. Miller" <davem@...emloft.net>,
Steev Klimaszewski <steev@...i.org>
Subject: [PATCH 5.14 033/168] net: qrtr: revert check in qrtr_endpoint_post()
From: Dan Carpenter <dan.carpenter@...cle.com>
commit d2cabd2dc8da78faf9b690ea521d03776686c9fe upstream.
I tried to make this check stricter as a hardenning measure but it broke
audo and wifi on these devices so revert it.
Fixes: aaa8e4922c88 ("net: qrtr: make checks in qrtr_endpoint_post() stricter")
Reported-by: John Stultz <john.stultz@...aro.org>
Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
Tested-by: Srinivas Kandagatla <srinivas.kandagatla@...aro.org>
Signed-off-by: David S. Miller <davem@...emloft.net>
Cc: Steev Klimaszewski <steev@...i.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
---
net/qrtr/qrtr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/net/qrtr/qrtr.c
+++ b/net/qrtr/qrtr.c
@@ -493,7 +493,7 @@ int qrtr_endpoint_post(struct qrtr_endpo
goto err;
}
- if (!size || size & 3 || len != size + hdrlen)
+ if (!size || len != ALIGN(size, 4) + hdrlen)
goto err;
if (cb->dst_port != QRTR_PORT_CTRL && cb->type != QRTR_TYPE_DATA &&
Powered by blists - more mailing lists