]> git.ipfire.org Git - thirdparty/qemu.git/commit
hw/nvme: fix invalid check on mcl
authorKlaus Jensen <k.jensen@samsung.com>
Thu, 8 Feb 2024 12:22:48 +0000 (13:22 +0100)
committerMichael Tokarev <mjt@tls.msk.ru>
Wed, 13 Mar 2024 17:35:36 +0000 (20:35 +0300)
commit389f6655cacef1108c08e53450cd5abc86e70142
tree467ad9502babd1bbddb5bba9d3d94b2e6237d035
parent2d281e030d02952a4fcca984275e2e8e6cae5d5f
hw/nvme: fix invalid check on mcl

The number of logical blocks within a source range is converted into a
1s based number at the time of parsing. However, when verifying the copy
length we add one again, causing the check against MCL to fail in error.

Cc: qemu-stable@nongnu.org
Fixes: 381ab99d8587 ("hw/nvme: check maximum copy length (MCL) for COPY")
Reviewed-by: Minwoo Im <minwoo.im@samsung.com>
Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
(cherry picked from commit 8c78015a55d84c016da6d5e41b6b5f618ecb25ab)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
hw/nvme/ctrl.c