All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aditya Srivastava <yashsri421@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: yashsri421@gmail.com, lukas.bulwahn@gmail.com,
	rdunlap@infradead.org, jarkko@kernel.org,
	dave.hansen@linux.intel.com, tglx@linutronix.de,
	mingo@redhat.com, bp@alien8.de, x86@kernel.org, hpa@zytor.com,
	linux-sgx@vger.kernel.org,
	linux-kernel-mentees@lists.linuxfoundation.org,
	linux-doc@vger.kernel.org
Subject: [PATCH] x86/sgx: fix incorrect kernel-doc comment syntax in files
Date: Wed, 31 Mar 2021 02:48:13 +0530	[thread overview]
Message-ID: <20210330211813.28030-1-yashsri421@gmail.com> (raw)

The opening comment mark '/**' is used for highlighting the beginning of
kernel-doc comments.
There are certain files in arch/x86/kernel/cpu/sgx, 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/kernel/cpu/sgx/encl.h causes this warning:
"warning: expecting prototype for 2016(). Prototype was for _X86_ENCL_H() instead"

Similarly for arch/x86/kernel/cpu/sgx/arch.h too.

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

Signed-off-by: Aditya Srivastava <yashsri421@gmail.com>
---
* Applies perfectly on next-20210326

 arch/x86/kernel/cpu/sgx/arch.h | 2 +-
 arch/x86/kernel/cpu/sgx/encl.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/x86/kernel/cpu/sgx/arch.h b/arch/x86/kernel/cpu/sgx/arch.h
index 26315bea1cb4..70b84bbdaa1d 100644
--- a/arch/x86/kernel/cpu/sgx/arch.h
+++ b/arch/x86/kernel/cpu/sgx/arch.h
@@ -1,5 +1,5 @@
 /* SPDX-License-Identifier: GPL-2.0 */
-/**
+/*
  * Copyright(c) 2016-20 Intel Corporation.
  *
  * Contains data structures defined by the SGX architecture.  Data structures
diff --git a/arch/x86/kernel/cpu/sgx/encl.h b/arch/x86/kernel/cpu/sgx/encl.h
index d8d30ccbef4c..76b9bc1c5c30 100644
--- a/arch/x86/kernel/cpu/sgx/encl.h
+++ b/arch/x86/kernel/cpu/sgx/encl.h
@@ -1,5 +1,5 @@
 /* SPDX-License-Identifier: GPL-2.0 */
-/**
+/*
  * Copyright(c) 2016-20 Intel Corporation.
  *
  * Contains the software defined data structures for enclaves.
-- 
2.17.1


WARNING: multiple messages have this Message-ID (diff)
From: Aditya Srivastava <yashsri421@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: dave.hansen@linux.intel.com, yashsri421@gmail.com,
	rdunlap@infradead.org, linux-doc@vger.kernel.org, x86@kernel.org,
	jarkko@kernel.org, mingo@redhat.com, bp@alien8.de, hpa@zytor.com,
	tglx@linutronix.de,
	linux-kernel-mentees@lists.linuxfoundation.org,
	linux-sgx@vger.kernel.org
Subject: [PATCH] x86/sgx: fix incorrect kernel-doc comment syntax in files
Date: Wed, 31 Mar 2021 02:48:13 +0530	[thread overview]
Message-ID: <20210330211813.28030-1-yashsri421@gmail.com> (raw)

The opening comment mark '/**' is used for highlighting the beginning of
kernel-doc comments.
There are certain files in arch/x86/kernel/cpu/sgx, 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/kernel/cpu/sgx/encl.h causes this warning:
"warning: expecting prototype for 2016(). Prototype was for _X86_ENCL_H() instead"

Similarly for arch/x86/kernel/cpu/sgx/arch.h too.

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

Signed-off-by: Aditya Srivastava <yashsri421@gmail.com>
---
* Applies perfectly on next-20210326

 arch/x86/kernel/cpu/sgx/arch.h | 2 +-
 arch/x86/kernel/cpu/sgx/encl.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/x86/kernel/cpu/sgx/arch.h b/arch/x86/kernel/cpu/sgx/arch.h
index 26315bea1cb4..70b84bbdaa1d 100644
--- a/arch/x86/kernel/cpu/sgx/arch.h
+++ b/arch/x86/kernel/cpu/sgx/arch.h
@@ -1,5 +1,5 @@
 /* SPDX-License-Identifier: GPL-2.0 */
-/**
+/*
  * Copyright(c) 2016-20 Intel Corporation.
  *
  * Contains data structures defined by the SGX architecture.  Data structures
diff --git a/arch/x86/kernel/cpu/sgx/encl.h b/arch/x86/kernel/cpu/sgx/encl.h
index d8d30ccbef4c..76b9bc1c5c30 100644
--- a/arch/x86/kernel/cpu/sgx/encl.h
+++ b/arch/x86/kernel/cpu/sgx/encl.h
@@ -1,5 +1,5 @@
 /* SPDX-License-Identifier: GPL-2.0 */
-/**
+/*
  * Copyright(c) 2016-20 Intel Corporation.
  *
  * Contains the software defined data structures for enclaves.
-- 
2.17.1

_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

             reply	other threads:[~2021-03-30 21:19 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-30 21:18 Aditya Srivastava [this message]
2021-03-30 21:18 ` [PATCH] x86/sgx: fix incorrect kernel-doc comment syntax in files Aditya Srivastava
2021-03-30 21:20 ` Randy Dunlap
2021-03-30 21:20   ` Randy Dunlap
2021-03-31  2:56 ` Jarkko Sakkinen
2021-03-31  2:56   ` Jarkko Sakkinen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210330211813.28030-1-yashsri421@gmail.com \
    --to=yashsri421@gmail.com \
    --cc=bp@alien8.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=jarkko@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel-mentees@lists.linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sgx@vger.kernel.org \
    --cc=lukas.bulwahn@gmail.com \
    --cc=mingo@redhat.com \
    --cc=rdunlap@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.