From: Namjae Jeon <linkinjeon@kernel.org>
To: viro@zeniv.linux.org.uk
Cc: linux-fsdevel@vger.kernel.org, linux-cifs@vger.kernel.org,
smfrench@gmail.com, senozhatsky@chromium.org, tom@talpey.com,
brauner@kernel.org, Namjae Jeon <linkinjeon@kernel.org>
Subject: [PATCH v8 1/3] ksmbd: remove internal.h include
Date: Thu, 16 Mar 2023 07:34:33 +0900 [thread overview]
Message-ID: <20230315223435.5139-2-linkinjeon@kernel.org> (raw)
In-Reply-To: <20230315223435.5139-1-linkinjeon@kernel.org>
Since vfs_path_lookup is exported, It should not be internal.
Move vfs_path_lookup prototype in internal.h to linux/namei.h.
Suggested-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
---
fs/internal.h | 2 --
fs/ksmbd/vfs.c | 2 --
include/linux/namei.h | 2 ++
3 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/fs/internal.h b/fs/internal.h
index dc4eb91a577a..071a7517f1a7 100644
--- a/fs/internal.h
+++ b/fs/internal.h
@@ -59,8 +59,6 @@ extern int finish_clean_context(struct fs_context *fc);
*/
extern int filename_lookup(int dfd, struct filename *name, unsigned flags,
struct path *path, struct path *root);
-extern int vfs_path_lookup(struct dentry *, struct vfsmount *,
- const char *, unsigned int, struct path *);
int do_rmdir(int dfd, struct filename *name);
int do_unlinkat(int dfd, struct filename *name);
int may_linkat(struct mnt_idmap *idmap, const struct path *link);
diff --git a/fs/ksmbd/vfs.c b/fs/ksmbd/vfs.c
index 5ea9229dad2c..cef07d7fb7dc 100644
--- a/fs/ksmbd/vfs.c
+++ b/fs/ksmbd/vfs.c
@@ -19,8 +19,6 @@
#include <linux/sched/xacct.h>
#include <linux/crc32c.h>
-#include "../internal.h" /* for vfs_path_lookup */
-
#include "glob.h"
#include "oplock.h"
#include "connection.h"
diff --git a/include/linux/namei.h b/include/linux/namei.h
index 0d4531fd46e7..c2747cfe97ac 100644
--- a/include/linux/namei.h
+++ b/include/linux/namei.h
@@ -63,6 +63,8 @@ extern struct dentry *kern_path_create(int, const char *, struct path *, unsigne
extern struct dentry *user_path_create(int, const char __user *, struct path *, unsigned int);
extern void done_path_create(struct path *, struct dentry *);
extern struct dentry *kern_path_locked(const char *, struct path *);
+int vfs_path_lookup(struct dentry *, struct vfsmount *, const char *,
+ unsigned int, struct path *);
extern struct dentry *try_lookup_one_len(const char *, struct dentry *, int);
extern struct dentry *lookup_one_len(const char *, struct dentry *, int);
--
2.25.1
next prev parent reply other threads:[~2023-03-15 22:35 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-15 22:34 [PATCH v8 0/3] ksmbd patches included vfs changes Namjae Jeon
2023-03-15 22:34 ` Namjae Jeon [this message]
2023-03-17 8:55 ` [PATCH v8 1/3] ksmbd: remove internal.h include Christian Brauner
2023-03-15 22:34 ` [PATCH v8 2/3] fs: introduce lock_rename_child() helper Namjae Jeon
2023-03-15 22:34 ` [PATCH v8 3/3] ksmbd: fix racy issue from using ->d_parent and ->d_name Namjae Jeon
2023-04-21 2:35 ` [PATCH v8 0/3] ksmbd patches included vfs changes Al Viro
2023-04-21 2:38 ` Al Viro
2023-04-21 7:26 ` Namjae Jeon
2023-06-13 10:57 ` Amir Goldstein
2023-06-13 12:24 ` Namjae Jeon
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=20230315223435.5139-2-linkinjeon@kernel.org \
--to=linkinjeon@kernel.org \
--cc=brauner@kernel.org \
--cc=linux-cifs@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=senozhatsky@chromium.org \
--cc=smfrench@gmail.com \
--cc=tom@talpey.com \
--cc=viro@zeniv.linux.org.uk \
/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).