All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 02/10] f2fs: convert to kobject_del_and_put()
@ 2023-03-22 16:58 ` Yangtao Li via Linux-f2fs-devel
  0 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:58 UTC (permalink / raw)
  To: Jaegeuk Kim, Chao Yu
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-f2fs-devel, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/f2fs/sysfs.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/fs/f2fs/sysfs.c b/fs/f2fs/sysfs.c
index 9ddc6ee19433..b455afc12cfc 100644
--- a/fs/f2fs/sysfs.c
+++ b/fs/f2fs/sysfs.c
@@ -1478,14 +1478,11 @@ void f2fs_unregister_sysfs(struct f2fs_sb_info *sbi)
 		remove_proc_entry(sbi->sb->s_id, f2fs_proc_root);
 	}
 
-	kobject_del(&sbi->s_stat_kobj);
-	kobject_put(&sbi->s_stat_kobj);
+	kobject_del_and_put(&sbi->s_stat_kobj);
 	wait_for_completion(&sbi->s_stat_kobj_unregister);
-	kobject_del(&sbi->s_feature_list_kobj);
-	kobject_put(&sbi->s_feature_list_kobj);
+	kobject_del_and_put(&sbi->s_feature_list_kobj);
 	wait_for_completion(&sbi->s_feature_list_kobj_unregister);
 
-	kobject_del(&sbi->s_kobj);
-	kobject_put(&sbi->s_kobj);
+	kobject_del_and_put(&sbi->s_kobj);
 	wait_for_completion(&sbi->s_kobj_unregister);
 }
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [f2fs-dev] [PATCH v3 02/10] f2fs: convert to kobject_del_and_put()
@ 2023-03-22 16:58 ` Yangtao Li via Linux-f2fs-devel
  0 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li via Linux-f2fs-devel @ 2023-03-22 16:58 UTC (permalink / raw)
  To: Jaegeuk Kim, Chao Yu
  Cc: Rafael J. Wysocki, Greg Kroah-Hartman, Damien Le Moal,
	Yangtao Li, linux-kernel, linux-f2fs-devel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/f2fs/sysfs.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/fs/f2fs/sysfs.c b/fs/f2fs/sysfs.c
index 9ddc6ee19433..b455afc12cfc 100644
--- a/fs/f2fs/sysfs.c
+++ b/fs/f2fs/sysfs.c
@@ -1478,14 +1478,11 @@ void f2fs_unregister_sysfs(struct f2fs_sb_info *sbi)
 		remove_proc_entry(sbi->sb->s_id, f2fs_proc_root);
 	}
 
-	kobject_del(&sbi->s_stat_kobj);
-	kobject_put(&sbi->s_stat_kobj);
+	kobject_del_and_put(&sbi->s_stat_kobj);
 	wait_for_completion(&sbi->s_stat_kobj_unregister);
-	kobject_del(&sbi->s_feature_list_kobj);
-	kobject_put(&sbi->s_feature_list_kobj);
+	kobject_del_and_put(&sbi->s_feature_list_kobj);
 	wait_for_completion(&sbi->s_feature_list_kobj_unregister);
 
-	kobject_del(&sbi->s_kobj);
-	kobject_put(&sbi->s_kobj);
+	kobject_del_and_put(&sbi->s_kobj);
 	wait_for_completion(&sbi->s_kobj_unregister);
 }
-- 
2.35.1



_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 03/10] erofs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
@ 2023-03-22 16:58   ` Yangtao Li
  -1 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:58 UTC (permalink / raw)
  To: Gao Xiang, Chao Yu, Yue Hu, Jeffle Xu
  Cc: Rafael J. Wysocki, Greg Kroah-Hartman, Damien Le Moal,
	Yangtao Li, linux-kernel, linux-erofs

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/erofs/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c
index 435e515c0792..9ed7d6552155 100644
--- a/fs/erofs/sysfs.c
+++ b/fs/erofs/sysfs.c
@@ -241,8 +241,7 @@ void erofs_unregister_sysfs(struct super_block *sb)
 	struct erofs_sb_info *sbi = EROFS_SB(sb);
 
 	if (sbi->s_kobj.state_in_sysfs) {
-		kobject_del(&sbi->s_kobj);
-		kobject_put(&sbi->s_kobj);
+		kobject_del_and_put(&sbi->s_kobj);
 		wait_for_completion(&sbi->s_kobj_unregister);
 	}
 }
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 03/10] erofs: convert to kobject_del_and_put()
@ 2023-03-22 16:58   ` Yangtao Li
  0 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:58 UTC (permalink / raw)
  To: Gao Xiang, Chao Yu, Yue Hu, Jeffle Xu
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-erofs, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/erofs/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c
index 435e515c0792..9ed7d6552155 100644
--- a/fs/erofs/sysfs.c
+++ b/fs/erofs/sysfs.c
@@ -241,8 +241,7 @@ void erofs_unregister_sysfs(struct super_block *sb)
 	struct erofs_sb_info *sbi = EROFS_SB(sb);
 
 	if (sbi->s_kobj.state_in_sysfs) {
-		kobject_del(&sbi->s_kobj);
-		kobject_put(&sbi->s_kobj);
+		kobject_del_and_put(&sbi->s_kobj);
 		wait_for_completion(&sbi->s_kobj_unregister);
 	}
 }
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 04/10] zonefs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
  (?)
  (?)
@ 2023-03-22 16:58 ` Yangtao Li
  2023-03-22 23:33   ` Damien Le Moal
  -1 siblings, 1 reply; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:58 UTC (permalink / raw)
  To: Damien Le Moal, Naohiro Aota, Johannes Thumshirn
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki, linux-fsdevel,
	linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/zonefs/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/zonefs/sysfs.c b/fs/zonefs/sysfs.c
index 8ccb65c2b419..5e117188fbb5 100644
--- a/fs/zonefs/sysfs.c
+++ b/fs/zonefs/sysfs.c
@@ -113,8 +113,7 @@ void zonefs_sysfs_unregister(struct super_block *sb)
 	if (!sbi || !sbi->s_sysfs_registered)
 		return;
 
-	kobject_del(&sbi->s_kobj);
-	kobject_put(&sbi->s_kobj);
+	kobject_del_and_put(&sbi->s_kobj);
 	wait_for_completion(&sbi->s_kobj_unregister);
 }
 
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
@ 2023-03-22 16:59   ` Yangtao Li
  -1 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Richard Weinberger
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-mtd, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/ubifs/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/ubifs/sysfs.c b/fs/ubifs/sysfs.c
index 1c958148bb87..9571718e61a9 100644
--- a/fs/ubifs/sysfs.c
+++ b/fs/ubifs/sysfs.c
@@ -130,8 +130,7 @@ int ubifs_sysfs_register(struct ubifs_info *c)
 
 void ubifs_sysfs_unregister(struct ubifs_info *c)
 {
-	kobject_del(&c->kobj);
-	kobject_put(&c->kobj);
+	kobject_del_and_put(&c->kobj);
 	wait_for_completion(&c->kobj_unregister);
 
 	kfree(c->stats);
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
@ 2023-03-22 16:59   ` Yangtao Li
  0 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Richard Weinberger
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-mtd, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/ubifs/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/ubifs/sysfs.c b/fs/ubifs/sysfs.c
index 1c958148bb87..9571718e61a9 100644
--- a/fs/ubifs/sysfs.c
+++ b/fs/ubifs/sysfs.c
@@ -130,8 +130,7 @@ int ubifs_sysfs_register(struct ubifs_info *c)
 
 void ubifs_sysfs_unregister(struct ubifs_info *c)
 {
-	kobject_del(&c->kobj);
-	kobject_put(&c->kobj);
+	kobject_del_and_put(&c->kobj);
 	wait_for_completion(&c->kobj_unregister);
 
 	kfree(c->stats);
-- 
2.35.1


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 06/10] btrfs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
                   ` (3 preceding siblings ...)
  (?)
@ 2023-03-22 16:59 ` Yangtao Li
  2023-03-22 23:35   ` Damien Le Moal
  -1 siblings, 1 reply; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Chris Mason, Josef Bacik, David Sterba
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-btrfs, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
Acked-by: David Sterba <dsterba@suse.com>
---
 fs/btrfs/block-group.c |  5 +----
 fs/btrfs/sysfs.c       | 38 ++++++++++++--------------------------
 2 files changed, 13 insertions(+), 30 deletions(-)

diff --git a/fs/btrfs/block-group.c b/fs/btrfs/block-group.c
index 5fc670c27f86..a2876235c6dc 100644
--- a/fs/btrfs/block-group.c
+++ b/fs/btrfs/block-group.c
@@ -1125,10 +1125,7 @@ int btrfs_remove_block_group(struct btrfs_trans_handle *trans,
 	}
 	up_write(&block_group->space_info->groups_sem);
 	clear_incompat_bg_bits(fs_info, block_group->flags);
-	if (kobj) {
-		kobject_del(kobj);
-		kobject_put(kobj);
-	}
+	kobject_del_and_put(kobj);
 
 	if (block_group->cached == BTRFS_CACHE_STARTED)
 		btrfs_wait_block_group_cache_done(block_group);
diff --git a/fs/btrfs/sysfs.c b/fs/btrfs/sysfs.c
index 37fc58a7f27e..49b837561135 100644
--- a/fs/btrfs/sysfs.c
+++ b/fs/btrfs/sysfs.c
@@ -1390,20 +1390,17 @@ static int addrm_unknown_feature_attrs(struct btrfs_fs_info *fs_info, bool add)
 static void __btrfs_sysfs_remove_fsid(struct btrfs_fs_devices *fs_devs)
 {
 	if (fs_devs->devinfo_kobj) {
-		kobject_del(fs_devs->devinfo_kobj);
-		kobject_put(fs_devs->devinfo_kobj);
+		kobject_del_and_put(fs_devs->devinfo_kobj);
 		fs_devs->devinfo_kobj = NULL;
 	}
 
 	if (fs_devs->devices_kobj) {
-		kobject_del(fs_devs->devices_kobj);
-		kobject_put(fs_devs->devices_kobj);
+		kobject_del_and_put(fs_devs->devices_kobj);
 		fs_devs->devices_kobj = NULL;
 	}
 
 	if (fs_devs->fsid_kobj.state_initialized) {
-		kobject_del(&fs_devs->fsid_kobj);
-		kobject_put(&fs_devs->fsid_kobj);
+		kobject_del_and_put(&fs_devs->fsid_kobj);
 		wait_for_completion(&fs_devs->kobj_unregister);
 	}
 }
@@ -1445,19 +1442,16 @@ void btrfs_sysfs_remove_mounted(struct btrfs_fs_info *fs_info)
 
 	if (fs_info->space_info_kobj) {
 		sysfs_remove_files(fs_info->space_info_kobj, allocation_attrs);
-		kobject_del(fs_info->space_info_kobj);
-		kobject_put(fs_info->space_info_kobj);
+		kobject_del_and_put(fs_info->space_info_kobj);
 	}
 	if (fs_info->discard_kobj) {
 		sysfs_remove_files(fs_info->discard_kobj, discard_attrs);
-		kobject_del(fs_info->discard_kobj);
-		kobject_put(fs_info->discard_kobj);
+		kobject_del_and_put(fs_info->discard_kobj);
 	}
 #ifdef CONFIG_BTRFS_DEBUG
 	if (fs_info->debug_kobj) {
 		sysfs_remove_files(fs_info->debug_kobj, btrfs_debug_mount_attrs);
-		kobject_del(fs_info->debug_kobj);
-		kobject_put(fs_info->debug_kobj);
+		kobject_del_and_put(fs_info->debug_kobj);
 	}
 #endif
 	addrm_unknown_feature_attrs(fs_info, false);
@@ -1620,13 +1614,9 @@ void btrfs_sysfs_remove_space_info(struct btrfs_space_info *space_info)
 
 		kobj = space_info->block_group_kobjs[i];
 		space_info->block_group_kobjs[i] = NULL;
-		if (kobj) {
-			kobject_del(kobj);
-			kobject_put(kobj);
-		}
+		kobject_del_and_put(kobj);
 	}
-	kobject_del(&space_info->kobj);
-	kobject_put(&space_info->kobj);
+	kobject_del_and_put(&space_info->kobj);
 }
 
 static const char *alloc_name(u64 flags)
@@ -1681,8 +1671,7 @@ void btrfs_sysfs_remove_device(struct btrfs_device *device)
 		sysfs_remove_link(devices_kobj, bdev_kobj(device->bdev)->name);
 
 	if (device->devid_kobj.state_initialized) {
-		kobject_del(&device->devid_kobj);
-		kobject_put(&device->devid_kobj);
+		kobject_del_and_put(&device->devid_kobj);
 		wait_for_completion(&device->kobj_unregister);
 	}
 }
@@ -2255,8 +2244,7 @@ void btrfs_sysfs_del_qgroups(struct btrfs_fs_info *fs_info)
 					     &fs_info->qgroup_tree, node)
 		btrfs_sysfs_del_one_qgroup(fs_info, qgroup);
 	if (fs_info->qgroups_kobj) {
-		kobject_del(fs_info->qgroups_kobj);
-		kobject_put(fs_info->qgroups_kobj);
+		kobject_del_and_put(fs_info->qgroups_kobj);
 		fs_info->qgroups_kobj = NULL;
 	}
 }
@@ -2304,10 +2292,8 @@ void btrfs_sysfs_del_one_qgroup(struct btrfs_fs_info *fs_info,
 	if (test_bit(BTRFS_FS_STATE_DUMMY_FS_INFO, &fs_info->fs_state))
 		return;
 
-	if (qgroup->kobj.state_initialized) {
-		kobject_del(&qgroup->kobj);
-		kobject_put(&qgroup->kobj);
-	}
+	if (qgroup->kobj.state_initialized)
+		kobject_del_and_put(&qgroup->kobj);
 }
 
 /*
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 07/10] xfs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
                   ` (4 preceding siblings ...)
  (?)
@ 2023-03-22 16:59 ` Yangtao Li
  2023-03-22 23:35   ` Damien Le Moal
  -1 siblings, 1 reply; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Darrick J. Wong
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-xfs, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
Acked-by: Darrick J. Wong <djwong@kernel.org>
---
 fs/xfs/xfs_sysfs.h | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/xfs/xfs_sysfs.h b/fs/xfs/xfs_sysfs.h
index 148893ebfdef..e2ff063e2c29 100644
--- a/fs/xfs/xfs_sysfs.h
+++ b/fs/xfs/xfs_sysfs.h
@@ -48,8 +48,7 @@ static inline void
 xfs_sysfs_del(
 	struct xfs_kobj	*kobj)
 {
-	kobject_del(&kobj->kobject);
-	kobject_put(&kobj->kobject);
+	kobject_del_and_put(&kobj->kobject);
 	wait_for_completion(&kobj->complete);
 }
 
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 08/10] ocfs2: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
@ 2023-03-22 16:59   ` Yangtao Li via Ocfs2-devel
  -1 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Mark Fasheh, Joel Becker, Joseph Qi
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, ocfs2-devel, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/ocfs2/filecheck.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/ocfs2/filecheck.c b/fs/ocfs2/filecheck.c
index 1ad7106741f8..fb9cf601245b 100644
--- a/fs/ocfs2/filecheck.c
+++ b/fs/ocfs2/filecheck.c
@@ -198,8 +198,7 @@ void ocfs2_filecheck_remove_sysfs(struct ocfs2_super *osb)
 	if (!osb->osb_fc_ent.fs_fcheck)
 		return;
 
-	kobject_del(&osb->osb_fc_ent.fs_kobj);
-	kobject_put(&osb->osb_fc_ent.fs_kobj);
+	kobject_del_and_put(&osb->osb_fc_ent.fs_kobj);
 	wait_for_completion(&osb->osb_fc_ent.fs_kobj_unregister);
 	ocfs2_filecheck_sysfs_free(&osb->osb_fc_ent);
 }
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [Ocfs2-devel] [PATCH v3 08/10] ocfs2: convert to kobject_del_and_put()
@ 2023-03-22 16:59   ` Yangtao Li via Ocfs2-devel
  0 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li via Ocfs2-devel @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Mark Fasheh, Joel Becker, Joseph Qi
  Cc: Rafael J. Wysocki, Greg Kroah-Hartman, Damien Le Moal,
	Yangtao Li, linux-kernel, ocfs2-devel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/ocfs2/filecheck.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/ocfs2/filecheck.c b/fs/ocfs2/filecheck.c
index 1ad7106741f8..fb9cf601245b 100644
--- a/fs/ocfs2/filecheck.c
+++ b/fs/ocfs2/filecheck.c
@@ -198,8 +198,7 @@ void ocfs2_filecheck_remove_sysfs(struct ocfs2_super *osb)
 	if (!osb->osb_fc_ent.fs_fcheck)
 		return;
 
-	kobject_del(&osb->osb_fc_ent.fs_kobj);
-	kobject_put(&osb->osb_fc_ent.fs_kobj);
+	kobject_del_and_put(&osb->osb_fc_ent.fs_kobj);
 	wait_for_completion(&osb->osb_fc_ent.fs_kobj_unregister);
 	ocfs2_filecheck_sysfs_free(&osb->osb_fc_ent);
 }
-- 
2.35.1


_______________________________________________
Ocfs2-devel mailing list
Ocfs2-devel@oss.oracle.com
https://oss.oracle.com/mailman/listinfo/ocfs2-devel

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 09/10] nfs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
                   ` (6 preceding siblings ...)
  (?)
@ 2023-03-22 16:59 ` Yangtao Li
  2023-03-22 23:36   ` Damien Le Moal
  -1 siblings, 1 reply; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Trond Myklebust, Anna Schumaker
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-nfs, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/nfs/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/nfs/sysfs.c b/fs/nfs/sysfs.c
index 0cbcd2dfa732..a6072be5fa5a 100644
--- a/fs/nfs/sysfs.c
+++ b/fs/nfs/sysfs.c
@@ -185,8 +185,7 @@ void nfs_netns_sysfs_destroy(struct nfs_net *netns)
 
 	if (clp) {
 		kobject_uevent(&clp->kobject, KOBJ_REMOVE);
-		kobject_del(&clp->kobject);
-		kobject_put(&clp->kobject);
+		kobject_del_and_put(&clp->kobject);
 		netns->nfs_client = NULL;
 	}
 }
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 10/10] nilfs2: convert to kobject_del_and_put()
@ 2023-03-22 16:59   ` Yangtao Li
  0 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Ryusuke Konishi
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-nilfs, linux-kernel

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/nilfs2/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/nilfs2/sysfs.c b/fs/nilfs2/sysfs.c
index 379d22e28ed6..150965d58ca5 100644
--- a/fs/nilfs2/sysfs.c
+++ b/fs/nilfs2/sysfs.c
@@ -1042,8 +1042,7 @@ void nilfs_sysfs_delete_device_group(struct the_nilfs *nilfs)
 	nilfs_sysfs_delete_segments_group(nilfs);
 	nilfs_sysfs_delete_superblock_group(nilfs);
 	nilfs_sysfs_delete_segctor_group(nilfs);
-	kobject_del(&nilfs->ns_dev_kobj);
-	kobject_put(&nilfs->ns_dev_kobj);
+	kobject_del_and_put(&nilfs->ns_dev_kobj);
 	kfree(nilfs->ns_dev_subgroups);
 }
 
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH v3 10/10] nilfs2: convert to kobject_del_and_put()
@ 2023-03-22 16:59   ` Yangtao Li
  0 siblings, 0 replies; 34+ messages in thread
From: Yangtao Li @ 2023-03-22 16:59 UTC (permalink / raw)
  To: Ryusuke Konishi
  Cc: Yangtao Li, Greg Kroah-Hartman, Rafael J. Wysocki,
	Damien Le Moal, linux-nilfs-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA

Use kobject_del_and_put() to simplify code.

Cc: Greg Kroah-Hartman <gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>
Cc: "Rafael J. Wysocki" <rafael-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: Damien Le Moal <damien.lemoal-yzvPICuk2AC/Fx7ZUtofftBPR1lH4CV8@public.gmane.org>
Signed-off-by: Yangtao Li <frank.li-DGpbCiVdSXo@public.gmane.org>
---
 fs/nilfs2/sysfs.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/fs/nilfs2/sysfs.c b/fs/nilfs2/sysfs.c
index 379d22e28ed6..150965d58ca5 100644
--- a/fs/nilfs2/sysfs.c
+++ b/fs/nilfs2/sysfs.c
@@ -1042,8 +1042,7 @@ void nilfs_sysfs_delete_device_group(struct the_nilfs *nilfs)
 	nilfs_sysfs_delete_segments_group(nilfs);
 	nilfs_sysfs_delete_superblock_group(nilfs);
 	nilfs_sysfs_delete_segctor_group(nilfs);
-	kobject_del(&nilfs->ns_dev_kobj);
-	kobject_put(&nilfs->ns_dev_kobj);
+	kobject_del_and_put(&nilfs->ns_dev_kobj);
 	kfree(nilfs->ns_dev_subgroups);
 }
 
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
  2023-03-22 16:59   ` Yangtao Li
@ 2023-03-22 17:02     ` Richard Weinberger
  -1 siblings, 0 replies; 34+ messages in thread
From: Richard Weinberger @ 2023-03-22 17:02 UTC (permalink / raw)
  To: Yangtao Li
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, Damien Le Moal, linux-mtd,
	linux-kernel

----- Ursprüngliche Mail -----
> Von: "Yangtao Li" <frank.li@vivo.com>
> An: "richard" <richard@nod.at>
> CC: "Yangtao Li" <frank.li@vivo.com>, "Greg Kroah-Hartman" <gregkh@linuxfoundation.org>, "Rafael J. Wysocki"
> <rafael@kernel.org>, "Damien Le Moal" <damien.lemoal@opensource.wdc.com>, "linux-mtd" <linux-mtd@lists.infradead.org>,
> "linux-kernel" <linux-kernel@vger.kernel.org>
> Gesendet: Mittwoch, 22. März 2023 17:59:00
> Betreff: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()

> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
> fs/ubifs/sysfs.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/fs/ubifs/sysfs.c b/fs/ubifs/sysfs.c
> index 1c958148bb87..9571718e61a9 100644
> --- a/fs/ubifs/sysfs.c
> +++ b/fs/ubifs/sysfs.c
> @@ -130,8 +130,7 @@ int ubifs_sysfs_register(struct ubifs_info *c)
> 
> void ubifs_sysfs_unregister(struct ubifs_info *c)
> {
> -	kobject_del(&c->kobj);
> -	kobject_put(&c->kobj);
> +	kobject_del_and_put(&c->kobj);
> 	wait_for_completion(&c->kobj_unregister);

Acked-by: Richard Weinberger <richard@nod.at>

Thanks,
//richard

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
@ 2023-03-22 17:02     ` Richard Weinberger
  0 siblings, 0 replies; 34+ messages in thread
From: Richard Weinberger @ 2023-03-22 17:02 UTC (permalink / raw)
  To: Yangtao Li
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, Damien Le Moal, linux-mtd,
	linux-kernel

----- Ursprüngliche Mail -----
> Von: "Yangtao Li" <frank.li@vivo.com>
> An: "richard" <richard@nod.at>
> CC: "Yangtao Li" <frank.li@vivo.com>, "Greg Kroah-Hartman" <gregkh@linuxfoundation.org>, "Rafael J. Wysocki"
> <rafael@kernel.org>, "Damien Le Moal" <damien.lemoal@opensource.wdc.com>, "linux-mtd" <linux-mtd@lists.infradead.org>,
> "linux-kernel" <linux-kernel@vger.kernel.org>
> Gesendet: Mittwoch, 22. März 2023 17:59:00
> Betreff: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()

> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
> fs/ubifs/sysfs.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/fs/ubifs/sysfs.c b/fs/ubifs/sysfs.c
> index 1c958148bb87..9571718e61a9 100644
> --- a/fs/ubifs/sysfs.c
> +++ b/fs/ubifs/sysfs.c
> @@ -130,8 +130,7 @@ int ubifs_sysfs_register(struct ubifs_info *c)
> 
> void ubifs_sysfs_unregister(struct ubifs_info *c)
> {
> -	kobject_del(&c->kobj);
> -	kobject_put(&c->kobj);
> +	kobject_del_and_put(&c->kobj);
> 	wait_for_completion(&c->kobj_unregister);

Acked-by: Richard Weinberger <richard@nod.at>

Thanks,
//richard

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 03/10] erofs: convert to kobject_del_and_put()
  2023-03-22 16:58   ` Yangtao Li
@ 2023-03-22 19:09     ` Gao Xiang
  -1 siblings, 0 replies; 34+ messages in thread
From: Gao Xiang @ 2023-03-22 19:09 UTC (permalink / raw)
  To: Yangtao Li, Gao Xiang, Chao Yu, Yue Hu, Jeffle Xu
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, Damien Le Moal,
	linux-erofs, linux-kernel



On 2023/3/23 00:58, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Acked-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

> ---
>   fs/erofs/sysfs.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c
> index 435e515c0792..9ed7d6552155 100644
> --- a/fs/erofs/sysfs.c
> +++ b/fs/erofs/sysfs.c
> @@ -241,8 +241,7 @@ void erofs_unregister_sysfs(struct super_block *sb)
>   	struct erofs_sb_info *sbi = EROFS_SB(sb);
>   
>   	if (sbi->s_kobj.state_in_sysfs) {
> -		kobject_del(&sbi->s_kobj);
> -		kobject_put(&sbi->s_kobj);
> +		kobject_del_and_put(&sbi->s_kobj);
>   		wait_for_completion(&sbi->s_kobj_unregister);
>   	}
>   }

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 03/10] erofs: convert to kobject_del_and_put()
@ 2023-03-22 19:09     ` Gao Xiang
  0 siblings, 0 replies; 34+ messages in thread
From: Gao Xiang @ 2023-03-22 19:09 UTC (permalink / raw)
  To: Yangtao Li, Gao Xiang, Chao Yu, Yue Hu, Jeffle Xu
  Cc: Greg Kroah-Hartman, Damien Le Moal, linux-erofs, linux-kernel,
	Rafael J. Wysocki



On 2023/3/23 00:58, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Acked-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

> ---
>   fs/erofs/sysfs.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c
> index 435e515c0792..9ed7d6552155 100644
> --- a/fs/erofs/sysfs.c
> +++ b/fs/erofs/sysfs.c
> @@ -241,8 +241,7 @@ void erofs_unregister_sysfs(struct super_block *sb)
>   	struct erofs_sb_info *sbi = EROFS_SB(sb);
>   
>   	if (sbi->s_kobj.state_in_sysfs) {
> -		kobject_del(&sbi->s_kobj);
> -		kobject_put(&sbi->s_kobj);
> +		kobject_del_and_put(&sbi->s_kobj);
>   		wait_for_completion(&sbi->s_kobj_unregister);
>   	}
>   }

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 02/10] f2fs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
@ 2023-03-22 23:32   ` Damien Le Moal via Linux-f2fs-devel
  -1 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:32 UTC (permalink / raw)
  To: Yangtao Li, Jaegeuk Kim, Chao Yu
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-f2fs-devel, linux-kernel

On 3/23/23 01:58, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>

-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [f2fs-dev] [PATCH v3 02/10] f2fs: convert to kobject_del_and_put()
@ 2023-03-22 23:32   ` Damien Le Moal via Linux-f2fs-devel
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal via Linux-f2fs-devel @ 2023-03-22 23:32 UTC (permalink / raw)
  To: Yangtao Li, Jaegeuk Kim, Chao Yu
  Cc: Greg Kroah-Hartman, linux-f2fs-devel, linux-kernel, Rafael J. Wysocki

On 3/23/23 01:58, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>

-- 
Damien Le Moal
Western Digital Research



_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 03/10] erofs: convert to kobject_del_and_put()
  2023-03-22 16:58   ` Yangtao Li
@ 2023-03-22 23:33     ` Damien Le Moal via Linux-erofs
  -1 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:33 UTC (permalink / raw)
  To: Yangtao Li, Gao Xiang, Chao Yu, Yue Hu, Jeffle Xu
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-erofs, linux-kernel

On 3/23/23 01:58, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>


-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 03/10] erofs: convert to kobject_del_and_put()
@ 2023-03-22 23:33     ` Damien Le Moal via Linux-erofs
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal via Linux-erofs @ 2023-03-22 23:33 UTC (permalink / raw)
  To: Yangtao Li, Gao Xiang, Chao Yu, Yue Hu, Jeffle Xu
  Cc: Greg Kroah-Hartman, linux-erofs, linux-kernel, Rafael J. Wysocki

On 3/23/23 01:58, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>


-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 04/10] zonefs: convert to kobject_del_and_put()
  2023-03-22 16:58 ` [PATCH v3 04/10] zonefs: " Yangtao Li
@ 2023-03-22 23:33   ` Damien Le Moal
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:33 UTC (permalink / raw)
  To: Yangtao Li, Naohiro Aota, Johannes Thumshirn
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-fsdevel, linux-kernel

On 3/23/23 01:58, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Acked-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>


-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
  2023-03-22 16:59   ` Yangtao Li
@ 2023-03-22 23:34     ` Damien Le Moal
  -1 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:34 UTC (permalink / raw)
  To: Yangtao Li, Richard Weinberger
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-mtd, linux-kernel

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>

-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
@ 2023-03-22 23:34     ` Damien Le Moal
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:34 UTC (permalink / raw)
  To: Yangtao Li, Richard Weinberger
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-mtd, linux-kernel

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>

-- 
Damien Le Moal
Western Digital Research


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 06/10] btrfs: convert to kobject_del_and_put()
  2023-03-22 16:59 ` [PATCH v3 06/10] btrfs: " Yangtao Li
@ 2023-03-22 23:35   ` Damien Le Moal
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:35 UTC (permalink / raw)
  To: Yangtao Li, Chris Mason, Josef Bacik, David Sterba
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-btrfs, linux-kernel

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> Acked-by: David Sterba <dsterba@suse.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>

-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 07/10] xfs: convert to kobject_del_and_put()
  2023-03-22 16:59 ` [PATCH v3 07/10] xfs: " Yangtao Li
@ 2023-03-22 23:35   ` Damien Le Moal
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:35 UTC (permalink / raw)
  To: Yangtao Li, Darrick J. Wong
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-xfs, linux-kernel

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> Acked-by: Darrick J. Wong <djwong@kernel.org>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>

-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 08/10] ocfs2: convert to kobject_del_and_put()
  2023-03-22 16:59   ` [Ocfs2-devel] " Yangtao Li via Ocfs2-devel
@ 2023-03-22 23:36     ` Damien Le Moal via Ocfs2-devel
  -1 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:36 UTC (permalink / raw)
  To: Yangtao Li, Mark Fasheh, Joel Becker, Joseph Qi
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, ocfs2-devel, linux-kernel

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>


-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [Ocfs2-devel] [PATCH v3 08/10] ocfs2: convert to kobject_del_and_put()
@ 2023-03-22 23:36     ` Damien Le Moal via Ocfs2-devel
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal via Ocfs2-devel @ 2023-03-22 23:36 UTC (permalink / raw)
  To: Yangtao Li, Mark Fasheh, Joel Becker, Joseph Qi
  Cc: Greg Kroah-Hartman, linux-kernel, ocfs2-devel, Rafael J. Wysocki

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>


-- 
Damien Le Moal
Western Digital Research


_______________________________________________
Ocfs2-devel mailing list
Ocfs2-devel@oss.oracle.com
https://oss.oracle.com/mailman/listinfo/ocfs2-devel

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 09/10] nfs: convert to kobject_del_and_put()
  2023-03-22 16:59 ` [PATCH v3 09/10] nfs: " Yangtao Li
@ 2023-03-22 23:36   ` Damien Le Moal
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:36 UTC (permalink / raw)
  To: Yangtao Li, Trond Myklebust, Anna Schumaker
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-nfs, linux-kernel

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>


-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 10/10] nilfs2: convert to kobject_del_and_put()
@ 2023-03-22 23:36     ` Damien Le Moal
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:36 UTC (permalink / raw)
  To: Yangtao Li, Ryusuke Konishi
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, linux-nilfs, linux-kernel

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>

-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 10/10] nilfs2: convert to kobject_del_and_put()
@ 2023-03-22 23:36     ` Damien Le Moal
  0 siblings, 0 replies; 34+ messages in thread
From: Damien Le Moal @ 2023-03-22 23:36 UTC (permalink / raw)
  To: Yangtao Li, Ryusuke Konishi
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki,
	linux-nilfs-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA

On 3/23/23 01:59, Yangtao Li wrote:
> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>
> Cc: "Rafael J. Wysocki" <rafael-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
> Cc: Damien Le Moal <damien.lemoal-yzvPICuk2AC/Fx7ZUtofftBPR1lH4CV8@public.gmane.org>
> Signed-off-by: Yangtao Li <frank.li-DGpbCiVdSXo@public.gmane.org>

Reviewed-by: Damien Le Moal <damien.lemoal-yzvPICuk2AC/Fx7ZUtofftBPR1lH4CV8@public.gmane.org>

-- 
Damien Le Moal
Western Digital Research


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
  2023-03-22 16:59   ` Yangtao Li
@ 2023-03-23  1:08     ` Zhihao Cheng
  -1 siblings, 0 replies; 34+ messages in thread
From: Zhihao Cheng @ 2023-03-23  1:08 UTC (permalink / raw)
  To: Yangtao Li, Richard Weinberger
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, Damien Le Moal, linux-mtd,
	linux-kernel

> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
>   fs/ubifs/sysfs.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
> 

Reviewed-by: Zhihao Cheng <chengzhihao1@huawei.com>
> diff --git a/fs/ubifs/sysfs.c b/fs/ubifs/sysfs.c
> index 1c958148bb87..9571718e61a9 100644
> --- a/fs/ubifs/sysfs.c
> +++ b/fs/ubifs/sysfs.c
> @@ -130,8 +130,7 @@ int ubifs_sysfs_register(struct ubifs_info *c)
>   
>   void ubifs_sysfs_unregister(struct ubifs_info *c)
>   {
> -	kobject_del(&c->kobj);
> -	kobject_put(&c->kobj);
> +	kobject_del_and_put(&c->kobj);
>   	wait_for_completion(&c->kobj_unregister);
>   
>   	kfree(c->stats);
> 


^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH v3 05/10] ubifs: convert to kobject_del_and_put()
@ 2023-03-23  1:08     ` Zhihao Cheng
  0 siblings, 0 replies; 34+ messages in thread
From: Zhihao Cheng @ 2023-03-23  1:08 UTC (permalink / raw)
  To: Yangtao Li, Richard Weinberger
  Cc: Greg Kroah-Hartman, Rafael J. Wysocki, Damien Le Moal, linux-mtd,
	linux-kernel

> Use kobject_del_and_put() to simplify code.
> 
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> Cc: Damien Le Moal <damien.lemoal@opensource.wdc.com>
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
>   fs/ubifs/sysfs.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
> 

Reviewed-by: Zhihao Cheng <chengzhihao1@huawei.com>
> diff --git a/fs/ubifs/sysfs.c b/fs/ubifs/sysfs.c
> index 1c958148bb87..9571718e61a9 100644
> --- a/fs/ubifs/sysfs.c
> +++ b/fs/ubifs/sysfs.c
> @@ -130,8 +130,7 @@ int ubifs_sysfs_register(struct ubifs_info *c)
>   
>   void ubifs_sysfs_unregister(struct ubifs_info *c)
>   {
> -	kobject_del(&c->kobj);
> -	kobject_put(&c->kobj);
> +	kobject_del_and_put(&c->kobj);
>   	wait_for_completion(&c->kobj_unregister);
>   
>   	kfree(c->stats);
> 


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2023-03-23  1:09 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-22 16:58 [PATCH v3 02/10] f2fs: convert to kobject_del_and_put() Yangtao Li
2023-03-22 16:58 ` [f2fs-dev] " Yangtao Li via Linux-f2fs-devel
2023-03-22 16:58 ` [PATCH v3 03/10] erofs: " Yangtao Li
2023-03-22 16:58   ` Yangtao Li
2023-03-22 19:09   ` Gao Xiang
2023-03-22 19:09     ` Gao Xiang
2023-03-22 23:33   ` Damien Le Moal
2023-03-22 23:33     ` Damien Le Moal via Linux-erofs
2023-03-22 16:58 ` [PATCH v3 04/10] zonefs: " Yangtao Li
2023-03-22 23:33   ` Damien Le Moal
2023-03-22 16:59 ` [PATCH v3 05/10] ubifs: " Yangtao Li
2023-03-22 16:59   ` Yangtao Li
2023-03-22 17:02   ` Richard Weinberger
2023-03-22 17:02     ` Richard Weinberger
2023-03-22 23:34   ` Damien Le Moal
2023-03-22 23:34     ` Damien Le Moal
2023-03-23  1:08   ` Zhihao Cheng
2023-03-23  1:08     ` Zhihao Cheng
2023-03-22 16:59 ` [PATCH v3 06/10] btrfs: " Yangtao Li
2023-03-22 23:35   ` Damien Le Moal
2023-03-22 16:59 ` [PATCH v3 07/10] xfs: " Yangtao Li
2023-03-22 23:35   ` Damien Le Moal
2023-03-22 16:59 ` [PATCH v3 08/10] ocfs2: " Yangtao Li
2023-03-22 16:59   ` [Ocfs2-devel] " Yangtao Li via Ocfs2-devel
2023-03-22 23:36   ` Damien Le Moal
2023-03-22 23:36     ` [Ocfs2-devel] " Damien Le Moal via Ocfs2-devel
2023-03-22 16:59 ` [PATCH v3 09/10] nfs: " Yangtao Li
2023-03-22 23:36   ` Damien Le Moal
2023-03-22 16:59 ` [PATCH v3 10/10] nilfs2: " Yangtao Li
2023-03-22 16:59   ` Yangtao Li
2023-03-22 23:36   ` Damien Le Moal
2023-03-22 23:36     ` Damien Le Moal
2023-03-22 23:32 ` [PATCH v3 02/10] f2fs: " Damien Le Moal
2023-03-22 23:32   ` [f2fs-dev] " Damien Le Moal via Linux-f2fs-devel

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.