FreeBSDDesktop / kms-drm

the DRM part of the linuxkpi-based KMS
63 stars 26 forks source link

Crash on kmscube exit, sometimes #66

Closed johalun closed 6 years ago

johalun commented 6 years ago
[drm:cik_sdma_process_trap_irq] panic: Assertion (state & ~TASK_NORMAL) == 0 failed at /usr/src/sys/compat/linuxkpi/common/src/linux_schedule.c:50
cpuid = 2
time = 1526715721
KDB: stack backtrace:
db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe004532d190
vpanic() at vpanic+0x1a3/frame 0xfffffe004532d1f0
doadump() at doadump/frame 0xfffffe004532d270
linux_add_to_sleepqueue() at linux_add_to_sleepqueue+0x1ca/frame 0xfffffe004532d2c0
linux_wait_event_common() at linux_wait_event_common+0x149/frame 0xfffffe004532d310
amd_sched_entity_fini() at amd_sched_entity_fini+0x108/frame 0xfffffe004532d3a0
amdgpu_vm_fini() at amdgpu_vm_fini+0xda/frame 0xfffffe004532d420
amdgpu_driver_postclose_kms() at amdgpu_driver_postclose_kms+0x1f2/frame 0xfffffe004532d470
drm_release() at drm_release+0x2e1/frame 0xfffffe004532d4c0
linux_file_close() at linux_file_close+0x165/frame 0xfffffe004532d510
_fdrop() at _fdrop+0x1a/frame 0xfffffe004532d530
linux_cdev_handle_free() at linux_cdev_handle_free+0x72/frame 0xfffffe004532d560
dev_pager_dealloc() at dev_pager_dealloc+0x33/frame 0xfffffe004532d580
vm_object_terminate() at vm_object_terminate+0x2b3/frame 0xfffffe004532d5d0
vm_object_deallocate() at vm_object_deallocate+0x45c/frame 0xfffffe004532d630
vm_map_process_deferred() at vm_map_process_deferred+0x99/frame 0xfffffe004532d660
vm_map_remove() at vm_map_remove+0xc6/frame 0xfffffe004532d690
vmspace_exit() at vmspace_exit+0xc9/frame 0xfffffe004532d6d0
exit1() at exit1+0x5ad/frame 0xfffffe004532d740
sigexit() at sigexit+0xae8/frame 0xfffffe004532d920
postsig() at postsig+0x154/frame 0xfffffe004532d9f0
ast() at ast+0x2a7/frame 0xfffffe004532da30
doreti_ast() at doreti_ast+0x1f/frame 0x7fffffffe940
Uptime: 28m4s
Dumping 405 out of 7086 MB:..4%..12%..24%..32%..44%..52%..64%..72%..83%..91%
johalun commented 6 years ago

@hselasky would you mind take a look?

hselasky commented 6 years ago

Adding @markjdb to also look at this issue.

hselasky commented 6 years ago

@johalun : What version of code is this? Is this the code with the added state-bits needed for 4.15?

johalun commented 6 years ago

Yes, with 4.15 branch in freebsd-base-graphics

On Sat, May 19, 2018 at 11:30 HPS notifications@github.com wrote:

@johalun https://github.com/johalun : What version of code is this? Is this the code with the added state-bits needed for 4.15?

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/FreeBSDDesktop/kms-drm/issues/66#issuecomment-390395776, or mute the thread https://github.com/notifications/unsubscribe-auth/AGCqzNZR7Hoio7SdcTMnG_BVEoPJoDAgks5tz_QogaJpZM4UFngq .

johalun commented 6 years ago

It might be super simple to fix. We need to handle task-killable case I think.

On Sat, May 19, 2018 at 11:30 HPS notifications@github.com wrote:

@johalun https://github.com/johalun : What version of code is this? Is this the code with the added state-bits needed for 4.15?

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/FreeBSDDesktop/kms-drm/issues/66#issuecomment-390395776, or mute the thread https://github.com/notifications/unsubscribe-auth/AGCqzNZR7Hoio7SdcTMnG_BVEoPJoDAgks5tz_QogaJpZM4UFngq .

johalun commented 6 years ago

Assert panic is fixed although the case of TASK_KILLABLE might require additional handling in linux_schedule.c.