summaryrefslogtreecommitdiff
path: root/ports/stm32/storage.c
AgeCommit message (Collapse)Author
2019-10-13remove ports/stm32Dan Halbert
2018-05-28stm32: Allow to have no storage support if there are no block devices.Damien George
If no block devices are defined by a board then storage support will be disabled. This means there is no filesystem provided by either the internal flash or external SPI flash. But the VFS system can still be enabled and filesystems provided on external devices like an SD card.
2018-05-02stm32/irq: Define IRQ priorities directly as encoded hardware values.Damien George
For a given IRQn (eg UART) there's no need to carry around both a PRI and SUBPRI value (eg IRQ_PRI_UART, IRQ_SUBPRI_UART). Instead, the IRQ_PRI_UART value has been changed in this patch to be the encoded hardware value, using NVIC_EncodePriority. This way the NVIC_SetPriority function can be used directly, instead of going through HAL_NVIC_SetPriority which must do extra processing to encode the PRI+SUBPRI. For a priority grouping of 4 (4 bits for preempt priority, 0 bits for the sub-priority), which is used in the stm32 port, the IRQ_PRI_xxx constants remain unchanged in their value. This patch also "fixes" the use of raise_irq_pri() which should be passed the encoded value (but as mentioned above the unencoded value is the same as the encoded value for priority grouping 4, so there was no bug from this error).
2018-03-10stm32/storage: Provide support for a second block device.Damien George
2018-03-10stm32/storage: Introduce MICROPY_HW_ENABLE_INTERNAL_FLASH_STORAGE cfg.Damien George
This config variable controls whether to support storage on the internal flash of the MCU. It is enabled by default and should be explicitly disabled by boards that don't want internal flash storage.
2018-03-10stm32/storage: Remove all SPI-flash bdev cfg, to be provided per board.Damien George
If a board wants to use SPI flash for storage then it must now provide the configuration itself, using the MICROPY_HW_BDEV_xxx macros.
2018-03-10stm32/storage: Make spi_bdev interface take a data pointer as first arg.Damien George
This allows a board to have multiple instances of the SPI block device.
2018-03-10stm32/storage: Merge all misc block-dev funcs into a single ioctl func.Damien George
It makes it cleaner, and simpler to support multiple different block devices. It also allows to easily extend a given block device with new ioctl operations.
2018-03-03stm32/spibdev: Convert to use multiple block read/write interface.Damien George
The spiflash driver now supports read/write of multiple blocks at a time.
2018-03-02stm32/storage: Add option for bdev to supply readblock/writeblocks.Damien George
If the underlying block device supports it, it's more efficient to read/write multiple blocks at once.
2018-03-02stm32/spibdev: Update to work with new spiflash driver.Damien George
2018-02-13stm32: Factor out flash and SPI block-device code to separate files.Damien George
Prior to this patch, storage.c was a combination of code that handled either internal flash or external SPI flash and exposed one of them as a block device for the local storage. It was also exposed to the USB MSC. This patch splits out the flash and SPI code to separate files, which each provide a general block-device interface (at the C level). Then storage.c just picks one of them to use as the local storage medium. The aim of this factoring is to allow to add new block devices in the future and allow for easier configurability.
2017-09-10stm32/boards: Add new board B_L475E_IOT01A based on STM32L475.Tobias Badertscher
2017-09-06ports: Make new ports/ sub-directory and move all ports there.Damien George
This is to keep the top-level directory clean, to make it clear what is core and what is a port, and to allow the repository to grow with new ports in a sustainable way.