summaryrefslogtreecommitdiff
path: root/src/soc/mediatek/mt8192/spi.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/mediatek/mt8192/spi.c')
-rw-r--r--src/soc/mediatek/mt8192/spi.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/src/soc/mediatek/mt8192/spi.c b/src/soc/mediatek/mt8192/spi.c
index f7a8756d1a..b5abc85b83 100644
--- a/src/soc/mediatek/mt8192/spi.c
+++ b/src/soc/mediatek/mt8192/spi.c
@@ -112,23 +112,6 @@ void mtk_spi_set_gpio_pinmux(unsigned int bus, enum spi_pad_mask pad_select)
gpio_set_mode((gpio_t){.id = ptr[i].pin_id}, ptr[i].func);
}
-void mtk_spi_set_timing(struct mtk_spi_regs *regs, u32 sck_ticks, u32 cs_ticks,
- unsigned int tick_dly)
-{
- write32(&regs->spi_cfg0_reg,
- ((cs_ticks - 1) << SPI_CFG0_CS_HOLD_SHIFT) |
- ((cs_ticks - 1) << SPI_CFG0_CS_SETUP_SHIFT));
-
- write32(&regs->spi_cfg2_reg,
- ((sck_ticks - 1) << SPI_CFG2_SCK_HIGH_SHIFT) |
- ((sck_ticks - 1) << SPI_CFG2_SCK_LOW_SHIFT));
-
- clrsetbits32(&regs->spi_cfg1_reg, SPI_CFG1_TICK_DLY_MASK |
- SPI_CFG1_CS_IDLE_MASK,
- (tick_dly << SPI_CFG1_TICK_DLY_SHIFT) |
- ((cs_ticks - 1) << SPI_CFG1_CS_IDLE_SHIFT));
-}
-
static const struct spi_ctrlr spi_flash_ctrlr = {
.max_xfer_size = 65535,
.flash_probe = mtk_spi_flash_probe,