Skip to contentSkip to conversation

gfs2: document ip in __gfs2_holder_init kernel-doc comment

PATCH Applied Sukrut Heroorkar 2 participants 2 messages Oct 27, 2025 – Oct 28, 2025 GFS2 file system

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gfs2: document ip in __gfs2_holder_init kernel-doc comment

Building with W=1 reports:
Warning: fs/gfs2/glock.c:1248 function parameter 'ip' not described in '__gfs2_holder_init'

The ip parameter was added when __gfs2_holder_init started saving the gfs2_glock_nq_init caller's return address to gh_ip. This makes it easier to backtrack which holder took the lock. Document @ip to silence this warning.

Fixes b016d9a84abd ("gfs2: Save ip from gfs2_glock_nq_init")
---
 fs/gfs2/glock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/gfs2/glock.c +1 -1
index 91d0afec4087..bc6f236b899c 100644
@@ -1163,7 +1163,7 @@ int gfs2_glock_get(struct gfs2_sbd *sdp, u64 number,
  * @state: the state we're requesting
  * @flags: the modifier flags
  * @gh: the holder structure
- *
+ * @ip: caller's return address for debugging
  */
 
 void __gfs2_holder_init(struct gfs2_glock *gl, unsigned int state, u16 flags,
Signature · 1 line
2.43.0
maintainer Applied
#1 lore raw
Quoted 29 lines · Sukrut Heroorkar

Building with W=1 reports:
Warning: fs/gfs2/glock.c:1248 function parameter 'ip' not described in '__gfs2_holder_init'

The ip parameter was added when __gfs2_holder_init started saving the gfs2_glock_nq_init caller's return address to gh_ip. This makes it easier to backtrack which holder took the lock. Document @ip to silence this warning.

Fixes b016d9a84abd ("gfs2: Save ip from gfs2_glock_nq_init")
---
 fs/gfs2/glock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/gfs2/glock.c +1 -2
index 91d0afec4087..bc6f236b899c 100644
@@ -1163,7 +1163,7 @@ int gfs2_glock_get(struct gfs2_sbd *sdp, u64 number,
  * @state: the state we're requesting
  * @flags: the modifier flags
  * @gh: the holder structure
- *
+ * @ip: caller's return address for debugging
  */
 
 void __gfs2_holder_init(struct gfs2_glock *gl, unsigned int state, u16 flags,
--
Quoted 2 lines

2.43.0

Applied, thanks.

Andreas