[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v8 19/21] backends/cryptodev: drop local_err from cryptodev_backe
From: |
Vladimir Sementsov-Ogievskiy |
Subject: |
[PATCH v8 19/21] backends/cryptodev: drop local_err from cryptodev_backend_complete() |
Date: |
Thu, 5 Dec 2019 20:46:33 +0300 |
No reason for local_err here, use errp directly instead.
Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Marc-André Lureau <address@hidden>
Reviewed-by: Gonglei <address@hidden>
---
backends/cryptodev.c | 11 +----------
1 file changed, 1 insertion(+), 10 deletions(-)
diff --git a/backends/cryptodev.c b/backends/cryptodev.c
index 3c071eab95..5a9735684e 100644
--- a/backends/cryptodev.c
+++ b/backends/cryptodev.c
@@ -176,19 +176,10 @@ cryptodev_backend_complete(UserCreatable *uc, Error
**errp)
{
CryptoDevBackend *backend = CRYPTODEV_BACKEND(uc);
CryptoDevBackendClass *bc = CRYPTODEV_BACKEND_GET_CLASS(uc);
- Error *local_err = NULL;
if (bc->init) {
- bc->init(backend, &local_err);
- if (local_err) {
- goto out;
- }
+ bc->init(backend, errp);
}
-
- return;
-
-out:
- error_propagate(errp, local_err);
}
void cryptodev_backend_set_used(CryptoDevBackend *backend, bool used)
--
2.21.0
- Re: [PATCH v8 06/21] qdev-monitor: well form error hint helpers, (continued)
[PATCH v8 01/21] hw/core/loader-fit: fix freeing errp in fit_load_fdt, Vladimir Sementsov-Ogievskiy, 2019/12/05
[PATCH v8 19/21] backends/cryptodev: drop local_err from cryptodev_backend_complete(),
Vladimir Sementsov-Ogievskiy <=
[PATCH v8 16/21] hw/tpm: rename Error ** parameter to more common errp, Vladimir Sementsov-Ogievskiy, 2019/12/05
[PATCH v8 03/21] error: make Error **errp const where it is appropriate, Vladimir Sementsov-Ogievskiy, 2019/12/05
[PATCH v8 12/21] qga: rename Error ** parameter to more common errp, Vladimir Sementsov-Ogievskiy, 2019/12/05
[PATCH v8 04/21] hmp: drop Error pointer indirection in hmp_handle_error, Vladimir Sementsov-Ogievskiy, 2019/12/05