[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-commits] [qemu/qemu] 86a518: dump: Use ERRP_GUARD()
From: |
Richard Henderson |
Subject: |
[Qemu-commits] [qemu/qemu] 86a518: dump: Use ERRP_GUARD() |
Date: |
Fri, 22 Apr 2022 04:45:17 -0700 |
Branch: refs/heads/staging
Home: https://github.com/qemu/qemu
Commit: 86a518bba4f4d7c9016fc5b104fe1e58b00ad756
https://github.com/qemu/qemu/commit/86a518bba4f4d7c9016fc5b104fe1e58b00ad756
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
Log Message:
-----------
dump: Use ERRP_GUARD()
Let's move to the new way of handling errors before changing the dump
code. This patch has mostly been generated by the coccinelle script
scripts/coccinelle/errp-guard.cocci.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220330123603.107120-2-frankja@linux.ibm.com>
Commit: 046bc4160bc780eaacc2d702a2589f1a7a01188d
https://github.com/qemu/qemu/commit/046bc4160bc780eaacc2d702a2589f1a7a01188d
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
M include/sysemu/dump.h
Log Message:
-----------
dump: Remove the sh_info variable
There's no need to have phdr_num and sh_info at the same time. We can
make phdr_num 32 bit and set PN_XNUM when we write the header if
phdr_num >= PN_XNUM.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220407094824.5074-1-frankja@linux.ibm.com>
Commit: 862a395858e5a302ed5921487777acdc95a3a31b
https://github.com/qemu/qemu/commit/862a395858e5a302ed5921487777acdc95a3a31b
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
M include/sysemu/dump.h
Log Message:
-----------
dump: Introduce shdr_num to decrease complexity
Let's move from a boolean to a int variable which will later enable us
to store the number of sections that are in the dump file.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220330123603.107120-4-frankja@linux.ibm.com>
Commit: 344107e07bd81546474a54ab83800158ca953059
https://github.com/qemu/qemu/commit/344107e07bd81546474a54ab83800158ca953059
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
Log Message:
-----------
dump: Remove the section if when calculating the memory offset
When s->shdr_num is 0 we'll add 0 bytes of section headers which is
equivalent to not adding section headers but with the multiplication
we can remove a if/else.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220330123603.107120-5-frankja@linux.ibm.com>
Commit: e71d353360bb09a8e784e35d78370c691f6ea185
https://github.com/qemu/qemu/commit/e71d353360bb09a8e784e35d78370c691f6ea185
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
M include/sysemu/dump.h
Log Message:
-----------
dump: Add more offset variables
Offset calculations are easy enough to get wrong. Let's add a few
variables to make moving around elf headers and data sections easier.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20220330123603.107120-6-frankja@linux.ibm.com>
Commit: 05bbaa5040ccb3419e8b93af8040485430e2db42
https://github.com/qemu/qemu/commit/05bbaa5040ccb3419e8b93af8040485430e2db42
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
Log Message:
-----------
dump: Introduce dump_is_64bit() helper function
Checking d_class in dump_info leads to lengthy conditionals so let's
shorten things a bit by introducing a helper function.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220330123603.107120-7-frankja@linux.ibm.com>
Commit: bc7d558017e6700f9a05c61b0b638a8994945f0d
https://github.com/qemu/qemu/commit/bc7d558017e6700f9a05c61b0b638a8994945f0d
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
Log Message:
-----------
dump: Consolidate phdr note writes
There's no need to have two write functions. Let's rather have two
functions that set the data for elf 32/64 and then write it in a
common function.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220330123603.107120-8-frankja@linux.ibm.com>
Commit: 5ff2e5a3e1e67930e523486e39549a33fcf97227
https://github.com/qemu/qemu/commit/5ff2e5a3e1e67930e523486e39549a33fcf97227
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
Log Message:
-----------
dump: Cleanup dump_begin write functions
There's no need to have a gigantic if in there let's move the elf
32/64 bit logic into the section, segment or note code.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220330123603.107120-9-frankja@linux.ibm.com>
Commit: c68124738bc29017e4254c898bc40be7be477af7
https://github.com/qemu/qemu/commit/c68124738bc29017e4254c898bc40be7be477af7
Author: Janosch Frank <frankja@linux.ibm.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/dump.c
Log Message:
-----------
dump: Consolidate elf note function
Just like with the other write functions let's move the 32/64 bit elf
handling to a function to improve readability.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220330123603.107120-10-frankja@linux.ibm.com>
Commit: a64b4e179a85cefd8fd492e019430185e19fa32e
https://github.com/qemu/qemu/commit/a64b4e179a85cefd8fd492e019430185e19fa32e
Author: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M contrib/elf2dmp/main.c
M dump/win_dump.c
M include/qemu/win_dump_defs.h
Log Message:
-----------
include/qemu: rename Windows context definitions to expose bitness
Context structure in 64-bit Windows differs from 32-bit one and it
should be reflected in its name.
Signed-off-by: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220406171558.199263-2-viktor.prutyanov@redhat.com>
Commit: fb21efe99a5ce6a52abe47eaa286603453e18073
https://github.com/qemu/qemu/commit/fb21efe99a5ce6a52abe47eaa286603453e18073
Author: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/win_dump.c
Log Message:
-----------
dump/win_dump: add helper macros for Windows dump header access
Perform read access to Windows dump header fields via helper macros.
This is preparation for the next 32-bit guest Windows dump support.
Signed-off-by: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220406171558.199263-3-viktor.prutyanov@redhat.com>
Commit: c4fe30921f42d2dba4bc51458839039f71e13a6b
https://github.com/qemu/qemu/commit/c4fe30921f42d2dba4bc51458839039f71e13a6b
Author: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M include/qemu/win_dump_defs.h
Log Message:
-----------
include/qemu: add 32-bit Windows dump structures
These structures are required to produce 32-bit guest Windows Complete
Memory Dump. Add 32-bit Windows dump header, CPU context and physical
memory descriptor structures along with corresponding definitions.
Signed-off-by: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220406171558.199263-4-viktor.prutyanov@redhat.com>
Commit: f5daa8293b292929cb429f154e926191ba8e040c
https://github.com/qemu/qemu/commit/f5daa8293b292929cb429f154e926191ba8e040c
Author: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M dump/win_dump.c
M hmp-commands.hx
Log Message:
-----------
dump/win_dump: add 32-bit guest Windows support
Before this patch, 'dump-guest-memory -w' was accepting only 64-bit
dump header provided by guest through vmcoreinfo and thus was unable
to produce 32-bit guest Windows dump. So, add 32-bit guest Windows
dumping support.
Signed-off-by: Viktor Prutyanov <viktor.prutyanov@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
[ misc error handling fixes to avoid compiler warning ]
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220406171558.199263-5-viktor.prutyanov@redhat.com>
Commit: f7f40b8198ade2679cbabc37cfc5c0cc125a6576
https://github.com/qemu/qemu/commit/f7f40b8198ade2679cbabc37cfc5c0cc125a6576
Author: Richard Henderson <richard.henderson@linaro.org>
Date: 2022-04-22 (Fri, 22 Apr 2022)
Changed paths:
M contrib/elf2dmp/main.c
M dump/dump.c
M dump/win_dump.c
M hmp-commands.hx
M include/qemu/win_dump_defs.h
M include/sysemu/dump.h
Log Message:
-----------
Merge tag 'dump-pull-request' of gitlab.com:marcandre.lureau/qemu into staging
dump queue
Hi
The "dump" queue, with:
- [PATCH v3/v4 0/9] dump: Cleanup and consolidation
- [PATCH v4 0/4] dump: add 32-bit guest Windows support
v2:
- fix compiler warning in "dump/win_dump: add 32-bit guest Windows support"
# -----BEGIN PGP SIGNATURE-----
#
# iQJQBAABCAA6FiEEh6m9kz+HxgbSdvYt2ujhCXWWnOUFAmJigBkcHG1hcmNhbmRy
# ZS5sdXJlYXVAcmVkaGF0LmNvbQAKCRDa6OEJdZac5T92EACNSdzJTeXmoGV3yzyq
# oVQAH9ViuH6nINH04KZvS6gPoFvm6h/0pj2A2n9iy9ULcc0hNNKDtDkiYoIyLWTE
# 34ywOpWUNbRNEefifo2wcKqebpyeSS+0Y2fttHzIwVl+t5qFZt7JwXdbmo4Xpf6a
# MY4LS7WfmQkXZvg0nkv3nw32vAJK4VvSKhnbSTE1m0AYEkrBTntexDby9XDoDyWL
# QPzDemyLi6A9HO/NeB6sdKwwXd4g4mfIKy0WI+T5M1Ped0BpBoKrQpJ/KNYrZuJE
# 0IJJFXA8D+tIfYdGD3MAO2X7IHVR6Ld2GV10pPmzLFHt06MFlDua360cFYohB2ua
# 2Hk0syqwuEDRZSES5eQPbwu3sXGAZAw3kth32tlGFawTVwXLEw9YTU1ZwHhnwvG0
# Uocu44v2+x0Swtuw2Dw1J5PBLH1ebYdQozpA4U4TibCKzRTjnO6idZIFh/64oA4q
# RdpEvrQ1nnJTnIgkllZ9KxAcOZECjREEB33UAxcpKxtJbann6bv/Gz754qqiNVZv
# LOMcgZJ7HItChRV+dFQQRgyeX+IrGeq+N4zoLRZehib5+kYi50UKQIPIc9TUgzbw
# CwOESkyipmljjx9016pmY8LYipnm0hDVMoxzdKPsdYbagxWC/JFPxvqlB+7xQBud
# ez/xPfN8799O+mlwZ7zgXwYaUg==
# =QWiq
# -----END PGP SIGNATURE-----
# gpg: Signature made Fri 22 Apr 2022 03:14:49 AM PDT
# gpg: using RSA key 87A9BD933F87C606D276F62DDAE8E10975969CE5
# gpg: issuer "marcandre.lureau@redhat.com"
# gpg: Good signature from "Marc-André Lureau <marcandre.lureau@redhat.com>"
[full]
# gpg: aka "Marc-André Lureau <marcandre.lureau@gmail.com>"
[full]
* tag 'dump-pull-request' of gitlab.com:marcandre.lureau/qemu:
dump/win_dump: add 32-bit guest Windows support
include/qemu: add 32-bit Windows dump structures
dump/win_dump: add helper macros for Windows dump header access
include/qemu: rename Windows context definitions to expose bitness
dump: Consolidate elf note function
dump: Cleanup dump_begin write functions
dump: Consolidate phdr note writes
dump: Introduce dump_is_64bit() helper function
dump: Add more offset variables
dump: Remove the section if when calculating the memory offset
dump: Introduce shdr_num to decrease complexity
dump: Remove the sh_info variable
dump: Use ERRP_GUARD()
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Compare: https://github.com/qemu/qemu/compare/51cb4ec7488f...f7f40b8198ad
- [Qemu-commits] [qemu/qemu] 86a518: dump: Use ERRP_GUARD(),
Richard Henderson <=