Bug 2212225

Summary: PCem crashed when launch a VM on Wayland.
Product: [Fedora] Fedora Reporter: Egor Gavrilov <gavrilovegor519+fedora>
Component: pcemAssignee: Davide Cavalca <davide>
Status: NEW --- QA Contact:
Severity: urgent Docs Contact:
Priority: unspecified    
Version: 38CC: davide
Target Milestone: ---Keywords: Desktop
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 2170952    

Description Egor Gavrilov 2023-06-04 21:19:31 UTC
When starting the PCem virtual machine using the Wayland session, PCem stupidly crashes.

Reproducible: Always

Steps to Reproduce:
1. Create emulated VM on PCem.
2. Launch it.
3. Crash!
Actual Results:  
Emulated VM is crashed.

Expected Results:  
Emulated VM is normal starting and working.

Comment 1 Davide Cavalca 2023-06-26 07:47:16 UTC
I can't repro this on my end, can you share a bit more about your setup?

Comment 2 Egor Gavrilov 2023-06-26 08:17:45 UTC
(In reply to Davide Cavalca from comment #1)
> I can't repro this on my end, can you share a bit more about your setup?

CPU: Ryzen 3 4300U.
RAM: 8 GB DDR4 3200 MHz.
GPU: Radeon iGPU.
Fedora version: 38.
Graphic protocol: Wayland.
DE: GNOME 44.
Secure Boot: disabled.
TPM 2.0: enabled.
Boot method: UEFI.

Comment 3 Davide Cavalca 2023-06-27 09:01:32 UTC
Ok I managed to get this to repro when booting a 486 VM with S3 video. This looks the same as https://bugzilla.redhat.com/show_bug.cgi?id=2170952 and it boils down to pcem not really supporting wayland. There's some discussion upstream in https://github.com/sarah-walker-pcem/pcem/issues/128 for a related issue. I will push an updated to build forcing pcem to x11 for the time being, in the meantime you can workaround this by setting the SDL_VIDEODRIVER=x11 and GDK_BACKEND=x11 environment variables before running pcem.