]> git.ipfire.org Git - thirdparty/qemu.git/commit
hw/misc/aspeed_scu: Fix the hw-strap1 cannot be set in the SOC layer for AST2700
authorJamin Lin <jamin_lin@aspeedtech.com>
Tue, 4 Mar 2025 06:47:06 +0000 (14:47 +0800)
committerCédric Le Goater <clg@redhat.com>
Sun, 9 Mar 2025 13:36:53 +0000 (14:36 +0100)
commit720e850f83ef6497d9992c43716fb5d7cc9a2ad2
tree8335794c41cfc694dbe50a9970c100575943c819
parent172329c6b281e11feb3d6e60df6754008e23a089
hw/misc/aspeed_scu: Fix the hw-strap1 cannot be set in the SOC layer for AST2700

There is one hw_strap1 register in the SCU (CPU DIE) and another hw_strap1
register in the SCUIO (IO DIE).

In the "ast2700_a0_resets" function, the hardcoded value "0x00000800" is set in
SCU hw-strap1 (CPU DIE), and in "ast2700_a0_resets_io" the hardcoded value
"0x00000504" is set in SCUIO hw-strap1 (IO DIE). Both values cannot be set via
the SOC layer.

The value of "s->hw_strap1" is set by the SOC layer via the "hw-strap1" property.
Update the "aspeed_ast2700_scu_reset" function to set the value of "s->hw_strap1"
in both the SCU and SCUIO hw-strap1 registers.

Signed-off-by: Jamin Lin <jamin_lin@aspeedtech.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Tested-by: Nabih Estefan <nabihestefan@google.com>
Link: https://lore.kernel.org/qemu-devel/20250304064710.2128993-5-jamin_lin@aspeedtech.com
Signed-off-by: Cédric Le Goater <clg@redhat.com>
hw/misc/aspeed_scu.c