]> git.ipfire.org Git - thirdparty/qemu.git/commit
hw/nvme: fix missing check for PMR capability
authorKlaus Jensen <k.jensen@samsung.com>
Mon, 7 Jun 2021 09:47:57 +0000 (11:47 +0200)
committerMichael Roth <michael.roth@amd.com>
Thu, 14 Oct 2021 22:05:22 +0000 (17:05 -0500)
commitbef905cd8a3eb0753262703ecebf2fae0658154b
treeb0d4e04de8244309ecffc54b371639995fd974e7
parentaa99651295cf13aafa8db030c3cc1a0c1b64427d
hw/nvme: fix missing check for PMR capability

Qiang Liu reported that an access on an unknown address is triggered in
memory_region_set_enabled because a check on CAP.PMRS is missing for the
PMRCTL register write when no PMR is configured.

Cc: qemu-stable@nongnu.org
Fixes: 75c3c9de961d ("hw/block/nvme: disable PMR at boot up")
Resolves: https://gitlab.com/qemu-project/qemu/-/issues/362
Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
Reviewed-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 2b02aabc9d02f9e95946cf639f546bb61f1721b7)
Signed-off-by: Michael Roth <michael.roth@amd.com>
hw/block/nvme.c