From: Markus Armbruster <armbru@redhat.com>
To: zhenwei pi <pizhenwei@bytedance.com>
Cc: qemu-devel@nongnu.org, arei.gonglei@huawei.com
Subject: Re: [PATCH] cryptodev: Fix error handling in cryptodev_lkcf_execute_task()
Date: Wed, 19 Mar 2025 06:12:35 +0100 [thread overview]
Message-ID: <87ecyt4n98.fsf@pond.sub.org> (raw)
In-Reply-To: <8b093cdc-f41e-48e7-8be6-b592f313e4f6@bytedance.com> (zhenwei pi's message of "Wed, 19 Mar 2025 10:21:32 +0800")
zhenwei pi <pizhenwei@bytedance.com> writes:
> On 3/18/25 21:21, Markus Armbruster wrote:
>> zhenwei pi <pizhenwei@bytedance.com> writes:
>>
>>> Hi Markus,
>>>
>>> Current code style seems buggy, I think the main reason is that the Error *errp is not generated at right place. keyctl_pkey_XXX fails without new error, qcrypto_akcipher_XXX fails with new error, but they are in the same switch-case code block. If we can separate crypto operations into two functions - cryptodev_lkcf_keyctl_op and cryptodev_lkcf_qakcipher_op, and the error is generate inside the functions, it may be handled easily. Then applying your changes, it seem more clear. What do you think?
>>
>> Looks like a reasonable cleanup to me.
>>
>> I suggest to proceed as follows. We apply my minimal bug fix as is.
>> You post your cleanup on top. Okay?
>>
>
> OK!
Thanks! I'll include the patch in a pull request of error handling
fixes. Care to give your Reviewed-by?
next prev parent reply other threads:[~2025-03-19 5:13 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-12 10:11 [PATCH] cryptodev: Fix error handling in cryptodev_lkcf_execute_task() Markus Armbruster
2025-03-12 10:28 ` zhenwei pi
2025-03-12 12:02 ` Markus Armbruster
2025-03-14 8:34 ` zhenwei pi
2025-03-18 13:21 ` Markus Armbruster
2025-03-19 2:21 ` zhenwei pi
2025-03-19 5:12 ` Markus Armbruster [this message]
2025-03-19 6:29 ` zhenwei pi
2025-03-19 8:37 ` Markus Armbruster
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ecyt4n98.fsf@pond.sub.org \
--to=armbru@redhat.com \
--cc=arei.gonglei@huawei.com \
--cc=pizhenwei@bytedance.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.