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

    x86: uv: xpc NULL deref when mesq becomes empty

to the 2.6.32-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:
     x86-uv-xpc-null-deref-when-mesq-becomes-empty.patch
and it can be found in the queue-2.6.32 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.


>From 15b87d67ff3dc042bee42f991858d6b121b3b3ca Mon Sep 17 00:00:00 2001
From: Robin Holt <[email protected]>
Date: Tue, 15 Dec 2009 16:47:57 -0800
Subject: x86: uv: xpc NULL deref when mesq becomes empty

From: Robin Holt <[email protected]>

commit 15b87d67ff3dc042bee42f991858d6b121b3b3ca upstream.

Under heavy load conditions, our set of xpc messages may become exhausted.
 The code handles this correctly with the exception of the management code
which hits a NULL pointer dereference.

Signed-off-by: Robin Holt <[email protected]>
Cc: Jack Steiner <[email protected]>
Cc: Ingo Molnar <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>

---
 drivers/misc/sgi-xp/xpc_uv.c |    8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

--- a/drivers/misc/sgi-xp/xpc_uv.c
+++ b/drivers/misc/sgi-xp/xpc_uv.c
@@ -965,11 +965,13 @@ xpc_get_fifo_entry_uv(struct xpc_fifo_he
                head->first = first->next;
                if (head->first == NULL)
                        head->last = NULL;
+
+               head->n_entries--;
+               BUG_ON(head->n_entries < 0);
+
+               first->next = NULL;
        }
-       head->n_entries--;
-       BUG_ON(head->n_entries < 0);
        spin_unlock_irqrestore(&head->lock, irq_flags);
-       first->next = NULL;
        return first;
 }
 


Patches currently in stable-queue which might be from [email protected] are

queue-2.6.32/sgi-xpc-xpc-fails-to-discover-partitions-with-all-nasids-above-128.patch
queue-2.6.32/x86-uv-xpc-receive-message-reuse-triggers-invalid-bug_on.patch
queue-2.6.32/uv-xpc-pass-nasid-instead-of-nid-to-gru_create_message_queue.patch
queue-2.6.32/x86-uv-xpc_make_first_contact-hang-due-to-not-accepting-active-state.patch
queue-2.6.32/limit-sysctl_tcp_mem-and-sysctl_udp_mem-initializers-to-prevent-integer-overflows.patch
queue-2.6.32/x86-uv-xpc-null-deref-when-mesq-becomes-empty.patch
queue-2.6.32/x86-uv-update-xpc-to-handle-updated-bios-interface.patch
queue-2.6.32/x86-uv-xpc-needs-to-provide-an-abstraction-for-uv_gpa.patch

_______________________________________________
stable mailing list
[email protected]
http://linux.kernel.org/mailman/listinfo/stable

Reply via email to