dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops
       [not found] <20250702211305.GE1880847@ZenIV>
@ 2025-07-02 21:14 ` Al Viro
  2025-07-02 21:24   ` [PATCH 07/11] debugfs: split short and full proxy wrappers, kill debugfs_real_fops() Al Viro
                     ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Al Viro @ 2025-07-02 21:14 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: linux-fsdevel, dri-devel

When debugfs file has been created by debugfs_create_file_unsafe(),
we do need the file_operations methods to use debugfs_file_{get,put}()
to prevent concurrent removal; for files created by debugfs_create_file()
that is done in the wrappers that call underlying methods, so there's
no point whatsoever duplicating that in the underlying methods themselves.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
 drivers/gpu/drm/xlnx/zynqmp_dp.c | 38 ++++----------------------------
 1 file changed, 4 insertions(+), 34 deletions(-)

diff --git a/drivers/gpu/drm/xlnx/zynqmp_dp.c b/drivers/gpu/drm/xlnx/zynqmp_dp.c
index 238cbb49963e..197defe4f928 100644
--- a/drivers/gpu/drm/xlnx/zynqmp_dp.c
+++ b/drivers/gpu/drm/xlnx/zynqmp_dp.c
@@ -1869,20 +1869,14 @@ static int zynqmp_dp_test_setup(struct zynqmp_dp *dp)
 static ssize_t zynqmp_dp_pattern_read(struct file *file, char __user *user_buf,
 				      size_t count, loff_t *ppos)
 {
-	struct dentry *dentry = file->f_path.dentry;
 	struct zynqmp_dp *dp = file->private_data;
 	char buf[16];
 	ssize_t ret;
 
-	ret = debugfs_file_get(dentry);
-	if (unlikely(ret))
-		return ret;
-
 	scoped_guard(mutex, &dp->lock)
 		ret = snprintf(buf, sizeof(buf), "%s\n",
 			       test_pattern_str[dp->test.pattern]);
 
-	debugfs_file_put(dentry);
 	return simple_read_from_buffer(user_buf, count, ppos, buf, ret);
 }
 
@@ -1890,27 +1884,20 @@ static ssize_t zynqmp_dp_pattern_write(struct file *file,
 				       const char __user *user_buf,
 				       size_t count, loff_t *ppos)
 {
-	struct dentry *dentry = file->f_path.dentry;
 	struct zynqmp_dp *dp = file->private_data;
 	char buf[16];
 	ssize_t ret;
 	int pattern;
 
-	ret = debugfs_file_get(dentry);
-	if (unlikely(ret))
-		return ret;
-
 	ret = simple_write_to_buffer(buf, sizeof(buf) - 1, ppos, user_buf,
 				     count);
 	if (ret < 0)
-		goto out;
+		return ret;
 	buf[ret] = '\0';
 
 	pattern = sysfs_match_string(test_pattern_str, buf);
-	if (pattern < 0) {
-		ret = -EINVAL;
-		goto out;
-	}
+	if (pattern < 0)
+		return -EINVAL;
 
 	mutex_lock(&dp->lock);
 	dp->test.pattern = pattern;
@@ -1919,8 +1906,6 @@ static ssize_t zynqmp_dp_pattern_write(struct file *file,
 						 dp->test.custom) ?: ret;
 	mutex_unlock(&dp->lock);
 
-out:
-	debugfs_file_put(dentry);
 	return ret;
 }
 
@@ -2026,20 +2011,13 @@ DEFINE_DEBUGFS_ATTRIBUTE(fops_zynqmp_dp_active, zynqmp_dp_active_get,
 static ssize_t zynqmp_dp_custom_read(struct file *file, char __user *user_buf,
 				     size_t count, loff_t *ppos)
 {
-	struct dentry *dentry = file->f_path.dentry;
 	struct zynqmp_dp *dp = file->private_data;
 	ssize_t ret;
 
-	ret = debugfs_file_get(dentry);
-	if (unlikely(ret))
-		return ret;
-
 	mutex_lock(&dp->lock);
 	ret = simple_read_from_buffer(user_buf, count, ppos, &dp->test.custom,
 				      sizeof(dp->test.custom));
 	mutex_unlock(&dp->lock);
-
-	debugfs_file_put(dentry);
 	return ret;
 }
 
@@ -2047,18 +2025,13 @@ static ssize_t zynqmp_dp_custom_write(struct file *file,
 				      const char __user *user_buf,
 				      size_t count, loff_t *ppos)
 {
-	struct dentry *dentry = file->f_path.dentry;
 	struct zynqmp_dp *dp = file->private_data;
 	ssize_t ret;
 	char buf[sizeof(dp->test.custom)];
 
-	ret = debugfs_file_get(dentry);
-	if (unlikely(ret))
-		return ret;
-
 	ret = simple_write_to_buffer(buf, sizeof(buf), ppos, user_buf, count);
 	if (ret < 0)
-		goto out;
+		return ret;
 
 	mutex_lock(&dp->lock);
 	memcpy(dp->test.custom, buf, ret);
@@ -2066,9 +2039,6 @@ static ssize_t zynqmp_dp_custom_write(struct file *file,
 		ret = zynqmp_dp_set_test_pattern(dp, dp->test.pattern,
 						 dp->test.custom) ?: ret;
 	mutex_unlock(&dp->lock);
-
-out:
-	debugfs_file_put(dentry);
 	return ret;
 }
 
-- 
2.39.5


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

* [PATCH 07/11] debugfs: split short and full proxy wrappers, kill debugfs_real_fops()
  2025-07-02 21:14 ` [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Al Viro
@ 2025-07-02 21:24   ` Al Viro
  2025-07-02 23:19   ` (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Jens Axboe
  2025-07-04 15:34   ` Mark Brown
  2 siblings, 0 replies; 8+ messages in thread
From: Al Viro @ 2025-07-02 21:24 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: linux-fsdevel, dri-devel

All users outside of fs/debugfs/file.c are gone, in there we can just
fully split the wrappers for full and short cases and be done with that.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
 fs/debugfs/file.c       | 87 ++++++++++++++++++-----------------------
 include/linux/debugfs.h |  2 -
 2 files changed, 38 insertions(+), 51 deletions(-)

diff --git a/fs/debugfs/file.c b/fs/debugfs/file.c
index 69e9ddcb113d..77784091a10f 100644
--- a/fs/debugfs/file.c
+++ b/fs/debugfs/file.c
@@ -53,23 +53,6 @@ const void *debugfs_get_aux(const struct file *file)
 }
 EXPORT_SYMBOL_GPL(debugfs_get_aux);
 
-const struct file_operations *debugfs_real_fops(const struct file *filp)
-{
-	struct debugfs_fsdata *fsd = F_DENTRY(filp)->d_fsdata;
-
-	if (!fsd) {
-		/*
-		 * Urgh, we've been called w/o a protecting
-		 * debugfs_file_get().
-		 */
-		WARN_ON(1);
-		return NULL;
-	}
-
-	return fsd->real_fops;
-}
-EXPORT_SYMBOL_GPL(debugfs_real_fops);
-
 enum dbgfs_get_mode {
 	DBGFS_GET_ALREADY,
 	DBGFS_GET_REGULAR,
@@ -302,15 +285,13 @@ static int debugfs_locked_down(struct inode *inode,
 static int open_proxy_open(struct inode *inode, struct file *filp)
 {
 	struct dentry *dentry = F_DENTRY(filp);
-	const struct file_operations *real_fops = NULL;
+	const struct file_operations *real_fops = DEBUGFS_I(inode)->real_fops;
 	int r;
 
 	r = __debugfs_file_get(dentry, DBGFS_GET_REGULAR);
 	if (r)
 		return r == -EIO ? -ENOENT : r;
 
-	real_fops = debugfs_real_fops(filp);
-
 	r = debugfs_locked_down(inode, filp, real_fops);
 	if (r)
 		goto out;
@@ -352,7 +333,6 @@ static ret_type full_proxy_ ## name(proto)				\
 {									\
 	struct dentry *dentry = F_DENTRY(filp);				\
 	struct debugfs_fsdata *fsd = dentry->d_fsdata;			\
-	const struct file_operations *real_fops;			\
 	ret_type r;							\
 									\
 	if (!(fsd->methods & bit))					\
@@ -360,14 +340,13 @@ static ret_type full_proxy_ ## name(proto)				\
 	r = debugfs_file_get(dentry);					\
 	if (unlikely(r))						\
 		return r;						\
-	real_fops = debugfs_real_fops(filp);				\
-	r = real_fops->name(args);					\
+	r = fsd->real_fops->name(args);					\
 	debugfs_file_put(dentry);					\
 	return r;							\
 }
 
-#define FULL_PROXY_FUNC_BOTH(name, ret_type, filp, proto, args, bit, ret)	\
-static ret_type full_proxy_ ## name(proto)				\
+#define SHORT_PROXY_FUNC(name, ret_type, filp, proto, args, bit, ret)	\
+static ret_type short_proxy_ ## name(proto)				\
 {									\
 	struct dentry *dentry = F_DENTRY(filp);				\
 	struct debugfs_fsdata *fsd = dentry->d_fsdata;			\
@@ -378,27 +357,38 @@ static ret_type full_proxy_ ## name(proto)				\
 	r = debugfs_file_get(dentry);					\
 	if (unlikely(r))						\
 		return r;						\
-	if (fsd->real_fops)						\
-		r = fsd->real_fops->name(args);				\
-	else								\
-		r = fsd->short_fops->name(args);			\
+	r = fsd->short_fops->name(args);				\
 	debugfs_file_put(dentry);					\
 	return r;							\
 }
 
-FULL_PROXY_FUNC_BOTH(llseek, loff_t, filp,
-		     PROTO(struct file *filp, loff_t offset, int whence),
-		     ARGS(filp, offset, whence), HAS_LSEEK, -ESPIPE);
+SHORT_PROXY_FUNC(llseek, loff_t, filp,
+		PROTO(struct file *filp, loff_t offset, int whence),
+		ARGS(filp, offset, whence), HAS_LSEEK, -ESPIPE);
 
-FULL_PROXY_FUNC_BOTH(read, ssize_t, filp,
-		     PROTO(struct file *filp, char __user *buf, size_t size,
-			   loff_t *ppos),
-		     ARGS(filp, buf, size, ppos), HAS_READ, -EINVAL);
+FULL_PROXY_FUNC(llseek, loff_t, filp,
+		PROTO(struct file *filp, loff_t offset, int whence),
+		ARGS(filp, offset, whence), HAS_LSEEK, -ESPIPE);
 
-FULL_PROXY_FUNC_BOTH(write, ssize_t, filp,
-		     PROTO(struct file *filp, const char __user *buf,
-			   size_t size, loff_t *ppos),
-		     ARGS(filp, buf, size, ppos), HAS_WRITE, -EINVAL);
+SHORT_PROXY_FUNC(read, ssize_t, filp,
+		PROTO(struct file *filp, char __user *buf, size_t size,
+			loff_t *ppos),
+		ARGS(filp, buf, size, ppos), HAS_READ, -EINVAL);
+
+FULL_PROXY_FUNC(read, ssize_t, filp,
+		PROTO(struct file *filp, char __user *buf, size_t size,
+			loff_t *ppos),
+		ARGS(filp, buf, size, ppos), HAS_READ, -EINVAL);
+
+SHORT_PROXY_FUNC(write, ssize_t, filp,
+		PROTO(struct file *filp, const char __user *buf,
+			size_t size, loff_t *ppos),
+		ARGS(filp, buf, size, ppos), HAS_WRITE, -EINVAL);
+
+FULL_PROXY_FUNC(write, ssize_t, filp,
+		PROTO(struct file *filp, const char __user *buf,
+			size_t size, loff_t *ppos),
+		ARGS(filp, buf, size, ppos), HAS_WRITE, -EINVAL);
 
 FULL_PROXY_FUNC(unlocked_ioctl, long, filp,
 		PROTO(struct file *filp, unsigned int cmd, unsigned long arg),
@@ -410,22 +400,21 @@ static __poll_t full_proxy_poll(struct file *filp,
 	struct dentry *dentry = F_DENTRY(filp);
 	struct debugfs_fsdata *fsd = dentry->d_fsdata;
 	__poll_t r = 0;
-	const struct file_operations *real_fops;
 
 	if (!(fsd->methods & HAS_POLL))
 		return DEFAULT_POLLMASK;
 	if (debugfs_file_get(dentry))
 		return EPOLLHUP;
 
-	real_fops = debugfs_real_fops(filp);
-	r = real_fops->poll(filp, wait);
+	r = fsd->real_fops->poll(filp, wait);
 	debugfs_file_put(dentry);
 	return r;
 }
 
-static int full_proxy_release(struct inode *inode, struct file *filp)
+static int full_proxy_release(struct inode *inode, struct file *file)
 {
-	const struct file_operations *real_fops = debugfs_real_fops(filp);
+	struct debugfs_fsdata *fsd = F_DENTRY(file)->d_fsdata;
+	const struct file_operations *real_fops = fsd->real_fops;
 	int r = 0;
 
 	/*
@@ -435,7 +424,7 @@ static int full_proxy_release(struct inode *inode, struct file *filp)
 	 * ->i_private is still being meaningful here.
 	 */
 	if (real_fops->release)
-		r = real_fops->release(inode, filp);
+		r = real_fops->release(inode, file);
 
 	fops_put(real_fops);
 	return r;
@@ -517,9 +506,9 @@ static int full_proxy_open_short(struct inode *inode, struct file *filp)
 
 const struct file_operations debugfs_full_short_proxy_file_operations = {
 	.open = full_proxy_open_short,
-	.llseek = full_proxy_llseek,
-	.read = full_proxy_read,
-	.write = full_proxy_write,
+	.llseek = short_proxy_llseek,
+	.read = short_proxy_read,
+	.write = short_proxy_write,
 };
 
 ssize_t debugfs_attr_read(struct file *file, char __user *buf,
diff --git a/include/linux/debugfs.h b/include/linux/debugfs.h
index fa2568b4380d..a420152105d0 100644
--- a/include/linux/debugfs.h
+++ b/include/linux/debugfs.h
@@ -162,7 +162,6 @@ void debugfs_remove(struct dentry *dentry);
 
 void debugfs_lookup_and_remove(const char *name, struct dentry *parent);
 
-const struct file_operations *debugfs_real_fops(const struct file *filp);
 const void *debugfs_get_aux(const struct file *file);
 
 int debugfs_file_get(struct dentry *dentry);
@@ -329,7 +328,6 @@ static inline void debugfs_lookup_and_remove(const char *name,
 					     struct dentry *parent)
 { }
 
-const struct file_operations *debugfs_real_fops(const struct file *filp);
 void *debugfs_get_aux(const struct file *file);
 
 static inline int debugfs_file_get(struct dentry *dentry)
-- 
2.39.5


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

* Re: (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops
  2025-07-02 21:14 ` [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Al Viro
  2025-07-02 21:24   ` [PATCH 07/11] debugfs: split short and full proxy wrappers, kill debugfs_real_fops() Al Viro
@ 2025-07-02 23:19   ` Jens Axboe
  2025-07-03  0:23     ` Al Viro
  2025-07-04 15:34   ` Mark Brown
  2 siblings, 1 reply; 8+ messages in thread
From: Jens Axboe @ 2025-07-02 23:19 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Al Viro; +Cc: linux-fsdevel, dri-devel


On Wed, 02 Jul 2025 22:14:08 +0100, Al Viro wrote:
> When debugfs file has been created by debugfs_create_file_unsafe(),
> we do need the file_operations methods to use debugfs_file_{get,put}()
> to prevent concurrent removal; for files created by debugfs_create_file()
> that is done in the wrappers that call underlying methods, so there's
> no point whatsoever duplicating that in the underlying methods themselves.
> 
> 
> [...]

Applied, thanks!

[10/11] blk-mq-debugfs: use debugfs_get_aux()
        commit: c25885fc939f29200cccb58ffdb920a91ec62647

Best regards,
-- 
Jens Axboe




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

* Re: (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops
  2025-07-02 23:19   ` (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Jens Axboe
@ 2025-07-03  0:23     ` Al Viro
  2025-07-03  0:56       ` Jens Axboe
  2025-07-03 11:37       ` Greg Kroah-Hartman
  0 siblings, 2 replies; 8+ messages in thread
From: Al Viro @ 2025-07-03  0:23 UTC (permalink / raw)
  To: Jens Axboe; +Cc: Greg Kroah-Hartman, linux-fsdevel, dri-devel

On Wed, Jul 02, 2025 at 05:19:12PM -0600, Jens Axboe wrote:
> 
> On Wed, 02 Jul 2025 22:14:08 +0100, Al Viro wrote:
> > When debugfs file has been created by debugfs_create_file_unsafe(),
> > we do need the file_operations methods to use debugfs_file_{get,put}()
> > to prevent concurrent removal; for files created by debugfs_create_file()
> > that is done in the wrappers that call underlying methods, so there's
> > no point whatsoever duplicating that in the underlying methods themselves.
> > 
> > 
> > [...]
> 
> Applied, thanks!
> 
> [10/11] blk-mq-debugfs: use debugfs_get_aux()
>         commit: c25885fc939f29200cccb58ffdb920a91ec62647

Umm...  That sucker depends upon the previous commit - you'll
need to cast debugfs_get_aux() result to void * without that...

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

* Re: (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops
  2025-07-03  0:23     ` Al Viro
@ 2025-07-03  0:56       ` Jens Axboe
  2025-07-03 11:37       ` Greg Kroah-Hartman
  1 sibling, 0 replies; 8+ messages in thread
From: Jens Axboe @ 2025-07-03  0:56 UTC (permalink / raw)
  To: Al Viro; +Cc: Greg Kroah-Hartman, linux-fsdevel, dri-devel

On 7/2/25 6:23 PM, Al Viro wrote:
> On Wed, Jul 02, 2025 at 05:19:12PM -0600, Jens Axboe wrote:
>>
>> On Wed, 02 Jul 2025 22:14:08 +0100, Al Viro wrote:
>>> When debugfs file has been created by debugfs_create_file_unsafe(),
>>> we do need the file_operations methods to use debugfs_file_{get,put}()
>>> to prevent concurrent removal; for files created by debugfs_create_file()
>>> that is done in the wrappers that call underlying methods, so there's
>>> no point whatsoever duplicating that in the underlying methods themselves.
>>>
>>>
>>> [...]
>>
>> Applied, thanks!
>>
>> [10/11] blk-mq-debugfs: use debugfs_get_aux()
>>         commit: c25885fc939f29200cccb58ffdb920a91ec62647
> 
> Umm...  That sucker depends upon the previous commit - you'll
> need to cast debugfs_get_aux() result to void * without that...

Gah ok - wasn't cleear since I wasn't CC'ed on the series, just the
single patch. If it's a single patch, I'm assuming it's good to go
if it looks good.

I'll just drop it.

-- 
Jens Axboe


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

* Re: (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops
  2025-07-03  0:23     ` Al Viro
  2025-07-03  0:56       ` Jens Axboe
@ 2025-07-03 11:37       ` Greg Kroah-Hartman
  2025-07-03 15:10         ` Al Viro
  1 sibling, 1 reply; 8+ messages in thread
From: Greg Kroah-Hartman @ 2025-07-03 11:37 UTC (permalink / raw)
  To: Al Viro; +Cc: Jens Axboe, linux-fsdevel, dri-devel

On Thu, Jul 03, 2025 at 01:23:29AM +0100, Al Viro wrote:
> On Wed, Jul 02, 2025 at 05:19:12PM -0600, Jens Axboe wrote:
> > 
> > On Wed, 02 Jul 2025 22:14:08 +0100, Al Viro wrote:
> > > When debugfs file has been created by debugfs_create_file_unsafe(),
> > > we do need the file_operations methods to use debugfs_file_{get,put}()
> > > to prevent concurrent removal; for files created by debugfs_create_file()
> > > that is done in the wrappers that call underlying methods, so there's
> > > no point whatsoever duplicating that in the underlying methods themselves.
> > > 
> > > 
> > > [...]
> > 
> > Applied, thanks!
> > 
> > [10/11] blk-mq-debugfs: use debugfs_get_aux()
> >         commit: c25885fc939f29200cccb58ffdb920a91ec62647
> 
> Umm...  That sucker depends upon the previous commit - you'll
> need to cast debugfs_get_aux() result to void * without that...

Wait, what "previous commit" this is patch 01/11 of the series?

I'm all for you just taking this through your trees if it depends on
something else that is there, but that wasn't obvious, sorry.

greg k-h

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

* Re: (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops
  2025-07-03 11:37       ` Greg Kroah-Hartman
@ 2025-07-03 15:10         ` Al Viro
  0 siblings, 0 replies; 8+ messages in thread
From: Al Viro @ 2025-07-03 15:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: Jens Axboe, linux-fsdevel, dri-devel

On Thu, Jul 03, 2025 at 01:37:58PM +0200, Greg Kroah-Hartman wrote:
> On Thu, Jul 03, 2025 at 01:23:29AM +0100, Al Viro wrote:
> > On Wed, Jul 02, 2025 at 05:19:12PM -0600, Jens Axboe wrote:
> > > 
> > > On Wed, 02 Jul 2025 22:14:08 +0100, Al Viro wrote:
> > > > When debugfs file has been created by debugfs_create_file_unsafe(),
> > > > we do need the file_operations methods to use debugfs_file_{get,put}()
> > > > to prevent concurrent removal; for files created by debugfs_create_file()
> > > > that is done in the wrappers that call underlying methods, so there's
> > > > no point whatsoever duplicating that in the underlying methods themselves.
> > > > 
> > > > 
> > > > [...]
> > > 
> > > Applied, thanks!
> > > 
> > > [10/11] blk-mq-debugfs: use debugfs_get_aux()
       ^^^^^
> > >         commit: c25885fc939f29200cccb58ffdb920a91ec62647
> > 
> > Umm...  That sucker depends upon the previous commit - you'll
> > need to cast debugfs_get_aux() result to void * without that...
> 
> Wait, what "previous commit" this is patch 01/11 of the series?

Jens replied to 01/11 saying that he'd grabbed 10/11, unfortunately
without 09/11...

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

* Re: (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops
  2025-07-02 21:14 ` [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Al Viro
  2025-07-02 21:24   ` [PATCH 07/11] debugfs: split short and full proxy wrappers, kill debugfs_real_fops() Al Viro
  2025-07-02 23:19   ` (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Jens Axboe
@ 2025-07-04 15:34   ` Mark Brown
  2 siblings, 0 replies; 8+ messages in thread
From: Mark Brown @ 2025-07-04 15:34 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Al Viro; +Cc: linux-fsdevel, dri-devel

On Wed, 02 Jul 2025 22:14:08 +0100, Al Viro wrote:
> When debugfs file has been created by debugfs_create_file_unsafe(),
> we do need the file_operations methods to use debugfs_file_{get,put}()
> to prevent concurrent removal; for files created by debugfs_create_file()
> that is done in the wrappers that call underlying methods, so there's
> no point whatsoever duplicating that in the underlying methods themselves.
> 
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap.git for-next

Thanks!

[03/11] regmap: get rid of redundant debugfs_file_{get,put}()
        commit: 9f711c9321cffe3e03709176873c277fa911c366

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


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

end of thread, other threads:[~2025-07-04 15:35 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20250702211305.GE1880847@ZenIV>
2025-07-02 21:14 ` [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Al Viro
2025-07-02 21:24   ` [PATCH 07/11] debugfs: split short and full proxy wrappers, kill debugfs_real_fops() Al Viro
2025-07-02 23:19   ` (subset) [PATCH 01/11] zynqmp: don't bother with debugfs_file_{get,put}() in proxied fops Jens Axboe
2025-07-03  0:23     ` Al Viro
2025-07-03  0:56       ` Jens Axboe
2025-07-03 11:37       ` Greg Kroah-Hartman
2025-07-03 15:10         ` Al Viro
2025-07-04 15:34   ` Mark Brown

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).