* [PATCH] configfs: Remove unused configfs_hash_and_remove
@ 2024-10-10 20:56 linux
2024-11-12 21:36 ` Dr. David Alan Gilbert
0 siblings, 1 reply; 4+ messages in thread
From: linux @ 2024-10-10 20:56 UTC (permalink / raw)
To: jlbec, hch; +Cc: linux-kernel, Dr. David Alan Gilbert
From: "Dr. David Alan Gilbert" <linux@treblig.org>
configfs_hash_and_remove() has been unused since it was added in 2005
by commit
7063fbf22611 ("[PATCH] configfs: User-driven configuration filesystem")
Remove it.
Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
---
fs/configfs/configfs_internal.h | 2 --
fs/configfs/inode.c | 25 -------------------------
2 files changed, 27 deletions(-)
diff --git a/fs/configfs/configfs_internal.h b/fs/configfs/configfs_internal.h
index e710a1782382..5c20e83315bc 100644
--- a/fs/configfs/configfs_internal.h
+++ b/fs/configfs/configfs_internal.h
@@ -73,8 +73,6 @@ extern int configfs_make_dirent(struct configfs_dirent *, struct dentry *,
void *, umode_t, int, struct configfs_fragment *);
extern int configfs_dirent_is_ready(struct configfs_dirent *);
-extern void configfs_hash_and_remove(struct dentry * dir, const char * name);
-
extern const unsigned char * configfs_get_name(struct configfs_dirent *sd);
extern void configfs_drop_dentry(struct configfs_dirent *sd, struct dentry *parent);
extern int configfs_setattr(struct mnt_idmap *idmap,
diff --git a/fs/configfs/inode.c b/fs/configfs/inode.c
index dcc22f593e43..1d2e3a5738d1 100644
--- a/fs/configfs/inode.c
+++ b/fs/configfs/inode.c
@@ -216,28 +216,3 @@ void configfs_drop_dentry(struct configfs_dirent * sd, struct dentry * parent)
spin_unlock(&dentry->d_lock);
}
}
-
-void configfs_hash_and_remove(struct dentry * dir, const char * name)
-{
- struct configfs_dirent * sd;
- struct configfs_dirent * parent_sd = dir->d_fsdata;
-
- if (d_really_is_negative(dir))
- /* no inode means this hasn't been made visible yet */
- return;
-
- inode_lock(d_inode(dir));
- list_for_each_entry(sd, &parent_sd->s_children, s_sibling) {
- if (!sd->s_element)
- continue;
- if (!strcmp(configfs_get_name(sd), name)) {
- spin_lock(&configfs_dirent_lock);
- list_del_init(&sd->s_sibling);
- spin_unlock(&configfs_dirent_lock);
- configfs_drop_dentry(sd, dir);
- configfs_put(sd);
- break;
- }
- }
- inode_unlock(d_inode(dir));
-}
--
2.47.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] configfs: Remove unused configfs_hash_and_remove
2024-10-10 20:56 [PATCH] configfs: Remove unused configfs_hash_and_remove linux
@ 2024-11-12 21:36 ` Dr. David Alan Gilbert
2024-11-14 5:31 ` Christoph Hellwig
0 siblings, 1 reply; 4+ messages in thread
From: Dr. David Alan Gilbert @ 2024-11-12 21:36 UTC (permalink / raw)
To: jlbec, hch; +Cc: linux-kernel
* linux@treblig.org (linux@treblig.org) wrote:
> From: "Dr. David Alan Gilbert" <linux@treblig.org>
>
> configfs_hash_and_remove() has been unused since it was added in 2005
> by commit
> 7063fbf22611 ("[PATCH] configfs: User-driven configuration filesystem")
>
> Remove it.
>
> Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
Ping
Thanks,
Dave
> ---
> fs/configfs/configfs_internal.h | 2 --
> fs/configfs/inode.c | 25 -------------------------
> 2 files changed, 27 deletions(-)
>
> diff --git a/fs/configfs/configfs_internal.h b/fs/configfs/configfs_internal.h
> index e710a1782382..5c20e83315bc 100644
> --- a/fs/configfs/configfs_internal.h
> +++ b/fs/configfs/configfs_internal.h
> @@ -73,8 +73,6 @@ extern int configfs_make_dirent(struct configfs_dirent *, struct dentry *,
> void *, umode_t, int, struct configfs_fragment *);
> extern int configfs_dirent_is_ready(struct configfs_dirent *);
>
> -extern void configfs_hash_and_remove(struct dentry * dir, const char * name);
> -
> extern const unsigned char * configfs_get_name(struct configfs_dirent *sd);
> extern void configfs_drop_dentry(struct configfs_dirent *sd, struct dentry *parent);
> extern int configfs_setattr(struct mnt_idmap *idmap,
> diff --git a/fs/configfs/inode.c b/fs/configfs/inode.c
> index dcc22f593e43..1d2e3a5738d1 100644
> --- a/fs/configfs/inode.c
> +++ b/fs/configfs/inode.c
> @@ -216,28 +216,3 @@ void configfs_drop_dentry(struct configfs_dirent * sd, struct dentry * parent)
> spin_unlock(&dentry->d_lock);
> }
> }
> -
> -void configfs_hash_and_remove(struct dentry * dir, const char * name)
> -{
> - struct configfs_dirent * sd;
> - struct configfs_dirent * parent_sd = dir->d_fsdata;
> -
> - if (d_really_is_negative(dir))
> - /* no inode means this hasn't been made visible yet */
> - return;
> -
> - inode_lock(d_inode(dir));
> - list_for_each_entry(sd, &parent_sd->s_children, s_sibling) {
> - if (!sd->s_element)
> - continue;
> - if (!strcmp(configfs_get_name(sd), name)) {
> - spin_lock(&configfs_dirent_lock);
> - list_del_init(&sd->s_sibling);
> - spin_unlock(&configfs_dirent_lock);
> - configfs_drop_dentry(sd, dir);
> - configfs_put(sd);
> - break;
> - }
> - }
> - inode_unlock(d_inode(dir));
> -}
> --
> 2.47.0
>
--
-----Open up your eyes, open up your mind, open up your code -------
/ Dr. David Alan Gilbert | Running GNU/Linux | Happy \
\ dave @ treblig.org | | In Hex /
\ _________________________|_____ http://www.treblig.org |_______/
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] configfs: Remove unused configfs_hash_and_remove
2024-11-12 21:36 ` Dr. David Alan Gilbert
@ 2024-11-14 5:31 ` Christoph Hellwig
2024-11-14 12:17 ` Dr. David Alan Gilbert
0 siblings, 1 reply; 4+ messages in thread
From: Christoph Hellwig @ 2024-11-14 5:31 UTC (permalink / raw)
To: Dr. David Alan Gilbert; +Cc: jlbec, hch, linux-kernel
Hi David,
I thought I already picked this up, but I didn't.
It is queued up now, thanks a lot!
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] configfs: Remove unused configfs_hash_and_remove
2024-11-14 5:31 ` Christoph Hellwig
@ 2024-11-14 12:17 ` Dr. David Alan Gilbert
0 siblings, 0 replies; 4+ messages in thread
From: Dr. David Alan Gilbert @ 2024-11-14 12:17 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: jlbec, linux-kernel
* Christoph Hellwig (hch@lst.de) wrote:
> Hi David,
>
> I thought I already picked this up, but I didn't.
>
> It is queued up now, thanks a lot!
Thanks!
Dave
--
-----Open up your eyes, open up your mind, open up your code -------
/ Dr. David Alan Gilbert | Running GNU/Linux | Happy \
\ dave @ treblig.org | | In Hex /
\ _________________________|_____ http://www.treblig.org |_______/
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-11-14 12:17 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-10 20:56 [PATCH] configfs: Remove unused configfs_hash_and_remove linux
2024-11-12 21:36 ` Dr. David Alan Gilbert
2024-11-14 5:31 ` Christoph Hellwig
2024-11-14 12:17 ` Dr. David Alan Gilbert
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox