From: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>
To: Johannes Berg <johannes@sipsolutions.net>, linux-kernel@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
Johannes Berg <johannes.berg@intel.com>,
Suresh Kumar Kurmi <suresh.kumar.kurmi@intel.com>,
kernel test robot <oliver.sang@intel.com>
Subject: Re: [PATCH] fs: debugfs: fix open proxy for unsafe files
Date: Mon, 13 Jan 2025 11:04:48 +0530 [thread overview]
Message-ID: <555bb228-ac49-43a4-b1cf-1d163b053973@linux.vnet.ibm.com> (raw)
In-Reply-To: <20250110085826.cd74f3b7a36b.I430c79c82ec3f954c2ff9665753bf6ac9e63eef8@changeid>
Applied and Verified the below patch. Proposed fix works fine.
Please add below tag.
Tested-by: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>
Regards,
Venkat.
On 10/01/25 1:28 pm, Johannes Berg wrote:
> From: Johannes Berg <johannes.berg@intel.com>
>
> In the previous commit referenced below, I had to split
> the short fops handling into different proxy fops. This
> necessitated knowing out-of-band whether or not the ops
> are short or full, when attempting to convert from fops
> to allocated fsdata.
>
> Unfortunately, I only converted full_proxy_open() which
> is used for the new full_proxy_open_regular() and
> full_proxy_open_short(), but forgot about the call in
> open_proxy_open(), used for debugfs_create_file_unsafe().
>
> Fix that, it never has short fops.
>
> Fixes: f8f25893a477 ("fs: debugfs: differentiate short fops with proxy ops")
> Reported-by: Suresh Kumar Kurmi <suresh.kumar.kurmi@intel.com>
> Reported-by: kernel test robot <oliver.sang@intel.com>
> Closes: https://lore.kernel.org/oe-lkp/202501101055.bb8bf3e7-lkp@intel.com
> Reported-by: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>
> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
> ---
> fs/debugfs/file.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/debugfs/file.c b/fs/debugfs/file.c
> index bdb4f2ca0506..16e198a26339 100644
> --- a/fs/debugfs/file.c
> +++ b/fs/debugfs/file.c
> @@ -280,7 +280,7 @@ static int open_proxy_open(struct inode *inode, struct file *filp)
> const struct file_operations *real_fops = NULL;
> int r;
>
> - r = debugfs_file_get(dentry);
> + r = __debugfs_file_get(dentry, DBGFS_GET_REGULAR);
> if (r)
> return r == -EIO ? -ENOENT : r;
>
prev parent reply other threads:[~2025-01-13 5:35 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-10 7:58 Johannes Berg
2025-01-13 5:34 ` Venkat Rao Bagalkote [this message]
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=555bb228-ac49-43a4-b1cf-1d163b053973@linux.vnet.ibm.com \
--to=venkat88@linux.vnet.ibm.com \
--cc=gregkh@linuxfoundation.org \
--cc=johannes.berg@intel.com \
--cc=johannes@sipsolutions.net \
--cc=linux-kernel@vger.kernel.org \
--cc=oliver.sang@intel.com \
--cc=rafael@kernel.org \
--cc=suresh.kumar.kurmi@intel.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
all inboxes | Powered by JetHome®