stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: linux-kernel@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	stable@vger.kernel.org,
	Konstantin Khlebnikov <khlebnikov@openvz.org>,
	Luiz Capitulino <lcapitulino@redhat.com>,
	Richard Guy Briggs <rgb@redhat.com>,
	Eric Paris <eparis@redhat.com>,
	Chuck Anderson <chuck.anderson@oracle.com>,
	Dan Duval <dan.duval@oracle.com>,
	Dave Kleikamp <dave.kleikamp@oracle.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Jonghwan Choi <jhbird.choi@samsung.com>
Subject: [ 40/49] audit: fix endless wait in audit_log_start()
Date: Sun, 29 Sep 2013 12:27:14 -0700	[thread overview]
Message-ID: <20130929191605.721016878@linuxfoundation.org> (raw)
In-Reply-To: <20130929191603.008825488@linuxfoundation.org>

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

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

From: Konstantin Khlebnikov <khlebnikov@openvz.org>

commit 8ac1c8d5deba65513b6a82c35e89e73996c8e0d6 upstream.

After commit 829199197a43 ("kernel/audit.c: avoid negative sleep
durations") audit emitters will block forever if userspace daemon cannot
handle backlog.

After the timeout the waiting loop turns into busy loop and runs until
daemon dies or returns back to work.  This is a minimal patch for that
bug.

Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org>
Cc: Luiz Capitulino <lcapitulino@redhat.com>
Cc: Richard Guy Briggs <rgb@redhat.com>
Cc: Eric Paris <eparis@redhat.com>
Cc: Chuck Anderson <chuck.anderson@oracle.com>
Cc: Dan Duval <dan.duval@oracle.com>
Cc: Dave Kleikamp <dave.kleikamp@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Jonghwan Choi <jhbird.choi@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
 kernel/audit.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

--- a/kernel/audit.c
+++ b/kernel/audit.c
@@ -1117,9 +1117,10 @@ struct audit_buffer *audit_log_start(str
 
 			sleep_time = timeout_start + audit_backlog_wait_time -
 					jiffies;
-			if ((long)sleep_time > 0)
+			if ((long)sleep_time > 0) {
 				wait_for_auditd(sleep_time);
-			continue;
+				continue;
+			}
 		}
 		if (audit_rate_check() && printk_ratelimit())
 			printk(KERN_WARNING



  parent reply	other threads:[~2013-09-29 19:27 UTC|newest]

Thread overview: 53+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-29 19:26 [ 00/49] 3.10.14-stable review Greg Kroah-Hartman
2013-09-29 19:26 ` [ 01/49] PCI / ACPI / PM: Clear pme_poll for devices in D3cold on wakeup Greg Kroah-Hartman
2013-09-29 19:26 ` [ 02/49] net: usb: cdc_ether: Use wwan interface for Telit modules Greg Kroah-Hartman
2013-09-29 19:26 ` [ 03/49] cifs: fix filp leak in cifs_atomic_open() Greg Kroah-Hartman
2013-09-29 19:26 ` [ 04/49] bgmac: fix internal switch initialization Greg Kroah-Hartman
2013-09-29 19:26 ` [ 05/49] rt2800: fix wrong TX power compensation Greg Kroah-Hartman
2013-09-29 19:26 ` [ 06/49] timekeeping: Fix HRTICK related deadlock from ntp lock changes Greg Kroah-Hartman
2013-09-29 19:26 ` [ 07/49] sched/cputime: Do not scale when utime == 0 Greg Kroah-Hartman
2013-09-29 19:26 ` [ 08/49] sched/fair: Fix small race where child->se.parent,cfs_rq might point to invalid ones Greg Kroah-Hartman
2013-09-29 19:26 ` [ 09/49] HID: provide a helper for validating hid reports Greg Kroah-Hartman
2013-09-29 19:26 ` [ 10/49] HID: validate feature and input report details Greg Kroah-Hartman
2013-09-29 19:26 ` [ 11/49] HID: multitouch: validate indexes details Greg Kroah-Hartman
2013-09-29 19:26 ` [ 12/49] HID: LG: validate HID output report details Greg Kroah-Hartman
2013-09-29 19:26 ` [ 13/49] HID: zeroplus: validate " Greg Kroah-Hartman
2013-09-29 19:26 ` [ 14/49] HID: lenovo-tpkbd: fix leak if tpkbd_probe_tp fails Greg Kroah-Hartman
2013-09-29 19:26 ` [ 15/49] HID: steelseries: validate output report details Greg Kroah-Hartman
2013-09-29 19:26 ` [ 16/49] HID: lenovo-tpkbd: " Greg Kroah-Hartman
2013-09-29 19:26 ` [ 17/49] HID: logitech-dj: " Greg Kroah-Hartman
2013-09-29 19:26 ` [ 18/49] usb: gadget: fix a bug and a WARN_ON in dummy-hcd Greg Kroah-Hartman
2013-09-29 19:26 ` [ 19/49] drm/i915: fix gpu hang vs. flip stall deadlocks Greg Kroah-Hartman
2013-09-29 19:26 ` [ 20/49] drm/i915: fix wait_for_pending_flips vs gpu hang deadlock Greg Kroah-Hartman
2013-09-29 19:26 ` [ 21/49] drm: fix DRM_IOCTL_MODE_GETFB handle-leak Greg Kroah-Hartman
2013-09-29 19:26 ` [ 22/49] drm/ast: fix the ast open key function Greg Kroah-Hartman
2013-09-29 19:26 ` [ 23/49] drm/ttm: fix the tt_populated check in ttm_tt_destroy() Greg Kroah-Hartman
2013-09-29 19:26 ` [ 24/49] drm/nv50/disp: prevent false output detection on the original nv50 Greg Kroah-Hartman
2013-09-29 19:26 ` [ 25/49] drm/radeon: fix LCD record parsing Greg Kroah-Hartman
2013-09-29 19:27 ` [ 26/49] drm/radeon: fix endian bugs in hw i2c atom routines Greg Kroah-Hartman
2013-09-29 19:27 ` [ 27/49] drm/radeon/si: Add support for CP DMA to CS checker for compute v2 Greg Kroah-Hartman
2013-09-29 19:27 ` [ 28/49] drm/radeon: update line buffer allocation for dce4.1/5 Greg Kroah-Hartman
2013-09-29 19:27 ` [ 29/49] drm/radeon: update line buffer allocation for dce6 Greg Kroah-Hartman
2013-09-29 19:27 ` [ 30/49] drm/radeon: fix resume on some rs4xx boards (v2) Greg Kroah-Hartman
2013-09-29 19:27 ` [ 31/49] drm/radeon: fix handling of variable sized arrays for router objects Greg Kroah-Hartman
2013-09-29 19:27 ` [ 32/49] rt2800: change initialization sequence to fix system freeze Greg Kroah-Hartman
2013-09-29 19:27 ` [ 33/49] drm/radeon/atom: workaround vbios bug in transmitter table on rs880 (v2) Greg Kroah-Hartman
2013-09-29 19:27 ` [ 34/49] drm/radeon: fix panel scaling with eDP and LVDS bridges Greg Kroah-Hartman
2013-09-29 19:27 ` [ 35/49] drm/radeon: avoid UVD corruptions on AGP cards Greg Kroah-Hartman
2013-09-29 19:27 ` [ 36/49] media: media/usb: fix kconfig dependencies Greg Kroah-Hartman
2013-09-29 19:27 ` [ 37/49] Properly handle tristate dependencies on USB/PCI menus Greg Kroah-Hartman
2013-09-29 19:27 ` [ 38/49] udf: Standardize return values in mount sequence Greg Kroah-Hartman
2013-09-29 19:27 ` [ 39/49] udf: Refuse RW mount of the filesystem instead of making it RO Greg Kroah-Hartman
2013-09-29 19:27 ` Greg Kroah-Hartman [this message]
2013-09-29 19:27 ` [ 41/49] mm: fix aio performance regression for database caused by THP Greg Kroah-Hartman
2013-09-29 19:27 ` [ 42/49] perf tools: Handle JITed code in shared memory Greg Kroah-Hartman
2013-09-29 19:27 ` [ 43/49] bio-integrity: Fix use of bs->bio_integrity_pool after free Greg Kroah-Hartman
2013-09-29 19:27 ` [ 44/49] cfq: explicitly use 64bit divide operation for 64bit arguments Greg Kroah-Hartman
2013-09-29 19:27 ` [ 45/49] rpc: clean up decoding of gssproxy linux creds Greg Kroah-Hartman
2013-09-29 19:27 ` [ 46/49] rpc: comment on linux_cred encoding, treat all as unsigned Greg Kroah-Hartman
2013-09-29 19:27 ` [ 47/49] rpc: fix huge kmallocs in gss-proxy Greg Kroah-Hartman
2013-09-29 19:27 ` [ 48/49] rpc: let xdr layer allocate gssproxy receieve pages Greg Kroah-Hartman
2013-09-29 19:27 ` [ 49/49] netfilter: ipset: Fix serious failure in CIDR tracking Greg Kroah-Hartman
2013-09-30  1:27 ` [ 00/49] 3.10.14-stable review Guenter Roeck
2013-09-30  1:50   ` Greg Kroah-Hartman
2013-10-01 19:22 ` Shuah Khan

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=20130929191605.721016878@linuxfoundation.org \
    --to=gregkh@linuxfoundation.org \
    --cc=akpm@linux-foundation.org \
    --cc=chuck.anderson@oracle.com \
    --cc=dan.duval@oracle.com \
    --cc=dave.kleikamp@oracle.com \
    --cc=eparis@redhat.com \
    --cc=jhbird.choi@samsung.com \
    --cc=khlebnikov@openvz.org \
    --cc=lcapitulino@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rgb@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).