[PATCH 1/1] dix: Hold the input_lock() when accessing the miEventQueue through checkForInput

Keith Packard keithp at keithp.com
Mon Sep 19 15:30:15 UTC 2016


Jeremy Huddleston Sequoia <jeremyhu at apple.com> writes:

> ==================
> WARNING: ThreadSanitizer: data race (pid=4943)
>   Read of size 4 at 0x00010c4e3854 by thread T8:
>     #0 WaitForSomething WaitFor.c:237 (X11.bin+0x00010049216c)
>     #1 Dispatch dispatch.c:413 (X11.bin+0x000100352ed9)
>     #2 dix_main main.c:287 (X11.bin+0x00010036e894)
>     #3 server_thread quartzStartup.c:66 (X11.bin+0x000100039e63)
>
>   Previous write of size 4 at 0x00010c4e3854 by thread T12 (mutexes: write M856, write M1976):
>     #0 mieqEnqueue mieq.c:263 (X11.bin+0x000100448d14)
>     #1 DarwinSendDDXEvent darwinEvents.c:641 (X11.bin+0x000100033613)
>     #2 DarwinProcessFDAdditionQueue_thread darwinEvents.c:338 (X11.bin+0x000100032039)

I'm not sure I want to resolve this "bug" -- the event queue has been
designed to be safe in a lockless threaded environment as it was originally
designed to directly map a kernel address which would be modified at
interrupt time. Is there an actual issue with the design?

-- 
-keith
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 800 bytes
Desc: not available
URL: <https://lists.x.org/archives/xorg-devel/attachments/20160919/7cababc2/attachment.sig>


More information about the xorg-devel mailing list