From dca2ec7e7a570ca1be0fb118d4725d5856d660a7 Mon Sep 17 00:00:00 2001 From: Hugues Kamba Date: Mon, 21 Dec 2020 12:56:45 +0000 Subject: [PATCH 1/2] Correct OSPIF include directory The include directory was incorrectly named QSPIF. --- .../include/{QSPIF => OSPIF}/MX25LM51245G_config.h | 0 .../COMPONENT_OSPIF/include/{QSPIF => OSPIF}/OSPIFBlockDevice.h | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename storage/blockdevice/COMPONENT_OSPIF/include/{QSPIF => OSPIF}/MX25LM51245G_config.h (100%) rename storage/blockdevice/COMPONENT_OSPIF/include/{QSPIF => OSPIF}/OSPIFBlockDevice.h (100%) diff --git a/storage/blockdevice/COMPONENT_OSPIF/include/QSPIF/MX25LM51245G_config.h b/storage/blockdevice/COMPONENT_OSPIF/include/OSPIF/MX25LM51245G_config.h similarity index 100% rename from storage/blockdevice/COMPONENT_OSPIF/include/QSPIF/MX25LM51245G_config.h rename to storage/blockdevice/COMPONENT_OSPIF/include/OSPIF/MX25LM51245G_config.h diff --git a/storage/blockdevice/COMPONENT_OSPIF/include/QSPIF/OSPIFBlockDevice.h b/storage/blockdevice/COMPONENT_OSPIF/include/OSPIF/OSPIFBlockDevice.h similarity index 100% rename from storage/blockdevice/COMPONENT_OSPIF/include/QSPIF/OSPIFBlockDevice.h rename to storage/blockdevice/COMPONENT_OSPIF/include/OSPIF/OSPIFBlockDevice.h From b99822628b8a1c0fafa0a6b87fcf72e6d6e9801b Mon Sep 17 00:00:00 2001 From: Hugues Kamba Date: Mon, 21 Dec 2020 13:04:12 +0000 Subject: [PATCH 2/2] CMake: Add support for OSPIF blockdevice --- storage/CMakeLists.txt | 1 + storage/blockdevice/CMakeLists.txt | 4 ++++ storage/blockdevice/COMPONENT_OSPIF/CMakeLists.txt | 13 +++++++++++++ 3 files changed, 18 insertions(+) create mode 100644 storage/blockdevice/COMPONENT_OSPIF/CMakeLists.txt diff --git a/storage/CMakeLists.txt b/storage/CMakeLists.txt index 558afc7f79a..95d984e0773 100644 --- a/storage/CMakeLists.txt +++ b/storage/CMakeLists.txt @@ -8,6 +8,7 @@ add_library(mbed-storage-blockdevice INTERFACE) add_library(mbed-storage-dataflash INTERFACE) add_library(mbed-storage-flashiap INTERFACE) add_library(mbed-storage-i2cee INTERFACE) +add_library(mbed-storage-ospif INTERFACE) add_library(mbed-storage-qspif INTERFACE) add_library(mbed-storage-sd INTERFACE) add_library(mbed-storage-spif INTERFACE) diff --git a/storage/blockdevice/CMakeLists.txt b/storage/blockdevice/CMakeLists.txt index 39bacf2f076..6181735cd3b 100644 --- a/storage/blockdevice/CMakeLists.txt +++ b/storage/blockdevice/CMakeLists.txt @@ -17,6 +17,10 @@ if("QSPIF" IN_LIST MBED_TARGET_LABELS) add_subdirectory(COMPONENT_QSPIF) endif() +if("OSPIF" IN_LIST MBED_TARGET_LABELS) + add_subdirectory(COMPONENT_OSPIF) +endif() + if("SD" IN_LIST MBED_TARGET_LABELS) add_subdirectory(COMPONENT_SD) endif() diff --git a/storage/blockdevice/COMPONENT_OSPIF/CMakeLists.txt b/storage/blockdevice/COMPONENT_OSPIF/CMakeLists.txt new file mode 100644 index 00000000000..0cd380760aa --- /dev/null +++ b/storage/blockdevice/COMPONENT_OSPIF/CMakeLists.txt @@ -0,0 +1,13 @@ +# Copyright (c) 2020 ARM Limited. All rights reserved. +# SPDX-License-Identifier: Apache-2.0 + +target_include_directories(mbed-storage-ospif + INTERFACE + include + include/OSPIF +) + +target_sources(mbed-storage-ospif + INTERFACE + source/OSPIFBlockDevice.cpp +)