This is a note to let you know that I've just added the patch titled spi: fsi: Fix clock running too fast to the 5.8-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: spi-fsi-fix-clock-running-too-fast.patch and it can be found in the queue-5.8 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. commit 40b48c6c3db9a88715fe3cba079520a9a62df647 Author: Brad Bishop <bradleyb@xxxxxxxxxxxxxxxxxx> Date: Wed Sep 9 17:28:53 2020 -0500 spi: fsi: Fix clock running too fast [ Upstream commit 0b546bbe9474ff23e6843916ad6d567f703b2396 ] Use a clock divider tuned to a 200MHz FSI bus frequency (the maximum). Use of the previous divider at 200MHz results in corrupt data from endpoint devices. Ideally the clock divider would be calculated from the FSI clock, but that would require some significant work on the FSI driver. With FSI frequencies slower than 200MHz, the SPI clock will simply run slower, but safely. Signed-off-by: Brad Bishop <bradleyb@xxxxxxxxxxxxxxxxxx> Signed-off-by: Eddie James <eajames@xxxxxxxxxxxxx> Signed-off-by: Joel Stanley <joel@xxxxxxxxx> Link: https://lore.kernel.org/r/20200909222857.28653-3-eajames@xxxxxxxxxxxxx Signed-off-by: Mark Brown <broonie@xxxxxxxxxx> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> diff --git a/drivers/spi/spi-fsi.c b/drivers/spi/spi-fsi.c index ef5e0826a53c3..a702e9d7d68c0 100644 --- a/drivers/spi/spi-fsi.c +++ b/drivers/spi/spi-fsi.c @@ -403,7 +403,7 @@ static int fsi_spi_transfer_init(struct fsi_spi *ctx) u64 status = 0ULL; u64 wanted_clock_cfg = SPI_FSI_CLOCK_CFG_ECC_DISABLE | SPI_FSI_CLOCK_CFG_SCK_NO_DEL | - FIELD_PREP(SPI_FSI_CLOCK_CFG_SCK_DIV, 4); + FIELD_PREP(SPI_FSI_CLOCK_CFG_SCK_DIV, 19); end = jiffies + msecs_to_jiffies(SPI_FSI_INIT_TIMEOUT_MS); do {