All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Brian Norris <briannorris@chromium.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	"Rafael J . Wysocki" <rafael@kernel.org>,
	Ingo Molnar <mingo@redhat.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] tracefs: Only clobber mode/uid/gid on remount if asked
Date: Wed, 7 Sep 2022 18:45:24 -0400	[thread overview]
Message-ID: <20220907184524.0dfb3a8a@gandalf.local.home> (raw)
In-Reply-To: <YxkS5uzouv2bn6ZB@google.com>

On Wed, 7 Sep 2022 14:53:42 -0700
Brian Norris <briannorris@chromium.org> wrote:

> Try these:
> 
>   umount /sys/kernel/debug/tracing/
>   grep tracefs /proc/mounts
>   stat /sys/kernel/debug/tracing/.
>   grep tracefs /proc/mounts
> 
> The first and the second grep will give you different results.

How about this:

  # grep tracefs /proc/mounts
tracefs /sys/kernel/tracing tracefs rw,nosuid,nodev,noexec,relatime 0 0
tracefs /sys/kernel/debug/tracing tracefs rw,nosuid,nodev,noexec,relatime 0 0

 # umount /sys/kernel/debug/tracing 
 # grep tracefs /proc/mounts
tracefs /sys/kernel/tracing tracefs rw,nosuid,nodev,noexec,relatime 0 0

 # ls /sys/kernel/debug/tracing
available_events            hwlat_detector       set_event_notrace_pid   trace_clock
available_filter_functions  instances            set_event_pid           trace_marker
available_tracers           kprobe_events        set_ftrace_filter       trace_marker_raw
buffer_percent              kprobe_profile       set_ftrace_notrace      trace_options
buffer_size_kb              max_graph_depth      set_ftrace_notrace_pid  trace_pipe
buffer_total_size_kb        options              set_ftrace_pid          trace_stat
current_tracer              osnoise              set_graph_function      tracing_cpumask
dynamic_events              per_cpu              set_graph_notrace       tracing_max_latency
dyn_ftrace_total_info       printk_formats       snapshot                tracing_on
enabled_functions           README               stack_max_size          tracing_thresh
error_log                   recursed_functions   stack_trace             uprobe_events
eval_map                    saved_cmdlines       stack_trace_filter      uprobe_profile
events                      saved_cmdlines_size  synthetic_events        user_events_data
free_buffer                 saved_tgids          timestamp_mode          user_events_status
function_profile_enabled    set_event            trace

 # grep tracefs /proc/mounts
tracefs /sys/kernel/tracing tracefs rw,nosuid,nodev,noexec,relatime 0 0
tracefs /sys/kernel/debug/tracing tracefs rw,nosuid,nodev,noexec,relatime 0 0

So it appears that accessing debugfs/tracing will automatically remount it.

Lean something new everyday! ;-)

-- Steve

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

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-27  0:44 [PATCH 1/2] debugfs: Only clobber mode/uid/gid on remount if asked Brian Norris
2022-08-27  0:44 ` [PATCH 2/2] tracefs: " Brian Norris
2022-09-07 11:44   ` Steven Rostedt
2022-09-07 20:52     ` Brian Norris
2022-09-08  1:25       ` Steven Rostedt
2022-09-07 21:46   ` Steven Rostedt
2022-09-07 21:48     ` Steven Rostedt
2022-09-07 21:53       ` Brian Norris
2022-09-07 22:45         ` Steven Rostedt [this message]
2022-09-01 15:58 ` [PATCH 1/2] debugfs: " Greg Kroah-Hartman
2022-09-01 16:11   ` Steven Rostedt
2022-09-01 22:32   ` Brian Norris
2022-09-02  5:45     ` Greg Kroah-Hartman
2022-09-09  0:16       ` Brian Norris
2022-09-09  0:43         ` Steven Rostedt
2022-09-09  0:57           ` Brian Norris
2022-09-09  1:05             ` 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=20220907184524.0dfb3a8a@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=briannorris@chromium.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=rafael@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.