aboutsummaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorMikael Olsson <mikael.olsson@arm.com>2024-02-07 11:22:26 +0100
committerMikael Olsson <mikael.olsson@arm.com>2024-02-12 13:04:41 +0100
commitd4ad9e55cb8e17a4a42b3a94c64e6bc48529b26e (patch)
tree9084d770574bc2a278ddfa121985ac030f711daa /kernel
parent09cdc30b3b3a52176cd02518c07d5f44c1ce8dd1 (diff)
downloadethos-u-linux-driver-stack-d4ad9e55cb8e17a4a42b3a94c64e6bc48529b26e.tar.gz
Restructure kernel driver source tree
As a first step to have a clearer separation of the different parts of the kernel driver, the source files have been placed into separate directories according to their purpose and the different parts are only allowed to use headers from another part in the include folder. Files have been renamed accordingly to namespace them by their purpose. Change-Id: I75e09ebf0002c99a22b6d4b09d34504d186c32b3 Signed-off-by: Mikael Olsson <mikael.olsson@arm.com>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/CMakeLists.txt4
-rw-r--r--kernel/Kbuild26
-rw-r--r--kernel/common/ethosu_buffer.c (renamed from kernel/ethosu_buffer.c)10
-rw-r--r--kernel/common/ethosu_device.c (renamed from kernel/ethosu_device.c)24
-rw-r--r--kernel/common/ethosu_dma_mem.c (renamed from kernel/ethosu_dma_mem.c)4
-rw-r--r--kernel/common/ethosu_driver.c (renamed from kernel/ethosu_driver.c)11
-rw-r--r--kernel/include/common/ethosu_buffer.h (renamed from kernel/ethosu_buffer.h)2
-rw-r--r--kernel/include/common/ethosu_device.h (renamed from kernel/ethosu_device.h)9
-rw-r--r--kernel/include/common/ethosu_dma_mem.h (renamed from kernel/ethosu_dma_mem.h)2
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg.h (renamed from kernel/ethosu_core_rpmsg.h)5
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg_cancel_inference.h (renamed from kernel/ethosu_cancel_inference.h)9
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg_capabilities.h (renamed from kernel/ethosu_capabilities.h)7
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg_inference.h (renamed from kernel/ethosu_inference.h)9
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg_mailbox.h (renamed from kernel/ethosu_mailbox.h)4
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg_network.h (renamed from kernel/ethosu_network.h)2
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg_network_info.h (renamed from kernel/ethosu_network_info.h)7
-rw-r--r--kernel/include/rpmsg/ethosu_rpmsg_version.h (renamed from kernel/ethosu_version.h)7
-rw-r--r--kernel/include/uapi/ethosu.h (renamed from kernel/uapi/ethosu.h)2
-rw-r--r--kernel/rpmsg/ethosu_rpmsg_cancel_inference.c (renamed from kernel/ethosu_cancel_inference.c)8
-rw-r--r--kernel/rpmsg/ethosu_rpmsg_capabilities.c (renamed from kernel/ethosu_capabilities.c)8
-rw-r--r--kernel/rpmsg/ethosu_rpmsg_inference.c (renamed from kernel/ethosu_inference.c)14
-rw-r--r--kernel/rpmsg/ethosu_rpmsg_mailbox.c (renamed from kernel/ethosu_mailbox.c)15
-rw-r--r--kernel/rpmsg/ethosu_rpmsg_network.c (renamed from kernel/ethosu_network.c)14
-rw-r--r--kernel/rpmsg/ethosu_rpmsg_network_info.c (renamed from kernel/ethosu_network_info.c)11
-rw-r--r--kernel/rpmsg/ethosu_rpmsg_version.c (renamed from kernel/ethosu_version.c)10
25 files changed, 107 insertions, 117 deletions
diff --git a/kernel/CMakeLists.txt b/kernel/CMakeLists.txt
index 0192bdc..b5ce944 100644
--- a/kernel/CMakeLists.txt
+++ b/kernel/CMakeLists.txt
@@ -1,5 +1,5 @@
#
-# SPDX-FileCopyrightText: Copyright 2020-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+# SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
# SPDX-License-Identifier: GPL-2.0-only
#
# This program is free software and is provided to you under the terms of the
@@ -41,4 +41,4 @@ add_custom_target(kernel ALL
# Install the kernel object and headers
install(FILES ethosu.ko DESTINATION "modules")
-install(FILES "uapi/ethosu.h" DESTINATION "include/uapi")
+install(FILES "include/uapi/ethosu.h" DESTINATION "include/uapi")
diff --git a/kernel/Kbuild b/kernel/Kbuild
index 98bece3..88ce756 100644
--- a/kernel/Kbuild
+++ b/kernel/Kbuild
@@ -1,5 +1,5 @@
#
-# SPDX-FileCopyrightText: Copyright 2020,2022-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+# SPDX-FileCopyrightText: Copyright 2020, 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
# SPDX-License-Identifier: GPL-2.0-only
#
# This program is free software and is provided to you under the terms of the
@@ -17,18 +17,18 @@
# http://www.gnu.org/licenses/gpl-2.0.html.
#
-ccflags-y += -Werror
+ccflags-y += -Werror -I$(src)/include
obj-$(CONFIG_ETHOSU) = ethosu.o
-ethosu-objs := ethosu_driver.o \
- ethosu_buffer.o \
- ethosu_dma_mem.o \
- ethosu_device.o \
- ethosu_inference.o \
- ethosu_mailbox.o \
- ethosu_network.o \
- ethosu_network_info.o \
- ethosu_capabilities.o \
- ethosu_cancel_inference.o \
- ethosu_version.o
+ethosu-objs := common/ethosu_driver.o \
+ common/ethosu_buffer.o \
+ common/ethosu_dma_mem.o \
+ common/ethosu_device.o \
+ rpmsg/ethosu_rpmsg_cancel_inference.o \
+ rpmsg/ethosu_rpmsg_network.o \
+ rpmsg/ethosu_rpmsg_network_info.o \
+ rpmsg/ethosu_rpmsg_capabilities.o \
+ rpmsg/ethosu_rpmsg_inference.o \
+ rpmsg/ethosu_rpmsg_mailbox.o \
+ rpmsg/ethosu_rpmsg_version.o
diff --git a/kernel/ethosu_buffer.c b/kernel/common/ethosu_buffer.c
index 69b5007..cf41b8d 100644
--- a/kernel/ethosu_buffer.c
+++ b/kernel/common/ethosu_buffer.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -21,11 +21,11 @@
* Includes
****************************************************************************/
-#include "ethosu_buffer.h"
+#include <common/ethosu_buffer.h>
-#include "ethosu_device.h"
-#include "ethosu_dma_mem.h"
-#include "uapi/ethosu.h"
+#include <common/ethosu_device.h>
+#include <common/ethosu_dma_mem.h>
+#include <uapi/ethosu.h>
#include <linux/anon_inodes.h>
#include <linux/dma-mapping.h>
diff --git a/kernel/ethosu_device.c b/kernel/common/ethosu_device.c
index 32fb012..f1e00ab 100644
--- a/kernel/ethosu_device.c
+++ b/kernel/common/ethosu_device.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -21,17 +21,17 @@
* Includes
****************************************************************************/
-#include "ethosu_device.h"
-
-#include "ethosu_buffer.h"
-#include "ethosu_core_rpmsg.h"
-#include "ethosu_capabilities.h"
-#include "ethosu_inference.h"
-#include "ethosu_cancel_inference.h"
-#include "ethosu_network.h"
-#include "ethosu_network_info.h"
-#include "ethosu_version.h"
-#include "uapi/ethosu.h"
+#include <common/ethosu_device.h>
+
+#include <common/ethosu_buffer.h>
+#include <rpmsg/ethosu_rpmsg.h>
+#include <rpmsg/ethosu_rpmsg_cancel_inference.h>
+#include <rpmsg/ethosu_rpmsg_capabilities.h>
+#include <rpmsg/ethosu_rpmsg_inference.h>
+#include <rpmsg/ethosu_rpmsg_network.h>
+#include <rpmsg/ethosu_rpmsg_network_info.h>
+#include <rpmsg/ethosu_rpmsg_version.h>
+#include <uapi/ethosu.h>
#include <linux/dma-mapping.h>
#include <linux/errno.h>
diff --git a/kernel/ethosu_dma_mem.c b/kernel/common/ethosu_dma_mem.c
index cb63081..0e05978 100644
--- a/kernel/ethosu_dma_mem.c
+++ b/kernel/common/ethosu_dma_mem.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2023-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -21,7 +21,7 @@
* Includes
****************************************************************************/
-#include "ethosu_dma_mem.h"
+#include <common/ethosu_dma_mem.h>
#include <linux/err.h>
#include <linux/dma-mapping.h>
diff --git a/kernel/ethosu_driver.c b/kernel/common/ethosu_driver.c
index 48d2155..15f13b5 100644
--- a/kernel/ethosu_driver.c
+++ b/kernel/common/ethosu_driver.c
@@ -1,5 +1,6 @@
/*
- * Copyright 2020-2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,10 +15,11 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
+#include <common/ethosu_device.h>
+#include <uapi/ethosu.h>
+
#include <linux/bitmap.h>
#include <linux/fs.h>
#include <linux/module.h>
@@ -26,9 +28,6 @@
#include <linux/of_address.h>
#include <linux/rpmsg.h>
-#include "ethosu_device.h"
-#include "uapi/ethosu.h"
-
/****************************************************************************
* Defines
****************************************************************************/
diff --git a/kernel/ethosu_buffer.h b/kernel/include/common/ethosu_buffer.h
index 8bef2d2..868e783 100644
--- a/kernel/ethosu_buffer.h
+++ b/kernel/include/common/ethosu_buffer.h
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020,2022-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020, 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
diff --git a/kernel/ethosu_device.h b/kernel/include/common/ethosu_device.h
index af14c85..e96543e 100644
--- a/kernel/ethosu_device.h
+++ b/kernel/include/common/ethosu_device.h
@@ -1,5 +1,6 @@
/*
- * Copyright 2020-2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,8 +15,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
#ifndef ETHOSU_DEVICE_H
@@ -25,8 +24,8 @@
* Includes
****************************************************************************/
-#include "uapi/ethosu.h"
-#include "ethosu_mailbox.h"
+#include <uapi/ethosu.h>
+#include <rpmsg/ethosu_rpmsg_mailbox.h>
#include <linux/device.h>
#include <linux/cdev.h>
diff --git a/kernel/ethosu_dma_mem.h b/kernel/include/common/ethosu_dma_mem.h
index 11cdd39..eac4b42 100644
--- a/kernel/ethosu_dma_mem.h
+++ b/kernel/include/common/ethosu_dma_mem.h
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2023-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
diff --git a/kernel/ethosu_core_rpmsg.h b/kernel/include/rpmsg/ethosu_rpmsg.h
index 0b7feab..c1923c2 100644
--- a/kernel/ethosu_core_rpmsg.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg.h
@@ -1,5 +1,6 @@
/*
- * Copyright (c) 2020-2023 Arm Limited.
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,8 +15,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
#ifndef ETHOSU_CORE_RPMSG_H
diff --git a/kernel/ethosu_cancel_inference.h b/kernel/include/rpmsg/ethosu_rpmsg_cancel_inference.h
index a3982dd..1d6cc03 100644
--- a/kernel/ethosu_cancel_inference.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg_cancel_inference.h
@@ -1,5 +1,6 @@
/*
- * Copyright 2022-2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,8 +15,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
#ifndef ETHOSU_CANCEL_INFERENCE_H
@@ -25,8 +24,8 @@
* Includes
****************************************************************************/
-#include "ethosu_mailbox.h"
-#include "uapi/ethosu.h"
+#include <rpmsg/ethosu_rpmsg_mailbox.h>
+#include <uapi/ethosu.h>
#include <linux/types.h>
#include <linux/completion.h>
diff --git a/kernel/ethosu_capabilities.h b/kernel/include/rpmsg/ethosu_rpmsg_capabilities.h
index 30bf475..aefdbaa 100644
--- a/kernel/ethosu_capabilities.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg_capabilities.h
@@ -1,5 +1,6 @@
/*
- * Copyright 2022-2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,8 +15,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
#ifndef ETHOSU_CAPABILITIES_H
@@ -25,7 +24,7 @@
* Includes
****************************************************************************/
-#include "ethosu_mailbox.h"
+#include <rpmsg/ethosu_rpmsg_mailbox.h>
#include <linux/types.h>
#include <linux/completion.h>
diff --git a/kernel/ethosu_inference.h b/kernel/include/rpmsg/ethosu_rpmsg_inference.h
index 5040ef1..8bdfb8a 100644
--- a/kernel/ethosu_inference.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg_inference.h
@@ -1,5 +1,6 @@
/*
- * Copyright 2020,2022-2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2020, 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,8 +15,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
#ifndef ETHOSU_INFERENCE_H
@@ -25,8 +24,8 @@
* Includes
****************************************************************************/
-#include "ethosu_mailbox.h"
-#include "uapi/ethosu.h"
+#include <rpmsg/ethosu_rpmsg_mailbox.h>
+#include <uapi/ethosu.h>
#include <linux/kref.h>
#include <linux/types.h>
diff --git a/kernel/ethosu_mailbox.h b/kernel/include/rpmsg/ethosu_rpmsg_mailbox.h
index ab19613..66eb172 100644
--- a/kernel/ethosu_mailbox.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg_mailbox.h
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -23,7 +23,7 @@
/****************************************************************************
* Includes
****************************************************************************/
-#include "ethosu_core_rpmsg.h"
+#include <rpmsg/ethosu_rpmsg.h>
#include <linux/types.h>
#include <linux/mailbox_client.h>
diff --git a/kernel/ethosu_network.h b/kernel/include/rpmsg/ethosu_rpmsg_network.h
index 5484bac..269018a 100644
--- a/kernel/ethosu_network.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg_network.h
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020,2022-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020, 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
diff --git a/kernel/ethosu_network_info.h b/kernel/include/rpmsg/ethosu_rpmsg_network_info.h
index 8c2e659..aaa3733 100644
--- a/kernel/ethosu_network_info.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg_network_info.h
@@ -1,5 +1,6 @@
/*
- * Copyright 2022-2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,8 +15,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
#ifndef ETHOSU_NETWORK_INFO_H
@@ -25,7 +24,7 @@
* Includes
****************************************************************************/
-#include "ethosu_mailbox.h"
+#include <rpmsg/ethosu_rpmsg_mailbox.h>
#include <linux/types.h>
#include <linux/completion.h>
diff --git a/kernel/ethosu_version.h b/kernel/include/rpmsg/ethosu_rpmsg_version.h
index c5c02ad..755a3d5 100644
--- a/kernel/ethosu_version.h
+++ b/kernel/include/rpmsg/ethosu_rpmsg_version.h
@@ -1,5 +1,6 @@
/*
- * Copyright 2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2023-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,8 +15,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
#ifndef ETHOSU_VERSION_H
@@ -25,7 +24,7 @@
* Includes
****************************************************************************/
-#include "ethosu_mailbox.h"
+#include <rpmsg/ethosu_rpmsg_mailbox.h>
#include <linux/types.h>
#include <linux/completion.h>
diff --git a/kernel/uapi/ethosu.h b/kernel/include/uapi/ethosu.h
index 8240ad9..58b9c34 100644
--- a/kernel/uapi/ethosu.h
+++ b/kernel/include/uapi/ethosu.h
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only WITH Linux-syscall-note
*
* This program is free software and is provided to you under the terms of the
diff --git a/kernel/ethosu_cancel_inference.c b/kernel/rpmsg/ethosu_rpmsg_cancel_inference.c
index 47687b8..5d46434 100644
--- a/kernel/ethosu_cancel_inference.c
+++ b/kernel/rpmsg/ethosu_rpmsg_cancel_inference.c
@@ -22,11 +22,11 @@
* Includes
****************************************************************************/
-#include "ethosu_cancel_inference.h"
+#include <rpmsg/ethosu_rpmsg_cancel_inference.h>
-#include "ethosu_core_rpmsg.h"
-#include "ethosu_device.h"
-#include "ethosu_inference.h"
+#include <common/ethosu_device.h>
+#include <rpmsg/ethosu_rpmsg.h>
+#include <rpmsg/ethosu_rpmsg_inference.h>
#include <linux/remoteproc.h>
#include <linux/wait.h>
diff --git a/kernel/ethosu_capabilities.c b/kernel/rpmsg/ethosu_rpmsg_capabilities.c
index 2c2d23a..73ce2dc 100644
--- a/kernel/ethosu_capabilities.c
+++ b/kernel/rpmsg/ethosu_rpmsg_capabilities.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2022-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -22,10 +22,10 @@
* Includes
****************************************************************************/
-#include "ethosu_capabilities.h"
+#include <rpmsg/ethosu_rpmsg_capabilities.h>
-#include "ethosu_core_rpmsg.h"
-#include "ethosu_device.h"
+#include <common/ethosu_device.h>
+#include <rpmsg/ethosu_rpmsg.h>
#include <linux/delay.h>
#include <linux/dma-mapping.h>
diff --git a/kernel/ethosu_inference.c b/kernel/rpmsg/ethosu_rpmsg_inference.c
index 3238d7e..b721fb7 100644
--- a/kernel/ethosu_inference.c
+++ b/kernel/rpmsg/ethosu_rpmsg_inference.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020,2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020, 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -21,13 +21,13 @@
* Includes
****************************************************************************/
-#include "ethosu_inference.h"
+#include <rpmsg/ethosu_rpmsg_inference.h>
-#include "ethosu_buffer.h"
-#include "ethosu_core_rpmsg.h"
-#include "ethosu_device.h"
-#include "ethosu_network.h"
-#include "ethosu_cancel_inference.h"
+#include <common/ethosu_buffer.h>
+#include <common/ethosu_device.h>
+#include <rpmsg/ethosu_rpmsg.h>
+#include <rpmsg/ethosu_rpmsg_cancel_inference.h>
+#include <rpmsg/ethosu_rpmsg_network.h>
#include <linux/anon_inodes.h>
#include <linux/file.h>
diff --git a/kernel/ethosu_mailbox.c b/kernel/rpmsg/ethosu_rpmsg_mailbox.c
index 005e83e..11ac414 100644
--- a/kernel/ethosu_mailbox.c
+++ b/kernel/rpmsg/ethosu_rpmsg_mailbox.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -21,13 +21,14 @@
* Includes
****************************************************************************/
-#include "ethosu_mailbox.h"
+#include <rpmsg/ethosu_rpmsg_mailbox.h>
-#include "ethosu_buffer.h"
-#include "ethosu_core_rpmsg.h"
-#include "ethosu_device.h"
-#include "ethosu_dma_mem.h"
-#include "ethosu_network.h"
+#include <common/ethosu_buffer.h>
+#include <common/ethosu_device.h>
+#include <common/ethosu_dma_mem.h>
+#include <rpmsg/ethosu_rpmsg.h>
+
+#include <rpmsg/ethosu_rpmsg_network.h>
#include <linux/atomic.h>
#include <linux/jiffies.h>
diff --git a/kernel/ethosu_network.c b/kernel/rpmsg/ethosu_rpmsg_network.c
index 58d5c77..f5b8265 100644
--- a/kernel/ethosu_network.c
+++ b/kernel/rpmsg/ethosu_rpmsg_network.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2020,2022-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2020, 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -21,13 +21,13 @@
* Includes
****************************************************************************/
-#include "ethosu_network.h"
+#include <rpmsg/ethosu_rpmsg_network.h>
-#include "ethosu_device.h"
-#include "ethosu_dma_mem.h"
-#include "ethosu_inference.h"
-#include "ethosu_network_info.h"
-#include "uapi/ethosu.h"
+#include <common/ethosu_device.h>
+#include <common/ethosu_dma_mem.h>
+#include <rpmsg/ethosu_rpmsg_inference.h>
+#include <rpmsg/ethosu_rpmsg_network_info.h>
+#include <uapi/ethosu.h>
#include <linux/anon_inodes.h>
#include <linux/file.h>
diff --git a/kernel/ethosu_network_info.c b/kernel/rpmsg/ethosu_rpmsg_network_info.c
index 011a0b4..0e54d87 100644
--- a/kernel/ethosu_network_info.c
+++ b/kernel/rpmsg/ethosu_rpmsg_network_info.c
@@ -1,5 +1,5 @@
/*
- * SPDX-FileCopyrightText: Copyright 2022-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-FileCopyrightText: Copyright 2022-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
* SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
@@ -21,12 +21,11 @@
* Includes
****************************************************************************/
-#include "ethosu_network_info.h"
+#include <rpmsg/ethosu_rpmsg_network_info.h>
-#include "ethosu_device.h"
-#include "ethosu_network.h"
-#include "ethosu_mailbox.h"
-#include "uapi/ethosu.h"
+#include <common/ethosu_device.h>
+#include <rpmsg/ethosu_rpmsg_network.h>
+#include <uapi/ethosu.h>
#include <linux/bug.h>
diff --git a/kernel/ethosu_version.c b/kernel/rpmsg/ethosu_rpmsg_version.c
index 1a92dc2..03e164b 100644
--- a/kernel/ethosu_version.c
+++ b/kernel/rpmsg/ethosu_rpmsg_version.c
@@ -1,5 +1,6 @@
/*
- * Copyright 2023 Arm Limited and/or its affiliates
+ * SPDX-FileCopyrightText: Copyright 2023-2024 Arm Limited and/or its affiliates <open-source-office@arm.com>
+ * SPDX-License-Identifier: GPL-2.0-only
*
* This program is free software and is provided to you under the terms of the
* GNU General Public License version 2 as published by the Free Software
@@ -14,17 +15,14 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, you can access it online at
* http://www.gnu.org/licenses/gpl-2.0.html.
- *
- * SPDX-License-Identifier: GPL-2.0-only
*/
/****************************************************************************
* Includes
****************************************************************************/
-#include "ethosu_version.h"
-
-#include "ethosu_core_rpmsg.h"
+#include <rpmsg/ethosu_rpmsg_version.h>
+#include <rpmsg/ethosu_rpmsg.h>
#include <linux/errno.h>