stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ben Hutchings <ben@decadent.org.uk>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: akpm@linux-foundation.org, Oleg Nesterov <oleg@redhat.com>,
	Linus Torvalds <torvalds@linux-foundation.org>
Subject: [ 37/66] wake_up_process() should be never used to wakeup a TASK_STOPPED/TRACED task
Date: Sun, 17 Feb 2013 22:50:38 +0000	[thread overview]
Message-ID: <20130217225005.942397174@decadent.org.uk> (raw)
In-Reply-To: <20130217225001.621306883@decadent.org.uk>

3.2-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Oleg Nesterov <oleg@redhat.com>

commit 9067ac85d533651b98c2ff903182a20cbb361fcb upstream.

wake_up_process() should never wakeup a TASK_STOPPED/TRACED task.
Change it to use TASK_NORMAL and add the WARN_ON().

TASK_ALL has no other users, probably can be killed.

Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
[bwh: Backported to 3.2: adjust filename]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 kernel/sched/core.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -2924,7 +2924,8 @@ out:
  */
 int wake_up_process(struct task_struct *p)
 {
-	return try_to_wake_up(p, TASK_ALL, 0);
+	WARN_ON(task_is_stopped_or_traced(p));
+	return try_to_wake_up(p, TASK_NORMAL, 0);
 }
 EXPORT_SYMBOL(wake_up_process);
 



  parent reply	other threads:[~2013-02-17 22:50 UTC|newest]

Thread overview: 70+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-17 22:50 [ 00/66] 3.2.39-stable review Ben Hutchings
2013-02-17 22:50 ` [ 01/66] drm/i915: Fix misplaced intel_mark_page_flip_active() Ben Hutchings
2013-02-17 22:50 ` [ 02/66] xhci: Fix isoc TD encoding Ben Hutchings
2013-02-17 22:50 ` [ 03/66] xhci: Fix TD size for isochronous URBs Ben Hutchings
2013-02-17 22:50 ` [ 04/66] USB: XHCI: fix memory leak of URB-private data Ben Hutchings
2013-02-17 22:50 ` [ 05/66] usb: Prevent dead ports when xhci is not enabled Ben Hutchings
2013-02-17 22:50 ` [ 06/66] sched/rt: Use root_domain of rt_rq not current processor Ben Hutchings
2013-02-17 22:50 ` [ 07/66] rtlwifi: Fix the usage of the wrong variable in usb.c Ben Hutchings
2013-02-17 22:50 ` [ 08/66] drm/radeon: add quirk for RV100 board Ben Hutchings
2013-02-17 22:50 ` [ 09/66] USB: qcserial: add Telit Gobi QDL device Ben Hutchings
2013-02-17 22:50 ` [ 10/66] USB: option: add support for Telit LE920 Ben Hutchings
2013-02-17 22:50 ` [ 11/66] mwifiex: fix incomplete scan in case of IE parsing error Ben Hutchings
2013-02-17 22:50 ` [ 12/66] USB: EHCI: fix bug in scheduling periodic split transfers Ben Hutchings
2013-02-17 22:50 ` [ 13/66] x86-64: Replace left over sti/cli in ia32 audit exit code Ben Hutchings
2013-02-17 22:50 ` [ 14/66] Bluetooth: Fix handling of unexpected SMP PDUs Ben Hutchings
2013-02-17 22:50 ` [ 15/66] drm/radeon: Calling object_unrefer() when creating fb failure Ben Hutchings
2013-02-17 22:50 ` [ 16/66] drm/radeon: prevent crash in the ring space allocation Ben Hutchings
2013-02-17 22:50 ` [ 17/66] can: c_can: Set reserved bit in IFx_MASK2 to 1 on write Ben Hutchings
2013-02-17 22:50 ` [ 18/66] USB: ftdi_sio: add PID/VID entries for ELV WS 300 PC II Ben Hutchings
2013-02-17 22:50 ` [ 19/66] USB: option: add Changhong CH690 Ben Hutchings
2013-02-17 22:50 ` [ 20/66] USB: ftdi_sio: add Zolix FTDI PID Ben Hutchings
2013-02-17 22:50 ` [ 21/66] USB: storage: Define a new macro for USB storage match rules Ben Hutchings
2013-02-17 22:50 ` [ 22/66] USB: storage: optimize to match the Huawei USB storage devices and support new switch command Ben Hutchings
2013-02-17 22:50 ` [ 23/66] nilfs2: fix fix very long mount time issue Ben Hutchings
2013-02-17 22:50 ` [ 24/66] drivers/rtc/rtc-isl1208.c: call rtc_update_irq() from the alarm irq handler Ben Hutchings
2013-02-17 22:50 ` [ 25/66] drivers/rtc/rtc-pl031.c: fix the missing operation on enable Ben Hutchings
2013-02-17 22:50 ` [ 26/66] virtio_console: Dont access uninitialized data Ben Hutchings
2013-02-17 22:50 ` [ 27/66] wireless: rt2x00: rt{2500,73}usb.c put back duplicate id Ben Hutchings
2013-02-17 22:50 ` [ 28/66] Wireless: rt2x00: Add device id for Sweex LW323 to rt2800usb.c Ben Hutchings
2013-02-17 22:50 ` [ 29/66] rt2800usb: Add support for 2001:3c1e (D-Link DWA-125 rev B1) USB Wi-Fi adapter Ben Hutchings
2013-02-17 22:50 ` [ 30/66] [media] gspca_kinect: add Kinect for Windows USB id Ben Hutchings
2013-02-17 22:50 ` [ 31/66] ahci: support the STA2X11 I/O Hub Ben Hutchings
2013-02-17 22:50 ` [ 32/66] [libata] ahci: Add support for Enmotus Bobcat device Ben Hutchings
2013-02-17 22:50 ` [ 33/66] ptrace/x86: Introduce set_task_blockstep() helper Ben Hutchings
2013-02-17 22:50 ` [ 34/66] ptrace/x86: Partly fix set_task_blockstep()->update_debugctlmsr() logic Ben Hutchings
2013-02-17 22:50 ` [ 35/66] ptrace: introduce signal_wake_up_state() and ptrace_signal_wake_up() Ben Hutchings
2013-02-17 22:50 ` [ 36/66] ptrace: ensure arch_ptrace/ptrace_request can never race with SIGKILL Ben Hutchings
2013-02-17 22:50 ` Ben Hutchings [this message]
2013-02-17 22:50 ` [ 38/66] Bluetooth: Fix sending HCI commands after reset Ben Hutchings
2013-02-17 22:50 ` [ 39/66] HID: usbhid: quirk for Formosa IR receiver Ben Hutchings
2013-02-17 22:50 ` [ 40/66] kernel/resource.c: fix stack overflow in __reserve_region_with_split() Ben Hutchings
2013-02-17 22:50 ` [ 41/66] net: prevent setting ttl=0 via IP_TTL Ben Hutchings
2013-02-17 22:50 ` [ 42/66] ipv6: fix the noflags test in addrconf_get_prefix_route Ben Hutchings
2013-02-17 22:50 ` [ 43/66] MAINTAINERS: Stephen Hemminger email change Ben Hutchings
2013-02-17 22:50 ` [ 44/66] ipv6: fix header length calculation in ip6_append_data() Ben Hutchings
2013-02-17 22:50 ` [ 45/66] isdn/gigaset: fix zero size border case in debug dump Ben Hutchings
2013-02-17 22:50 ` [ 46/66] netxen: fix off by one bug in netxen_release_tx_buffer() Ben Hutchings
2013-02-17 22:50 ` [ 47/66] r8169: remove the obsolete and incorrect AMD workaround Ben Hutchings
2013-02-17 22:50 ` [ 48/66] net: loopback: fix a dst refcounting issue Ben Hutchings
2013-02-17 22:50 ` [ 49/66] pktgen: correctly handle failures when adding a device Ben Hutchings
2013-02-17 22:50 ` [ 50/66] ipv6: do not create neighbor entries for local delivery Ben Hutchings
2013-02-17 22:50 ` [ 51/66] packet: fix leakage of tx_ring memory Ben Hutchings
2013-02-17 22:50 ` [ 52/66] atm/iphase: rename fregt_t -> ffreg_t Ben Hutchings
2013-02-17 22:50 ` [ 53/66] sctp: refactor sctp_outq_teardown to insure proper re-initalization Ben Hutchings
2013-02-17 22:50 ` [ 54/66] net: sctp: sctp_setsockopt_auth_key: use kzfree instead of kfree Ben Hutchings
2013-02-17 22:50 ` [ 55/66] net: sctp: sctp_endpoint_free: zero out secret key data Ben Hutchings
2013-02-17 22:50 ` [ 56/66] xen/netback: shutdown the ring if it contains garbage Ben Hutchings
2013-02-17 22:50 ` [ 57/66] xen/netback: dont leak pages on failure in xen_netbk_tx_check_gop Ben Hutchings
2013-02-17 22:50 ` [ 58/66] xen/netback: free already allocated memory on failure in xen_netbk_get_requests Ben Hutchings
2013-02-17 22:51 ` [ 59/66] netback: correct netbk_tx_err to handle wrap around Ben Hutchings
2013-02-17 22:51 ` [ 60/66] tcp: frto should not set snd_cwnd to 0 Ben Hutchings
2013-02-17 22:51 ` [ 61/66] tcp: fix for zero packets_in_flight was too broad Ben Hutchings
2013-02-17 22:51 ` [ 62/66] tcp: fix MSG_SENDPAGE_NOTLAST logic Ben Hutchings
2013-02-17 22:51 ` [ 63/66] bridge: Pull ip header into skb->data before looking into ip header Ben Hutchings
2013-02-17 22:51 ` [ 64/66] tg3: Avoid null pointer dereference in tg3_interrupt in netconsole mode Ben Hutchings
2013-02-17 22:51 ` [ 65/66] tg3: Fix crc errors on jumbo frame receive Ben Hutchings
2013-02-17 22:51 ` [ 66/66] x86/xen: dont assume %ds is usable in xen_iret for 32-bit PVOPS Ben Hutchings
2013-02-18  0:02 ` [ 00/66] 3.2.39-stable review Ben Hutchings
2013-02-19 22:25 ` Satoru Takeuchi
2013-02-20  2:59   ` Ben Hutchings

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130217225005.942397174@decadent.org.uk \
    --to=ben@decadent.org.uk \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=oleg@redhat.com \
    --cc=stable@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).