aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKristofer Jonsson <kristofer.jonsson@arm.com>2020-08-05 09:38:40 +0200
committerKristofer Jonsson <kristofer.jonsson@arm.com>2020-08-05 09:38:40 +0200
commit3c4391763b45c693e54b17b47e9bd65f0b3427c6 (patch)
treec06694c2a53484aaf751ed331573290aa7b54ff3 /src
parent5da4092d07c31acaa3d44ac57fa3b02a3be67182 (diff)
downloadethos-u-core-driver-3c4391763b45c693e54b17b47e9bd65f0b3427c6.tar.gz
Header cleanup
Change-Id: I84754f316ce940917516cb7f5c59189f523d4095
Diffstat (limited to 'src')
-rw-r--r--src/ethosu_common.h14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/ethosu_common.h b/src/ethosu_common.h
index a5ea197..b22bffd 100644
--- a/src/ethosu_common.h
+++ b/src/ethosu_common.h
@@ -16,14 +16,22 @@
* limitations under the License.
*/
-#if !defined ETHOSU_COMMON_H
+#ifndef ETHOSU_COMMON_H
#define ETHOSU_COMMON_H
+/******************************************************************************
+ * Includes
+ ******************************************************************************/
+
#include "ethosu55_interface.h"
#include "ethosu_device.h"
#include <stdio.h>
+/******************************************************************************
+ * Defines
+ ******************************************************************************/
+
#if defined(DRIVER_LOG_SEVERITY) && (DRIVER_LOG_SEVERITY >= LOG_SEVERITY_EMERG)
#define LOG_EMERG(format, ...) \
fprintf(stderr, format, ##__VA_ARGS__); \
@@ -97,6 +105,10 @@
#define MASK_0_31_BITS (0xFFFFFFFF)
#define MASK_32_47_BITS (0xFFFF00000000)
+/******************************************************************************
+ * Inline functions
+ ******************************************************************************/
+
static const __attribute__((section("npu_driver_version"))) char driver_version_str[] = VER_STR(
ETHOSU_DRIVER_VERSION_MAJOR) "." VER_STR(ETHOSU_DRIVER_VERSION_MINOR) "." VER_STR(ETHOSU_DRIVER_VERSION_PATCH);