Skip to content

Commit 09015c7

Browse files
committed
Revert "[nrf noup] drivers: spi_dw: add custom EXMIF peripheral handling"
This reverts commit 1a630d8. Signed-off-by: Andrzej Głąbek <[email protected]>
1 parent ff6ab5f commit 09015c7

File tree

2 files changed

+2
-21
lines changed

2 files changed

+2
-21
lines changed

drivers/spi/spi_dw.c

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,6 @@ LOG_MODULE_REGISTER(spi_dw);
4141
#include <zephyr/drivers/pinctrl.h>
4242
#endif
4343

44-
#ifdef CONFIG_HAS_NRFX
45-
#include <nrfx.h>
46-
#endif
47-
4844
static inline bool spi_dw_is_slave(struct spi_dw_data *spi)
4945
{
5046
return (IS_ENABLED(CONFIG_SPI_SLAVE) &&
@@ -262,7 +258,6 @@ static int spi_dw_configure(const struct device *dev,
262258
/* Baud rate and Slave select, for master only */
263259
write_baudr(dev, SPI_DW_CLK_DIVIDER(info->clock_frequency,
264260
config->frequency));
265-
write_ser(dev, BIT(config->slave));
266261
}
267262

268263
if (spi_dw_is_slave(spi)) {
@@ -505,10 +500,6 @@ void spi_dw_isr(const struct device *dev)
505500
uint32_t int_status;
506501
int error;
507502

508-
#ifdef CONFIG_HAS_NRFX
509-
NRF_EXMIF->EVENTS_CORE = 0;
510-
#endif
511-
512503
int_status = read_isr(dev);
513504

514505
LOG_DBG("SPI %p int_status 0x%x - (tx: %d, rx: %d)", dev, int_status,
@@ -557,11 +548,6 @@ int spi_dw_init(const struct device *dev)
557548

558549
DEVICE_MMIO_MAP(dev, K_MEM_CACHE_NONE);
559550

560-
#ifdef CONFIG_HAS_NRFX
561-
NRF_EXMIF->INTENSET = BIT(0);
562-
NRF_EXMIF->TASKS_START = 1;
563-
#endif
564-
565551
info->config_func();
566552

567553
/* Masking interrupt and making sure controller is disabled */
@@ -580,11 +566,6 @@ int spi_dw_init(const struct device *dev)
580566
return 0;
581567
}
582568

583-
#define REG_ADDR(inst) \
584-
COND_CODE_1(DT_NODE_HAS_COMPAT(DT_DRV_INST(inst), nordic_nrf_exmif), \
585-
(Z_DEVICE_MMIO_NAMED_ROM_INITIALIZER(core, DT_DRV_INST(inst))), \
586-
(DEVICE_MMIO_ROM_INIT(DT_DRV_INST(inst))))
587-
588569
#define SPI_CFG_IRQS_SINGLE_ERR_LINE(inst) \
589570
IRQ_CONNECT(DT_INST_IRQ_BY_NAME(inst, rx_avail, irq), \
590571
DT_INST_IRQ_BY_NAME(inst, rx_avail, priority), \
@@ -657,7 +638,7 @@ COND_CODE_1(IS_EQ(DT_NUM_IRQS(DT_DRV_INST(inst)), 1), \
657638
SPI_CONTEXT_CS_GPIOS_INITIALIZE(DT_DRV_INST(inst), ctx) \
658639
}; \
659640
static const struct spi_dw_config spi_dw_config_##inst = { \
660-
REG_ADDR(inst), \
641+
DEVICE_MMIO_ROM_INIT(DT_DRV_INST(inst)), \
661642
.clock_frequency = COND_CODE_1( \
662643
DT_NODE_HAS_PROP(DT_INST_PHANDLE(inst, clocks), clock_frequency), \
663644
(DT_INST_PROP_BY_PHANDLE(inst, clocks, clock_frequency)), \

dts/common/nordic/nrf54h20.dtsi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -507,7 +507,7 @@
507507
};
508508

509509
exmif: spi@95000 {
510-
compatible = "nordic,nrf-exmif", "snps,designware-spi";
510+
compatible = "nordic,nrf-exmif";
511511
#address-cells = <1>;
512512
#size-cells = <0>;
513513
reg = <0x95000 0x500 0x95500 0xb00>;

0 commit comments

Comments
 (0)