]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
blkcache: Remove unused NEEDS_MANUAL_RELOC code bits
authorMarek Vasut <marek.vasut+renesas@mailbox.org>
Wed, 6 Sep 2023 21:29:42 +0000 (23:29 +0200)
committerTom Rini <trini@konsulko.com>
Thu, 14 Sep 2023 14:42:24 +0000 (10:42 -0400)
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.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
cmd/blkcache.c
common/board_r.c
drivers/block/blkcache.c
include/blk.h

index 47ea1ec0b93d807f471e3e498496e358d590ed3b..1456654df6f5a0e313f13c0e340b74aaead9b5c1 100644 (file)
@@ -46,24 +46,11 @@ static struct cmd_tbl cmd_blkc_sub[] = {
        U_BOOT_CMD_MKENT(configure, 3, 0, blkc_configure, "", ""),
 };
 
-static __maybe_unused void blkc_reloc(void)
-{
-       static int relocated;
-
-       if (!relocated) {
-               fixup_cmdtable(cmd_blkc_sub, ARRAY_SIZE(cmd_blkc_sub));
-               relocated = 1;
-       };
-}
-
 static int do_blkcache(struct cmd_tbl *cmdtp, int flag,
                       int argc, char *const argv[])
 {
        struct cmd_tbl *c;
 
-#ifdef CONFIG_NEEDS_MANUAL_RELOC
-       blkc_reloc();
-#endif
        if (argc < 2)
                return CMD_RET_USAGE;
 
index ad9a3cf6336a0fef2ca59a09fd37806fb1775c9f..697d4a5bd3dd880439e079a1c42fd6cb1304f6a8 100644 (file)
@@ -657,9 +657,6 @@ static init_fnc_t init_sequence_r[] = {
        initr_watchdog,
 #endif
        INIT_FUNC_WATCHDOG_RESET
-#if defined(CONFIG_NEEDS_MANUAL_RELOC) && defined(CONFIG_BLOCK_CACHE)
-       blkcache_init,
-#endif
 #ifdef CONFIG_NEEDS_MANUAL_RELOC
        initr_manual_reloc_cmdtable,
 #endif
index f99465aa4799c64d452f12d6125cb301d950eda4..26bcbea4353307bf81c61b8a25bd45b8192846b8 100644 (file)
 #include <linux/ctype.h>
 #include <linux/list.h>
 
-#ifdef CONFIG_NEEDS_MANUAL_RELOC
-DECLARE_GLOBAL_DATA_PTR;
-#endif
-
 struct block_cache_node {
        struct list_head lh;
        int iftype;
@@ -34,18 +30,6 @@ static struct block_cache_stats _stats = {
        .max_entries = 32
 };
 
-#ifdef CONFIG_NEEDS_MANUAL_RELOC
-int blkcache_init(void)
-{
-       struct list_head *head = &block_cache;
-
-       head->next = (uintptr_t)head->next + gd->reloc_off;
-       head->prev = (uintptr_t)head->prev + gd->reloc_off;
-
-       return 0;
-}
-#endif
-
 static struct block_cache_node *cache_find(int iftype, int devnum,
                                           lbaint_t start, lbaint_t blkcnt,
                                           unsigned long blksz)
index b819f97c2f1e06d11a3c9f7f6dac116c99f0da0d..95e86e2d5d16cba0be33fc7557b7d99b8de999e6 100644 (file)
@@ -105,12 +105,6 @@ struct blk_desc {
        (PAD_SIZE(size, blk_desc->blksz))
 
 #if CONFIG_IS_ENABLED(BLOCK_CACHE)
-
-/**
- * blkcache_init() - initialize the block cache list pointers
- */
-int blkcache_init(void);
-
 /**
  * blkcache_read() - attempt to read a set of blocks from cache
  *