[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-arm] [Qemu-devel] [PATCH] Use error_fatal to simplify obvious
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-arm] [Qemu-devel] [PATCH] Use error_fatal to simplify obvious fatal errors |
Date: |
Thu, 10 Dec 2015 13:31:03 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
Paolo Bonzini <address@hidden> writes:
> On 10/12/2015 11:19, Markus Armbruster wrote:
>> + object_property_set_int(OBJECT(cpu), ZYNQ_BOARD_MIDR, "midr",
>> + &error_fatal);object_property_set_int(OBJECT(cpu),
>> + MPCORE_PERIPHBASE,
>> + "reset-cbar",
>> + &error_fatal);object_property_set_bool(OBJECT(cpu),
>> + true,
>> + "realized",
>> + &error_fatal);
>
> Something went wrong here. :)
Once again I demonstrate incompetence at proofreading my own patches %-}
No idea what happened. I'll fix it.
>> void qdev_prop_set_drive_nofail(DeviceState *dev, const char *name,
>> BlockBackend *value)
>> {
>> - Error *err = NULL;
>> -
>> - qdev_prop_set_drive(dev, name, value, &err);
>> - if (err) {
>> - error_report_err(err);
>> - exit(1);
>> - }
>> + qdev_prop_set_drive(dev, name, value, &error_fatal);
>> }
>
>
> This should be inlined entirely into the callers (possibly as a follow up).
Yes, a FOO_nofail() wrapper around a FOO() taking Error ** is pointless.
I'll prep a follow-up patch.
> Otherwise looks great, thanks!
Thanks!