Skip to contentSkip to conversation

x86/platform/intel/quark: fix incorrect kernel-doc comment syntax in files

PATCH Applied Aditya Srivastava 3 participants 3 messages Mar 30, 2021 – Apr 10, 2021

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86/platform/intel/quark: fix incorrect kernel-doc comment syntax in files

The opening comment mark '/**' is used for highlighting the beginning of kernel-doc comments.
There are certain files in arch/x86/platform/intel-quark, which follow this syntax, but the content inside does not comply with kernel-doc. Such lines were probably not meant for kernel-doc parsing, but are parsed due to the presence of kernel-doc like comment syntax(i.e, '/**'), which causes unexpected warnings from kernel-doc.

E.g., presence of kernel-doc like comment in the header lines for arch/x86/platform/intel-quark/imr.c causes these warnings:
"warning: Function parameter or member 'fmt' not described in 'pr_fmt'" "warning: expecting prototype for c(). Prototype was for pr_fmt() instead"

Similarly for arch/x86/platform/intel-quark/imr_selftest.c too.

Provide a simple fix by replacing these occurrences with general comment format, i.e. '/*', to prevent kernel-doc from parsing it.

---
* Applies perfectly on next-20210326

 arch/x86/platform/intel-quark/imr.c          | 2 +-
 arch/x86/platform/intel-quark/imr_selftest.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/x86/platform/intel-quark/imr.c +1 -1
index 122e0f37b1f5..d3d456925b2a 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
  * imr.c -- Intel Isolated Memory Region driver
  *
  * Copyright(c) 2013 Intel Corporation.
arch/x86/platform/intel-quark/imr_selftest.c +1 -1
index 570e3062faac..761f3689f60a 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0
-/**
+/*
  * imr_selftest.c -- Intel Isolated Memory Region self-test driver
  *
  * Copyright(c) 2013 Intel Corporation.
Signature · 6 lines
2.17.1

_______________________________________________
Linux-kernel-mentees mailing list
[email protected]
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees
reviewer Acked-by on v1 1/1
#1 lore raw
Quoted 13 lines · Aditya Srivastava

The opening comment mark '/**' is used for highlighting the beginning of kernel-doc comments.
There are certain files in arch/x86/platform/intel-quark, which follow this syntax, but the content inside does not comply with kernel-doc. Such lines were probably not meant for kernel-doc parsing, but are parsed due to the presence of kernel-doc like comment syntax(i.e, '/**'), which causes unexpected warnings from kernel-doc.

E.g., presence of kernel-doc like comment in the header lines for arch/x86/platform/intel-quark/imr.c causes these warnings:
"warning: Function parameter or member 'fmt' not described in 'pr_fmt'" "warning: expecting prototype for c(). Prototype was for pr_fmt() instead"

Quoted 6 lines

Similarly for arch/x86/platform/intel-quark/imr_selftest.c too.

Provide a simple fix by replacing these occurrences with general comment format, i.e. '/*', to prevent kernel-doc from parsing it.

Quoted 30 lines

---
* Applies perfectly on next-20210326

 arch/x86/platform/intel-quark/imr.c          | 2 +-
 arch/x86/platform/intel-quark/imr_selftest.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/x86/platform/intel-quark/imr.c +1 -1
index 122e0f37b1f5..d3d456925b2a 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
  * imr.c -- Intel Isolated Memory Region driver
  *
  * Copyright(c) 2013 Intel Corporation.
arch/x86/platform/intel-quark/imr_selftest.c +1 -1
index 570e3062faac..761f3689f60a 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0
-/**
+/*
  * imr_selftest.c -- Intel Isolated Memory Region self-test driver
  *
  * Copyright(c) 2013 Intel Corporation.
Signature · 6 lines
~Randy

_______________________________________________
Linux-kernel-mentees mailing list
[email protected]
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees
#2 lore raw

[tip: x86/cleanups] x86/platform/intel/quark: Fix incorrect kernel-doc comment syntax in files

In reply to Aditya Srivastava
The following commit has been merged into the x86/cleanups branch of tip:

The following commit has been merged into the x86/cleanups branch of tip:

Commit-ID:     0d6c8e1e246586b81cb4e6ab1a93a6d4a08a0cf9
Gitweb:        https://git.kernel.org/tip/0d6c8e1e246586b81cb4e6ab1a93a6d4a08a0cf9
Author:        Aditya Srivastava <[email protected]>
AuthorDate:    Wed, 31 Mar 2021 03:00:22 +05:30
Committer:     Thomas Gleixner <[email protected]>
CommitterDate: Sat, 10 Apr 2021 13:59:25 +02:00

x86/platform/intel/quark: Fix incorrect kernel-doc comment syntax in files

The opening comment mark '/**' is used for highlighting the beginning of kernel-doc comments.
There are certain files in arch/x86/platform/intel-quark, which follow this syntax, but the content inside does not comply with kernel-doc. Such lines were probably not meant for kernel-doc parsing, but are parsed due to the presence of kernel-doc like comment syntax(i.e, '/**'), which causes unexpected warnings from kernel-doc.

E.g., presence of kernel-doc like comment in the header lines for arch/x86/platform/intel-quark/imr.c causes these warnings:
"warning: Function parameter or member 'fmt' not described in 'pr_fmt'" "warning: expecting prototype for c(). Prototype was for pr_fmt() instead"

Similarly for arch/x86/platform/intel-quark/imr_selftest.c too.

Provide a simple fix by replacing these occurrences with general comment format, i.e. '/*', to prevent kernel-doc from parsing it.

---
 arch/x86/platform/intel-quark/imr.c          | 2 +-
 arch/x86/platform/intel-quark/imr_selftest.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/x86/platform/intel-quark/imr.c +1 -1
index 122e0f3..d3d4569 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
  * imr.c -- Intel Isolated Memory Region driver
  *
  * Copyright(c) 2013 Intel Corporation.
arch/x86/platform/intel-quark/imr_selftest.c +1 -1
index 570e306..761f368 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0
-/**
+/*
  * imr_selftest.c -- Intel Isolated Memory Region self-test driver
  *
  * Copyright(c) 2013 Intel Corporation.