Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
W
weston
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 273
    • Issues 273
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 120
    • Merge Requests 120
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • wayland
  • weston
  • Issues
  • #137

Closed
Open
Opened Aug 29, 2018 by Marius Vlad@marius.vlad0Reporter

libc abort when compositor re-gains connector after a hot-plug. malloc(): smallbin double linked list corrupted

Weston has only one output. Start a simple application like weston-simple-egl. Disconnected the connector. Weston will disable that output, then plug in back the connector. weston-simple-egl will not resume rendering being stuck

[4014018.805] wl_registry@3.global_remove(14)
[4014018.830] wl_registry@3.global(22, "wl_output", 3)
[4014018.948] wl_registry@2.global_remove(14)
[4014018.979] wl_registry@2.global(22, "wl_output", 3)
20 frames in 5 seconds: 4.000000 fps
[4014019.432]  -> wl_surface@9.set_opaque_region(nil)
[4014142.213] wl_display@1.delete_id(17)
[4014142.295] wl_callback@17.done(84567509)
[4014142.341]  -> wl_surface@9.frame(new id wl_callback@17)
[4014142.386]  -> wl_viv@10.enable_tile_status(wl_buffer@13, 1, 0, 1, 2147483648, 2147483648)
[4014142.500]  -> wl_surface@9.attach(wl_buffer@13, 0, 0)
[4014142.558]  -> wl_surface@9.damage(61, 62, 127, 127)
[4014142.612]  -> wl_surface@9.commit()
[4014142.644] wl_buffer@18.release()
[4014143.012]  -> wl_surface@9.set_opaque_region(nil)
[4014161.056] wl_display@1.delete_id(17)
[4014161.138] wl_callback@17.done(84567589)
[4014161.184]  -> wl_surface@9.frame(new id wl_callback@17)
[4014161.230]  -> wl_viv@10.enable_tile_status(wl_buffer@18, 1, 0, 1, 2147483648, 2147483648)
[4014161.330]  -> wl_surface@9.attach(wl_buffer@18, 0, 0)
[4014161.386]  -> wl_surface@9.damage(61, 62, 127, 127)
[4014161.449]  -> wl_surface@9.commit()
[4014161.485] wl_buffer@19.release()
[4014161.802]  -> wl_surface@9.set_opaque_region(nil)

Forcibly closing weston-simple-egl gives: malloc(): smallbin double linked list corrupted. This seems to originate in libdrm in drmModeAtomicCommit(). Hopefully other can replicate this as I don't have a cross-compiled Valgrind.

__GI_raise (sig=sig@entry=6)
    at /usr/src/debug/glibc/2.27-r0/git/sysdeps/unix/sysv/linux/raise.c:51
#1  0x0000ffffb62df1d0 in __GI_abort () at /usr/src/debug/glibc/2.27-r0/git/stdlib/abort.c:79
#2  0x0000ffffb63177b0 in __libc_message (action=action@entry=do_abort, 
    fmt=fmt@entry=0xffffb63d4d10 "%s\n")
    at /usr/src/debug/glibc/2.27-r0/git/sysdeps/posix/libc_fatal.c:181
#3  0x0000ffffb631da9c in malloc_printerr (
    str=str@entry=0xffffb63d0d90 "malloc(): smallbin double linked list corrupted")
    at /usr/src/debug/glibc/2.27-r0/git/malloc/malloc.c:5350
#4  0x0000ffffb6320f10 in _int_malloc (av=av@entry=0xffffb63faa70 <main_arena>, 
    bytes=bytes@entry=52) at /usr/src/debug/glibc/2.27-r0/git/malloc/malloc.c:3648
#5  0x0000ffffb6323050 in __libc_calloc (n=<optimized out>, elem_size=<optimized out>)
    at /usr/src/debug/glibc/2.27-r0/git/malloc/malloc.c:3436
#6  0x0000ffffb5f4b490 in drmModeAtomicCommit () from /usr/lib/libdrm.so.2
#7  0x0000ffffb6056fa0 in drm_pending_state_apply_atomic (pending_state=0x3f132280, 
    mode=DRM_STATE_APPLY_ASYNC) at libweston/compositor-drm.c:2694
#8  0x0000ffffb6057110 in drm_pending_state_apply (pending_state=0x3f132280)
    at libweston/compositor-drm.c:2773
#9  0x0000ffffb6057b08 in drm_repaint_flush (compositor=0x3ed47830, repaint_data=0x3f132280)
    at libweston/compositor-drm.c:3076
#10 0x0000ffffb649e794 in output_repaint_timer_handler (data=0x3ed47830)
    at libweston/compositor.c:2551
#11 0x0000ffffb64597e4 in ?? () from /usr/lib/libwayland-server.so.0
#12 0x00000000ffffffff in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

PS: Not sure if there are two issues here: that the application doesn't resume rendering and the fact that it crashes this way when trying to close it forcibly.

Edited Aug 29, 2018 by Marius Vlad
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: wayland/weston#137