[PATCH v3 0/2] KVM Support for imx8mp-evk Machine

Bernhard Beschow posted 2 patches 1 week, 6 days ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20251101120130.236721-1-shentey@gmail.com
Maintainers: Bernhard Beschow <shentey@gmail.com>, Paolo Bonzini <pbonzini@redhat.com>, Peter Maydell <peter.maydell@linaro.org>
docs/system/arm/imx8mp-evk.rst | 19 +++++++++++++++++++
hw/arm/fsl-imx8mp.c            | 34 +++++++++++++++++++++++++++++-----
hw/arm/imx8mp-evk.c            | 20 ++++++++++++++++++++
hw/arm/Kconfig                 |  3 ++-
4 files changed, 70 insertions(+), 6 deletions(-)
[PATCH v3 0/2] KVM Support for imx8mp-evk Machine
Posted by Bernhard Beschow 1 week, 6 days ago
This series adds KVM support to the imx8mp-evk machine, allowing it to run
guests with KVM acceleration. Inspiration was taken from the virt machine. This
required a device tree quirk for the guest clock to be kept in sync with the
host. Without this quirk the guest's clock would advance with factor <host
system counter> / 8Mhz.

Testing done:
* Run `make check`
* Run Buildroot image with TCG
* Run `qemu-system-aarch64 -M imx8mp-evk -accel kvm -smp 4` under
  `qemu-system-aarch64 -M virt,secure=on,virtualization=on,gic-version=4 \
  -cpu cortex-a72 -smp 4 -accel tcg` and `qemu-system-aarch64 -M imx8mp-evk \
  -accel tcg -smp 4". Observe that the `date` command reflects the host's date.

v3:
* Fix crash in qtest (Peter) by using cortex-a53 CPU when ms->cpu_type == NULL
* Apply Peter's style fixes in board documentation
* Apply Phil's R-b -- thanks!
* Rebase onto master

v2:
* Rebase onto master
* Mention various tradeoffs in the board documentation (Peter)
* Accommodate for single-binary (Peter, Pierrick) by having CPU defaults
* Add quirk to fix guest clock

Bernhard Beschow (2):
  hw/arm/imx8mp-evk: Add KVM support
  hw/arm/imx8mp-evk: Fix guest time in KVM mode

 docs/system/arm/imx8mp-evk.rst | 19 +++++++++++++++++++
 hw/arm/fsl-imx8mp.c            | 34 +++++++++++++++++++++++++++++-----
 hw/arm/imx8mp-evk.c            | 20 ++++++++++++++++++++
 hw/arm/Kconfig                 |  3 ++-
 4 files changed, 70 insertions(+), 6 deletions(-)

-- 
2.51.2

Re: [PATCH v3 0/2] KVM Support for imx8mp-evk Machine
Posted by Bernhard Beschow 1 week, 4 days ago

Am 1. November 2025 12:01:28 UTC schrieb Bernhard Beschow <shentey@gmail.com>:
>This series adds KVM support to the imx8mp-evk machine, allowing it to run
>
>guests with KVM acceleration. Inspiration was taken from the virt machine. This
>
>required a device tree quirk for the guest clock to be kept in sync with the
>
>host. Without this quirk the guest's clock would advance with factor <host
>
>system counter> / 8Mhz.
>
>
>
>Testing done:
>
>* Run `make check`
>
>* Run Buildroot image with TCG
>
>* Run `qemu-system-aarch64 -M imx8mp-evk -accel kvm -smp 4` under
>
>  `qemu-system-aarch64 -M virt,secure=on,virtualization=on,gic-version=4 \
>
>  -cpu cortex-a72 -smp 4 -accel tcg` and `qemu-system-aarch64 -M imx8mp-evk \
>
>  -accel tcg -smp 4". Observe that the `date` command reflects the host's date.
>
>
>
>v3:
>
>* Fix crash in qtest (Peter) by using cortex-a53 CPU when ms->cpu_type == NULL
>
>* Apply Peter's style fixes in board documentation
>
>* Apply Phil's R-b -- thanks!
>
>* Rebase onto master
>

Is there still a chance to get this series into 10.2? Soft feature freeze is tomorrow.

Best regards,
Bernhard

>
>
>v2:
>
>* Rebase onto master
>
>* Mention various tradeoffs in the board documentation (Peter)
>
>* Accommodate for single-binary (Peter, Pierrick) by having CPU defaults
>
>* Add quirk to fix guest clock
>
>
>
>Bernhard Beschow (2):
>
>  hw/arm/imx8mp-evk: Add KVM support
>
>  hw/arm/imx8mp-evk: Fix guest time in KVM mode
>
>
>
> docs/system/arm/imx8mp-evk.rst | 19 +++++++++++++++++++
>
> hw/arm/fsl-imx8mp.c            | 34 +++++++++++++++++++++++++++++-----
>
> hw/arm/imx8mp-evk.c            | 20 ++++++++++++++++++++
>
> hw/arm/Kconfig                 |  3 ++-
>
> 4 files changed, 70 insertions(+), 6 deletions(-)
>
>
>
>-- >
>2.51.2
>
>
>
Re: [PATCH v3 0/2] KVM Support for imx8mp-evk Machine
Posted by Peter Maydell 1 week, 3 days ago
On Mon, 3 Nov 2025 at 08:55, Bernhard Beschow <shentey@gmail.com> wrote:
>
>
>
> Am 1. November 2025 12:01:28 UTC schrieb Bernhard Beschow <shentey@gmail.com>:
> >This series adds KVM support to the imx8mp-evk machine, allowing it to run
> >
> >guests with KVM acceleration. Inspiration was taken from the virt machine. This
> >
> >required a device tree quirk for the guest clock to be kept in sync with the
> >
> >host. Without this quirk the guest's clock would advance with factor <host
> >
> >system counter> / 8Mhz.
> >
> >
> >
> >Testing done:
> >
> >* Run `make check`
> >
> >* Run Buildroot image with TCG
> >
> >* Run `qemu-system-aarch64 -M imx8mp-evk -accel kvm -smp 4` under
> >
> >  `qemu-system-aarch64 -M virt,secure=on,virtualization=on,gic-version=4 \
> >
> >  -cpu cortex-a72 -smp 4 -accel tcg` and `qemu-system-aarch64 -M imx8mp-evk \
> >
> >  -accel tcg -smp 4". Observe that the `date` command reflects the host's date.
> >
> >
> >
> >v3:
> >
> >* Fix crash in qtest (Peter) by using cortex-a53 CPU when ms->cpu_type == NULL
> >
> >* Apply Peter's style fixes in board documentation
> >
> >* Apply Phil's R-b -- thanks!
> >
> >* Rebase onto master
> >
>
> Is there still a chance to get this series into 10.2? Soft feature freeze is tomorrow.

I've put this into the pullreq I've just sent out for softfreeze.

thanks
-- PMM
Re: [PATCH v3 0/2] KVM Support for imx8mp-evk Machine
Posted by Bernhard Beschow 1 week, 3 days ago

Am 3. November 2025 15:47:29 UTC schrieb Peter Maydell <peter.maydell@linaro.org>:
>On Mon, 3 Nov 2025 at 08:55, Bernhard Beschow <shentey@gmail.com> wrote:
>>
>>
>>
>> Am 1. November 2025 12:01:28 UTC schrieb Bernhard Beschow <shentey@gmail.com>:
>> >This series adds KVM support to the imx8mp-evk machine, allowing it to run
>> >
>> >guests with KVM acceleration. Inspiration was taken from the virt machine. This
>> >
>> >required a device tree quirk for the guest clock to be kept in sync with the
>> >
>> >host. Without this quirk the guest's clock would advance with factor <host
>> >
>> >system counter> / 8Mhz.
>> >
>> >
>> >
>> >Testing done:
>> >
>> >* Run `make check`
>> >
>> >* Run Buildroot image with TCG
>> >
>> >* Run `qemu-system-aarch64 -M imx8mp-evk -accel kvm -smp 4` under
>> >
>> >  `qemu-system-aarch64 -M virt,secure=on,virtualization=on,gic-version=4 \
>> >
>> >  -cpu cortex-a72 -smp 4 -accel tcg` and `qemu-system-aarch64 -M imx8mp-evk \
>> >
>> >  -accel tcg -smp 4". Observe that the `date` command reflects the host's date.
>> >
>> >
>> >
>> >v3:
>> >
>> >* Fix crash in qtest (Peter) by using cortex-a53 CPU when ms->cpu_type == NULL
>> >
>> >* Apply Peter's style fixes in board documentation
>> >
>> >* Apply Phil's R-b -- thanks!
>> >
>> >* Rebase onto master
>> >
>>
>> Is there still a chance to get this series into 10.2? Soft feature freeze is tomorrow.
>
>I've put this into the pullreq I've just sent out for softfreeze.

Thanks, Peter!

>
>thanks
>-- PMM