[RCarH3][DRM] In linux guest mode, rogue_km crash.

root@salvator-x:~# weston-launch -u root
Date: 2020-03-19 UTC
[07:49:12.240] weston 2.0.0
http://wayland.freedesktop.org
Bug reports to: bugs.freedesktop.org/enter_bug.cgi
Build: 84709dd-dirty v4l2-renderer: use uint8_t* for variables to be operated by pointer (2018-10-11 18:53:57 +0900)
[07:49:12.246] Command line: /usr/bin/weston
[07:49:12.247] OS: Linux, 4.14.75-ltsi-yocto-standard, #1 SMP PREEMPT Mon May 17 10:24:06 CST 2021, aarch64
[07:49:12.251] Using config file '/etc/xdg/weston/weston.ini'
[07:49:12.255] Output repaint window is 34 ms maximum.
[07:49:12.258] Loading module '/usr/lib/libweston-2/drm-backend.so'
[07:49:12.265] initializing drm backend
[07:49:12.266] logind: failed to get session seat
[07:49:12.267] logind: cannot setup systemd-logind helper (-61), using legacy fallback
[07:49:12.271] using /dev/dri/card1
[07:49:12.273] Loading module '/usr/lib/libweston-2/gl-renderer.so'
loaded module: libgbm_kms.so.1
[07:49:12.335] warning: either no EGL_EXT_platform_base support or specific platform support; falling back to eglGetDisplay.
[ 38.876439] PVR_K:(Error): 2409: RGXDevInitCompatCheck: Missing compatibility info from FW (9)
[ 38.878126] PVR_K:(Error): 2409: PVRSRVDeviceFinalise: Failed compatibility check for device ffff8005fbed4000 (PVRSRV_ERROR_TIMEOUT)
[ 38.880401] PVR_K: 2409: ------------[ PVR DBG: START (High) ]------------
[ 38.881701] PVR_K: 2409: DDK info: Rogue_DDK_Linux rogueddk 1.10@5187610 (release) r8a7795_qnx_vz
[ 38.883443] PVR_K: 2409: Time now: 000000002515070
[ 38.884433] PVR_K: 2409: Services State: OK
[ 38.885243] PVR_K: 2409: Active connects: No active connections
[ 38.886439] PVR_K: 2409: ------[ Driver Info ]------
[ 38.887394] PVR_K: 2409: UM info: 0.0 @ 0 (debug) build options: 0x00000000
[ 38.888883] PVR_K: 2409: KM info: 0.0 @ 0 (debug) build options: 0x00000000
[ 38.890309] PVR_K: 2409: FW info: UNINITIALIZED
[ 38.891237] PVR_K: 2409: Comparison of UM/KM components: MATCHING
[ 38.892464] PVR_K: 2409: KM Arch: 32 Bit
[ 38.893204] PVR_K: 2409: Driver Mode: Guest
[ 38.894027] PVR_K: 2409: ------[ RGX summary ]------
[ 38.894991] PVR_K: 2409: RGX BVNC: 4.43.6.62
[ 38.895811] PVR_K: 2409: RGX Device State: Active
[ 38.896753] PVR_K: 2409: RGX Power State: ON
[ 38.897571] PVR_K: 2409: RGX FW State: Unavailable under Guest Mode of operation
[ 38.899012] PVR_K: 2409: RGX FW Power State: Unavailable under Guest Mode of operation
[ 38.900569] PVR_K: 2409: (!) Guest Mode of operation. No registers dumped
[ 38.901826] PVR_K: 2409: RGX Kernel CCB WO:0x2 RO:0x0
[ 38.902754] PVR_K: 2409: RGX Firmware CCB WO:0x0 RO:0x0
[ 38.903712] PVR_K: 2409: RGX Kernel CCB commands executed = 0
[ 38.904870] PVR_K: 2409: FW OS config flags = 0x800127 (Ctx switch: TA; 3D; CDM; VDM CS INDEX mode; Medium CSW profile; Use extended; HWR EN; )
[ 38.907204] PVR_K: 2409: Device System Power State: ON
[ 38.908203] PVR_K: 2409: Debug log type: none
[ 38.909051] PVR_K: 2409: RGX FW thread 0: Trace buffer not yet allocated
[ 38.910266] PVR_K: 2409: ------[ Stalled FWCtxs ]------
[ 38.911227] PVR_K: 2409: ------[ Active Sync Checkpoints ]------
[ 38.912387] PVR_K: 2409: ------[ Pending Server Syncs ]------
[ 38.913451] PVR_K: 2409: ------[ Debug summary ]------
[ 38.914480] PVR_K: 2409: RGX FW State: Unavailable under Guest Mode of operation
[ 38.915866] PVR_K: 2409: RGX FW Power State: Unavailable under Guest Mode of operation
[ 38.917388] PVR_K: 2409: ------[ Server Thread Summary ]------
[ 38.921209] PVR_K: 2409: pvr_defer_free : Running
[ 38.924558] PVR_K: 2409: Number of deferred cleanup items : 0
[ 38.930373] PVR_K: 2409: pvr_device_wdg : Running
[ 38.936068] PVR_K: 2409: pvr_cacheop : Running
[ 38.942010] PVR_K: 2409: Configuration: QSZ: 16, UKT: -16, KDFT: 1073741823, KGFT: -1, LINESIZE: 64, PGSIZE: 4096, KDF: Yes, URBF: Yes, KGF: Yes, KRBF: Yes
[ 38.956540] PVR_K: 2409: Pending deferred CacheOp entries : 0
[ 38.960106] PVR_K: 2409: ------[ AppHint Settings ]------
[ 38.965814] PVR_K: 2409: Build Vars
[ 38.971490] PVR_K: 2409: HWRDebugDumpLimit: 0x00000001
[ 38.974877] PVR_K: 2409: EnableTrustedDeviceAceConfig: N
[ 38.980519] PVR_K: 2409: CleanupThreadPriority: 0x00000000
[ 38.988957] PVR_K: 2409: CleanupThreadWeight: 0x00000000
[ 38.992443] PVR_K: 2409: WatchdogThreadPriority: 0x00000000
[ 38.998211] PVR_K: 2409: WatchdogThreadWeight: 0x00000000
[ 39.003904] PVR_K: 2409: HWPerfClientBufferSize: 0x000c0000
[ 39.012339] PVR_K: 2409: Module Params
[ 39.015808] PVR_K: 2409: EnableSignatureChecks: N
[ 39.019117] PVR_K: 2409: SignatureChecksBufSize: 0x00002000
[ 39.024815] PVR_K: 2409: DisableClockGating: N
[ 39.030532] PVR_K: 2409: BIFTilingMode: 0x00000004
[ 39.036323] PVR_K: 2409: DisableDMOverlap: N
[ 39.039470] PVR_K: 2409: EnableCDMKillingRandMode: N
[ 39.045053] PVR_K: 2409: EnableFWContextSwitch: 0x00000007
[ 39.050856] PVR_K: 2409: VDMContextSwitchMode: 0x00000000
[ 39.056633] PVR_K: 2409: EnableRDPowerIsland: 0x00000002
[ 39.062248] PVR_K: 2409: GeneralNon4KHeapPageSize: 0x00004000
[ 39.070637] PVR_K: 2409: DriverMode: 0x00000001
[ 39.074016] PVR_K: 2409: FirmwarePerf: 0x00000000
[ 39.079796] PVR_K: 2409: FWContextSwitchProfile: 0x00000002
[ 39.085741] PVR_K: 2409: HWPerfDisableCustomCounterFilter: N
[ 39.091733] PVR_K: 2409: HWPerfFWBufSizeInKB: 0x00000800
[ 39.097693] PVR_K: 2409: HWPerfHostBufSizeInKB: 0x00000800
[ 39.103731] PVR_K: 2409: JonesDisableMask: 0x00000000
[ 39.109789] PVR_K: 2409: NewFilteringMode: Y
[ 39.113252] PVR_K: 2409: TruncateMode: 0x00000000
[ 39.119125] PVR_K: 2409: UseMETAT1: 0x00000000
[ 39.122396] PVR_K: 2409: EmuMaxFreq: 0x00000000
[ 39.128103] PVR_K: 2409: GPIOValidationMode: 0x00000000
[ 39.133985] PVR_K: 2409: RGXBVNC: (none)
[ 39.137190] PVR_K: 2409: FWContextSwitchCrossDM: 0x00000000
[ 39.142885] PVR_K: 2409: OSidRegion0Min: 0x00000000 0x04000000 0x10000000 0x18000000 0x20000000 0x28000000 0x30000000 0x38000000
[ 39.156955] PVR_K: 2409: OSidRegion0Max: 0x3FFFFFFF 0x0FFFFFFF 0x17FFFFFF 0x1FFFFFFF 0x27FFFFFF 0x2FFFFFFF 0x37FFFFFF 0x3FFFFFFF
[ 39.168637] PVR_K: 2409: OSidRegion1Min: 0x3F000000 0x3F000000 0x3F000000 0x3F000000 0x3F000000 0x3F000000 0x3F000000 0x3F000000
[ 39.180235] PVR_K: 2409: OSidRegion1Max: 0x3FFFFFFF 0x3FFFFFFF 0x3FFFFFFF 0x3FFFFFFF 0x3FFFFFFF 0x3FFFFFFF 0x3FFFFFFF 0x3FFFFFFF
[ 39.191799] PVR_K: 2409: HTBufferSizeInKB: 0x00000040
[ 39.197659] PVR_K: 2409: Debugfs Params
[ 39.200987] PVR_K: 2409: EnableHTBLogGroup: none
[ 39.206858] PVR_K: 2409: HTBOperationMode: dropoldest
[ 39.212902] PVR_K: 2409: EnableFTraceGPU: N
[ 39.216259] PVR_K: 2409: HWPerfFWFilter: 0x0000000000000000
[ 39.222140] PVR_K: 2409: HWPerfHostFilter: 0x00000000
[ 39.228020] PVR_K: 2409: HWPerfClientFilter_Services: 0x00000000
[ 39.233977] PVR_K: 2409: HWPerfClientFilter_EGL: 0x00000000
[ 39.239843] PVR_K: 2409: HWPerfClientFilter_OpenGLES: 0x00000000
[ 39.245747] PVR_K: 2409: HWPerfClientFilter_OpenCL: 0x00000000
[ 39.254271] PVR_K: 2409: HWPerfClientFilter_OpenRL: 0x00000000
[ 39.257740] PVR_K: 2409: HWPerfClientFilter_Vulkan: 0x00000000
[ 39.266223] PVR_K: 2409: CacheOpConfig: 0x0000000f
[ 39.269573] PVR_K: 2409: CacheOpGFThresholdSize: 0xffffffff
[ 39.275333] PVR_K: 2409: CacheOpUMKMThresholdSize: 0xfffffff0
[ 39.283761] PVR_K: 2409: TimeCorrClock: mono
[ 39.287216] PVR_K: 2409: Debugfs Params Device ID: 0
[ 39.293115] PVR_K: 2409: AssertOnHWRTrigger: N
[ 39.296482] PVR_K: 2409: AssertOutOfMemory: N
[ 39.302269] PVR_K: 2409: CheckMList: N
[ 39.305549] PVR_K: 2409: EnableHWR: Y
[ 39.311341] PVR_K:(Error): 2409: apphint_write: failed (10), index (55)
[ 39.317468] PVR_K: 2409: EnableLogGroup: Y
[ 39.320753] PVR_K:(Error): 2409: apphint_write: failed (10), index (56)
[ 39.329299] PVR_K: 2409: FirmwareLogType: Y
[ 39.332685] PVR_K: 2409: EnableAPM: 0x00000000
[ 39.338642] PVR_K: 2409: DisableFEDLogging: N
[ 39.342131] PVR_K: 2409: ZeroFreelist: N
[ 39.345297] PVR_K: 2409: DustRequestInject: N
[ 39.351060] PVR_K: 2409: DisablePDumpPanic: N
[ 39.356958] PVR_K: 2409: EnableFWPoisonOnFree: N
[ 39.360259] PVR_K: 2409: FWPoisonOnFreeValue: 0x000000bd
[ 39.365958] PVR_K: 2409: ------[ HTB Log state: Off ]------
[ 39.371659] PVR_K: 2409: ------------[ PVR DBG: END ]------------
[ 39.377477] ------------[ cut here ]------------
[ 39.383318] WARNING: CPU: 0 PID: 2409 at /home/project/rcarh3_linux_guest/graphic/1.0-r0_guest/rogue_km/binary_r8a7795_qnx_vz_release/target_aarch64/kbuild/services/server/common/pvr_notifier.c:507 PVRSRVDebugRequest+0x194/0x2b0 [pvrsrvkm]
[ 39.405845] Modules linked in: qnx_virtio_du(O) vsp2(O) vspm(O) pvrsrvkm(O) ipv6
[ 39.411899] CPU: 0 PID: 2409 Comm: weston Tainted: G O 4.14.75-ltsi-yocto-standard #1
[ 39.420442] Hardware name: Renesas Salvator-X boards based on r8a7795 (DT)
[ 39.428923] task: ffff8005f3798000 task.stack: ffff000009780000
[ 39.435190] PC is at PVRSRVDebugRequest+0x194/0x2b0 [pvrsrvkm]
[ 39.438770] LR is at PVRSRVDebugRequest+0x194/0x2b0 [pvrsrvkm]
[ 39.444463] pc : [<ffff000000bd1944>] lr : [<ffff000000bd1944>] pstate: 00000145
[ 39.452856] sp : ffff0000097839a0
[ 39.455962] x29: ffff0000097839a0 x28: 0000000000000000
[ 39.461846] x27: ffff8005f5f9de20 x26: 0000000000000002
[ 39.467789] x25: ffff8005f36bc700 x24: 0000000000000009
[ 39.471167] x23: 0000000000000000 x22: 0000000000000000
[ 39.476870] x21: 0000000000000003 x20: ffff8005f36bc7d8
[ 39.482675] x19: ffff8005f36bc7d8 x18: 0000000000000010
[ 39.488624] x17: 0000ffff8b26e4d0 x16: ffff000008220448
[ 39.491913] x15: ffffffffffffffff x14: ffff0000892ac857
[ 39.497600] x13: ffff0000092ac865 x12: ffff000009179df8
[ 39.503315] x11: ffff00000859f7c0 x10: ffff000009783610
[ 39.509106] x9 : 0000000000000016 x8 : 444e45203a474244
[ 39.515057] x7 : 20525650205b2d2d x6 : 0000000000000192
[ 39.518368] x5 : 0000000000000000 x4 : 0000000000000000
[ 39.524061] x3 : ffff8005f3798000 x2 : 0000000000000000
[ 39.529861] x1 : 0000000000000000 x0 : ffff8005f5d51680
[ 39.535721] Call trace:
[ 39.536177] Exception stack(0xffff000009783860 to 0xffff0000097839a0)
[ 39.544543] 3860: ffff8005f5d51680 0000000000000000 0000000000000000 ffff8005f3798000
[ 39.550524] 3880: 0000000000000000 0000000000000000 0000000000000192 20525650205b2d2d
[ 39.558886] 38a0: 444e45203a474244 0000000000000016 ffff000009783610 ffff00000859f7c0
[ 39.567355] 38c0: ffff000009179df8 ffff0000092ac865 ffff0000892ac857 ffffffffffffffff
[ 39.576005] 38e0: ffff000008220448 0000ffff8b26e4d0 0000000000000010 ffff8005f36bc7d8
[ 39.582048] 3900: ffff8005f36bc7d8 0000000000000003 0000000000000000 0000000000000000
[ 39.590517] 3920: 0000000000000009 ffff8005f36bc700 0000000000000002 ffff8005f5f9de20
[ 39.599159] 3940: 0000000000000000 ffff0000097839a0 ffff000000bd1944 ffff0000097839a0
[ 39.605210] 3960: ffff000000bd1944 0000000000000145 0000000000000000 0000000000000000
[ 39.613597] 3980: 0000ffffffffffff 0000000000000000 ffff0000097839a0 ffff000000bd1944
[ 39.622413] [<ffff000000bd1944>] PVRSRVDebugRequest+0x194/0x2b0 [pvrsrvkm]
[ 39.628561] [<ffff000000bd2e9c>] PVRSRVDeviceFinalise.part.2+0x484/0x530 [pvrsrvkm]
[ 39.637352] [<ffff000000bd50f8>] PVRSRVDeviceInitialise+0x218/0x2c8 [pvrsrvkm]
[ 39.643659] [<ffff000000bb1540>] PVRSRVCommonDeviceOpen+0x68/0xf8 [pvrsrvkm]
[ 39.649808] [<ffff000000c15fa8>] pvr_drm_open+0x38/0x90 [pvrsrvkm]
[ 39.655673] [<ffff0000085e1a84>] drm_open+0x1bc/0x3c0
[ 39.661397] [<ffff0000085e5f8c>] drm_stub_open+0xe4/0x110
[ 39.667265] [<ffff000008227bd4>] chrdev_open+0x8c/0x198
[ 39.673214] [<ffff00000821ea9c>] do_dentry_open+0x1bc/0x328
[ 39.676596] [<ffff00000821ff18>] vfs_open+0x50/0x88
[ 39.682300] [<ffff00000823278c>] path_openat+0x53c/0x1228
[ 39.688175] [<ffff0000082345c0>] do_filp_open+0x60/0xd8
[ 39.694150] [<ffff000008220380>] do_sys_open+0x170/0x210
[ 39.697521] [<ffff000008220458>] SyS_openat+0x10/0x18
[ 39.703222] Exception stack(0xffff000009783ec0 to 0xffff000009784000)
[ 39.709089] 3ec0: ffffffffffffff9c 0000ffffc6cd0740 0000000000000002 0000000000000000
[ 39.717633] 3ee0: 0000000040100401 0040555100000000 0000000000000064 00000000fffffffd
[ 39.726360] 3f00: 0000000000000038 0000000000000000 0000ffffc6cd0420 0000000000000020
[ 39.732520] 3f20: 0000000000000000 0000000000000000 0000000000000080 000000000000000a
[ 39.741076] 3f40: 0000ffff8abc6190 0000ffff8b26e4d0 0000ffffc6cd041d 0000ffffc6cd0740
[ 39.747035] 3f60: 0000ffffc6cd17cc 0000000014b6fba0 0000000000000020 0000000014b6fba8
[ 39.755320] 3f80: 0000000014b6fb90 0000000000000020 0000000014b6b260 0000000000000000
[ 39.763803] 3fa0: 0000000014b62350 0000ffffc6cd0650 0000ffff8a9c1490 0000ffffc6cd0650
[ 39.772338] 3fc0: 0000ffff8b26e51c 0000000080000000 ffffffffffffff9c 0000000000000038
[ 39.778299] 3fe0: 0000000000000000 0000000000000000 0000000000000000 0000000000000000
[ 39.786696] [<ffff000008083b18>] __sys_trace_return+0x0/0x4
[ 39.792411] ---[ end trace 5d269e51cee24c95 ]---
[ 39.798470] PVR_K:(Error): 2409: PVRSRVDeviceInitialise: Services failed to finalise the device (PVRSRV_ERROR_TIMEOUT)
[ 39.807473] PVR_K:(Error): 2409: PVRSRVCommonDeviceOpen: Failed to initialise device (PVRSRV_ERROR_TIMEOUT)
[ 39.819202] PVR_K:(Error): 2409: PVRSRVCommonDeviceOpen: Driver already in bad state. Device open failed.
[07:49:13.793] failed to initialize display
[07:49:13.794] EGL error state: EGL_NOT_INITIALIZED (0x3001)
[07:49:13.794] failed to initialize egl
[07:49:13.795] fatal: failed to create compositor backend

In linux guest mode, passthrough GPU, It seems it 's the firmware compatability problem, I have no idea about this, someone knows ?