summaryrefslogtreecommitdiff
path: root/src/target/armv4_5_mmu.c
diff options
context:
space:
mode:
authorØyvind Harboe <oyvind.harboe@zylin.com>2009-10-21 13:10:32 +0200
committerØyvind Harboe <oyvind.harboe@zylin.com>2009-10-21 13:14:27 +0200
commit69a6037ce6e76dca4117689208358231dffa0929 (patch)
tree4a464ac22868bb085a4cc5bc1c80ab03fd7cd0f2 /src/target/armv4_5_mmu.c
parent62525792e073a54f21e334764ddd9dcd2d47ff0c (diff)
downloadopenocd+libswd-69a6037ce6e76dca4117689208358231dffa0929.tar.gz
openocd+libswd-69a6037ce6e76dca4117689208358231dffa0929.tar.bz2
openocd+libswd-69a6037ce6e76dca4117689208358231dffa0929.tar.xz
openocd+libswd-69a6037ce6e76dca4117689208358231dffa0929.zip
Retire obsolete and superfluous implementations of virt2phys in each target. This is done in a polymorphic implementation in target.c
Diffstat (limited to 'src/target/armv4_5_mmu.c')
-rw-r--r--src/target/armv4_5_mmu.c45
1 files changed, 0 insertions, 45 deletions
diff --git a/src/target/armv4_5_mmu.c b/src/target/armv4_5_mmu.c
index e64021e8..33800122 100644
--- a/src/target/armv4_5_mmu.c
+++ b/src/target/armv4_5_mmu.c
@@ -170,51 +170,6 @@ int armv4_5_mmu_write_physical(target_t *target, armv4_5_mmu_common_t *armv4_5_m
return retval;
}
-int armv4_5_mmu_handle_virt2phys_command(command_context_t *cmd_ctx, char *cmd, char **args, int argc, target_t *target, armv4_5_mmu_common_t *armv4_5_mmu)
-{
- uint32_t va;
- uint32_t pa;
- int type;
- uint32_t cb;
- int domain;
- uint32_t ap;
-
- if (target->state != TARGET_HALTED)
- {
- command_print(cmd_ctx, "target must be stopped for \"virt2phys\" command");
- return ERROR_OK;
- }
-
- if (argc == 0)
- {
- command_print(cmd_ctx, "usage: virt2phys <virtual address>");
- return ERROR_OK;
- }
-
- if (argc == 1)
- {
- va = strtoul(args[0], NULL, 0);
- pa = armv4_5_mmu_translate_va(target, armv4_5_mmu, va, &type, &cb, &domain, &ap);
- if (type == -1)
- {
- switch (pa)
- {
- case ERROR_TARGET_TRANSLATION_FAULT:
- command_print(cmd_ctx, "no valid translation for 0x%8.8" PRIx32 "", va);
- break;
- default:
- command_print(cmd_ctx, "unknown translation error");
- }
- return ERROR_OK;
- }
-
- command_print(cmd_ctx, "0x%8.8" PRIx32 " -> 0x%8.8" PRIx32 ", type: %s, cb: %i, domain: %d, ap: %2.2x",
- va, pa, armv4_5_mmu_page_type_names[type], (int)cb, domain, (int)ap);
- }
-
- return ERROR_OK;
-}
-
int armv4_5_mmu_handle_md_phys_command(command_context_t *cmd_ctx, char *cmd, char **args, int argc, target_t *target, armv4_5_mmu_common_t *armv4_5_mmu)
{
int count = 1;