VFIO fixes and malachite things
This commit is contained in:
parent
c4e46d0a28
commit
53ef1f28c6
3 changed files with 24 additions and 10 deletions
|
@ -40,6 +40,14 @@ let
|
|||
# Load VFIO Kernel Module
|
||||
modprobe vfio vfio_pci vfio_iommu_type1
|
||||
|
||||
# Performance Governer
|
||||
for file in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor; do echo "performance" > "$file"; done
|
||||
|
||||
# Isolating CPU
|
||||
systemctl set-property --runtime -- user.slice AllowedCPUs=16-19
|
||||
systemctl set-property --runtime -- system.slice AllowedCPUs=16-19
|
||||
systemctl set-property --runtime -- init.scope AllowedCPUs=16-19
|
||||
|
||||
elif [[ "$HOOK_NAME/$STATE_NAME" == "release/end" ]]; then
|
||||
|
||||
modprobe -r vfio_iommu_type1 vfio_pci vfio
|
||||
|
@ -61,6 +69,13 @@ let
|
|||
# Reload Modules
|
||||
modprobe amdgpu
|
||||
|
||||
# Back to On-Demand Scheduler
|
||||
for file in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor; do echo "ondemand" > "$file"; done
|
||||
|
||||
systemctl set-property --runtime -- user.slice AllowedCPUs=0-19
|
||||
systemctl set-property --runtime -- system.slice AllowedCPUs=0-19
|
||||
systemctl set-property --runtime -- init.scope AllowedCPUs=0-19
|
||||
|
||||
fi
|
||||
|
||||
fi
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue