diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2024-04-12 17:08:05 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2024-04-25 10:21:06 +0100 |
commit | ef6ab2922fc94956c0b28c55ec2abe61f71446a9 (patch) | |
tree | 4847b39c3acdd423175126b551852d94d41ce0d1 /hw/sensor | |
parent | 1e0f2b38ac104ec3606750cce847cc9d8e4f66ac (diff) | |
download | qemu-ef6ab2922fc94956c0b28c55ec2abe61f71446a9.zip qemu-ef6ab2922fc94956c0b28c55ec2abe61f71446a9.tar.gz qemu-ef6ab2922fc94956c0b28c55ec2abe61f71446a9.tar.bz2 |
allwinner-i2c, adm1272: Use device_cold_reset() for software-triggered reset
Rather than directly calling the device's implementation of its 'hold'
reset phase, call device_cold_reset(). This means we don't have to
adjust this callsite when we add another argument to the function
signature for the hold and exit reset methods.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Luc Michel <luc.michel@amd.com>
Message-id: 20240412160809.1260625-3-peter.maydell@linaro.org
Diffstat (limited to 'hw/sensor')
-rw-r--r-- | hw/sensor/adm1272.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/sensor/adm1272.c b/hw/sensor/adm1272.c index 1f7c8ab..a19557e 100644 --- a/hw/sensor/adm1272.c +++ b/hw/sensor/adm1272.c @@ -386,7 +386,7 @@ static int adm1272_write_data(PMBusDevice *pmdev, const uint8_t *buf, break; case ADM1272_MFR_POWER_CYCLE: - adm1272_exit_reset((Object *)s); + device_cold_reset(DEVICE(s)); break; case ADM1272_HYSTERESIS_LOW: |