From dc2e4b70240f64cd83789cbeffbd2f76263364e1 Mon Sep 17 00:00:00 2001 From: "chao.an" Date: Sat, 16 Apr 2022 00:12:20 +0800 Subject: [PATCH] boards/ostest: remove board ostest implement Signed-off-by: chao.an --- .../cxd56xx/spresense/configs/rndis/defconfig | 1 - .../spresense/configs/rndis_smp/defconfig | 1 - .../cxd56xx/spresense/configs/smp/defconfig | 1 - .../cxd56xx/spresense/configs/wifi/defconfig | 1 - .../spresense/configs/wifi_smp/defconfig | 1 - boards/arm/cxd56xx/spresense/src/Make.defs | 4 - .../arm/cxd56xx/spresense/src/cxd56_ostest.c | 97 ------------------ boards/arm/lpc43xx/bambino-200e/src/Makefile | 4 - .../lpc43xx/bambino-200e/src/lpc43_ostest.c | 94 ------------------ .../arm/lpc43xx/lpc4330-xplorer/src/Makefile | 4 - .../lpc4330-xplorer/src/lpc43_ostest.c | 98 ------------------- boards/arm/lpc43xx/lpc4357-evb/src/Makefile | 4 - .../lpc43xx/lpc4357-evb/src/lpc43_ostest.c | 98 ------------------- boards/arm/lpc43xx/lpc4370-link2/src/Makefile | 4 - .../lpc43xx/lpc4370-link2/src/lpc43_ostest.c | 98 ------------------- boards/arm/sama5/giant-board/src/Makefile | 4 - boards/arm/sama5/giant-board/src/sam_ostest.c | 94 ------------------ boards/arm/sama5/sama5d2-xult/src/Makefile | 4 - .../arm/sama5/sama5d2-xult/src/sam_ostest.c | 98 ------------------- .../arm/sama5/sama5d3-xplained/src/Makefile | 4 - .../sama5/sama5d3-xplained/src/sam_ostest.c | 98 ------------------- boards/arm/sama5/sama5d3x-ek/src/Makefile | 4 - boards/arm/sama5/sama5d3x-ek/src/sam_ostest.c | 98 ------------------- boards/arm/sama5/sama5d4-ek/src/Makefile | 4 - boards/arm/sama5/sama5d4-ek/src/sam_ostest.c | 98 ------------------- .../arm/stm32/olimex-stm32-e407/src/Make.defs | 4 - .../arm/stm32/olimex-stm32-h407/src/Make.defs | 4 - boards/arm/stm32/omnibusf4/src/Make.defs | 4 - boards/arm/stm32/omnibusf4/src/stm32_ostest.c | 96 ------------------ boards/arm/stm32/stm3240g-eval/src/Make.defs | 4 - .../stm32/stm3240g-eval/src/stm32_ostest.c | 98 ------------------- .../arm/stm32/stm32f429i-disco/src/Make.defs | 4 - .../stm32/stm32f429i-disco/src/stm32_ostest.c | 98 ------------------- .../stm32f4discovery/configs/wifi/defconfig | 1 - .../arm/stm32/stm32f4discovery/src/Make.defs | 4 - .../stm32/stm32f4discovery/src/stm32_ostest.c | 94 ------------------ .../arm/stm32f7/stm32f746g-disco/src/Makefile | 4 - .../stm32f746g-disco/src/stm32_ostest.c | 98 ------------------- .../arm/stm32f7/stm32f769i-disco/src/Makefile | 4 - .../stm32f769i-disco/src/stm32_ostest.c | 98 ------------------- .../nucleo-h743zi2/configs/jumbo/defconfig | 1 - .../arm/stm32h7/nucleo-h743zi2/src/Makefile | 4 - .../stm32h7/nucleo-h743zi2/src/stm32_ostest.c | 94 ------------------ boards/arm/xmc4/xmc4500-relax/src/Makefile | 4 - .../arm/xmc4/xmc4500-relax/src/xmc4_ostest.c | 94 ------------------ boards/arm/xmc4/xmc4700-relax/src/Makefile | 4 - .../arm/xmc4/xmc4700-relax/src/xmc4_ostest.c | 94 ------------------ .../bl602/bl602evb/configs/elf/defconfig | 1 - .../bl602/bl602evb/configs/fpu/defconfig | 1 - .../bl602/bl602evb/configs/wifi/defconfig | 1 - boards/risc-v/bl602/bl602evb/src/Makefile | 4 - .../risc-v/bl602/bl602evb/src/bl602_ostest.c | 94 ------------------ .../c906/smartl-c906/configs/elf/defconfig | 1 - .../c906/smartl-c906/configs/fpu/defconfig | 1 - .../c906/smartl-c906/configs/knsh/defconfig | 1 - .../c906/smartl-c906/configs/module/defconfig | 1 - .../c906/smartl-c906/configs/nsh/defconfig | 1 - .../c906/smartl-c906/configs/sotest/defconfig | 1 - boards/risc-v/c906/smartl-c906/src/Makefile | 4 - .../risc-v/c906/smartl-c906/src/c906_ostest.c | 94 ------------------ boards/risc-v/mpfs/common/src/Make.defs | 4 - boards/risc-v/mpfs/common/src/mpfs_ostest.c | 94 ------------------ .../risc-v/mpfs/icicle/configs/knsh/defconfig | 1 - .../qemu-rv/rv-virt/configs/nsh/defconfig | 1 - .../qemu-rv/rv-virt/configs/nsh64/defconfig | 1 - .../qemu-rv/rv-virt/configs/smp/defconfig | 1 - .../qemu-rv/rv-virt/configs/smp64/defconfig | 1 - boards/risc-v/qemu-rv/rv-virt/src/Makefile | 2 +- .../qemu-rv/rv-virt/src/qemu_rv_ostest.c | 94 ------------------ 69 files changed, 1 insertion(+), 2329 deletions(-) delete mode 100644 boards/arm/cxd56xx/spresense/src/cxd56_ostest.c delete mode 100644 boards/arm/lpc43xx/bambino-200e/src/lpc43_ostest.c delete mode 100644 boards/arm/lpc43xx/lpc4330-xplorer/src/lpc43_ostest.c delete mode 100644 boards/arm/lpc43xx/lpc4357-evb/src/lpc43_ostest.c delete mode 100644 boards/arm/lpc43xx/lpc4370-link2/src/lpc43_ostest.c delete mode 100644 boards/arm/sama5/giant-board/src/sam_ostest.c delete mode 100644 boards/arm/sama5/sama5d2-xult/src/sam_ostest.c delete mode 100644 boards/arm/sama5/sama5d3-xplained/src/sam_ostest.c delete mode 100644 boards/arm/sama5/sama5d3x-ek/src/sam_ostest.c delete mode 100644 boards/arm/sama5/sama5d4-ek/src/sam_ostest.c delete mode 100644 boards/arm/stm32/omnibusf4/src/stm32_ostest.c delete mode 100644 boards/arm/stm32/stm3240g-eval/src/stm32_ostest.c delete mode 100644 boards/arm/stm32/stm32f429i-disco/src/stm32_ostest.c delete mode 100644 boards/arm/stm32/stm32f4discovery/src/stm32_ostest.c delete mode 100644 boards/arm/stm32f7/stm32f746g-disco/src/stm32_ostest.c delete mode 100644 boards/arm/stm32f7/stm32f769i-disco/src/stm32_ostest.c delete mode 100644 boards/arm/stm32h7/nucleo-h743zi2/src/stm32_ostest.c delete mode 100644 boards/arm/xmc4/xmc4500-relax/src/xmc4_ostest.c delete mode 100644 boards/arm/xmc4/xmc4700-relax/src/xmc4_ostest.c delete mode 100644 boards/risc-v/bl602/bl602evb/src/bl602_ostest.c delete mode 100644 boards/risc-v/c906/smartl-c906/src/c906_ostest.c delete mode 100755 boards/risc-v/mpfs/common/src/mpfs_ostest.c delete mode 100644 boards/risc-v/qemu-rv/rv-virt/src/qemu_rv_ostest.c diff --git a/boards/arm/cxd56xx/spresense/configs/rndis/defconfig b/boards/arm/cxd56xx/spresense/configs/rndis/defconfig index 00e277734d0..da2c6be2d7a 100644 --- a/boards/arm/cxd56xx/spresense/configs/rndis/defconfig +++ b/boards/arm/cxd56xx/spresense/configs/rndis/defconfig @@ -152,7 +152,6 @@ CONFIG_SYSTEM_NXPLAYER=y CONFIG_SYSTEM_NXRECORDER=y CONFIG_SYSTEM_PING=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=64 CONFIG_UART1_SERIAL_CONSOLE=y CONFIG_USBDEV=y CONFIG_USBDEV_DMA=y diff --git a/boards/arm/cxd56xx/spresense/configs/rndis_smp/defconfig b/boards/arm/cxd56xx/spresense/configs/rndis_smp/defconfig index 903de5f57d9..80f3d2e3d91 100644 --- a/boards/arm/cxd56xx/spresense/configs/rndis_smp/defconfig +++ b/boards/arm/cxd56xx/spresense/configs/rndis_smp/defconfig @@ -157,7 +157,6 @@ CONFIG_SYSTEM_SYSTEM=y CONFIG_SYSTEM_TASKSET=y CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=64 CONFIG_TESTING_SMP=y CONFIG_UART1_SERIAL_CONSOLE=y CONFIG_USBDEV=y diff --git a/boards/arm/cxd56xx/spresense/configs/smp/defconfig b/boards/arm/cxd56xx/spresense/configs/smp/defconfig index bbf2211f225..4209329e9ea 100644 --- a/boards/arm/cxd56xx/spresense/configs/smp/defconfig +++ b/boards/arm/cxd56xx/spresense/configs/smp/defconfig @@ -57,6 +57,5 @@ CONFIG_SYSTEM_NSH=y CONFIG_SYSTEM_SYSTEM=y CONFIG_SYSTEM_TASKSET=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=64 CONFIG_TESTING_SMP=y CONFIG_UART1_SERIAL_CONSOLE=y diff --git a/boards/arm/cxd56xx/spresense/configs/wifi/defconfig b/boards/arm/cxd56xx/spresense/configs/wifi/defconfig index 13e23908577..2fd37f87490 100644 --- a/boards/arm/cxd56xx/spresense/configs/wifi/defconfig +++ b/boards/arm/cxd56xx/spresense/configs/wifi/defconfig @@ -159,7 +159,6 @@ CONFIG_SYSTEM_NXRECORDER=y CONFIG_SYSTEM_USBMSC=y CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=64 CONFIG_UART1_SERIAL_CONSOLE=y CONFIG_USBDEV=y CONFIG_USBDEV_DMA=y diff --git a/boards/arm/cxd56xx/spresense/configs/wifi_smp/defconfig b/boards/arm/cxd56xx/spresense/configs/wifi_smp/defconfig index 0151beabf28..69f73e0a2a3 100644 --- a/boards/arm/cxd56xx/spresense/configs/wifi_smp/defconfig +++ b/boards/arm/cxd56xx/spresense/configs/wifi_smp/defconfig @@ -167,7 +167,6 @@ CONFIG_SYSTEM_TASKSET=y CONFIG_SYSTEM_USBMSC=y CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=64 CONFIG_TESTING_SMP=y CONFIG_UART1_SERIAL_CONSOLE=y CONFIG_USBDEV=y diff --git a/boards/arm/cxd56xx/spresense/src/Make.defs b/boards/arm/cxd56xx/spresense/src/Make.defs index 1bb84d5462b..ff4b0f48886 100644 --- a/boards/arm/cxd56xx/spresense/src/Make.defs +++ b/boards/arm/cxd56xx/spresense/src/Make.defs @@ -31,10 +31,6 @@ ifeq ($(CONFIG_BOARDCTL_IOCTL),y) CSRCS += cxd56_ioctl.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += cxd56_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += cxd56_leds.c else diff --git a/boards/arm/cxd56xx/spresense/src/cxd56_ostest.c b/boards/arm/cxd56xx/spresense/src/cxd56_ostest.c deleted file mode 100644 index 1175382fc35..00000000000 --- a/boards/arm/cxd56xx/spresense/src/cxd56_ostest.c +++ /dev/null @@ -1,97 +0,0 @@ -/**************************************************************************** - * boards/arm/cxd56xx/spresense/src/cxd56_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/lpc43xx/bambino-200e/src/Makefile b/boards/arm/lpc43xx/bambino-200e/src/Makefile index 5f07e77ee2a..a38320c0298 100644 --- a/boards/arm/lpc43xx/bambino-200e/src/Makefile +++ b/boards/arm/lpc43xx/bambino-200e/src/Makefile @@ -30,10 +30,6 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += lpc43_appinit.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += lpc43_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += lpc43_autoleds.c else diff --git a/boards/arm/lpc43xx/bambino-200e/src/lpc43_ostest.c b/boards/arm/lpc43xx/bambino-200e/src/lpc43_ostest.c deleted file mode 100644 index 8492c28abb4..00000000000 --- a/boards/arm/lpc43xx/bambino-200e/src/lpc43_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/arm/lpc43xx/bambino-200e/src/lpc43_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "bambino-200e.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/lpc43xx/lpc4330-xplorer/src/Makefile b/boards/arm/lpc43xx/lpc4330-xplorer/src/Makefile index 8deabf2a3a2..4f02477a51f 100644 --- a/boards/arm/lpc43xx/lpc4330-xplorer/src/Makefile +++ b/boards/arm/lpc43xx/lpc4330-xplorer/src/Makefile @@ -26,10 +26,6 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += lpc43_appinit.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += lpc43_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += lpc43_autoleds.c else diff --git a/boards/arm/lpc43xx/lpc4330-xplorer/src/lpc43_ostest.c b/boards/arm/lpc43xx/lpc4330-xplorer/src/lpc43_ostest.c deleted file mode 100644 index 4a40ae092a3..00000000000 --- a/boards/arm/lpc43xx/lpc4330-xplorer/src/lpc43_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/lpc43xx/lpc4330-xplorer/src/lpc43_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "lpc4330-xplorer.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/lpc43xx/lpc4357-evb/src/Makefile b/boards/arm/lpc43xx/lpc4357-evb/src/Makefile index b669b3cde45..5e7eed65367 100644 --- a/boards/arm/lpc43xx/lpc4357-evb/src/Makefile +++ b/boards/arm/lpc43xx/lpc4357-evb/src/Makefile @@ -26,10 +26,6 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += lpc43_appinit.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += lpc43_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += lpc43_autoleds.c else diff --git a/boards/arm/lpc43xx/lpc4357-evb/src/lpc43_ostest.c b/boards/arm/lpc43xx/lpc4357-evb/src/lpc43_ostest.c deleted file mode 100644 index 7881b3467ed..00000000000 --- a/boards/arm/lpc43xx/lpc4357-evb/src/lpc43_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/lpc43xx/lpc4357-evb/src/lpc43_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "lpc4357-evb.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function - * will return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/lpc43xx/lpc4370-link2/src/Makefile b/boards/arm/lpc43xx/lpc4370-link2/src/Makefile index e251651d6ef..0f20f8dcd5a 100644 --- a/boards/arm/lpc43xx/lpc4370-link2/src/Makefile +++ b/boards/arm/lpc43xx/lpc4370-link2/src/Makefile @@ -26,10 +26,6 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += lpc43_appinit.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += lpc43_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += lpc43_autoleds.c else diff --git a/boards/arm/lpc43xx/lpc4370-link2/src/lpc43_ostest.c b/boards/arm/lpc43xx/lpc4370-link2/src/lpc43_ostest.c deleted file mode 100644 index f416e346ddd..00000000000 --- a/boards/arm/lpc43xx/lpc4370-link2/src/lpc43_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/lpc43xx/lpc4370-link2/src/lpc43_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "lpc4370-link2.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/sama5/giant-board/src/Makefile b/boards/arm/sama5/giant-board/src/Makefile index 15ebdd1e83e..7ca41149876 100644 --- a/boards/arm/sama5/giant-board/src/Makefile +++ b/boards/arm/sama5/giant-board/src/Makefile @@ -88,10 +88,6 @@ ifeq ($(CONFIG_USBMSC),y) CSRCS += sam_usbmsc.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += sam_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += sam_autoleds.c else diff --git a/boards/arm/sama5/giant-board/src/sam_ostest.c b/boards/arm/sama5/giant-board/src/sam_ostest.c deleted file mode 100644 index 40b8952f883..00000000000 --- a/boards/arm/sama5/giant-board/src/sam_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/arm/sama5/giant-board/src/sam_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "giant-board.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*FPU_CONTEXT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*FPU_CONTEXT_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*FPU_CONTEXT_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/sama5/sama5d2-xult/src/Makefile b/boards/arm/sama5/sama5d2-xult/src/Makefile index d31528ac9f6..e1b01cef051 100644 --- a/boards/arm/sama5/sama5d2-xult/src/Makefile +++ b/boards/arm/sama5/sama5d2-xult/src/Makefile @@ -110,10 +110,6 @@ ifeq ($(CONFIG_USBMSC),y) CSRCS += sam_usbmsc.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += sam_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += sam_autoleds.c else diff --git a/boards/arm/sama5/sama5d2-xult/src/sam_ostest.c b/boards/arm/sama5/sama5d2-xult/src/sam_ostest.c deleted file mode 100644 index b6f9993d346..00000000000 --- a/boards/arm/sama5/sama5d2-xult/src/sam_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/sama5/sama5d2-xult/src/sam_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "sama5d2-xult.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*FPU_CONTEXT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*FPU_CONTEXT_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*FPU_CONTEXT_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/sama5/sama5d3-xplained/src/Makefile b/boards/arm/sama5/sama5d3-xplained/src/Makefile index 74dd01f0de2..8a557aeba40 100644 --- a/boards/arm/sama5/sama5d3-xplained/src/Makefile +++ b/boards/arm/sama5/sama5d3-xplained/src/Makefile @@ -102,10 +102,6 @@ ifeq ($(CONFIG_USBMSC),y) CSRCS += sam_usbmsc.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += sam_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += sam_autoleds.c else diff --git a/boards/arm/sama5/sama5d3-xplained/src/sam_ostest.c b/boards/arm/sama5/sama5d3-xplained/src/sam_ostest.c deleted file mode 100644 index 543347ba4fa..00000000000 --- a/boards/arm/sama5/sama5d3-xplained/src/sam_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/sama5/sama5d3-xplained/src/sam_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "sama5d3-xplained.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*FPU_CONTEXT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*FPU_CONTEXT_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*FPU_CONTEXT_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/sama5/sama5d3x-ek/src/Makefile b/boards/arm/sama5/sama5d3x-ek/src/Makefile index 6c6b035a282..71023e784e4 100644 --- a/boards/arm/sama5/sama5d3x-ek/src/Makefile +++ b/boards/arm/sama5/sama5d3x-ek/src/Makefile @@ -120,10 +120,6 @@ ifeq ($(CONFIG_USBMSC),y) CSRCS += sam_usbmsc.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += sam_ostest.c -endif - ifeq ($(CONFIG_SAMA5_TSD),y) CSRCS += sam_touchscreen.c endif diff --git a/boards/arm/sama5/sama5d3x-ek/src/sam_ostest.c b/boards/arm/sama5/sama5d3x-ek/src/sam_ostest.c deleted file mode 100644 index 4f7efeecc62..00000000000 --- a/boards/arm/sama5/sama5d3x-ek/src/sam_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/sama5/sama5d3x-ek/src/sam_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "sama5d3x-ek.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*FPU_CONTEXT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*FPU_CONTEXT_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*FPU_CONTEXT_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/sama5/sama5d4-ek/src/Makefile b/boards/arm/sama5/sama5d4-ek/src/Makefile index 9388bb3fd37..ee4f58cb850 100644 --- a/boards/arm/sama5/sama5d4-ek/src/Makefile +++ b/boards/arm/sama5/sama5d4-ek/src/Makefile @@ -116,10 +116,6 @@ ifeq ($(CONFIG_USBMSC),y) CSRCS += sam_usbmsc.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += sam_ostest.c -endif - ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += sam_autoleds.c else diff --git a/boards/arm/sama5/sama5d4-ek/src/sam_ostest.c b/boards/arm/sama5/sama5d4-ek/src/sam_ostest.c deleted file mode 100644 index 03bd727574b..00000000000 --- a/boards/arm/sama5/sama5d4-ek/src/sam_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/sama5/sama5d4-ek/src/sam_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "sama5d4-ek.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*FPU_CONTEXT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*FPU_CONTEXT_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*FPU_CONTEXT_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/stm32/olimex-stm32-e407/src/Make.defs b/boards/arm/stm32/olimex-stm32-e407/src/Make.defs index a7bb9d375bb..69f09fd6df5 100644 --- a/boards/arm/stm32/olimex-stm32-e407/src/Make.defs +++ b/boards/arm/stm32/olimex-stm32-e407/src/Make.defs @@ -60,10 +60,6 @@ ifeq ($(CONFIG_CAN),y) CSRCS += stm32_can.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_DAC),y) CSRCS += stm32_dac.c endif diff --git a/boards/arm/stm32/olimex-stm32-h407/src/Make.defs b/boards/arm/stm32/olimex-stm32-h407/src/Make.defs index 941b2adcfd6..1d83f6ebe90 100644 --- a/boards/arm/stm32/olimex-stm32-h407/src/Make.defs +++ b/boards/arm/stm32/olimex-stm32-h407/src/Make.defs @@ -64,10 +64,6 @@ ifeq ($(CONFIG_STM32_SDIO),y) CSRCS += stm32_sdio.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += stm32_ostest.c -endif - DEPPATH += --dep-path board VPATH += :board CFLAGS += $(shell $(INCDIR) "$(CC)" $(TOPDIR)$(DELIM)arch$(DELIM)$(CONFIG_ARCH)$(DELIM)src$(DELIM)board$(DELIM)board) diff --git a/boards/arm/stm32/omnibusf4/src/Make.defs b/boards/arm/stm32/omnibusf4/src/Make.defs index 3e7e821550b..405c979ccaa 100644 --- a/boards/arm/stm32/omnibusf4/src/Make.defs +++ b/boards/arm/stm32/omnibusf4/src/Make.defs @@ -60,10 +60,6 @@ ifeq ($(CONFIG_ARCH_IDLE_CUSTOM),y) CSRCS += stm32_idle.c endif -ifeq ($(CONFIG_TESTING_OSTEST),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_TIMER),y) CSRCS += stm32_timer.c endif diff --git a/boards/arm/stm32/omnibusf4/src/stm32_ostest.c b/boards/arm/stm32/omnibusf4/src/stm32_ostest.c deleted file mode 100644 index 45a854417ef..00000000000 --- a/boards/arm/stm32/omnibusf4/src/stm32_ostest.c +++ /dev/null @@ -1,96 +0,0 @@ -/**************************************************************************** - * boards/arm/stm32/omnibusf4/src/stm32_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "omnibusf4.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && \ - !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4 * SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/stm32/stm3240g-eval/src/Make.defs b/boards/arm/stm32/stm3240g-eval/src/Make.defs index bb1822e029b..a235b8112cb 100644 --- a/boards/arm/stm32/stm3240g-eval/src/Make.defs +++ b/boards/arm/stm32/stm3240g-eval/src/Make.defs @@ -57,10 +57,6 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += stm32_appinit.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_INPUT_STMPE811),y) CSRCS += stm32_stmpe811.c endif diff --git a/boards/arm/stm32/stm3240g-eval/src/stm32_ostest.c b/boards/arm/stm32/stm3240g-eval/src/stm32_ostest.c deleted file mode 100644 index db0f92fa228..00000000000 --- a/boards/arm/stm32/stm3240g-eval/src/stm32_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/stm32/stm3240g-eval/src/stm32_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "stm3240g-eval.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/stm32/stm32f429i-disco/src/Make.defs b/boards/arm/stm32/stm32f429i-disco/src/Make.defs index 9d15d35b6c4..6ce6c93cb71 100644 --- a/boards/arm/stm32/stm32f429i-disco/src/Make.defs +++ b/boards/arm/stm32/stm32f429i-disco/src/Make.defs @@ -63,10 +63,6 @@ ifeq ($(and \ CSRCS += stm32_lcd.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_PWM),y) CSRCS += stm32_pwm.c endif diff --git a/boards/arm/stm32/stm32f429i-disco/src/stm32_ostest.c b/boards/arm/stm32/stm32f429i-disco/src/stm32_ostest.c deleted file mode 100644 index 6c79bd6bee5..00000000000 --- a/boards/arm/stm32/stm32f429i-disco/src/stm32_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/stm32/stm32f429i-disco/src/stm32_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "stm32f429i-disco.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/stm32/stm32f4discovery/configs/wifi/defconfig b/boards/arm/stm32/stm32f4discovery/configs/wifi/defconfig index f82dda52b09..346c91707fe 100644 --- a/boards/arm/stm32/stm32f4discovery/configs/wifi/defconfig +++ b/boards/arm/stm32/stm32f4discovery/configs/wifi/defconfig @@ -100,7 +100,6 @@ CONFIG_SYSTEM_NSH_SYMTAB_ARRAYNAME="g_symtab" CONFIG_SYSTEM_NSH_SYMTAB_COUNTNAME="g_nsymbols" CONFIG_SYSTEM_NTPC=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=132 CONFIG_USART2_RXBUFSIZE=128 CONFIG_USART2_SERIAL_CONSOLE=y CONFIG_USART2_TXBUFSIZE=128 diff --git a/boards/arm/stm32/stm32f4discovery/src/Make.defs b/boards/arm/stm32/stm32f4discovery/src/Make.defs index d0e06dc9da9..89fb34f1547 100644 --- a/boards/arm/stm32/stm32f4discovery/src/Make.defs +++ b/boards/arm/stm32/stm32f4discovery/src/Make.defs @@ -131,10 +131,6 @@ ifeq ($(CONFIG_LCD_UG2864HSWEG01),y) CSRCS += stm32_ug2864hsweg01.c endif -ifeq ($(CONFIG_TESTING_OSTEST),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_TIMER),y) CSRCS += stm32_timer.c endif diff --git a/boards/arm/stm32/stm32f4discovery/src/stm32_ostest.c b/boards/arm/stm32/stm32f4discovery/src/stm32_ostest.c deleted file mode 100644 index 44af8111d95..00000000000 --- a/boards/arm/stm32/stm32f4discovery/src/stm32_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/arm/stm32/stm32f4discovery/src/stm32_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "stm32f4discovery.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/stm32f7/stm32f746g-disco/src/Makefile b/boards/arm/stm32f7/stm32f746g-disco/src/Makefile index 7ce6fed1dad..142e3d97295 100644 --- a/boards/arm/stm32f7/stm32f746g-disco/src/Makefile +++ b/boards/arm/stm32f7/stm32f746g-disco/src/Makefile @@ -40,10 +40,6 @@ ifeq ($(CONFIG_ADC),y) CSRCS += stm32_adc.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_SPORADIC_INSTRUMENTATION),y) CSRCS += stm32_sporadic.c endif diff --git a/boards/arm/stm32f7/stm32f746g-disco/src/stm32_ostest.c b/boards/arm/stm32f7/stm32f746g-disco/src/stm32_ostest.c deleted file mode 100644 index 976450cd2bb..00000000000 --- a/boards/arm/stm32f7/stm32f746g-disco/src/stm32_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/stm32f7/stm32f746g-disco/src/stm32_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "stm32f746g-disco.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/stm32f7/stm32f769i-disco/src/Makefile b/boards/arm/stm32f7/stm32f769i-disco/src/Makefile index 7df48a10a90..2c1888268f4 100644 --- a/boards/arm/stm32f7/stm32f769i-disco/src/Makefile +++ b/boards/arm/stm32f7/stm32f769i-disco/src/Makefile @@ -36,10 +36,6 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += stm32_appinitialize.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_PWM),y) CSRCS += stm32_pwm.c endif diff --git a/boards/arm/stm32f7/stm32f769i-disco/src/stm32_ostest.c b/boards/arm/stm32f7/stm32f769i-disco/src/stm32_ostest.c deleted file mode 100644 index 71cc535dbf5..00000000000 --- a/boards/arm/stm32f7/stm32f769i-disco/src/stm32_ostest.c +++ /dev/null @@ -1,98 +0,0 @@ -/**************************************************************************** - * boards/arm/stm32f7/stm32f769i-disco/src/stm32_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "stm32f769i-disco.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Private Functions - ****************************************************************************/ - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4 * SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/stm32h7/nucleo-h743zi2/configs/jumbo/defconfig b/boards/arm/stm32h7/nucleo-h743zi2/configs/jumbo/defconfig index b631fe000e1..ee449cc203f 100644 --- a/boards/arm/stm32h7/nucleo-h743zi2/configs/jumbo/defconfig +++ b/boards/arm/stm32h7/nucleo-h743zi2/configs/jumbo/defconfig @@ -130,7 +130,6 @@ CONFIG_TESTING_FSTEST_STACKSIZE=2048 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_GETPRIME_STACKSIZE=2048 CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=132 CONFIG_TESTING_OSTEST_FPUSTACKSIZE=2048 CONFIG_USART3_SERIAL_CONSOLE=y CONFIG_USBHOST=y diff --git a/boards/arm/stm32h7/nucleo-h743zi2/src/Makefile b/boards/arm/stm32h7/nucleo-h743zi2/src/Makefile index 609fd1701f3..222e9f41c85 100644 --- a/boards/arm/stm32h7/nucleo-h743zi2/src/Makefile +++ b/boards/arm/stm32h7/nucleo-h743zi2/src/Makefile @@ -36,10 +36,6 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += stm32_appinitialize.c endif -ifeq ($(CONFIG_TESTING_OSTEST),y) -CSRCS += stm32_ostest.c -endif - ifeq ($(CONFIG_BOARDCTL_RESET),y) CSRCS += stm32_reset.c endif diff --git a/boards/arm/stm32h7/nucleo-h743zi2/src/stm32_ostest.c b/boards/arm/stm32h7/nucleo-h743zi2/src/stm32_ostest.c deleted file mode 100644 index 29e38ef2e01..00000000000 --- a/boards/arm/stm32h7/nucleo-h743zi2/src/stm32_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/arm/stm32h7/nucleo-h743zi2/src/stm32_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "nucleo-h743zi2.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/xmc4/xmc4500-relax/src/Makefile b/boards/arm/xmc4/xmc4500-relax/src/Makefile index 463afc99a6e..05d500d715a 100644 --- a/boards/arm/xmc4/xmc4500-relax/src/Makefile +++ b/boards/arm/xmc4/xmc4500-relax/src/Makefile @@ -44,8 +44,4 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += xmc4_appinit.c endif -ifeq ($(CONFIG_TESTING_OSTEST),y) -CSRCS += xmc4_ostest.c -endif - include $(TOPDIR)/boards/Board.mk diff --git a/boards/arm/xmc4/xmc4500-relax/src/xmc4_ostest.c b/boards/arm/xmc4/xmc4500-relax/src/xmc4_ostest.c deleted file mode 100644 index a7a9a7d72f3..00000000000 --- a/boards/arm/xmc4/xmc4500-relax/src/xmc4_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/arm/xmc4/xmc4500-relax/src/xmc4_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "xmc4500-relax.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/arm/xmc4/xmc4700-relax/src/Makefile b/boards/arm/xmc4/xmc4700-relax/src/Makefile index 38ec1525a3d..ea8d4fb4af5 100644 --- a/boards/arm/xmc4/xmc4700-relax/src/Makefile +++ b/boards/arm/xmc4/xmc4700-relax/src/Makefile @@ -36,8 +36,4 @@ ifeq ($(CONFIG_BOARDCTL),y) CSRCS += xmc4_appinit.c endif -ifeq ($(CONFIG_TESTING_OSTEST),y) -CSRCS += xmc4_ostest.c -endif - include $(TOPDIR)/boards/Board.mk diff --git a/boards/arm/xmc4/xmc4700-relax/src/xmc4_ostest.c b/boards/arm/xmc4/xmc4700-relax/src/xmc4_ostest.c deleted file mode 100644 index bb860e0e133..00000000000 --- a/boards/arm/xmc4/xmc4700-relax/src/xmc4_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/arm/xmc4/xmc4700-relax/src/xmc4_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include -#include - -#include "arm_internal.h" -#include "xmc4700-relax.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4*SW_FPU_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[REG_S0], (4*SW_FPU_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*SW_FPU_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/risc-v/bl602/bl602evb/configs/elf/defconfig b/boards/risc-v/bl602/bl602evb/configs/elf/defconfig index 89e0f7906b3..a04e406f288 100644 --- a/boards/risc-v/bl602/bl602evb/configs/elf/defconfig +++ b/boards/risc-v/bl602/bl602evb/configs/elf/defconfig @@ -66,7 +66,6 @@ CONFIG_TASK_NAME_SIZE=12 CONFIG_TASK_SPAWN_DEFAULT_STACKSIZE=8192 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=132 CONFIG_TIMER=y CONFIG_TIMER_ARCH=y CONFIG_UART0_BAUD=2000000 diff --git a/boards/risc-v/bl602/bl602evb/configs/fpu/defconfig b/boards/risc-v/bl602/bl602evb/configs/fpu/defconfig index 664023349b3..37583ab44a6 100644 --- a/boards/risc-v/bl602/bl602evb/configs/fpu/defconfig +++ b/boards/risc-v/bl602/bl602evb/configs/fpu/defconfig @@ -59,7 +59,6 @@ CONFIG_TASK_NAME_SIZE=12 CONFIG_TASK_SPAWN_DEFAULT_STACKSIZE=8192 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=132 CONFIG_TIMER=y CONFIG_TIMER_ARCH=y CONFIG_UART0_BAUD=2000000 diff --git a/boards/risc-v/bl602/bl602evb/configs/wifi/defconfig b/boards/risc-v/bl602/bl602evb/configs/wifi/defconfig index c9f1a05033a..e5fa4e03804 100644 --- a/boards/risc-v/bl602/bl602evb/configs/wifi/defconfig +++ b/boards/risc-v/bl602/bl602evb/configs/wifi/defconfig @@ -128,7 +128,6 @@ CONFIG_TASK_NAME_SIZE=12 CONFIG_TASK_SPAWN_DEFAULT_STACKSIZE=8192 CONFIG_TESTING_MM=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=132 CONFIG_UART0_BAUD=2000000 CONFIG_UART0_RXBUFSIZE=128 CONFIG_UART0_SERIAL_CONSOLE=y diff --git a/boards/risc-v/bl602/bl602evb/src/Makefile b/boards/risc-v/bl602/bl602evb/src/Makefile index 0fd6eb42751..8cfa6cee637 100644 --- a/boards/risc-v/bl602/bl602evb/src/Makefile +++ b/boards/risc-v/bl602/bl602evb/src/Makefile @@ -33,8 +33,4 @@ ifeq ($(CONFIG_DEV_GPIO),y) CSRCS += bl602_gpio.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += bl602_ostest.c -endif - include $(TOPDIR)/boards/Board.mk diff --git a/boards/risc-v/bl602/bl602evb/src/bl602_ostest.c b/boards/risc-v/bl602/bl602evb/src/bl602_ostest.c deleted file mode 100644 index 64805b5dec6..00000000000 --- a/boards/risc-v/bl602/bl602evb/src/bl602_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/risc-v/bl602/bl602evb/src/bl602_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include - -#include "riscv_internal.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && \ - !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (4 * FPU_XCPT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint32_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[INT_XCPT_REGS], (4*FPU_XCPT_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (4*FPU_XCPT_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/risc-v/c906/smartl-c906/configs/elf/defconfig b/boards/risc-v/c906/smartl-c906/configs/elf/defconfig index 62d7a1cbd45..a75a2cfa7c5 100644 --- a/boards/risc-v/c906/smartl-c906/configs/elf/defconfig +++ b/boards/risc-v/c906/smartl-c906/configs/elf/defconfig @@ -63,5 +63,4 @@ CONFIG_SYSTEM_NSH=y CONFIG_TASK_NAME_SIZE=20 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_UART0_SERIAL_CONSOLE=y diff --git a/boards/risc-v/c906/smartl-c906/configs/fpu/defconfig b/boards/risc-v/c906/smartl-c906/configs/fpu/defconfig index d10e626689b..0bee31ed59a 100644 --- a/boards/risc-v/c906/smartl-c906/configs/fpu/defconfig +++ b/boards/risc-v/c906/smartl-c906/configs/fpu/defconfig @@ -57,5 +57,4 @@ CONFIG_SYSTEM_NSH=y CONFIG_TASK_NAME_SIZE=20 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_UART0_SERIAL_CONSOLE=y diff --git a/boards/risc-v/c906/smartl-c906/configs/knsh/defconfig b/boards/risc-v/c906/smartl-c906/configs/knsh/defconfig index 441d885080b..48ef0eaca15 100644 --- a/boards/risc-v/c906/smartl-c906/configs/knsh/defconfig +++ b/boards/risc-v/c906/smartl-c906/configs/knsh/defconfig @@ -61,5 +61,4 @@ CONFIG_SYSTEM_NSH=y CONFIG_TASK_NAME_SIZE=20 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_UART0_SERIAL_CONSOLE=y diff --git a/boards/risc-v/c906/smartl-c906/configs/module/defconfig b/boards/risc-v/c906/smartl-c906/configs/module/defconfig index 7f7238ef203..c4bd41717ea 100644 --- a/boards/risc-v/c906/smartl-c906/configs/module/defconfig +++ b/boards/risc-v/c906/smartl-c906/configs/module/defconfig @@ -65,5 +65,4 @@ CONFIG_SYSTEM_NSH=y CONFIG_TASK_NAME_SIZE=20 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_UART0_SERIAL_CONSOLE=y diff --git a/boards/risc-v/c906/smartl-c906/configs/nsh/defconfig b/boards/risc-v/c906/smartl-c906/configs/nsh/defconfig index 8cbacfd62e1..193335211f5 100644 --- a/boards/risc-v/c906/smartl-c906/configs/nsh/defconfig +++ b/boards/risc-v/c906/smartl-c906/configs/nsh/defconfig @@ -56,5 +56,4 @@ CONFIG_SYSTEM_NSH=y CONFIG_TASK_NAME_SIZE=20 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_UART0_SERIAL_CONSOLE=y diff --git a/boards/risc-v/c906/smartl-c906/configs/sotest/defconfig b/boards/risc-v/c906/smartl-c906/configs/sotest/defconfig index 13270546828..fb24a30245b 100644 --- a/boards/risc-v/c906/smartl-c906/configs/sotest/defconfig +++ b/boards/risc-v/c906/smartl-c906/configs/sotest/defconfig @@ -63,5 +63,4 @@ CONFIG_SYSTEM_NSH=y CONFIG_TASK_NAME_SIZE=20 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_UART0_SERIAL_CONSOLE=y diff --git a/boards/risc-v/c906/smartl-c906/src/Makefile b/boards/risc-v/c906/smartl-c906/src/Makefile index 86dffec6b37..78c59d08eec 100644 --- a/boards/risc-v/c906/smartl-c906/src/Makefile +++ b/boards/risc-v/c906/smartl-c906/src/Makefile @@ -30,8 +30,4 @@ ifeq ($(CONFIG_ARCH_LEDS),y) CSRCS += c906_leds.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += c906_ostest.c -endif - include $(TOPDIR)/boards/Board.mk diff --git a/boards/risc-v/c906/smartl-c906/src/c906_ostest.c b/boards/risc-v/c906/smartl-c906/src/c906_ostest.c deleted file mode 100644 index ea670d5bca0..00000000000 --- a/boards/risc-v/c906/smartl-c906/src/c906_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/risc-v/c906/smartl-c906/src/c906_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include - -#include "riscv_internal.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && \ - !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (8 * FPU_XCPT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uintptr_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[INT_XCPT_REGS], INT_REG_SIZE * FPU_XCPT_REGS); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, INT_REG_SIZE * FPU_XCPT_REGS) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/risc-v/mpfs/common/src/Make.defs b/boards/risc-v/mpfs/common/src/Make.defs index 2d9465b58a7..6505f672467 100755 --- a/boards/risc-v/mpfs/common/src/Make.defs +++ b/boards/risc-v/mpfs/common/src/Make.defs @@ -26,10 +26,6 @@ ifeq ($(CONFIG_I2C),y) CSRCS += mpfs_i2c.c endif -ifeq ($(CONFIG_ARCH_FPU),y) -CSRCS += mpfs_ostest.c -endif - ifeq ($(CONFIG_SPI),y) CSRCS += mpfs_board_spi.c endif diff --git a/boards/risc-v/mpfs/common/src/mpfs_ostest.c b/boards/risc-v/mpfs/common/src/mpfs_ostest.c deleted file mode 100755 index d85bc811eac..00000000000 --- a/boards/risc-v/mpfs/common/src/mpfs_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/risc-v/mpfs/common/src/mpfs_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include - -#include "riscv_internal.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && \ - !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (8 * FPU_XCPT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uint64_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[INT_XCPT_REGS], (8 * FPU_XCPT_REGS)); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, (8 * FPU_XCPT_REGS)) == 0; -} - -#endif /* HAVE_FPU */ diff --git a/boards/risc-v/mpfs/icicle/configs/knsh/defconfig b/boards/risc-v/mpfs/icicle/configs/knsh/defconfig index e53d5639d9c..9223c2e2210 100644 --- a/boards/risc-v/mpfs/icicle/configs/knsh/defconfig +++ b/boards/risc-v/mpfs/icicle/configs/knsh/defconfig @@ -78,5 +78,4 @@ CONFIG_SYSTEM_TIME64=y CONFIG_TASK_NAME_SIZE=20 CONFIG_TESTING_GETPRIME=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_UART1_SERIAL_CONSOLE=y diff --git a/boards/risc-v/qemu-rv/rv-virt/configs/nsh/defconfig b/boards/risc-v/qemu-rv/rv-virt/configs/nsh/defconfig index b4544075c37..811017d354b 100644 --- a/boards/risc-v/qemu-rv/rv-virt/configs/nsh/defconfig +++ b/boards/risc-v/qemu-rv/rv-virt/configs/nsh/defconfig @@ -66,5 +66,4 @@ CONFIG_START_MONTH=12 CONFIG_START_YEAR=2021 CONFIG_SYSTEM_NSH=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=528 CONFIG_USEC_PER_TICK=1000 diff --git a/boards/risc-v/qemu-rv/rv-virt/configs/nsh64/defconfig b/boards/risc-v/qemu-rv/rv-virt/configs/nsh64/defconfig index f621901598b..2da99c02388 100644 --- a/boards/risc-v/qemu-rv/rv-virt/configs/nsh64/defconfig +++ b/boards/risc-v/qemu-rv/rv-virt/configs/nsh64/defconfig @@ -68,5 +68,4 @@ CONFIG_START_YEAR=2021 CONFIG_SYSTEM_NSH=y CONFIG_SYSTEM_NSH_STACKSIZE=3072 CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_USEC_PER_TICK=1000 diff --git a/boards/risc-v/qemu-rv/rv-virt/configs/smp/defconfig b/boards/risc-v/qemu-rv/rv-virt/configs/smp/defconfig index 6830e95321c..09cbeb05033 100644 --- a/boards/risc-v/qemu-rv/rv-virt/configs/smp/defconfig +++ b/boards/risc-v/qemu-rv/rv-virt/configs/smp/defconfig @@ -68,6 +68,5 @@ CONFIG_START_MONTH=12 CONFIG_START_YEAR=2021 CONFIG_SYSTEM_NSH=y CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=528 CONFIG_TESTING_SMP=y CONFIG_USEC_PER_TICK=1000 diff --git a/boards/risc-v/qemu-rv/rv-virt/configs/smp64/defconfig b/boards/risc-v/qemu-rv/rv-virt/configs/smp64/defconfig index e9a7d67d2b9..3b5cd2ddce2 100644 --- a/boards/risc-v/qemu-rv/rv-virt/configs/smp64/defconfig +++ b/boards/risc-v/qemu-rv/rv-virt/configs/smp64/defconfig @@ -70,6 +70,5 @@ CONFIG_START_YEAR=2021 CONFIG_SYSTEM_NSH=y CONFIG_SYSTEM_NSH_STACKSIZE=3072 CONFIG_TESTING_OSTEST=y -CONFIG_TESTING_OSTEST_FPUSIZE=264 CONFIG_TESTING_SMP=y CONFIG_USEC_PER_TICK=1000 diff --git a/boards/risc-v/qemu-rv/rv-virt/src/Makefile b/boards/risc-v/qemu-rv/rv-virt/src/Makefile index d8a56d84cc5..2dc661b9287 100644 --- a/boards/risc-v/qemu-rv/rv-virt/src/Makefile +++ b/boards/risc-v/qemu-rv/rv-virt/src/Makefile @@ -22,6 +22,6 @@ include $(TOPDIR)/Make.defs RCSRCS = etc/init.d/rcS -CSRCS = qemu_rv_appinit.c qemu_rv_ostest.c +CSRCS = qemu_rv_appinit.c include $(TOPDIR)/boards/Board.mk diff --git a/boards/risc-v/qemu-rv/rv-virt/src/qemu_rv_ostest.c b/boards/risc-v/qemu-rv/rv-virt/src/qemu_rv_ostest.c deleted file mode 100644 index e2dd2165a0d..00000000000 --- a/boards/risc-v/qemu-rv/rv-virt/src/qemu_rv_ostest.c +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** - * boards/risc-v/qemu-rv/rv-virt/src/qemu_rv_ostest.c - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ****************************************************************************/ - -/**************************************************************************** - * Included Files - ****************************************************************************/ - -#include - -#include -#include -#include -#include - -#include - -#include "riscv_internal.h" - -/**************************************************************************** - * Pre-processor Definitions - ****************************************************************************/ - -/* Configuration ************************************************************/ - -#undef HAVE_FPU -#if defined(CONFIG_ARCH_FPU) && \ - !defined(CONFIG_TESTING_OSTEST_FPUTESTDISABLE) && \ - defined(CONFIG_TESTING_OSTEST_FPUSIZE) && \ - defined(CONFIG_SCHED_WAITPID) -# define HAVE_FPU 1 -#endif - -#ifdef HAVE_FPU - -#if CONFIG_TESTING_OSTEST_FPUSIZE != (8 * FPU_XCPT_REGS) -# error "CONFIG_TESTING_OSTEST_FPUSIZE has the wrong size" -#endif - -/**************************************************************************** - * Private Data - ****************************************************************************/ - -static uintptr_t g_saveregs[XCPTCONTEXT_REGS]; - -/**************************************************************************** - * Public Functions - ****************************************************************************/ - -/* Given an array of size CONFIG_TESTING_OSTEST_FPUSIZE, this function will - * return the current FPU registers. - */ - -void arch_getfpu(FAR uint32_t *fpusave) -{ - irqstate_t flags; - - /* Take a snapshot of the thread context right now */ - - flags = enter_critical_section(); - up_saveusercontext(g_saveregs); - - /* Return only the floating register values */ - - memcpy(fpusave, &g_saveregs[INT_XCPT_REGS], INT_REG_SIZE * FPU_XCPT_REGS); - leave_critical_section(flags); -} - -/* Given two arrays of size CONFIG_TESTING_OSTEST_FPUSIZE this function - * will compare them and return true if they are identical. - */ - -bool arch_cmpfpu(FAR const uint32_t *fpusave1, FAR const uint32_t *fpusave2) -{ - return memcmp(fpusave1, fpusave2, INT_REG_SIZE * FPU_XCPT_REGS) == 0; -} - -#endif /* HAVE_FPU */