1 /**
2   ******************************************************************************
3   * @file    low_level_ospi_device.c
4   * @author  MCD Application Team
5   * @brief   This file contains device definition for low_level_ospi_device
6   ******************************************************************************
7   * @attention
8   *
9   * <h2><center>&copy; Copyright (c) 2020 STMicroelectronics.
10   * All rights reserved.</center></h2>
11   *
12   * This software component is licensed by ST under BSD 3-Clause license,
13   * the "License"; You may not use this file except in compliance with the
14   * License. You may obtain a copy of the License at:
15   *                        opensource.org/licenses/BSD-3-Clause
16   *
17   ******************************************************************************
18   */
19 #include "flash_layout.h"
20 #include "low_level_ospi_flash.h"
21 /* give access to all flash */
22 static struct ospi_flash_range access_vect[] =
23 {
24   {0, OSPI_FLASH_TOTAL_SIZE}
25 };
26 
27 struct low_level_ospi_device OSPI_FLASH0_DEV =
28 {
29   .erase = { .nb = sizeof(access_vect) / sizeof(struct ospi_flash_range), .range = access_vect},
30   .write = { .nb = sizeof(access_vect) / sizeof(struct ospi_flash_range), .range = access_vect},
31   .read_error = 1
32 };
33 
34 
35 
36