Documentation/gpu: resolve kerneldoc duplicate declaration warning
Subsystems (3)
PATCH 1/1 Documentation/gpu: resolve kerneldoc duplicate declaration warning
From: Sanjay Chitroda <[email protected]>
kernel-doc build with make htmldocs reports following WARNINGS.
Documentation/gpu/drm-kms:360: ../drivers/gpu/drm/drm_fourcc.c:397:
WARNING: Duplicate C declaration, also defined at gpu/drm-kms:35. Declaration is '.. c:function::
const struct drm_format_info * drm_format_info (u32 format)'.
Documentation/gpu/drm-kms:491: ../drivers/gpu/drm/drm_modeset_lock.c:377:
WARNING: Duplicate C declaration, also defined at gpu/drm-kms:48. Declaration is '.. c:function:: int drm_modeset_lock
(struct drm_modeset_lock *lock, struct drm_modeset_acquire_ctx *ctx)'.
Documentation/gpu/drm-uapi:607: ../drivers/gpu/drm/drm_ioctl.c:923:
WARNING: Duplicate C declaration, also defined at gpu/drm-uapi:69. Declaration is '.. c:function::
bool drm_ioctl_flags (unsigned int nr, unsigned int *flags)'.
Add :no-identifiers: to prevent duplicate identifier generation and keep the function documented at its implementation site.
No functional change.
--- Documentation/gpu/drm-kms.rst | 2 ++ Documentation/gpu/drm-uapi.rst | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-)
Documentation/gpu/drm-kms.rst +2 -0
@@ -356,6 +356,7 @@ Format Functions Reference .. kernel-doc:: include/drm/drm_fourcc.h :internal: + :no-identifiers: drm_format_info .. kernel-doc:: drivers/gpu/drm/drm_fourcc.c :export:
@@ -487,6 +488,7 @@ KMS Locking .. kernel-doc:: include/drm/drm_modeset_lock.h :internal: + :no-identifiers: drm_modeset_lock .. kernel-doc:: drivers/gpu/drm/drm_modeset_lock.c :export:
Documentation/gpu/drm-uapi.rst +2 -1
@@ -603,6 +603,7 @@ DRM specific patterns. Note that ENOTTY has the slightly unintuitive meaning of .. kernel-doc:: include/drm/drm_ioctl.h :internal: + :no-identifiers: drm_ioctl_flags .. kernel-doc:: drivers/gpu/drm/drm_ioctl.c :export:
@@ -761,4 +762,4 @@ Stable uAPI events From ``drivers/gpu/drm/scheduler/gpu_scheduler_trace.h`` .. kernel-doc:: drivers/gpu/drm/scheduler/gpu_scheduler_trace.h - :doc: uAPI trace events + :doc: uAPI trace events
Signature · 1 line
2.34.1
Quoted 67 lines · Sanjay Chitroda
From: Sanjay Chitroda <[email protected]>
kernel-doc build with
make htmldocsreports following WARNINGS.
Documentation/gpu/drm-kms:360:../drivers/gpu/drm/drm_fourcc.c:397:
WARNING: Duplicate C declaration, also defined at gpu/drm-kms:35. Declaration is '.. c:function::
const structdrm_format_info*drm_format_info(u32 format)'.
Documentation/gpu/drm-kms:491:../drivers/gpu/drm/drm_modeset_lock.c:377:
WARNING: Duplicate C declaration, also defined at gpu/drm-kms:48. Declaration is '.. c:function:: intdrm_modeset_lock
(structdrm_modeset_lock*lock, structdrm_modeset_acquire_ctx*ctx)'.
Documentation/gpu/drm-uapi:607:../drivers/gpu/drm/drm_ioctl.c:923:
WARNING: Duplicate C declaration, also defined at gpu/drm-uapi:69. Declaration is '.. c:function::
booldrm_ioctl_flags(unsigned int nr, unsigned int *flags)'.Add :no-identifiers: to prevent duplicate identifier generation and keep the function documented at its implementation site.
No functional change.
Signed-off-by Sanjay Chitroda <[email protected]>---
Documentation/gpu/drm-kms.rst| 2 ++Documentation/gpu/drm-uapi.rst| 3 ++-2 files changed, 4 insertions(+), 1 deletion(-)Documentation/gpu/drm-kms.rst +0
-0@@ -356,6 +356,7 @@ Format Functions Reference.. kernel-doc::
include/drm/drm_fourcc.h
:internal:
+ :no-identifiers:drm_format_info.. kernel-doc::
drivers/gpu/drm/drm_fourcc.c
:export:Documentation/gpu/drm-kms.rst +0
-0@@ -487,6 +488,7 @@ KMS Locking.. kernel-doc::
include/drm/drm_modeset_lock.h
:internal:
+ :no-identifiers:drm_modeset_lock.. kernel-doc::
drivers/gpu/drm/drm_modeset_lock.c
:export:Documentation/gpu/drm-uapi.rst +0
-0@@ -603,6 +603,7 @@ DRM specific patterns. Note that ENOTTY has the slightly unintuitive meaning of.. kernel-doc::
include/drm/drm_ioctl.h
:internal:
+ :no-identifiers:drm_ioctl_flags.. kernel-doc::
drivers/gpu/drm/drm_ioctl.c
:export:Documentation/gpu/drm-uapi.rst +0
-0@@ -761,4 +762,4 @@ Stable uAPI eventsFrom ``drivers/gpu/drm/scheduler/gpu_scheduler_trace.h``
.. kernel-doc::
drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
Documentation/gpu/drm-uapi.rst Stable uAPI events · line 765
Quoted 3 lines
Documentation/gpu/drm-uapi.rst +1
-1- :doc: uAPI trace events + :doc: uAPI trace events
Hi all,
Requesting your input on the change.
Is there anything that I missed or required correction ?
Hello,
Quoted 74 lines · Sanjay Chitroda
Quoted 67 lines
From: Sanjay Chitroda <[email protected]>
kernel-doc build with
make htmldocsreports following WARNINGS.
Documentation/gpu/drm-kms:360:../drivers/gpu/drm/drm_fourcc.c:397:
WARNING: Duplicate C declaration, also defined at gpu/drm-kms:35. Declaration is '.. c:function::
const structdrm_format_info*drm_format_info(u32 format)'.
Documentation/gpu/drm-kms:491:../drivers/gpu/drm/drm_modeset_lock.c:377:
WARNING: Duplicate C declaration, also defined at gpu/drm-kms:48. Declaration is '.. c:function:: intdrm_modeset_lock
(structdrm_modeset_lock*lock, structdrm_modeset_acquire_ctx*ctx)'.
Documentation/gpu/drm-uapi:607:../drivers/gpu/drm/drm_ioctl.c:923:
WARNING: Duplicate C declaration, also defined at gpu/drm-uapi:69. Declaration is '.. c:function::
booldrm_ioctl_flags(unsigned int nr, unsigned int *flags)'.Add :no-identifiers: to prevent duplicate identifier generation and keep the function documented at its implementation site.
No functional change.
Signed-off-by Sanjay Chitroda <[email protected]>---
Documentation/gpu/drm-kms.rst| 2 ++Documentation/gpu/drm-uapi.rst| 3 ++-2 files changed, 4 insertions(+), 1 deletion(-)Documentation/gpu/drm-kms.rst +0
-0@@ -356,6 +356,7 @@ Format Functions Reference.. kernel-doc::
include/drm/drm_fourcc.h
:internal:
+ :no-identifiers:drm_format_info.. kernel-doc::
drivers/gpu/drm/drm_fourcc.c
:export:Documentation/gpu/drm-kms.rst +0
-0@@ -487,6 +488,7 @@ KMS Locking.. kernel-doc::
include/drm/drm_modeset_lock.h
:internal:
+ :no-identifiers:drm_modeset_lock.. kernel-doc::
drivers/gpu/drm/drm_modeset_lock.c
:export:Documentation/gpu/drm-uapi.rst +0
-0@@ -603,6 +603,7 @@ DRM specific patterns. Note that ENOTTY has the slightly unintuitive meaning of.. kernel-doc::
include/drm/drm_ioctl.h
:internal:
+ :no-identifiers:drm_ioctl_flags.. kernel-doc::
drivers/gpu/drm/drm_ioctl.c
:export:Documentation/gpu/drm-uapi.rst +0
-0@@ -761,4 +762,4 @@ Stable uAPI eventsFrom ``drivers/gpu/drm/scheduler/gpu_scheduler_trace.h``
.. kernel-doc::
drivers/gpu/drm/scheduler/gpu_scheduler_trace.hDocumentation/gpu/drm-uapi.rst Stable uAPI events · line 765
Quoted 3 lines
Documentation/gpu/drm-uapi.rst +1
-1- :doc: uAPI trace events + :doc: uAPI trace eventsHi all,
Quoted 2 lines
Requesting your input on the change.
Is there anything that I missed or required correction ?
Your patch is ignored because there is no duplicate in those identifiers. As you are well aware of, you can have a function and a struct of the same name.
It is a long-standing bug (almost 6 years now!) in Sphinx C-domain support.
Please have a look at my earlier email:
https://lore.kernel.org/[email protected]/
It is dated "26 Mar 2024", but the issue remains unresolved.
I'd appreciate if you could make some contribution for fixing the Sphinx bug.
Regards, Akira
PS: Please ignore several typos I made in the earlier email ;-)