All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Waiman Long <longman@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>,
	Ingo Molnar <mingo@redhat.com>, Will Deacon <will@kernel.org>,
	Boqun Feng <boqun.feng@gmail.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] tracing: Use proper do_arch_spin_lock() API
Date: Wed, 21 Sep 2022 22:08:00 -0400	[thread overview]
Message-ID: <20220921220800.02c4c63e@gandalf.local.home> (raw)
In-Reply-To: <3789bf4d-d699-63d4-c97b-c8d9524cbc2f@redhat.com>

On Wed, 21 Sep 2022 21:48:41 -0400
Waiman Long <longman@redhat.com> wrote:

> On 9/21/22 18:17, Steven Rostedt wrote:
> >>   	savedcmd_temp = savedcmd;
> >>   	savedcmd = s;
> >> -	arch_spin_unlock(&trace_cmdline_lock);
> >> +	do_arch_spin_unlock(&trace_cmdline_lock);
> >>   	free_saved_cmdlines_buffer(savedcmd_temp);
> >>   
> >>   	return 0;
> >> @@ -6373,10 +6369,10 @@ int tracing_set_tracer(struct trace_array *tr, const char *buf)
> >>   
> >>   #ifdef CONFIG_TRACER_SNAPSHOT
> >>   	if (t->use_max_tr) {
> >> -		arch_spin_lock(&tr->max_lock);
> >> +		do_arch_spin_lock(&tr->max_lock);  
> > Add preemption disabling.
> >  
> The pattern that I have seen so far is to disable preemption for 
> trace_cmdline_lock, but interrupt for max_lock. So should we also 
> disable interrupt here instead of preemption?
> 

Ah yes.

Thanks,

-- Steve

  parent reply	other threads:[~2022-09-22  2:07 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-21 13:21 [PATCH 0/2] locking, tracing: Fix incorrect use of arch_spin_lock() Waiman Long
2022-09-21 13:21 ` [PATCH 1/2] locking: Provide a low overhead do_arch_spin_lock() API Waiman Long
2022-09-21 22:06   ` Steven Rostedt
2022-09-22  0:51     ` Waiman Long
2022-09-21 13:21 ` [PATCH 2/2] tracing: Use proper " Waiman Long
2022-09-21 22:17   ` Steven Rostedt
2022-09-22  0:50     ` Waiman Long
     [not found]     ` <3789bf4d-d699-63d4-c97b-c8d9524cbc2f@redhat.com>
2022-09-22  2:08       ` Steven Rostedt [this message]
2022-09-22  7:55     ` Peter Zijlstra
2022-09-22 12:25       ` Waiman Long
2022-09-22 12:40       ` Steven Rostedt

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=20220921220800.02c4c63e@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=boqun.feng@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=longman@redhat.com \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=will@kernel.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.