All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Andy Lutomirski <luto@amacapital.net>
Cc: X86 ML <x86@kernel.org>, kvm list <kvm@vger.kernel.org>,
	"Luis R. Rodriguez" <mcgrof@suse.com>,
	"Luis R. Rodriguez" <mcgrof@do-not-panic.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@suse.de>,
	David Vrabel <david.vrabel@citrix.com>,
	Jan Beulich <JBeulich@suse.com>, "H. Peter Anvin" <hpa@zytor.com>,
	Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>,
	"xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>,
	Boris Ostrovsky <boris.ostrovsky@oracle.com>,
	Paul McKenney <paulmck@linux.vnet.ibm.com>,
	Thomas Gleixner <tglx@linutronix.de>
Subject: Re: [RFC v4 2/2] x86/xen: allow privcmd hypercalls to be preempted
Date: Thu, 22 Jan 2015 20:57:17 -0500	[thread overview]
Message-ID: <20150122205717.57615751__15459.8645786338$1421978316$gmane$org@grimm.local.home> (raw)
In-Reply-To: <CALCETrXKeoFKCDYcqeN=HV6MJt_CjwSPQmn_DbBxY6s-76W3Tw@mail.gmail.com>

On Thu, 22 Jan 2015 17:40:27 -0800
Andy Lutomirski <luto@amacapital.net> wrote:

> >
> > +/*
> > + * CONFIG_PREEMPT=n kernels can end up triggering the softlock
> > + * TASK_UNINTERRUPTIBLE hanger check (default 120 seconds)
> > + * when certain multicalls are used [0] on large systems, in
> > + * that case we need a way to voluntarily preempt. This is
> > + * only an issue on CONFIG_PREEMPT=n kernels.
> > + *
> > + * [0] https://bugzilla.novell.com/show_bug.cgi?id=861093
> > + */
> > +void xen_end_upcall(struct pt_regs *regs)
> > +{
> > +       if (xen_is_preemptible_hypercall(regs)) {
> > +               int cpuid = smp_processor_id();
> > +               if (_cond_resched())
> > +                       trace_xen_hypercall_preemption(cpuid);
> 
> If you want to speed this up a bit, I think you could move the
> smp_processor_id() into the TP_fast_assign.  But don't tracepoints
> report the cpu number even without any action?

Yes, but if you scheduled here, the tracepoint could happen on a
different CPU. Thus, cpuid will not equal smp_processor_id().

-- Steve

  reply	other threads:[~2015-01-23  1:56 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-23  0:29 [RFC v4 0/2] x86/xen: add xen hypercall preemption Luis R. Rodriguez
2015-01-23  0:29 ` [RFC v4 1/2] x86/xen: add xen_is_preemptible_hypercall() Luis R. Rodriguez
2015-01-23  1:40   ` Andy Lutomirski
2015-01-27  1:45     ` Luis R. Rodriguez
2015-01-27  1:45     ` Luis R. Rodriguez
2015-01-23  1:40   ` Andy Lutomirski
2015-01-23 11:30   ` [Xen-devel] " David Vrabel
2015-01-23 18:57     ` Luis R. Rodriguez
2015-01-23 18:57     ` [Xen-devel] " Luis R. Rodriguez
2015-01-23 11:30   ` David Vrabel
2015-01-23  0:29 ` Luis R. Rodriguez
2015-01-23  0:29 ` [RFC v4 2/2] x86/xen: allow privcmd hypercalls to be preempted Luis R. Rodriguez
2015-01-23  1:40   ` Andy Lutomirski
2015-01-23  1:40   ` Andy Lutomirski
2015-01-23  1:57     ` Steven Rostedt [this message]
2015-01-23  1:57     ` Steven Rostedt
2015-01-23 11:45   ` [Xen-devel] " David Vrabel
2015-01-23 18:58     ` Luis R. Rodriguez
2015-01-23 18:58     ` [Xen-devel] " Luis R. Rodriguez
2015-01-26 10:46       ` Jan Beulich
2015-01-26 10:46       ` Jan Beulich
2015-01-26 10:47       ` David Vrabel
2015-01-26 10:47       ` [Xen-devel] " David Vrabel
2015-01-23 19:16     ` Luis R. Rodriguez
2015-01-23 19:16     ` Luis R. Rodriguez
2015-01-23 11:45   ` David Vrabel
2015-01-23  0:29 ` Luis R. Rodriguez
2015-01-23 11:51 ` [Xen-devel] [RFC v4 0/2] x86/xen: add xen hypercall preemption David Vrabel
2015-01-23 18:58   ` Luis R. Rodriguez
2015-01-23 18:58   ` Luis R. Rodriguez
2015-01-23 11:51 ` David Vrabel

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='20150122205717.57615751__15459.8645786338$1421978316$gmane$org@grimm.local.home' \
    --to=rostedt@goodmis.org \
    --cc=JBeulich@suse.com \
    --cc=boris.ostrovsky@oracle.com \
    --cc=bp@suse.de \
    --cc=david.vrabel@citrix.com \
    --cc=hpa@zytor.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@amacapital.net \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=mcgrof@do-not-panic.com \
    --cc=mcgrof@suse.com \
    --cc=mingo@redhat.com \
    --cc=paulmck@linux.vnet.ibm.com \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    --cc=xen-devel@lists.xenproject.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.