Skip to contentSkip to conversation

drm/vram-helper: fix kernel-doc warnings

PATCH In review Randy Dunlap 3 participants 9 messages Jan 6, 2024 – Jan 9, 2024

Subsystems (3)
lore
Share & tools
lore

Randy Dunlap

author reviewer
#0 lore raw

PATCH v2 1/1 drm/vram-helper: fix kernel-doc warnings

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
* DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

 include/drm/drm_gem_vram_helper.h |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
include/drm/drm_gem_vram_helper.h +1 -2
diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
 				     struct drm_plane_state *old_state);
 
 /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \
  *	Initializes struct drm_plane_helper_funcs for VRAM handling
  *
  * Drivers may use GEM BOs as VRAM helpers for the framebuffer memory. This
@@ -170,7 +170,6 @@ void drm_gem_vram_simple_display_pipe_cl
  * @vram_base:	Base address of the managed video memory
  * @vram_size:	Size of the managed video memory in bytes
  * @bdev:	The TTM BO device.
- * @funcs:	TTM BO functions
  *
  * The fields &struct drm_vram_mm.vram_base and
  * &struct drm_vram_mm.vrm_size are managed by VRAM MM, but are
#1 lore raw

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 29 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
* DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 129

Quoted 5 lines
include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
  				     struct drm_plane_state *old_state);
 
  /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

Best regards
Thomas

Quoted 11 lines
include/drm/drm_gem_vram_helper.h +0 -1
   *	Initializes struct drm_plane_helper_funcs for VRAM handling
   *
   * Drivers may use GEM BOs as VRAM helpers for the framebuffer memory. This
@@ -170,7 +170,6 @@ void drm_gem_vram_simple_display_pipe_cl
   * @vram_base:	Base address of the managed video memory
   * @vram_size:	Size of the managed video memory in bytes
   * @bdev:	The TTM BO device.
- * @funcs:	TTM BO functions
   *
   * The fields &struct drm_vram_mm.vram_base and
   * &struct drm_vram_mm.vrm_size are managed by VRAM MM, but are
Signature · 6 lines
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstrasse 146, 90461 Nuernberg, Germany
GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman
HRB 36809 (AG Nuernberg)
author reviewer
#2 lore raw

Hi Thomas,

Quoted 30 lines · Thomas Zimmermann

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 25 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
  * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--

  1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 11 lines

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 128

Quoted 8 lines

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
                        struct drm_plane_state *old_state);
     /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

There are no doc syntax changes that I know of. This is not new syntax. It has been around since 2014:
cbb4d3e6510b ("scripts/kernel-doc: handle object-like macros")

"define OBJ_LIKE_MACRO" is used 2 other times in include/drm/:

drm_fb_helper.h:

/**
* define DRM_FB_HELPER_DEFAULT_OPS - helper define for drm drivers *
* Helper define to register default implementations of drm_fb_helper
* functions. To be used in struct fb_ops of drm drivers. */

drm_gem_vram_helper.h: (the file being patched here)

/**
* define DRM_GEM_VRAM_DRIVER - default callback functions for \
&struct drm_driver
*
* Drivers that use VRAM MM and GEM VRAM can use this macro to initialize
* &struct drm_driver with default functions.
*/

Quoted 13 lines
Quoted 12 lines
include/drm/drm_gem_vram_helper.h +0 -1
    *    Initializes struct drm_plane_helper_funcs for VRAM handling
    *
    * Drivers may use GEM BOs as VRAM helpers for the framebuffer memory. This
@@ -170,7 +170,6 @@ void drm_gem_vram_simple_display_pipe_cl
    * @vram_base:    Base address of the managed video memory
    * @vram_size:    Size of the managed video memory in bytes
    * @bdev:    The TTM BO device.
- * @funcs:    TTM BO functions
    *
    * The fields &struct drm_vram_mm.vram_base and
    * &struct drm_vram_mm.vrm_size are managed by VRAM MM, but are
Signature · 1 line
#Randy
#3 lore raw
Quoted 45 lines · Randy Dunlap

Hi Thomas,

Quoted 30 lines · Thomas Zimmermann

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 25 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
  * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--

  1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 11 lines

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 128

Quoted 8 lines

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
                        struct drm_plane_state *old_state);
     /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

Quoted 3 lines

There are no doc syntax changes that I know of. This is not new syntax. It has been around since 2014:
cbb4d3e6510b ("scripts/kernel-doc: handle object-like macros")

I had no idea this exists, thanks a lot for this TIL :-)

I guess the issue here is that this exists, yay, but it's not documented with the other here:

https://dri.freedesktop.org/docs/drm/doc-guide/kernel-doc.html#structure-union-and-enumeration-documentation

I guess a patch to kernel-doc.rst would be great. Adding some kernel-doc folks.

Cheers, Sima

Signature · 3 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
#4 lore raw
Quoted 53 lines · Daniel Vetter
Quoted 45 lines · Randy Dunlap

Hi Thomas,

Quoted 30 lines · Thomas Zimmermann

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 25 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
* DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 11 lines

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 128

Quoted 8 lines

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
                       struct drm_plane_state *old_state);
    /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

Quoted 3 lines

There are no doc syntax changes that I know of. This is not new syntax. It has been around since 2014:
cbb4d3e6510b ("scripts/kernel-doc: handle object-like macros")

I had no idea this exists, thanks a lot for this TIL :-)

Quoted 7 lines

I guess the issue here is that this exists, yay, but it's not documented with the other here:

https://dri.freedesktop.org/docs/drm/doc-guide/kernel-doc.html#structure-union-and-enumeration-documentation

I guess a patch to kernel-doc.rst would be great. Adding some kernel-doc folks.

Ok I went ahead and typed that patch (just we don't waste effort), just waiting for the sphinx build to finish to make sure it looks nice before I send out the patch.
-Sima

Signature · 3 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
author reviewer
#5 lore raw
Quoted 59 lines · Daniel Vetter
Quoted 58 lines · Daniel Vetter
Quoted 45 lines · Randy Dunlap

Hi Thomas,

Quoted 30 lines · Thomas Zimmermann

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 25 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
* DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 11 lines

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 128

Quoted 8 lines

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
                       struct drm_plane_state *old_state);
    /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

Quoted 3 lines

There are no doc syntax changes that I know of. This is not new syntax. It has been around since 2014:
cbb4d3e6510b ("scripts/kernel-doc: handle object-like macros")

I had no idea this exists, thanks a lot for this TIL :-)

I guess the issue here is that this exists, yay, but it's not documented with the other here:

https://dri.freedesktop.org/docs/drm/doc-guide/kernel-doc.html#structure-union-and-enumeration-documentation

Quoted 7 lines
Quoted 2 lines

I guess a patch to kernel-doc.rst would be great. Adding some kernel-doc folks.

Ok I went ahead and typed that patch (just we don't waste effort), just waiting for the sphinx build to finish to make sure it looks nice before I send out the patch.
-Sima

I sent one a few days ago:

https://lore.kernel.org/lkml/[email protected]/

Signature · 1 line
#Randy
#6 lore raw
Quoted 66 lines · Randy Dunlap
Quoted 62 lines · Daniel Vetter
Quoted 60 lines · Daniel Vetter
Quoted 45 lines · Randy Dunlap

Hi Thomas,

Quoted 30 lines · Thomas Zimmermann

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 25 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
* DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 11 lines

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 128

Quoted 8 lines

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
                       struct drm_plane_state *old_state);
    /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

Quoted 3 lines

There are no doc syntax changes that I know of. This is not new syntax. It has been around since 2014:
cbb4d3e6510b ("scripts/kernel-doc: handle object-like macros")

I had no idea this exists, thanks a lot for this TIL :-)

I guess the issue here is that this exists, yay, but it's not documented with the other here:

https://dri.freedesktop.org/docs/drm/doc-guide/kernel-doc.html#structure-union-and-enumeration-documentation

I guess a patch to kernel-doc.rst would be great. Adding some kernel-doc folks.

Quoted 8 lines
Quoted 4 lines

Ok I went ahead and typed that patch (just we don't waste effort), just waiting for the sphinx build to finish to make sure it looks nice before I send out the patch.
-Sima

I sent one a few days ago:

https://lore.kernel.org/lkml/[email protected]/

Could you please also add documentation for function-like macros, since that's also missing? With that acked-by: me.

Cheers!

Signature · 3 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
author reviewer
#7 lore raw
Quoted 72 lines · Daniel Vetter
Quoted 71 lines · Randy Dunlap
Quoted 66 lines · Daniel Vetter
Quoted 53 lines · Daniel Vetter
Quoted 45 lines · Randy Dunlap

Hi Thomas,

Quoted 30 lines · Thomas Zimmermann

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 25 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
* DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 11 lines

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 128

Quoted 8 lines

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
                       struct drm_plane_state *old_state);
    /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

Quoted 3 lines

There are no doc syntax changes that I know of. This is not new syntax. It has been around since 2014:
cbb4d3e6510b ("scripts/kernel-doc: handle object-like macros")

I had no idea this exists, thanks a lot for this TIL :-)

Quoted 7 lines

I guess the issue here is that this exists, yay, but it's not documented with the other here:

https://dri.freedesktop.org/docs/drm/doc-guide/kernel-doc.html#structure-union-and-enumeration-documentation

I guess a patch to kernel-doc.rst would be great. Adding some kernel-doc folks.

Ok I went ahead and typed that patch (just we don't waste effort), just waiting for the sphinx build to finish to make sure it looks nice before I send out the patch.
-Sima

Quoted 8 lines
Quoted 3 lines

I sent one a few days ago:

https://lore.kernel.org/lkml/[email protected]/

Could you please also add documentation for function-like macros, since that's also missing? With that acked-by: me.

Cheers!

This is already present:

Function documentation
----------------------

The general format of a function and function-like macro kernel-doc comment is::

/**
* function_name() - Brief description of function.
* @arg1: Describe the first argument.
* @arg2: Describe the second argument.
* One can provide multiple line descriptions
* for arguments.

but the way that you did it makes sense also.

Signature · 1 line
#Randy
Acked-by
#8 lore raw
Quoted 100 lines · Randy Dunlap
Quoted 72 lines · Daniel Vetter
Quoted 71 lines · Randy Dunlap
Quoted 66 lines · Daniel Vetter
Quoted 53 lines · Daniel Vetter
Quoted 45 lines · Randy Dunlap

Hi Thomas,

Quoted 30 lines · Thomas Zimmermann

Hi,

thanks for the fix.

Am 06.01.24 um 04:29 schrieb Randy Dunlap:

Quoted 25 lines

Remove the @funcs entry from struct drm_vram_mm to quieten the kernel-doc warning.

Use the "define" kernel-doc keyword and an '\' line continuation to fix another kernel-doc warning.

drm_gem_vram_helper.h:129: warning: missing initial short description on line:
* DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
drm_gem_vram_helper.h:185: warning: Excess struct member 'funcs' description in 'drm_vram_mm'

Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Thomas Zimmermann <[email protected]>

---
v2: Add commit description

base-commit: 610a9b8f49fbcf1100716370d3b5f6f884a2835a

  include/drm/drm_gem_vram_helper.h |    3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 11 lines

include/drm/drm_gem_vram_helper.h drm_gem_vram_plane_helper_cleanup_fb(str · line 128

Quoted 8 lines

diff -- a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h

include/drm/drm_gem_vram_helper.h +1 -1
@@ -126,7 +126,7 @@ drm_gem_vram_plane_helper_cleanup_fb(str
                       struct drm_plane_state *old_state);
    /**
- * DRM_GEM_VRAM_PLANE_HELPER_FUNCS -
+ * define DRM_GEM_VRAM_PLANE_HELPER_FUNCS - \

Did something change wrt. doc syntax? I think this used to work without warnings. About this 'define': we don't use is in another docs. Can we leave it out here or is this the new syntax?

Quoted 3 lines

There are no doc syntax changes that I know of. This is not new syntax. It has been around since 2014:
cbb4d3e6510b ("scripts/kernel-doc: handle object-like macros")

I had no idea this exists, thanks a lot for this TIL :-)

Quoted 7 lines

I guess the issue here is that this exists, yay, but it's not documented with the other here:

https://dri.freedesktop.org/docs/drm/doc-guide/kernel-doc.html#structure-union-and-enumeration-documentation

I guess a patch to kernel-doc.rst would be great. Adding some kernel-doc folks.

Ok I went ahead and typed that patch (just we don't waste effort), just waiting for the sphinx build to finish to make sure it looks nice before I send out the patch.
-Sima

Quoted 8 lines
Quoted 3 lines

I sent one a few days ago:

https://lore.kernel.org/lkml/[email protected]/

Could you please also add documentation for function-like macros, since that's also missing? With that acked-by: me.

Cheers!

This is already present:

Function documentation
----------------------

The general format of a function and function-like macro kernel-doc comment is::

/**
* function_name() - Brief description of function.
* @arg1: Describe the first argument.
* @arg2: Describe the second argument.
* One can provide multiple line descriptions
* for arguments.

Quoted 1 line

but the way that you did it makes sense also.

Ah missed that it includes wording for function-like macros. On your patch as-is:

Signature · 3 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch