Author SHA1 Message Date
Void fa22cf6c0a Merge branch 'WORMSTweaker-master-patch-96744' into 'master'
Add link to the wiki in the README (why wasn't this done before?)

See merge request risingprismtv/single-gpu-passthrough!20
2023-07-07 12:55:21 +00:00
Void d1a8e2c6a3 Merge branch 'master' into 'master'
No longer touch system directories where not needed.

See merge request risingprismtv/single-gpu-passthrough!15
2023-07-07 12:51:26 +00:00
Balázs Vadász e70f12845e No longer touch system directories where not needed. 2023-07-07 12:51:25 +00:00
WORMSTweaker 3dd1af49e7 Add link to the wiki in the README (why wasn't this done before?) 2023-07-03 15:09:00 +00:00
5 changed files with 12 additions and 10 deletions
+2
View File
@@ -9,5 +9,7 @@ Note the PCI ids and display manager should be detected automatically. If you ar
If using startx, add a line `killall -u user_name` to qemu/vfio-startup.sh script towards the beginning and you can add a line to vfio-teardown.sh to start your window manager/ desktop environment again. Don't just add startx because it will be run as root. Instead add `su -s /bin/bash -c "/usr/bin/startx" -g username username` replacing username with your username to the end of the vfio-teardown.sh script. If using startx, add a line `killall -u user_name` to qemu/vfio-startup.sh script towards the beginning and you can add a line to vfio-teardown.sh to start your window manager/ desktop environment again. Don't just add startx because it will be run as root. Instead add `su -s /bin/bash -c "/usr/bin/startx" -g username username` replacing username with your username to the end of the vfio-teardown.sh script.
For a detailled guide on how to use these scripts, [check out the the wiki of this repo.](https://gitlab.com/risingprismtv/single-gpu-passthrough/-/wikis/home)
For suggestions or support, join us on Discord at: https://discord.gg/bh4maVc For suggestions or support, join us on Discord at: https://discord.gg/bh4maVc
+2 -2
View File
@@ -7,12 +7,12 @@ if [[ $OBJECT == "win10" ]]; then
case "$OPERATION" in case "$OPERATION" in
"prepare") "prepare")
systemctl start libvirt-nosleep@"$OBJECT" 2>&1 | tee -a /var/log/libvirt/custom_hooks.log systemctl start libvirt-nosleep@"$OBJECT" 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
/bin/vfio-startup.sh 2>&1 | tee -a /var/log/libvirt/custom_hooks.log /usr/local/bin/vfio-startup 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
;; ;;
"release") "release")
systemctl stop libvirt-nosleep@"$OBJECT" 2>&1 | tee -a /var/log/libvirt/custom_hooks.log systemctl stop libvirt-nosleep@"$OBJECT" 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
/bin/vfio-teardown.sh 2>&1 | tee -a /var/log/libvirt/custom_hooks.log /usr/local/bin/vfio-teardown 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
;; ;;
esac esac
fi fi
+8 -8
View File
@@ -8,13 +8,13 @@ if test -e /etc/libvirt/hooks/qemu;
then then
mv /etc/libvirt/hooks/qemu /etc/libvirt/hooks/qemu_last_backup mv /etc/libvirt/hooks/qemu /etc/libvirt/hooks/qemu_last_backup
fi fi
if test -e /bin/vfio-startup.sh; if test -e /usr/local/bin/vfio-startup;
then then
mv /bin/vfio-startup.sh /bin/vfio-startup.sh.bkp mv /usr/local/bin/vfio-startup /usr/local/bin/vfio-startup.bkp
fi fi
if test -e /bin/vfio-teardown.sh; if test -e /usr/local/bin/vfio-teardown;
then then
mv /bin/vfio-teardown.sh /bin/vfio-teardown.sh.bkp mv /usr/local/bin/vfio-teardown /usr/local/bin/vfio-teardown.bkp
fi fi
if test -e /etc/systemd/system/libvirt-nosleep@.service; if test -e /etc/systemd/system/libvirt-nosleep@.service;
then then
@@ -22,10 +22,10 @@ then
fi fi
cp systemd-no-sleep/libvirt-nosleep@.service /etc/systemd/system/libvirt-nosleep@.service cp systemd-no-sleep/libvirt-nosleep@.service /etc/systemd/system/libvirt-nosleep@.service
cp hooks/vfio-startup.sh /bin/vfio-startup.sh cp hooks/vfio-startup /usr/local/bin/vfio-startup
cp hooks/vfio-teardown.sh /bin/vfio-teardown.sh cp hooks/vfio-teardown /usr/local/bin/vfio-teardown
cp hooks/qemu /etc/libvirt/hooks/qemu cp hooks/qemu /etc/libvirt/hooks/qemu
chmod +x /bin/vfio-startup.sh chmod +x /usr/local/bin/vfio-startup
chmod +x /bin/vfio-teardown.sh chmod +x /usr/local/bin/vfio-teardown
chmod +x /etc/libvirt/hooks/qemu chmod +x /etc/libvirt/hooks/qemu