mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: linux-security-module@vger.kernel.org, jmorris@namei.org
Cc: dhowells@redhat.com, oleg@redhat.com, linux-kernel@vger.kernel.org
Subject: [PATCH] SELinux: Remove excessive interrupt disablement
Date: Wed, 29 Apr 2009 13:47:19 +0100	[thread overview]
Message-ID: <20090429124719.19278.51952.stgit@warthog.procyon.org.uk> (raw)

There's no need to disable interrupts with spin_lock_irqsave() inside of
read_lock_irq().

Signed-off-by: David Howells <dhowells@redhat.com>
---

 security/selinux/hooks.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)


diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c
index ba808ef..0702ba6 100644
--- a/security/selinux/hooks.c
+++ b/security/selinux/hooks.c
@@ -2378,7 +2378,6 @@ static void selinux_bprm_committed_creds(struct linux_binprm *bprm)
 	struct sighand_struct *psig;
 	u32 osid, sid;
 	int rc, i;
-	unsigned long flags;
 
 	osid = tsec->osid;
 	sid = tsec->sid;
@@ -2410,9 +2409,9 @@ static void selinux_bprm_committed_creds(struct linux_binprm *bprm)
 	 * wait permission to the new task SID. */
 	read_lock_irq(&tasklist_lock);
 	psig = current->parent->sighand;
-	spin_lock_irqsave(&psig->siglock, flags);
+	spin_lock(&psig->siglock);
 	wake_up_interruptible(&current->parent->signal->wait_chldexit);
-	spin_unlock_irqrestore(&psig->siglock, flags);
+	spin_unlock(&psig->siglock);
 	read_unlock_irq(&tasklist_lock);
 }
 


             reply	other threads:[~2009-04-29 12:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-29 12:47 David Howells [this message]
2009-04-29 13:05 ` Oleg Nesterov

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=20090429124719.19278.51952.stgit@warthog.procyon.org.uk \
    --to=dhowells@redhat.com \
    --cc=jmorris@namei.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=oleg@redhat.com \
    /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

all inboxes | Powered by JetHome®