stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Patch "irda: precedence bug in irlmp_seq_hb_idx()" has been added to the 4.2-stable tree
@ 2015-11-17 22:41 gregkh
  0 siblings, 0 replies; only message in thread
From: gregkh @ 2015-11-17 22:41 UTC (permalink / raw)
  To: dan.carpenter, chengmiao.cj, davem, gregkh; +Cc: stable, stable-commits


This is a note to let you know that I've just added the patch titled

    irda: precedence bug in irlmp_seq_hb_idx()

to the 4.2-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     irda-precedence-bug-in-irlmp_seq_hb_idx.patch
and it can be found in the queue-4.2 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.


>From foo@baz Tue Nov 17 14:34:38 PST 2015
From: Dan Carpenter <dan.carpenter@oracle.com>
Date: Mon, 19 Oct 2015 13:16:49 +0300
Subject: irda: precedence bug in irlmp_seq_hb_idx()
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

From: Dan Carpenter <dan.carpenter@oracle.com>

[ Upstream commit 50010c20597d14667eff0fdb628309986f195230 ]

This is decrementing the pointer, instead of the value stored in the
pointer.  KASan detects it as an out of bounds reference.

Reported-by: "Berry Cheng 程君(成淼)" <chengmiao.cj@alibaba-inc.com>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 net/irda/irlmp.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/net/irda/irlmp.c
+++ b/net/irda/irlmp.c
@@ -1839,7 +1839,7 @@ static void *irlmp_seq_hb_idx(struct irl
 	for (element = hashbin_get_first(iter->hashbin);
 	     element != NULL;
 	     element = hashbin_get_next(iter->hashbin)) {
-		if (!off || *off-- == 0) {
+		if (!off || (*off)-- == 0) {
 			/* NB: hashbin left locked */
 			return element;
 		}


Patches currently in stable-queue which might be from dan.carpenter@oracle.com are

queue-4.2/irda-precedence-bug-in-irlmp_seq_hb_idx.patch

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-11-17 22:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-17 22:41 Patch "irda: precedence bug in irlmp_seq_hb_idx()" has been added to the 4.2-stable tree gregkh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).