19.12.2015 11:15, Michael Tokarev wrote: >> commit ebac1202c95a4f1b76b6ef3f0f63926fa76e753e >> Author: Paolo Bonzini <pbonz...@redhat.com> >> Date: Fri Nov 27 12:43:06 2015 +0100 >> virtio-9p: use QEMU thread pool > > Program received signal SIGSEGV, Segmentation fault. > thread_pool_submit_aio (pool=0x0, func=0x55555580f6a0 <coroutine_enter_func>, > arg=0x555557698870, cb=<optimized out>, > opaque=<optimized out>) at /build/kvm/git/thread-pool.c:246 > 246 QLIST_INSERT_HEAD(&pool->head, req, all); > (gdb) bt > #0 thread_pool_submit_aio (pool=0x0, func=0x55555580f6a0 > <coroutine_enter_func>, arg=0x555557698870, cb=<optimized out>, > opaque=<optimized out>) at /build/kvm/git/thread-pool.c:246 > #1 0x000055555592c9ed in aio_bh_call (bh=<optimized out>) at > /build/kvm/git/async.c:64 > #2 aio_bh_poll (ctx=ctx@entry=0x5555563c9360) at /build/kvm/git/async.c:92 > #3 0x0000555555939390 in aio_dispatch (ctx=0x5555563c9360) at > /build/kvm/git/aio-posix.c:305 > #4 0x000055555592c7de in aio_ctx_dispatch (source=<optimized out>, > callback=<optimized out>, user_data=<optimized out>) > at /build/kvm/git/async.c:231 > #5 0x00007ffff49d1c5d in g_main_context_dispatch () from > /lib/x86_64-linux-gnu/libglib-2.0.so.0 > #6 0x0000555555937cf8 in glib_pollfds_poll () at > /build/kvm/git/main-loop.c:211 > #7 os_host_main_loop_wait (timeout=<optimized out>) at > /build/kvm/git/main-loop.c:256 > #8 main_loop_wait (nonblocking=<optimized out>) at > /build/kvm/git/main-loop.c:504 > #9 0x00005555556dbe3e in main_loop () at /build/kvm/git/vl.c:1923 > #10 main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) > at /build/kvm/git/vl.c:4684 > (gdb) p pool > $2 = (ThreadPool *) 0x0
In 9pfs/virtio-9p-coth.c:co_run_in_worker_bh(), in this context: void co_run_in_worker_bh(void *opaque) { Coroutine *co = opaque; thread_pool_submit_aio(qemu_get_aio_context()->thread_pool, coroutine_enter_func, co, coroutine_enter_cb, co); } qemu_get_aio_context()->thread_pool is NULL. Thanks, /mjt