From d24ed9783b78ea997a6acb994523b9ccb994c6d5 Mon Sep 17 00:00:00 2001 From: Martin Stein Date: Tue, 5 Nov 2013 11:08:05 +0100 Subject: [PATCH] hw: get rid of kernel_support.cc ref #935 --- base-hw/src/core/arndale/platform_support.cc | 4 ++++ base-hw/src/core/imx31/platform_support.cc | 3 +++ base-hw/src/core/imx53/platform_support.cc | 3 +++ base-hw/src/core/kernel_support.cc | 20 ------------------ base-hw/src/core/panda/platform_support.cc | 3 +++ base-hw/src/core/pbxa9/platform_support.cc | 3 +++ base-hw/src/core/rpi/platform_support.cc | 3 +++ base-hw/src/core/target.inc | 1 - .../vea9x4/no_trustzone/platform_support.cc | 3 +++ .../core/vea9x4/trustzone/kernel_support.cc | 21 ------------------- .../core/vea9x4/trustzone/platform_support.cc | 5 ++++- base-hw/src/core/vea9x4/trustzone/target.mk | 1 - 12 files changed, 26 insertions(+), 44 deletions(-) delete mode 100644 base-hw/src/core/kernel_support.cc delete mode 100644 base-hw/src/core/vea9x4/trustzone/kernel_support.cc diff --git a/base-hw/src/core/arndale/platform_support.cc b/base-hw/src/core/arndale/platform_support.cc index ee4fb12ab1..0f329fafd4 100644 --- a/base-hw/src/core/arndale/platform_support.cc +++ b/base-hw/src/core/arndale/platform_support.cc @@ -15,6 +15,7 @@ #include #include #include +#include #include #include @@ -83,3 +84,6 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) }; return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + + +Cpu::User_context::User_context() { cpsr = Psr::init_user(); } diff --git a/base-hw/src/core/imx31/platform_support.cc b/base-hw/src/core/imx31/platform_support.cc index 759ef5f0cf..eced4c8157 100644 --- a/base-hw/src/core/imx31/platform_support.cc +++ b/base-hw/src/core/imx31/platform_support.cc @@ -15,6 +15,7 @@ #include #include #include +#include #include using namespace Genode; @@ -97,3 +98,5 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + +Cpu::User_context::User_context() { cpsr = Psr::init_user(); } diff --git a/base-hw/src/core/imx53/platform_support.cc b/base-hw/src/core/imx53/platform_support.cc index b744c5e690..dc435ac0a5 100644 --- a/base-hw/src/core/imx53/platform_support.cc +++ b/base-hw/src/core/imx53/platform_support.cc @@ -15,6 +15,7 @@ #include #include #include +#include #include using namespace Genode; @@ -102,3 +103,5 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + +Cpu::User_context::User_context() { cpsr = Psr::init_user(); } diff --git a/base-hw/src/core/kernel_support.cc b/base-hw/src/core/kernel_support.cc deleted file mode 100644 index a91c350aef..0000000000 --- a/base-hw/src/core/kernel_support.cc +++ /dev/null @@ -1,20 +0,0 @@ -/* - * \brief Kernel function implementations specific for Cortex A9 CPUs - * \author Stefan Kalkowski - * \date 2012-10-11 - */ - -/* - * Copyright (C) 2012-2013 Genode Labs GmbH - * - * This file is part of the Genode OS framework, which is distributed - * under the terms of the GNU General Public License version 2. - */ - -/* core includes */ -#include - -using namespace Genode; - -Cpu::User_context::User_context() { cpsr = Psr::init_user(); } - diff --git a/base-hw/src/core/panda/platform_support.cc b/base-hw/src/core/panda/platform_support.cc index 2124b08002..32bed71bd0 100644 --- a/base-hw/src/core/panda/platform_support.cc +++ b/base-hw/src/core/panda/platform_support.cc @@ -95,3 +95,6 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) }; return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + + +Cpu::User_context::User_context() { cpsr = Psr::init_user(); } diff --git a/base-hw/src/core/pbxa9/platform_support.cc b/base-hw/src/core/pbxa9/platform_support.cc index 0cf7690ace..6b6c9bed25 100644 --- a/base-hw/src/core/pbxa9/platform_support.cc +++ b/base-hw/src/core/pbxa9/platform_support.cc @@ -91,3 +91,6 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) }; return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + + +Cpu::User_context::User_context() { cpsr = Psr::init_user(); } diff --git a/base-hw/src/core/rpi/platform_support.cc b/base-hw/src/core/rpi/platform_support.cc index c1441ea9d3..6f61ba4dc2 100644 --- a/base-hw/src/core/rpi/platform_support.cc +++ b/base-hw/src/core/rpi/platform_support.cc @@ -14,6 +14,7 @@ /* core includes */ #include #include +#include #include using namespace Genode; @@ -83,3 +84,5 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + +Cpu::User_context::User_context() { cpsr = Psr::init_user(); } diff --git a/base-hw/src/core/target.inc b/base-hw/src/core/target.inc index c1ae4e2562..ad6551119f 100644 --- a/base-hw/src/core/target.inc +++ b/base-hw/src/core/target.inc @@ -52,7 +52,6 @@ SRC_CC += console.cc \ kernel/signal_receiver.cc \ kernel/irq.cc \ rm_session_support.cc \ - kernel_support.cc \ trustzone.cc \ pager.cc \ _main.cc diff --git a/base-hw/src/core/vea9x4/no_trustzone/platform_support.cc b/base-hw/src/core/vea9x4/no_trustzone/platform_support.cc index 1f68d40b60..14142b64ae 100644 --- a/base-hw/src/core/vea9x4/no_trustzone/platform_support.cc +++ b/base-hw/src/core/vea9x4/no_trustzone/platform_support.cc @@ -94,3 +94,6 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) }; return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + + +Cpu::User_context::User_context() { cpsr = Psr::init_user(); } diff --git a/base-hw/src/core/vea9x4/trustzone/kernel_support.cc b/base-hw/src/core/vea9x4/trustzone/kernel_support.cc deleted file mode 100644 index 3b2c4c2a86..0000000000 --- a/base-hw/src/core/vea9x4/trustzone/kernel_support.cc +++ /dev/null @@ -1,21 +0,0 @@ -/* - * \brief Kernel-specific implementations for Versatile Express with TZ - * \author Stefan Kalkowski - * \date 2012-10-11 - */ - -/* - * Copyright (C) 2012-2013 Genode Labs GmbH - * - * This file is part of the Genode OS framework, which is distributed - * under the terms of the GNU General Public License version 2. - */ - -/* core includes */ -#include - -using namespace Genode; - -Cpu::User_context::User_context() { - cpsr = Psr::init_user_with_trustzone(); } - diff --git a/base-hw/src/core/vea9x4/trustzone/platform_support.cc b/base-hw/src/core/vea9x4/trustzone/platform_support.cc index 1a06083078..c793573971 100644 --- a/base-hw/src/core/vea9x4/trustzone/platform_support.cc +++ b/base-hw/src/core/vea9x4/trustzone/platform_support.cc @@ -13,9 +13,9 @@ /* core includes */ #include +#include #include #include -#include #include using namespace Genode; @@ -93,3 +93,6 @@ Native_region * Platform::_core_only_mmio_regions(unsigned const i) }; return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } + + +Cpu::User_context::User_context() { cpsr = Psr::init_user_with_trustzone(); } diff --git a/base-hw/src/core/vea9x4/trustzone/target.mk b/base-hw/src/core/vea9x4/trustzone/target.mk index 498bcd2cee..6cd07815a1 100644 --- a/base-hw/src/core/vea9x4/trustzone/target.mk +++ b/base-hw/src/core/vea9x4/trustzone/target.mk @@ -20,7 +20,6 @@ SRC_CC += vm_session_component.cc # declare source paths vpath platform_support.cc $(REP_DIR)/src/core/vea9x4/trustzone vpath platform_services.cc $(REP_DIR)/src/core/vea9x4/trustzone -vpath kernel_support.cc $(REP_DIR)/src/core/vea9x4/trustzone vpath trustzone.cc $(REP_DIR)/src/core/vea9x4/trustzone vpath vm_session_component.cc $(REP_DIR)/src/core