Unverified Commit 9d068f66 authored by Antonio Niño Díaz's avatar Antonio Niño Díaz Committed by GitHub
Browse files

Merge pull request #1673 from antonio-nino-diaz-arm/an/headers

Standardise header guards across codebase
parents f5ae1b0e c3cf06f1
......@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef __CORTEX_A73_H__
#define __CORTEX_A73_H__
#ifndef CORTEX_A73_H
#define CORTEX_A73_H
/* Cortex-A73 midr for revision 0 */
#define CORTEX_A73_MIDR 0x410FD090
......@@ -29,4 +29,4 @@
#define CORTEX_A73_IMP_DEF_REG1_DISABLE_LOAD_PASS_STORE (1 << 3)
#endif /* __CORTEX_A73_H__ */
#endif /* CORTEX_A73_H */
......@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef __CORTEX_A76_H__
#define __CORTEX_A76_H__
#ifndef CORTEX_A76_H
#define CORTEX_A76_H
/* Cortex-A76 MIDR for revision 0 */
#define CORTEX_A76_MIDR 0x410fd0b0
......@@ -26,4 +26,4 @@
/* Definitions of register field mask in CORTEX_A76_CPUPWRCTLR_EL1 */
#define CORTEX_A76_CORE_PWRDN_EN_MASK 0x1
#endif /* __CORTEX_A76_H__ */
#endif /* CORTEX_A76_H */
......@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef __CORTEX_DEIMOS_H__
#define __CORTEX_DEIMOS_H__
#ifndef CORTEX_DEIMOS_H
#define CORTEX_DEIMOS_H
#define CORTEX_DEIMOS_MIDR U(0x410FD0D0)
......@@ -20,4 +20,4 @@
#define CORTEX_DEIMOS_CPUPWRCTLR_EL1 S3_0_C15_C2_7
#define CORTEX_DEIMOS_CPUPWRCTLR_EL1_CORE_PWRDN_BIT (U(1) << 0)
#endif /* __CORTEX_DEIMOS_H__ */
#endif /* CORTEX_DEIMOS_H */
......@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef __CORTEX_HELIOS_H__
#define __CORTEX_HELIOS_H__
#ifndef CORTEX_HELIOS_H
#define CORTEX_HELIOS_H
#define CORTEX_HELIOS_MIDR U(0x410FD060)
......@@ -26,4 +26,4 @@
#define CORTEX_HELIOS_CPUPWRCTLR_EL1 S3_0_C15_C2_7
#define CORTEX_HELIOS_CPUPWRCTLR_EL1_CORE_PWRDN_BIT (U(1) << 0)
#endif /* __CORTEX_HELIOS_H__ */
#endif /* CORTEX_HELIOS_H */
......@@ -3,8 +3,8 @@
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef __CPU_MACROS_S__
#define __CPU_MACROS_S__
#ifndef CPU_MACROS_S
#define CPU_MACROS_S
#include <arch.h>
#include <errata_report.h>
......@@ -255,8 +255,6 @@
.endm
#endif
#endif /* __CPU_MACROS_S__ */
/*
* This macro is used on some CPUs to detect if they are vulnerable
* to CVE-2017-5715.
......@@ -285,3 +283,5 @@
cmp w0, #((\_cpu_midr >> MIDR_PN_SHIFT) & MIDR_PN_MASK)
b.eq \_label
.endm
#endif /* CPU_MACROS_S */
......@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef __DENVER_H__
#define __DENVER_H__
#ifndef DENVER_H
#define DENVER_H
/* MIDR values for Denver */
#define DENVER_MIDR_PN0 U(0x4E0F0000)
......@@ -39,6 +39,6 @@
/* Disable Dynamic Code Optimisation */
void denver_disable_dco(void);
#endif
#endif /* __ASSEMBLY__ */
#endif /* __DENVER_H__ */
#endif /* DENVER_H */
......@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef __PUBSUB_H__
#define __PUBSUB_H__
#ifndef PUBSUB_H
#define PUBSUB_H
#define __pubsub_start_sym(event) __pubsub_##event##_start
#define __pubsub_end_sym(event) __pubsub_##event##_end
......@@ -84,4 +84,4 @@
typedef void* (*pubsub_cb_t)(const void *arg);
#endif /* __LINKER__ */
#endif /* __PUBSUB_H__ */
#endif /* PUBSUB_H */
......@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef RAS_COMMON
#define RAS_COMMON
#ifndef RAS_H
#define RAS_H
#define ERR_HANDLER_VERSION 1U
......@@ -196,4 +196,5 @@ int ras_ea_handler(unsigned int ea_reason, uint64_t syndrome, void *cookie,
void ras_init(void);
#endif /* __ASSEMBLY__ */
#endif /* RAS_COMMON */
#endif /* RAS_H */
......@@ -36,8 +36,8 @@
* All rights reserved.
*/
#ifndef AARCH32_ENDIAN_H
#define AARCH32_ENDIAN_H
#ifndef ENDIAN__H
#define ENDIAN__H
#include <stdint.h>
......@@ -143,4 +143,4 @@ __bswap16_var(uint16_t v)
#define __bswap32(x) __bswap32_var(x)
#endif /* __OPTIMIZE__ */
#endif /* AARCH32_ENDIAN_H */
#endif /* ENDIAN__H */
......@@ -4,6 +4,9 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STDDEF__H
#define STDDEF__H
#ifndef SIZET_
typedef unsigned int size_t;
#define SIZET_
......@@ -13,3 +16,5 @@ typedef unsigned int size_t;
typedef long ptrdiff_t;
#define _PTRDIFF_T
#endif
#endif /* STDDEF__H */
......@@ -4,6 +4,9 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STDIO__H
#define STDIO__H
#ifndef SIZET_
typedef unsigned int size_t;
#define SIZET_
......@@ -13,3 +16,5 @@ typedef unsigned int size_t;
typedef int ssize_t;
#define SSIZET_
#endif
#endif /* STDIO__H */
......@@ -4,6 +4,9 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STDLIB__H
#define STDLIB__H
#ifndef SIZET_
typedef unsigned int size_t;
#define SIZET_
......@@ -11,3 +14,5 @@ typedef unsigned int size_t;
#define EXIT_FAILURE 1
#define EXIT_SUCCESS 0
#endif /* STDLIB__H */
......@@ -4,7 +4,12 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STRING__H
#define STRING__H
#ifndef SIZET_
typedef unsigned int size_t;
#define SIZET_
#endif
#endif /* STRING__H */
......@@ -4,9 +4,14 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef TIME__H
#define TIME__H
#ifndef SIZET_
typedef unsigned int size_t;
#define SIZET_
#endif
typedef long int time_t;
#endif /* TIME__H */
......@@ -36,8 +36,8 @@
* All rights reserved.
*/
#ifndef AARCH64_ENDIAN_H
#define AARCH64_ENDIAN_H
#ifndef ENDIAN__H
#define ENDIAN__H
#include <stdint.h>
......@@ -125,4 +125,4 @@ __bswap16_var(uint16_t v)
#define __bswap32(x) __bswap32_var(x)
#endif /* __OPTIMIZE__ */
#endif /* AARCH64_ENDIAN_H */
#endif /* ENDIAN__H */
......@@ -4,6 +4,9 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STDDEF__H
#define STDDEF__H
#ifndef SIZET_
typedef unsigned long size_t;
#define SIZET_
......@@ -13,3 +16,5 @@ typedef unsigned long size_t;
typedef long ptrdiff_t;
#define _PTRDIFF_T
#endif
#endif /* STDDEF__H */
......@@ -4,6 +4,9 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STDIO__H
#define STDIO__H
#ifndef SIZET_
typedef unsigned long size_t;
#define SIZET_
......@@ -13,3 +16,5 @@ typedef unsigned long size_t;
typedef long ssize_t;
#define SSIZET_
#endif
#endif /* STDIO__H */
......@@ -4,6 +4,9 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STDLIB__H
#define STDLIB__H
#ifndef SIZET_
typedef unsigned long size_t;
#define SIZET_
......@@ -11,3 +14,5 @@ typedef unsigned long size_t;
#define EXIT_FAILURE 1
#define EXIT_SUCCESS 0
#endif /* STDLIB__H */
......@@ -4,7 +4,12 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef STRING__H
#define STRING__H
#ifndef SIZET_
typedef unsigned long size_t;
#define SIZET_
#endif
#endif /* STRING__H */
......@@ -4,9 +4,14 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef TIME__H
#define TIME__H
#ifndef SIZET_
typedef unsigned long size_t;
#define SIZET_
#endif
typedef long int time_t;
#endif /* TIME__H */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment