summaryrefslogtreecommitdiffstats
path: root/scripts/dump-guest-memory.py
diff options
context:
space:
mode:
authorVladimir Sementsov-Ogievskiy2019-01-28 17:58:30 +0100
committerEric Blake2019-02-04 22:11:27 +0100
commite6798f06a67a25def45a6636259de38cc38f1414 (patch)
treeaa6666d07f2722947fea9f44b19aa1ec9d4ca5fa /scripts/dump-guest-memory.py
parentqemu-nbd: Deprecate qemu-nbd --partition (diff)
downloadqemu-e6798f06a67a25def45a6636259de38cc38f1414.tar.gz
qemu-e6798f06a67a25def45a6636259de38cc38f1414.tar.xz
qemu-e6798f06a67a25def45a6636259de38cc38f1414.zip
nbd: generalize usage of nbd_read
We generally do very similar things around nbd_read: error_prepend specifying what we have tried to read, and be_to_cpu conversion of integers. So, it seems reasonable to move common things to helper functions, which: 1. simplify code a bit 2. generalize nbd_read error descriptions, all starting with "Failed to read" 3. make it more difficult to forget to convert things from BE Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by: Eric Blake <eblake@redhat.com> Message-Id: <20190128165830.165170-1-vsementsov@virtuozzo.com> [eblake: rename macro to DEF_NBD_READ_N and formatting tweaks; checkpatch has false positive complaint] Signed-off-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'scripts/dump-guest-memory.py')
0 files changed, 0 insertions, 0 deletions