Skip to content

Commit

Permalink
drivers: spi: stm32: correct the operation flag type
Browse files Browse the repository at this point in the history
The commit 2c3165d ("drivers: spi: add opaque type to encode SPI
operation flags") introduces new type for operation flag, since it is
16/32-bit depending on CONFIG_SPI_EXTENDED_MODES.

Use the new type for safe, if the function 'spi_stm32_shift_frames' may
use extended operation flag later.

Signed-off-by: Haiyue Wang <haiyuewa@163.com>
  • Loading branch information
haiyuewa committed Jan 11, 2025
1 parent d4deeeb commit e5df4f4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/spi/spi_ll_stm32.c
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@ static void spi_stm32_shift_s(SPI_TypeDef *spi, struct spi_stm32_data *data)
static int spi_stm32_shift_frames(const struct spi_stm32_config *cfg,
struct spi_stm32_data *data)
{
uint16_t operation = data->ctx.config->operation;
spi_operation_t operation = data->ctx.config->operation;

if (SPI_OP_MODE_GET(operation) == SPI_OP_MODE_MASTER) {
spi_stm32_shift_m(cfg, data);
Expand Down

0 comments on commit e5df4f4

Please sign in to comment.