From: Al Viro <viro@zeniv.linux.org.uk>
To: Amir Goldstein <amir73il@gmail.com>
Cc: Christian Brauner <brauner@kernel.org>,
Miklos Szeredi <miklos@szeredi.hu>,
Paul Moore <paul@paul-moore.com>,
James Morris <jmorris@namei.org>,
"Serge E . Hallyn" <serge@hallyn.com>,
Mimi Zohar <zohar@linux.ibm.com>,
linux-security-module@vger.kernel.org,
linux-integrity@vger.kernel.org, linux-unionfs@vger.kernel.org,
linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH v2 2/3] fs: create helper file_user_path() for user displayed mapped file path
Date: Mon, 9 Oct 2023 08:00:48 +0100 [thread overview]
Message-ID: <20231009070048.GG800259@ZenIV> (raw)
In-Reply-To: <20231007084433.1417887-3-amir73il@gmail.com>
On Sat, Oct 07, 2023 at 11:44:32AM +0300, Amir Goldstein wrote:
> @@ -93,7 +93,8 @@ static void show_faulting_vma(unsigned long address)
> char *nm = "?";
>
> if (vma->vm_file) {
> - nm = file_path(vma->vm_file, buf, ARC_PATH_MAX-1);
> + nm = d_path(file_user_path(vma->vm_file), buf,
> + ARC_PATH_MAX-1);
> if (IS_ERR(nm))
> nm = "?";
Umm... At one point I considered this:
if (vma->vm_file)
pr_info(" @off 0x%lx in [%pD] VMA: 0x%08lx to 0x%08lx\n",
vma->vm_start < TASK_UNMAPPED_BASE ?
address : address - vma->vm_start,
vma->vm_file, vma->vm_start, vma->vm_end);
else
pr_info(" @off 0x%lx in [anon] VMA: 0x%08lx to 0x%08lx\n",
vma->vm_start < TASK_UNMAPPED_BASE ?
address : address - vma->vm_start,
vma->vm_start, vma->vm_end);
and to hell with that 'buf' thing...
next prev parent reply other threads:[~2023-10-09 7:01 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-07 8:44 [PATCH v2 0/3] Reduce impact of overlayfs backing files fake path Amir Goldstein
2023-10-07 8:44 ` [PATCH v2 1/3] fs: get mnt_writers count for an open backing file's real path Amir Goldstein
2023-10-09 6:43 ` Al Viro
2023-10-09 8:03 ` Amir Goldstein
2023-10-07 8:44 ` [PATCH v2 2/3] fs: create helper file_user_path() for user displayed mapped file path Amir Goldstein
2023-10-09 7:00 ` Al Viro [this message]
2023-10-09 7:51 ` Amir Goldstein
2023-10-07 8:44 ` [PATCH v2 3/3] fs: store real path instead of fake path in backing file f_path Amir Goldstein
2023-10-09 7:48 ` Al Viro
2023-10-09 8:25 ` Amir Goldstein
2023-10-09 18:53 ` Al Viro
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=20231009070048.GG800259@ZenIV \
--to=viro@zeniv.linux.org.uk \
--cc=amir73il@gmail.com \
--cc=brauner@kernel.org \
--cc=jmorris@namei.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-integrity@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=linux-unionfs@vger.kernel.org \
--cc=miklos@szeredi.hu \
--cc=paul@paul-moore.com \
--cc=serge@hallyn.com \
--cc=zohar@linux.ibm.com \
/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 NNTP newsgroup(s).