aboutsummaryrefslogtreecommitdiff
path: root/drivers/spi/spi-uclass.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2023-09-14 16:23:49 -0400
committerTom Rini <trini@konsulko.com>2023-09-14 16:23:49 -0400
commit2fe4b54556ea6271237b35de68dc458bfceab94c (patch)
treee98df3cab8a288829e16bab3999af50550163942 /drivers/spi/spi-uclass.c
parent3cba5a115ff8b5aeca62e5ae7dfad6bacb32e9fd (diff)
parent4babaa0c28becc2b80db13daa6f30d8f4d35e94e (diff)
Merge branch '2023-09-14-remove-NEEDS_MANUAL_RELOC' into next
To quote the author: The last user of the NEEDS_MANUAL_RELOC has been removed in commit 26af162ac8f8 ("arch: m68k: Implement relocation") Remove now unused NEEDS_MANUAL_RELOC code. This is a follow up on way over decade old commit 2e5167ccad93 ("Replace CONFIG_RELOC_FIXUP_WORKS by CONFIG_NEEDS_MANUAL_RELOC") " By now, the majority of architectures have working relocation support, so the few remaining architectures have become exceptions. To make this more obvious, we make working relocation now the default case, and flag the remaining cases with CONFIG_NEEDS_MANUAL_RELOC. " It took a bit longer than expected, but now we can really sunset CONFIG_NEEDS_MANUAL_RELOC. Make it so.
Diffstat (limited to 'drivers/spi/spi-uclass.c')
-rw-r--r--drivers/spi/spi-uclass.c32
1 files changed, 0 insertions, 32 deletions
diff --git a/drivers/spi/spi-uclass.c b/drivers/spi/spi-uclass.c
index c929e7c1d0..f4795e6867 100644
--- a/drivers/spi/spi-uclass.c
+++ b/drivers/spi/spi-uclass.c
@@ -196,38 +196,6 @@ static int spi_post_probe(struct udevice *bus)
spi->max_hz = dev_read_u32_default(bus, "spi-max-frequency", 0);
}
-#if defined(CONFIG_NEEDS_MANUAL_RELOC)
- struct dm_spi_ops *ops = spi_get_ops(bus);
- static int reloc_done;
-
- if (!reloc_done) {
- if (ops->claim_bus)
- ops->claim_bus += gd->reloc_off;
- if (ops->release_bus)
- ops->release_bus += gd->reloc_off;
- if (ops->set_wordlen)
- ops->set_wordlen += gd->reloc_off;
- if (ops->xfer)
- ops->xfer += gd->reloc_off;
- if (ops->set_speed)
- ops->set_speed += gd->reloc_off;
- if (ops->set_mode)
- ops->set_mode += gd->reloc_off;
- if (ops->cs_info)
- ops->cs_info += gd->reloc_off;
- if (ops->mem_ops) {
- struct spi_controller_mem_ops *mem_ops =
- (struct spi_controller_mem_ops *)ops->mem_ops;
- if (mem_ops->adjust_op_size)
- mem_ops->adjust_op_size += gd->reloc_off;
- if (mem_ops->supports_op)
- mem_ops->supports_op += gd->reloc_off;
- if (mem_ops->exec_op)
- mem_ops->exec_op += gd->reloc_off;
- }
- reloc_done++;
- }
-#endif
return 0;
}