diff mbox

sparse: add noclone as an ignored attribute

Message ID 51184E28.40909@infradead.org (mailing list archive)
State Superseded, archived
Headers show

Commit Message

Randy Dunlap Feb. 11, 2013, 1:49 a.m. UTC
From: Randy Dunlap <rdunlap@infradead.org>

Add attribute "noclone" or "__noclone" or "__noclone__" as an
ignored attribute. Fixes this sparse warning:

arch/x86/kvm/vmx.c:6268:13: error: attribute '__noclone__': unknown attribute

Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
---
 parse.c |    3 +++
 1 file changed, 3 insertions(+)

--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Christopher Li Feb. 21, 2013, 11:35 p.m. UTC | #1
On Sun, Feb 10, 2013 at 5:49 PM, Randy Dunlap <rdunlap@infradead.org> wrote:
> From: Randy Dunlap <rdunlap@infradead.org>
>
> Add attribute "noclone" or "__noclone" or "__noclone__" as an
> ignored attribute. Fixes this sparse warning:
>
> arch/x86/kvm/vmx.c:6268:13: error: attribute '__noclone__': unknown attribute

The change looks good. Can you add a test case for the noclone attribute
in the validations directory? I am happy to apply it.

Chris
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

--- sparse-2013-0210.orig/parse.c
+++ sparse-2013-0210/parse.c
@@ -541,6 +541,9 @@  const char *ignored_attributes[] = {
 	"__naked__",
 	"no_instrument_function",
 	"__no_instrument_function__",
+	"noclone",
+	"__noclone",
+	"__noclone__",
 	"noinline",
 	"__noinline__",
 	"nonnull",