spi: stm32: fix clock prescaler calculation
The current prescaler calculation incorrectly fails to configure the
desired frequency when it is possible to match it exactly. Fix this.
Without this patch, if the user requests frequency N Hz, and there is
a SPI prescaler that can match this frequency exactly, the actual
frequency chosen by spi_stm32_configure() will be N/2 Hz.
Signed-off-by:
Marti Bolivar <marti.bolivar@linaro.org>
Loading
Please sign in to comment