All of lore.kernel.org
 help / color / mirror / Atom feed
From: zhenwei pi <pizhenwei@bytedance.com>
To: berto@igalia.com
Cc: arei.gonglei@huawei.com, qemu-devel@nongnu.org,
	qemu-block@nongnu.org, berrange@redhat.com,
	zhenwei pi <pizhenwei@bytedance.com>
Subject: [PATCH v2 5/5] cryptodev: use NULL throttle timer cb for read direction
Date: Tue, 27 Jun 2023 15:24:31 +0800	[thread overview]
Message-ID: <20230627072431.449171-6-pizhenwei@bytedance.com> (raw)
In-Reply-To: <20230627072431.449171-1-pizhenwei@bytedance.com>

Operations on a crytpodev are considered as *write* only, the callback
of read direction is never invoked. Use NULL instead of an unreachable
path(cryptodev_backend_throttle_timer_cb on read direction).

Signed-off-by: zhenwei pi <pizhenwei@bytedance.com>
---
 backends/cryptodev.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/backends/cryptodev.c b/backends/cryptodev.c
index 7d29517843..5cfa25c61c 100644
--- a/backends/cryptodev.c
+++ b/backends/cryptodev.c
@@ -331,8 +331,7 @@ static void cryptodev_backend_set_throttle(CryptoDevBackend *backend, int field,
     if (!enabled) {
         throttle_init(&backend->ts);
         throttle_timers_init(&backend->tt, qemu_get_aio_context(),
-                             QEMU_CLOCK_REALTIME,
-                             cryptodev_backend_throttle_timer_cb, /* FIXME */
+                             QEMU_CLOCK_REALTIME, NULL,
                              cryptodev_backend_throttle_timer_cb, backend);
     }
 
-- 
2.34.1



  parent reply	other threads:[~2023-06-27  7:26 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-27  7:24 [PATCH v2 0/5] Misc fixes for throttle zhenwei pi
2023-06-27  7:24 ` [PATCH v2 1/5] throttle: introduce enum ThrottleType zhenwei pi
2023-07-03 10:26   ` Alberto Garcia
2023-06-27  7:24 ` [PATCH v2 2/5] test-throttle: use " zhenwei pi
2023-07-03 10:26   ` Alberto Garcia
2023-06-27  7:24 ` [PATCH v2 3/5] throttle: support read-only and write-only zhenwei pi
2023-07-03 10:28   ` Alberto Garcia
2023-06-27  7:24 ` [PATCH v2 4/5] test-throttle: test read only and write only zhenwei pi
2023-07-03 10:31   ` Alberto Garcia
2023-06-27  7:24 ` zhenwei pi [this message]
2023-07-03 10:28   ` [PATCH v2 5/5] cryptodev: use NULL throttle timer cb for read direction Alberto Garcia
2023-07-11  0:29 ` PING: [PATCH v2 0/5] Misc fixes for throttle zhenwei pi

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=20230627072431.449171-6-pizhenwei@bytedance.com \
    --to=pizhenwei@bytedance.com \
    --cc=arei.gonglei@huawei.com \
    --cc=berrange@redhat.com \
    --cc=berto@igalia.com \
    --cc=qemu-block@nongnu.org \
    --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.