[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH for 6.2 42/49] bsd-user: add stubbed out core dump support
From: |
Warner Losh |
Subject: |
Re: [PATCH for 6.2 42/49] bsd-user: add stubbed out core dump support |
Date: |
Thu, 19 Aug 2021 21:16:12 -0600 |
> On Aug 10, 2021, at 11:27 AM, Richard Henderson
> <richard.henderson@linaro.org> wrote:
>
> On 8/7/21 11:42 AM, Warner Losh wrote:
>> From: Warner Losh <imp@FreeBSD.org>
>> Add a stubbed-out version of the bsd-user fork's core dump support. This
>> allows elfload.c to be almost the same between what's upstream and
>> what's in qemu-project upstream w/o the burden of reviewing the core
>> dump support.
>> Signed-off-by: Stacey Son <sson@FreeBSD.org>
>> Signed-off-by: Warner Losh <imp@bsdimp.com>
>> Sponsored by: Netflix
>> ---
>> bsd-user/elfcore.c | 10 ++++++++++
>> bsd-user/elfload.c | 24 ++++++++++++++++++++++--
>> bsd-user/qemu.h | 6 ++++++
>> 3 files changed, 38 insertions(+), 2 deletions(-)
>> create mode 100644 bsd-user/elfcore.c
>> diff --git a/bsd-user/elfcore.c b/bsd-user/elfcore.c
>> new file mode 100644
>> index 0000000000..e3c161942d
>> --- /dev/null
>> +++ b/bsd-user/elfcore.c
>> @@ -0,0 +1,10 @@
>> +/* Stubbed out version of core dump support, explicitly in public domain */
>> +
>> +static int elf_core_dump(int signr, CPUArchState *env)
>> +{
>> + struct elf_note en;
>> +
>> + bswap_note(&en);
>> +
>> + return 0;
>> +}
>
> No warnings from this, e.g. uninitialized variable?
> If you have a chance, run this through clang-12 (mainline).
> It it getting much better at identifying such stuff.
It’s easy enough to initialize en, so I’ve done that.
Warner
> Otherwise,
> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
>
>
> r~
signature.asc
Description: Message signed with OpenPGP
[PATCH for 6.2 38/49] bsd-user: Update mapping to handle reserved and starting conditions, Warner Losh, 2021/08/07
[PATCH for 6.2 40/49] bsd-user: Add target_arch_reg to describe a target's register set, Warner Losh, 2021/08/07