1 /** 2 * @file sfcc.h 3 * @brief SPI Flash Controller Cache(SFCC) function prototypes and data types. 4 */ 5 6 /****************************************************************************** 7 * 8 * Copyright (C) 2022-2023 Maxim Integrated Products, Inc. (now owned by 9 * Analog Devices, Inc.), 10 * Copyright (C) 2023-2024 Analog Devices, Inc. 11 * 12 * Licensed under the Apache License, Version 2.0 (the "License"); 13 * you may not use this file except in compliance with the License. 14 * You may obtain a copy of the License at 15 * 16 * http://www.apache.org/licenses/LICENSE-2.0 17 * 18 * Unless required by applicable law or agreed to in writing, software 19 * distributed under the License is distributed on an "AS IS" BASIS, 20 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 21 * See the License for the specific language governing permissions and 22 * limitations under the License. 23 * 24 ******************************************************************************/ 25 26 /* Define to prevent redundant inclusion */ 27 #ifndef LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32570_SFCC_H_ 28 #define LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32570_SFCC_H_ 29 30 /* **** Includes **** */ 31 #include <stdint.h> 32 #include "icc_regs.h" 33 #include "icc.h" 34 35 #ifdef __cplusplus 36 extern "C" { 37 #endif 38 39 /** 40 * @defgroup sfcc SFCC 41 * @ingroup periphlibs 42 * @{ 43 */ 44 45 /** 46 * @brief Reads the data from the Cache Id Register. 47 * @param cid Enumeration type for Cache Id Register. 48 * @retval Returns the contents of Cache Id Register. 49 */ 50 int MXC_SFCC_ID(mxc_icc_info_t cid); 51 52 /** 53 * @brief Enable the instruction cache controller. 54 */ 55 void MXC_SFCC_Enable(void); 56 57 /** 58 * @brief Disable the instruction cache controller. 59 */ 60 void MXC_SFCC_Disable(void); 61 62 /** 63 * @brief Flush the instruction cache controller. 64 */ 65 void MXC_SFCC_Flush(void); 66 67 /**@} end of group sfcc */ 68 69 #ifdef __cplusplus 70 } 71 #endif 72 73 #endif // LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32570_SFCC_H_ 74