summaryrefslogtreecommitdiff
path: root/plugins/api.c
AgeCommit message (Collapse)Author
2020-05-15qemu/qemu-plugin: Make qemu_plugin_hwaddr_is_io() hwaddr argument constPhilippe Mathieu-Daudé
Rename qemu_plugin_hwaddr_is_io() address argument 'haddr' similarly to qemu_plugin_hwaddr_device_offset(), and make it const. Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Emilio G. Cota <cota@braap.org> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Message-Id: <20200510171119.20827-4-f4bug@amsat.org> Message-Id: <20200513173200.11830-4-alex.bennee@linaro.org>
2020-01-15plugins: Include trace/mem.h in api.cRichard Henderson
Code movement in an upcoming patch will show that this file was implicitly depending on trace/mem.h being included beforehand. Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Reported-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
2019-10-28plugin: add qemu_plugin_outs helperAlex Bennée
Having the plugins grab stdout and spew stuff there is a bit ugly and certainly makes the tests look ugly. Provide a hook back into QEMU which can be redirected as needed. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Aaron Lindsay <aaron@os.amperecomputing.com>
2019-10-28plugin: add qemu_plugin_insn_disas helperAlex Bennée
Give the plugins access to the QEMU dissasembler so they don't have to re-invent the wheel. We generate a warning when there are spare bytes in the decode buffer. This is usually due to the front end loading in more bytes than decoded. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2019-10-28plugins: implement helpers for resolving hwaddrAlex Bennée
We need to keep a local per-cpu copy of the data as other threads may be running. Currently we can provide insight as to if the access was IO or not and give the offset into a given device (usually the main RAMBlock). We store enough information to get details such as the MemoryRegion which might be useful in later expansions to the API. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2019-10-28plugin: add implementation of the apiAlex Bennée
[AJB: split from the core code commit] Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>