Re: [PATCH v2] hw/nvme: Add helper functions for qid-db conversion

2022-08-04 Thread Klaus Jensen
On Aug 3 09:58, Jinhao Fan wrote: > With the introduction of shadow doorbell and ioeventfd, we need to do > frequent conversion between qid and its doorbell offset. The original > hard-coded calculation is confusing and error-prone. Add several helper > functions to do this task. > > Signed-off-b

[PATCH v2] hw/nvme: Add helper functions for qid-db conversion

2022-08-02 Thread Jinhao Fan
With the introduction of shadow doorbell and ioeventfd, we need to do frequent conversion between qid and its doorbell offset. The original hard-coded calculation is confusing and error-prone. Add several helper functions to do this task. Signed-off-by: Jinhao Fan --- Changes since v1: - Use lef