summaryrefslogtreecommitdiffstatshomepage
path: root/docs/source/techspecs
diff options
context:
space:
mode:
author Vas Crabb <vas@vastheman.com>2017-08-01 15:19:44 +1000
committer Vas Crabb <vas@vastheman.com>2017-08-01 15:19:44 +1000
commit1e8c0b23c37a819d0f2cd3ef3d4f74a4f1a85a17 (patch)
tree1048cfed6c027c5b40c43ace23ff3d2ac705905b /docs/source/techspecs
parentd8b1cb0191e530180995c5c9f0cb890cf96cf95c (diff)
This is too contentious, please put it up for review
Revert "Changes to debugger memory address translation" This reverts commit bb0964f9a284b15851773f5428bd602ca01cc28b.
Diffstat (limited to 'docs/source/techspecs')
-rw-r--r--docs/source/techspecs/device_memory_interface.rst68
1 files changed, 5 insertions, 63 deletions
diff --git a/docs/source/techspecs/device_memory_interface.rst b/docs/source/techspecs/device_memory_interface.rst
index 1b338db94d8..d38faf8c996 100644
--- a/docs/source/techspecs/device_memory_interface.rst
+++ b/docs/source/techspecs/device_memory_interface.rst
@@ -102,72 +102,14 @@ version tests for AS_PROGRAM/AS_0.
5. MMU support for disassembler
-------------------------------
-| int **translate**\ (int spacenum, int intention, offs_t &address)
+| bool **translate**\ (int spacenum, int intention, offs_t &address)
Does a logical to physical address translation through the device's
MMU. spacenum gives the space number, intention the type of the
future access (TRANSLATE_(READ|WRITE|FETCH)(|_USER|_DEBUG)) and
address is an inout parameter with the address to translate and its
-translated version. This returns the translated space number if
-the translation went correctly, or AS_INVALID if the address is
-unmapped.
+translated version. Should return true if the translation went
+correctly, false if the address is unmapped.
-Note that the device itself must override the virtual method
-**memory_translate** with the same signature.
-
-
-| u8 **read_byte**\ (int spacenum, offs_t address, int intention)
-
-Returns a byte from the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_READ(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| u16 **read_word**\ (int spacenum, offs_t address, int intention)
-
-Returns a word from the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_READ(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| u32 **read_dword**\ (int spacenum, offs_t address, int intention)
-
-Returns a dword from the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_READ(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| u64 **read_qword**\ (int spacenum, offs_t address, int intention)
-Returns a qword from the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_READ(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| u64 **read_memory**\ (int spacenum, offs_t address, int size, int intention)
-Returns 1, 2, 4 or 8 bytes from the specified memory space, as per
-**read_byte**, **read_word**, **read_dword** or **read_qword**.
-
-| void **write_byte**\ (int spacenum, offs_t address, u8 data, int intention)
-Writes a byte to the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_WRITE(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| void **write_word**\ (int spacenum, offs_t address, u16 data, int intention)
-Writes a word to the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_WRITE(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| void **write_dword**\ (int spacenum, offs_t address, u32 data, int intention)
-Writes a dword to the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_WRITE(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| void **write_qword**\ (int spacenum, offs_t address, u64 data, int intention)
-Writes a qword to the specified memory space, doing address
-translation if requested. The intention must be specified as either
-TRANSLATE_WRITE(|_USER|_DEBUG) or TRANSLATE_NONE.
-
-| void **write_memory**\ (int spacenum, offs_t address, u64 data, int size, int intention)
-Writes 1, 2, 4 or 8 bytes to the specified memory space, as per
-**write_byte**, **write_word**, **write_dword** or **write_qword**.
-
-| u64 read_opcode(int spacenum, offs_t offset, int size)
-Reads 1, 2, 4 or 8 bytes at the given offset from the specified
-opcode space. This calls **translate** with TRANSLATE_FETCH_DEBUG
-as the intention.
+Note that for some historical reason the device itself must override
+the virtual method **memory_translate** with the same signature.