You are not logged in.
Pages: 1
How do I enable simpledrm with linux-zen?
Last edited by dosamoda (2023-06-19 07:26:49)
Offline
It already is: https://github.com/archlinux/svntogit-p … nfig#L6795
Since that answers the Y of your XY: https://xyproblem.info/ -- what exactly is it you are hoping/looking for?
Online
I was messing around with single gpu pass though and was having an issue.
When the windows guest session shut down, the host graphical session would not start and my monitor would suspend. This issue was solved when I disabled the igpu.
I don't know much about the topic, and was wondering if my current frame buffer may have been the cause and wanted to test with different buffers to see If I find a fix to this issue without disabling my igpu.
#sudo dmesg | grep "frame"
[ 0.000000] signal: max sigframe size: 3632
[ 3.456751] efifb: framebuffer at 0x40000000, using 8100k, total 8100k
[ 3.456797] fb0: EFI VGA frame buffer device
[ 3.824883] Console: switching to colour frame buffer device 240x67
[ 34.970271] r8169 0000:05:00.0 eth0: jumbo features [frames: 9194 bytes, tx checksumming: ko]
[ 36.558857] Console: switching to colour frame buffer device 240x67
[ 36.577629] amdgpu 0000:03:00.0: [drm] fb0: amdgpudrmfb frame buffer device
Offline
single gpu pass through ..... when I disabled the igpu
Single gpu pass-through refers to systems with only one gpu . Disabling that one gpu effectively turns it into a headless system .
How many gpus does your system have ?
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
single gpu pass through ..... when I disabled the igpu
How many gpus does your system have ?
2, An Intel igpu and an Amd dgpu.
Offline
You want to use the Intel chip for arch and switch the amd dGPU dynamically between arch & guest ?
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
You want to use the Intel chip for arch and switch the amd dGPU dynamically between arch & guest ?
Not exactly, I want to have the host and guest use the same dgpu. The Igpu was there for screen recording with obs.
I only use one DP cable from my dgpu to my monitor, nothing else provides output to the display
Let me post my VM xml file along with my startup and shut down hooks.
<domain type="kvm">
<name>win12</name>
<uuid>3e1613c0-cb9f-4d2e-9148-df92da176d76</uuid>
<metadata>
<libosinfo:libosinfo xmlns:libosinfo="http://libosinfo.org/xmlns/libvirt/domain/1.0">
<libosinfo:os id="http://microsoft.com/win/11"/>
</libosinfo:libosinfo>
</metadata>
<memory unit="KiB">16777216</memory>
<currentMemory unit="KiB">16777216</currentMemory>
<vcpu placement="static">8</vcpu>
<os firmware="efi">
<type arch="x86_64" machine="pc-q35-8.0">hvm</type>
<firmware>
<feature enabled="no" name="enrolled-keys"/>
<feature enabled="no" name="secure-boot"/>
</firmware>
<loader readonly="yes" type="pflash">/usr/share/edk2/x64/OVMF_CODE.fd</loader>
<nvram template="/usr/share/edk2/x64/OVMF_VARS.fd">/var/lib/libvirt/qemu/nvram/win12_VARS.fd</nvram>
</os>
<features>
<acpi/>
<apic/>
<hyperv mode="custom">
<relaxed state="on"/>
<vapic state="on"/>
<spinlocks state="on" retries="8191"/>
</hyperv>
<kvm>
<hidden state="on"/>
</kvm>
<vmport state="off"/>
</features>
<cpu mode="host-passthrough" check="none" migratable="on">
<topology sockets="1" dies="1" cores="4" threads="2"/>
<feature policy="disable" name="smep"/>
</cpu>
<clock offset="localtime">
<timer name="rtc" tickpolicy="catchup"/>
<timer name="pit" tickpolicy="delay"/>
<timer name="hpet" present="no"/>
<timer name="hypervclock" present="yes"/>
</clock>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>destroy</on_crash>
<pm>
<suspend-to-mem enabled="no"/>
<suspend-to-disk enabled="no"/>
</pm>
<devices>
<emulator>/usr/bin/qemu-system-x86_64</emulator>
<disk type="file" device="disk">
<driver name="qemu" type="qcow2" cache="writeback" discard="unmap"/>
<source file="/var/lib/libvirt/images/win12.qcow2"/>
<target dev="vda" bus="virtio"/>
<boot order="1"/>
<address type="pci" domain="0x0000" bus="0x04" slot="0x00" function="0x0"/>
</disk>
<disk type="file" device="disk">
<driver name="qemu" type="qcow2" cache="writeback" discard="unmap"/>
<source file="/var/lib/libvirt/images/win12-1.qcow2"/>
<target dev="vdb" bus="virtio"/>
<address type="pci" domain="0x0000" bus="0x07" slot="0x00" function="0x0"/>
</disk>
<controller type="usb" index="0" model="qemu-xhci" ports="15">
<address type="pci" domain="0x0000" bus="0x02" slot="0x00" function="0x0"/>
</controller>
<controller type="pci" index="0" model="pcie-root"/>
<controller type="pci" index="1" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="1" port="0x10"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x0" multifunction="on"/>
</controller>
<controller type="pci" index="2" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="2" port="0x11"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x1"/>
</controller>
<controller type="pci" index="3" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="3" port="0x12"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x2"/>
</controller>
<controller type="pci" index="4" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="4" port="0x13"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x3"/>
</controller>
<controller type="pci" index="5" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="5" port="0x14"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x4"/>
</controller>
<controller type="pci" index="6" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="6" port="0x15"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x5"/>
</controller>
<controller type="pci" index="7" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="7" port="0x16"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x6"/>
</controller>
<controller type="pci" index="8" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="8" port="0x17"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x7"/>
</controller>
<controller type="pci" index="9" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="9" port="0x18"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x0" multifunction="on"/>
</controller>
<controller type="pci" index="10" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="10" port="0x19"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x1"/>
</controller>
<controller type="pci" index="11" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="11" port="0x1a"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x2"/>
</controller>
<controller type="pci" index="12" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="12" port="0x1b"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x3"/>
</controller>
<controller type="pci" index="13" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="13" port="0x1c"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x4"/>
</controller>
<controller type="pci" index="14" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="14" port="0x1d"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x5"/>
</controller>
<controller type="pci" index="15" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="15" port="0x8"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x01" function="0x0"/>
</controller>
<controller type="pci" index="16" model="pcie-to-pci-bridge">
<model name="pcie-pci-bridge"/>
<address type="pci" domain="0x0000" bus="0x08" slot="0x00" function="0x0"/>
</controller>
<controller type="sata" index="0">
<address type="pci" domain="0x0000" bus="0x00" slot="0x1f" function="0x2"/>
</controller>
<interface type="network">
<mac address="52:54:00:d0:35:0f"/>
<source network="default"/>
<model type="e1000e"/>
<address type="pci" domain="0x0000" bus="0x01" slot="0x00" function="0x0"/>
</interface>
<input type="mouse" bus="ps2"/>
<input type="keyboard" bus="ps2"/>
<audio id="1" type="none"/>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x03" slot="0x00" function="0x0"/>
</source>
<rom file="/var/lib/libvirt/vbios/6600xt.rom"/>
<address type="pci" domain="0x0000" bus="0x03" slot="0x00" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x03" slot="0x00" function="0x1"/>
</source>
<address type="pci" domain="0x0000" bus="0x06" slot="0x00" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x00" slot="0x1f" function="0x0"/>
</source>
<address type="pci" domain="0x0000" bus="0x10" slot="0x01" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x00" slot="0x1f" function="0x3"/>
</source>
<address type="pci" domain="0x0000" bus="0x10" slot="0x02" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x00" slot="0x1f" function="0x4"/>
</source>
<address type="pci" domain="0x0000" bus="0x10" slot="0x03" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x00" slot="0x1f" function="0x5"/>
</source>
<address type="pci" domain="0x0000" bus="0x10" slot="0x04" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x00" slot="0x14" function="0x0"/>
</source>
<address type="pci" domain="0x0000" bus="0x10" slot="0x05" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x00" slot="0x14" function="0x2"/>
</source>
<address type="pci" domain="0x0000" bus="0x10" slot="0x06" function="0x0"/>
</hostdev>
<watchdog model="itco" action="reset"/>
<memballoon model="virtio">
<address type="pci" domain="0x0000" bus="0x05" slot="0x00" function="0x0"/>
</memballoon>
</devices>
</domain>#cat /bin/vfio-startup.sh
#!/bin/bash
## Load VFIO-PCI driver ##
modprobe vfio
modprobe vfio_pci
modprobe vfio_iommu_type1
#dGPU-VGA host unbind
echo "1002 73ff" > /sys/bus/pci/drivers/vfio-pci/new_id
echo "0000:03:00.0" > /sys/bus/pci/devices/0000:03:00.0/driver/unbind
echo "0000:03:00.0" > /sys/bus/pci/drivers/vfio-pci/bind
echo "1002 73ff" > /sys/bus/pci/drivers/vfio-pci/remove_id
#dGPU-AUDIO host unbind
echo "1002 ab28" > /sys/bus/pci/drivers/vfio-pci/new_id
echo "0000:03:00.1" > /sys/bus/pci/devices/0000:03:00.1/driver/unbind
echo "0000:03:00.1" > /sys/bus/pci/drivers/vfio-pci/bind
echo "1002 ab28" > /sys/bus/pci/drivers/vfio-pci/remove_id#cat /bin/vfio-teardown.sh
#!/bin/bash
#dGPU host bind
echo 1 > /sys/bus/pci/devices/0000:03:00.0/remove
echo 1 > /sys/bus/pci/devices/0000:03:00.1/remove
echo 1 > /sys/bus/pci/rescan
#iGPU host ubind
#iGPU-VGA
#echo "0000:00:02.0" > /sys/bus/pci/devices/0000:00:02.0/driver/unbind
#echo 1 > /sys/bus/pci/devices/0000:00:02.0/remove
#echo 1 > /sys/bus/pci/rescan
## Unload VFIO-PCI driver ##
modprobe -r vfio_pci
modprobe -r vfio_iommu_type1
modprobe -r vfioWith the relevant files, I hope it makes it easier to understand my situation.
Starting the VM is never an issue (with or without the iGPU), the problem occurs when the guest shuts down.
With the IGPU present, when the guest session shuts down my host will bind to the igpu to provide a graphical output; however, the performance of the host session diminishes (visible slow downs). To counter this I added the following snippet to the vfio-teardown.sh.
#iGPU-VGA
echo "0000:00:02.0" > /sys/bus/pci/devices/0000:00:02.0/driver/unbind
echo 1 > /sys/bus/pci/devices/0000:00:02.0/remove
echo 1 > /sys/bus/pci/rescanHere, when the guest shuts down, I want the host to unbind and rebind the igpu, so the dgpu will take over the host session before the igpu.
This fixed the issue; however, if I shutdown the guest session again (within the same host session) my host system would not start, and my monitor would suspend.
So I decided to turn the igpu off. With the igpu off, I can shutdown and start the vm as much as I want, and doesn't come with a performance penalty when I shut down the guest session.
This is where my suspicion of frame buffers came, I know distros used an old frame buffer and I wanted to know if changing it to a modern one would fix it.
I knew linux-zen had a modern frame buffer enabled at compile (SIMPLEDRM); however, nothing came up when I grep'd for "simple" in dmesg. That's why I asked how to load in the module.
Offline
It turn out SDDM was causing this, switching to lightdm has fixed the issue.
Last edited by dosamoda (2023-06-19 07:24:41)
Offline
Pages: 1