Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

spi: sh-msiof: Increase TX FIFO size for R-Car V4H/V4M

The MSIOF transmit FIFOs on R-Car V4H and V4M have 256 stages.
Add a new family-specific match entry to handle this.
Add quirk match entries for older R-Car Gen4 Socs (R-Car V3U and S4-8)
that have transmit FIFOs with only 64 stages, just like on R-Car Gen3.

Update the (unused) definition of SIFCTR_TFUA for consistency.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://patch.msgid.link/69cb5fc48f034d37484fa127b9864a1971a83417.1747401908.git.geert+renesas@glider.be
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Geert Uytterhoeven and committed by
Mark Brown
5b91dc7e f669c282

+13 -2
+13 -2
drivers/spi/spi-sh-msiof.c
··· 149 149 #define SIFCTR_TFWM_8 5U /* Transfer Request when 8 empty stages */ 150 150 #define SIFCTR_TFWM_4 6U /* Transfer Request when 4 empty stages */ 151 151 #define SIFCTR_TFWM_1 7U /* Transfer Request when 1 empty stage */ 152 - #define SIFCTR_TFUA GENMASK(26, 20) /* Transmit FIFO Usable Area */ 152 + #define SIFCTR_TFUA GENMASK(28, 20) /* Transmit FIFO Usable Area */ 153 153 #define SIFCTR_RFWM GENMASK(15, 13) /* Receive FIFO Watermark */ 154 154 #define SIFCTR_RFWM_1 0U /* Transfer Request when 1 valid stages */ 155 155 #define SIFCTR_RFWM_4 1U /* Transfer Request when 4 valid stages */ ··· 1113 1113 .min_div_pow = 1, 1114 1114 }; 1115 1115 1116 + static const struct sh_msiof_chipdata rcar_gen4_data = { 1117 + .bits_per_word_mask = SPI_BPW_MASK(8) | SPI_BPW_MASK(16) | 1118 + SPI_BPW_MASK(24) | SPI_BPW_MASK(32), 1119 + .tx_fifo_size = 256, 1120 + .rx_fifo_size = 256, 1121 + .ctlr_flags = SPI_CONTROLLER_MUST_TX, 1122 + .min_div_pow = 1, 1123 + }; 1124 + 1116 1125 static const struct sh_msiof_chipdata rcar_r8a7795_data = { 1117 1126 .bits_per_word_mask = SPI_BPW_MASK(8) | SPI_BPW_MASK(16) | 1118 1127 SPI_BPW_MASK(24) | SPI_BPW_MASK(32), ··· 1137 1128 { .compatible = "renesas,rcar-gen2-msiof", .data = &rcar_gen2_data }, 1138 1129 { .compatible = "renesas,msiof-r8a7795", .data = &rcar_r8a7795_data }, 1139 1130 { .compatible = "renesas,rcar-gen3-msiof", .data = &rcar_gen3_data }, 1140 - { .compatible = "renesas,rcar-gen4-msiof", .data = &rcar_gen3_data }, 1131 + { .compatible = "renesas,msiof-r8a779a0", .data = &rcar_gen3_data }, 1132 + { .compatible = "renesas,msiof-r8a779f0", .data = &rcar_gen3_data }, 1133 + { .compatible = "renesas,rcar-gen4-msiof", .data = &rcar_gen4_data }, 1141 1134 { .compatible = "renesas,sh-msiof", .data = &sh_data }, /* Deprecated */ 1142 1135 { /* sentinel */ } 1143 1136 };