From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andi Kleen Subject: Re: [PATCH-RT] Fix for sleeping function called from invalid context when running gdb Date: Fri, 2 Dec 2011 19:20:08 +0100 Message-ID: <20111202182008.GT24062@one.firstfloor.org> References: <1322833159-3846-1-git-send-email-jkacur@redhat.com> <1322840763.30977.39.camel@frodo> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: John Kacur , Thomas Gleixner , rt-users , lkml , Andi Kleen To: Steven Rostedt Return-path: Content-Disposition: inline In-Reply-To: <1322840763.30977.39.camel@frodo> Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-rt-users.vger.kernel.org > > -static inline void preempt_conditional_sti(struct pt_regs *regs) > > +static inline void preempt_conditional_sti(struct pt_regs *regs, int stack) > > { > > - inc_preempt_count(); > > + if (stack) > > + inc_preempt_count(); All callers now pass in true I think, so you could eliminate the stack argument. -Andi > > if (regs->flags & X86_EFLAGS_IF) > > local_irq_enable();