Repository navigation
Conversation
The destination's reset can assert a CPU's reset pin (ZynqMP's CRF does), and nothing lowers it once the state is loaded: CPUs that were halted when the state was saved never wake. The subsection is always sent, so for every target, streams no longer load on a QEMU without this change. Signed-off-by: Graeme Smecher <gsmecher@t0.technology>
vmstate_mb_cpu is version 0 but its env field is tagged version 1, so the registers were never saved or loaded. Make the description version 1, with a minimum of 1: older streams carry no registers. Also save env->wakeup, the levels of the wakeup lines. Fixes: 77f63e1 ("target/microblaze: Fill in VMStateDescription for cpu") Signed-off-by: Graeme Smecher <gsmecher@t0.technology>
The MicroBlaze I/O module's models have empty vmstates, so the ZynqMP PMU's interrupt controller and PITs come back as reset. Migrate their state. Versions go from 1 to 2 with a minimum of 2: older streams carry none of it. The memory-mapped ARM generic timer migrates its registers but not tick_offset and enabled. Add them as version 2 fields; older streams still load. Signed-off-by: Graeme Smecher <gsmecher@t0.technology>
Plain RAM nodes ("qemu,ram = <1>") are never registered for migration,
so they come back empty: the ZynqMP PMU's ROM, for one. Register them
once parenting has named them.
File-backed nodes ("qemu,ram = <2>") are left to the machine path's
shared files.
Signed-off-by: Graeme Smecher <gsmecher@t0.technology>
With use-pmufw, the boot sequence polls for the PMU firmware on a timer. The reset that precedes an incoming migration starts it, and with no migrated state to replace that, it runs again in the restored guest: it rewrites DDR at address 0, sends PM_SET_CONFIGURATION, and sets the boot CPU's PC. Restored Linux guests then sometimes hang or panic under MTTCG. The DDR contents saved while the firmware reads its configuration are not migrated: a machine saved in that window keeps the configuration object at address 0. Signed-off-by: Graeme Smecher <gsmecher@t0.technology>
The mb_sleep output is lowered when a wakeup line rises, but not when an interrupt wakes the CPU: it stays high while the CPU runs its handler. On ZynqMP, the FSBL waits on it (PMU_GLOBAL's MB_SLEEP) for the PMU's ROM to be done with an IPI before it writes the PMU's firmware, and so doesn't wait. Signed-off-by: Graeme Smecher <gsmecher@t0.technology>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We snapshot a zynqmp multi-arch machine (ARM APU + microblaze PMU) to accelerate regression testing on an RFSoC design. However, snapshots don't completely capture machine state and the stored images don't resume correctly:
The last patch is about booting through the FSBL, not snapshots:
MB_SLEEPdoesn't wait, and a slow PMU jumps into half-written firmware. This needs a companionqemu-devicetreeschange (posted-updates = <0>on the PMU's interrupt line).Not addressed:
make checkfails identically under both master and this PR series - the stock virt and petalogix machines don't start in this tree and we don't touch them.Tested with Linux guests restored under MTTCG, and with a 2026.1 backport in our cosimulation tree.