quickpassthrough/README.md

56 lines
3.1 KiB
Markdown
Raw Normal View History

2022-02-27 13:56:39 -05:00
# VFIO-enabler (name pending)
2022-02-27 13:58:00 -05:00
A project to simplify setting up GPU passthrough for [QuickEMU](https://github.com/quickemu-project/quickemu) and libvirt
2022-02-25 07:29:08 -05:00
2022-02-28 13:57:46 -05:00
Currently this project does NO MODIFICATIONS to your system, all it does is generate the files needed for testing inside `./config/`<br>
2022-02-28 13:57:10 -05:00
In a future version it will ask if you want changes applied to your system, however I am not enabling that until I have confirmation that this generates a working configuration for other systems than my own.
2022-02-27 13:56:39 -05:00
You can use it by simply running
```bash
git clone https://github.com/HikariKnight/VFIO-enabler.git
cd VFIO-enabler
./vfio-setup
```
2022-02-27 11:20:09 -05:00
2022-02-27 13:06:59 -05:00
## Features
* General warning and info about what you will be needing
* Enable and configure vfio modules
* Configure 2nd GPU for GPU Passthrough
* Dump the selected GPU rom (as some cards require a romfile for passthrough to work), however no rom patching support planned.
* Enable and configure the correct kernel modules
2022-02-27 13:56:39 -05:00
* Provides you with the correct kernel arguments to add to your bootloader entry
2022-02-25 07:29:08 -05:00
## Contributing
<img src="https://user-images.githubusercontent.com/2557889/156038229-4e70352f-9182-4474-8e32-d14d3ad67566.png" width="250px"><br>
I know my bash skills are not great, so help is always welcome! And help is wanted here.<br>
If you know bash well, you will be able to help! Just make a pull request with your changes!<br>
Just remember to add comments to document the work and explain it for people who are less familiar with the bash syntax or anything else you use. 😄<br>
<br>
Also if you know english, you can just help proof reading. English is not my native language, plus I have dyslexia so I often make spelling mistakes.<br>
Proof reading is still contribution!
2022-02-25 07:29:08 -05:00
## TODO
2022-02-25 08:35:32 -05:00
* ~~Everything~~
* ~~Show general warning to user and inform about making a backup and general expectations~~
2022-02-27 13:06:59 -05:00
* ~~Detect if user has an amd or intel CPU and provide the correct IOMMU kernel args based on that~~
2022-02-25 08:35:32 -05:00
* ~~Tell user to enable IOMMU (VT-d/AMD-v) on their motherboard and bootloader~~
2022-02-27 13:06:59 -05:00
* ~~Integrate ls-iommu and locate graphic cards and see what IOMMU group they are in~~
2022-02-27 16:03:57 -05:00
* ~~Enable and configure vfio modules~~
2022-02-27 13:56:39 -05:00
* ~~Fetch the ID for the GPUs and generate the correct kernel arguments for grub and systemd-boot~~
2022-02-27 13:06:59 -05:00
* ~~Dump the GPU rom, just in case it will be needed for passthrough~~ (no rom patching planned due to complexity)
2022-02-27 13:56:39 -05:00
* Get help to actually make the scripts better
2022-02-27 13:06:59 -05:00
* A non hacky menu system? (I will need help by some bash wizards for this)
2022-02-28 13:57:10 -05:00
* Colored highlight/text for important information?
2022-02-27 16:02:53 -05:00
* Blacklist drivers? (some cards require blacklisting as softdep is not enough)
2022-02-26 18:09:21 -05:00
* Install vendor_reset kernel module? (maybe far future)
2022-02-27 13:56:39 -05:00
* Setup looking-glass? (far future maybe)
<br>
### Why bash?
I wanted the dependencies to be minimal without the need for compilation and not have a potential breaking change in the future (like with the transition from python2 to python3).
I know enough bash to make things work, but I am in no way a professional in writing bash scripts as I usually write python and golang.
2022-02-28 13:57:10 -05:00
There is also quite a lot of perl usage as I am quite familiar with the perl regex format over something like sed