[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] hw/nvme: fix handling of over-committed queues
From: |
Keith Busch |
Subject: |
Re: [PATCH] hw/nvme: fix handling of over-committed queues |
Date: |
Fri, 25 Oct 2024 10:45:55 -0600 |
On Fri, Oct 25, 2024 at 12:50:45PM +0200, Klaus Jensen wrote:
> @@ -1520,9 +1520,16 @@ static void nvme_post_cqes(void *opaque)
> nvme_inc_cq_tail(cq);
> nvme_sg_unmap(&req->sg);
> +
> + if (QTAILQ_EMPTY(&sq->req_list) && !nvme_sq_empty(sq)) {
> + qemu_bh_schedule(sq->bh);
> + }
> +
> QTAILQ_INSERT_TAIL(&sq->req_list, req, entry);
> }
Shouldn't we schedule the bottom half after the req has been added to
the list? I think everything the callback needs to be written prior to
calling qemu_bh_schedule().