aboutsummaryrefslogtreecommitdiff
path: root/scripts/rust
diff options
context:
space:
mode:
authorNicholas Piggin <npiggin@gmail.com>2024-12-09 20:00:45 +1000
committerNicholas Piggin <npiggin@gmail.com>2025-03-11 22:43:30 +1000
commita1750b2cba9c70191221f206bfbed277251dd644 (patch)
treef274b6a022e438944eb77c5cea3de2838c183cc5 /scripts/rust
parent028b1803fbe79aaf598b3254338d7010960d1b44 (diff)
downloadqemu-a1750b2cba9c70191221f206bfbed277251dd644.zip
qemu-a1750b2cba9c70191221f206bfbed277251dd644.tar.gz
qemu-a1750b2cba9c70191221f206bfbed277251dd644.tar.bz2
ppc/pnv/occ: Implement a basic dynamic OCC model
The OCC is an On Chip Controller that handles various thermal and power management. It is a PPC405 microcontroller that runs its own firmware which is out of scope of the powernv machine model. Some dynamic behaviour and interfaces that are important for host CPU testing can be implemented with a much simpler state machine. This change adds a 100ms timer that ticks through a simple state machine that looks for "OCC command requests" coming from host firmware, and responds to them. For now the powercap command is implemented because that is used by OPAL and exported to Linux and is easy to test. $ F=/sys/firmware/opal/powercap/system-powercap/powercap-current $ cat $F 100 $ echo 50 | sudo tee $F 50 $ cat $F 50 Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Diffstat (limited to 'scripts/rust')
0 files changed, 0 insertions, 0 deletions