From: Frank Sorenson <sorenson@redhat.com>
To: systemtap@sourceware.org
Cc: sorenson@redhat.com
Subject: [PATCH] Fix vfs.open probe use of 'cred' variable
Date: Fri, 07 Feb 2020 16:16:00 -0000 [thread overview]
Message-ID: <20200207161446.676036-1-sorenson@redhat.com> (raw)
Commit f6d683666 adjusted the vfs.open probe to obtain the $cred
target variable from a field of the $file target variable on
kernels where $cred is not available. This change missed a
second reference to the $cred target variable within the probe.
Fix the reference to the possibly-unavailable target variable
by referencing the systemtap variable just obtained.
Fixes: Commit f6d683666 ("Adjust the vfs_open to provide cred variable with 4.18 kernels")
Signed-off-by: Frank Sorenson <sorenson@redhat.com>
---
tapset/linux/vfs.stp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tapset/linux/vfs.stp b/tapset/linux/vfs.stp
index 7505dfa32..d513ff970 100644
--- a/tapset/linux/vfs.stp
+++ b/tapset/linux/vfs.stp
@@ -1298,7 +1298,7 @@ probe vfs.open = kernel.function("vfs_open") ?
path = $path
cred = @defined($cred) ? $cred : $file->f_cred
pathname = fullpath_struct_path($path)
- argstr = sprintf("%s, %p", pathname, $cred)
+ argstr = sprintf("%s, %p", pathname, cred)
}
probe vfs.open.return = kernel.function("vfs_open").return ?
--
2.20.1
reply other threads:[~2020-02-07 16:16 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20200207161446.676036-1-sorenson@redhat.com \
--to=sorenson@redhat.com \
--cc=systemtap@sourceware.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).