spi: atmel: Exposing effective spi speed
Subsystems (3)
PATCH 1/1 spi: atmel: Exposing effective spi speed
This patch implements the reporting of the effectively used speed_hz for the transfer by setting xfer->effective_speed_hz.
See the following patch, which adds this feature to the SPI core for more information:
5d7e2b5ed585 spi: core: allow reporting the effectivly used speed_hz for a transfer
--- drivers/spi/spi-atmel.c | 1 + 1 file changed, 1 insertion(+)
drivers/spi/spi-atmel.c +1 -0
@@ -859,6 +859,7 @@ static int atmel_spi_set_xfer_speed(struct atmel_spi *as, csr =spi_readl (as,CSR0 +4 * chip_select); csr =SPI_BFINS (SCBR , scbr, csr);spi_writel (as,CSR0 +4 * chip_select, csr); + xfer->effective_speed_hz = bus_hz/scbr;return 0 ; }
Signature · 1 line
2.25.1
Hi, Thomas,
Quoted 7 lines · Thomas Kopp
This patch implements the reporting of the effectively used
speed_hzfor the transfer by settingxfer->effective_speed_hz.See the following patch, which adds this feature to the SPI core for more information:
5d7e2b5ed585spi: core: allow reporting the effectivly usedspeed_hzfor a transfer
s/effectivly/effectively
./scripts/checkpatch.pl --strict raises an error here, the commit should be
referred as commit 5d7e2b5ed585 ("spi: core: allow reporting the effectivly used speed_hz for a transfer")
Quoted 11 lines
Signed-off-by Thomas Kopp <[email protected]>--- drivers/spi/spi-atmel.c | 1 + 1 file changed, 1 insertion(+)drivers/spi/spi-atmel.c +0
-0
drivers/spi/spi-atmel.c static int atmel_spi_set_xfer_speed(struct atmel_spi *as, · line 862
Quoted 4 lines
drivers/spi/spi-atmel.c +1
-0@@ -859,6 +859,7 @@ static int atmel_spi_set_xfer_speed(struct atmel_spi *as, csr =spi_readl (as,CSR0 +4 * chip_select); csr =SPI_BFINS (SCBR , scbr, csr);spi_writel (as,CSR0 +4 * chip_select, csr); + xfer->effective_speed_hz = bus_hz/scbr;
spaces preferred around that '/'
with these addressed one can add:
Cheers,
ta
Quoted 6 lines · On 9/21/20 9:02 AM, Tudor Ambarus - M18064 wrote:
Hi, Thomas,
Quoted 3 lines · Thomas Kopp
This patch implements the reporting of the effectively used
speed_hzfor the transfer by settingxfer->effective_speed_hz.
Quoted 6 lines
Quoted 4 lines
See the following patch, which adds this feature to the SPI core for more information:
5d7e2b5ed585spi: core: allow reporting the effectivly usedspeed_hzfor a transfers/effectivly/effectively
oops, please ignore this, don't change the commit subject.