* [PATCH] arch: c6x: uapi: be sure of "_UAPI" prefix for all guard macros
@ 2013-11-17 10:30 Chen Gang
2013-11-21 16:03 ` Mark Salter
0 siblings, 1 reply; 3+ messages in thread
From: Chen Gang @ 2013-11-17 10:30 UTC (permalink / raw)
To: msalter, a-jacquiot, viro; +Cc: linux-c6x-dev, linux-kernel
For all uapi headers, need use "_UAPI" prefix for its guard macro
(which will be stripped by "scripts/headers_installer.sh").
Also be sure that all files have their guard macros.
Also be sure that all "#endif" are followed with correct comments.
Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
---
arch/c6x/include/uapi/asm/byteorder.h | 6 +++---
arch/c6x/include/uapi/asm/ptrace.h | 1 +
arch/c6x/include/uapi/asm/sigcontext.h | 7 +++----
arch/c6x/include/uapi/asm/swab.h | 6 +++---
arch/c6x/include/uapi/asm/unistd.h | 4 ++++
5 files changed, 14 insertions(+), 10 deletions(-)
diff --git a/arch/c6x/include/uapi/asm/byteorder.h b/arch/c6x/include/uapi/asm/byteorder.h
index 166038d..43f98aa 100644
--- a/arch/c6x/include/uapi/asm/byteorder.h
+++ b/arch/c6x/include/uapi/asm/byteorder.h
@@ -1,5 +1,5 @@
-#ifndef _ASM_C6X_BYTEORDER_H
-#define _ASM_C6X_BYTEORDER_H
+#ifndef _UAPI_ASM_C6X_BYTEORDER_H
+#define _UAPI_ASM_C6X_BYTEORDER_H
#include <asm/types.h>
@@ -9,4 +9,4 @@
#include <linux/byteorder/little_endian.h>
#endif /* _BIG_ENDIAN */
-#endif /* _ASM_BYTEORDER_H */
+#endif /* _UAPI_ASM_C6X_BYTEORDER_H */
diff --git a/arch/c6x/include/uapi/asm/ptrace.h b/arch/c6x/include/uapi/asm/ptrace.h
index cc0a4d9..e4bbe62 100644
--- a/arch/c6x/include/uapi/asm/ptrace.h
+++ b/arch/c6x/include/uapi/asm/ptrace.h
@@ -160,4 +160,5 @@ struct pt_regs {
};
#endif /* __ASSEMBLY__ */
+
#endif /* _UAPI_ASM_C6X_PTRACE_H */
diff --git a/arch/c6x/include/uapi/asm/sigcontext.h b/arch/c6x/include/uapi/asm/sigcontext.h
index eb702f3..1fb30e9 100644
--- a/arch/c6x/include/uapi/asm/sigcontext.h
+++ b/arch/c6x/include/uapi/asm/sigcontext.h
@@ -8,9 +8,8 @@
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/
-#ifndef _ASM_C6X_SIGCONTEXT_H
-#define _ASM_C6X_SIGCONTEXT_H
-
+#ifndef _UAPI_ASM_C6X_SIGCONTEXT_H
+#define _UAPI_ASM_C6X_SIGCONTEXT_H
struct sigcontext {
unsigned long sc_mask; /* old sigmask */
@@ -77,4 +76,4 @@ struct sigcontext {
unsigned long sc_pc;
};
-#endif /* _ASM_C6X_SIGCONTEXT_H */
+#endif /* _UAPI_ASM_C6X_SIGCONTEXT_H */
diff --git a/arch/c6x/include/uapi/asm/swab.h b/arch/c6x/include/uapi/asm/swab.h
index fd4bb05..58b738b 100644
--- a/arch/c6x/include/uapi/asm/swab.h
+++ b/arch/c6x/include/uapi/asm/swab.h
@@ -6,8 +6,8 @@
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/
-#ifndef _ASM_C6X_SWAB_H
-#define _ASM_C6X_SWAB_H
+#ifndef _UAPI_ASM_C6X_SWAB_H
+#define _UAPI_ASM_C6X_SWAB_H
static inline __attribute_const__ __u16 __c6x_swab16(__u16 val)
{
@@ -51,4 +51,4 @@ static inline __attribute_const__ __u32 __c6x_swahb32(__u32 val)
#define __arch_swahw32 __c6x_swahw32
#define __arch_swahb32 __c6x_swahb32
-#endif /* _ASM_C6X_SWAB_H */
+#endif /* _UAPI_ASM_C6X_SWAB_H */
diff --git a/arch/c6x/include/uapi/asm/unistd.h b/arch/c6x/include/uapi/asm/unistd.h
index e7d09a6..ec6aebb 100644
--- a/arch/c6x/include/uapi/asm/unistd.h
+++ b/arch/c6x/include/uapi/asm/unistd.h
@@ -13,6 +13,8 @@
* NON INFRINGEMENT. See the GNU General Public License for
* more details.
*/
+#ifndef _UAPI_ASM_C6X_UNISTD_H
+#define _UAPI_ASM_C6X_UNISTD_H
#define __ARCH_WANT_SYS_CLONE
@@ -22,3 +24,5 @@
/* C6X-specific syscalls. */
#define __NR_cache_sync (__NR_arch_specific_syscall + 0)
__SYSCALL(__NR_cache_sync, sys_cache_sync)
+
+#endif /* _UAPI_ASM_C6X_UNISTD_H */
--
1.7.11.7
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] arch: c6x: uapi: be sure of "_UAPI" prefix for all guard macros
2013-11-17 10:30 [PATCH] arch: c6x: uapi: be sure of "_UAPI" prefix for all guard macros Chen Gang
@ 2013-11-21 16:03 ` Mark Salter
2013-11-22 1:49 ` Chen Gang
0 siblings, 1 reply; 3+ messages in thread
From: Mark Salter @ 2013-11-21 16:03 UTC (permalink / raw)
To: Chen Gang; +Cc: a-jacquiot, viro, linux-c6x-dev, linux-kernel
On Sun, 2013-11-17 at 18:30 +0800, Chen Gang wrote:
> For all uapi headers, need use "_UAPI" prefix for its guard macro
> (which will be stripped by "scripts/headers_installer.sh").
>
> Also be sure that all files have their guard macros.
>
> Also be sure that all "#endif" are followed with correct comments.
>
>
> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
Acked-by: Mark Salter <msalter@redhat.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] arch: c6x: uapi: be sure of "_UAPI" prefix for all guard macros
2013-11-21 16:03 ` Mark Salter
@ 2013-11-22 1:49 ` Chen Gang
0 siblings, 0 replies; 3+ messages in thread
From: Chen Gang @ 2013-11-22 1:49 UTC (permalink / raw)
To: Mark Salter; +Cc: a-jacquiot, viro, linux-c6x-dev, linux-kernel
On 11/22/2013 12:03 AM, Mark Salter wrote:
> On Sun, 2013-11-17 at 18:30 +0800, Chen Gang wrote:
>> For all uapi headers, need use "_UAPI" prefix for its guard macro
>> (which will be stripped by "scripts/headers_installer.sh").
>>
>> Also be sure that all files have their guard macros.
>>
>> Also be sure that all "#endif" are followed with correct comments.
>>
>>
>> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
>
> Acked-by: Mark Salter <msalter@redhat.com>
>
>
Thank you very much!! :-)
Thanks.
--
Chen Gang
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-11-22 1:47 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-11-17 10:30 [PATCH] arch: c6x: uapi: be sure of "_UAPI" prefix for all guard macros Chen Gang
2013-11-21 16:03 ` Mark Salter
2013-11-22 1:49 ` Chen Gang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox