Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(202)

Issue 2494483003: Mojo Bindings: Fix lock-order inversion in associated controllers (Closed)

Created:
4 years, 1 month ago by Ken Rockot(use gerrit already)
Modified:
4 years, 1 month ago
Reviewers:
yzshen1
CC:
Aaron Boodman, abarth-chromium, chromium-reviews, darin (slow to review), darin-cc_chromium.org, jam, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Mojo Bindings: Fix lock-order inversion in associated controllers The two AssociatedGroupController implementations we have both own a lock which is acquired during message dispatch, among other operations. In the EDK layer a Watcher lock is also acquired further up the stack. Because sending a message may indirectly require notifying the same Watcher lock, it must never be true that the AssociatedGroupController's lock is held while its pipe is written to. This fixes the lock-order inversion resulting from the fact that pipe control messages were being sent under lock, and removes the associated TSAN suppression. BUG=663557 TBR=glider@chromium.org R=yzshen@chromium.org Committed: https://crrev.com/58909542197b704efe10526c169e4b502f799b57 Cr-Commit-Position: refs/heads/master@{#431331}

Patch Set 1 #

Patch Set 2 : . #

Total comments: 2

Patch Set 3 : . #

Patch Set 4 : . #

Unified diffs Side-by-side diffs Delta from patch set Stats (+28 lines, -12 lines) Patch
M build/sanitizers/tsan_suppressions.cc View 1 2 1 chunk +0 lines, -3 lines 0 comments Download
M ipc/ipc_mojo_bootstrap.cc View 1 4 chunks +12 lines, -4 lines 0 comments Download
M mojo/public/cpp/bindings/lib/multiplex_router.h View 1 chunk +2 lines, -0 lines 0 comments Download
M mojo/public/cpp/bindings/lib/multiplex_router.cc View 1 4 chunks +6 lines, -1 line 0 comments Download
M mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc View 1 2 2 chunks +4 lines, -2 lines 0 comments Download
M mojo/public/cpp/bindings/pipe_control_message_proxy.h View 1 2 3 2 chunks +4 lines, -2 lines 0 comments Download

Messages

Total messages: 21 (15 generated)
Ken Rockot(use gerrit already)
PTAL. Thanks!
4 years, 1 month ago (2016-11-10 00:51:51 UTC) #4
yzshen1
LGTM with one comment https://codereview.chromium.org/2494483003/diff/20001/ipc/ipc_mojo_bootstrap.cc File ipc/ipc_mojo_bootstrap.cc (right): https://codereview.chromium.org/2494483003/diff/20001/ipc/ipc_mojo_bootstrap.cc#newcode174 ipc/ipc_mojo_bootstrap.cc:174: control_message_proxy_.NotifyEndpointClosedBeforeSent(id); PipeControlMessageProxy has a |context_| ...
4 years, 1 month ago (2016-11-10 18:02:34 UTC) #8
Ken Rockot(use gerrit already)
https://codereview.chromium.org/2494483003/diff/20001/ipc/ipc_mojo_bootstrap.cc File ipc/ipc_mojo_bootstrap.cc (right): https://codereview.chromium.org/2494483003/diff/20001/ipc/ipc_mojo_bootstrap.cc#newcode174 ipc/ipc_mojo_bootstrap.cc:174: control_message_proxy_.NotifyEndpointClosedBeforeSent(id); On 2016/11/10 at 18:02:34, yzshen1 wrote: > PipeControlMessageProxy ...
4 years, 1 month ago (2016-11-10 18:26:44 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2494483003/60001
4 years, 1 month ago (2016-11-10 18:28:00 UTC) #18
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 1 month ago (2016-11-10 20:06:14 UTC) #19
commit-bot: I haz the power
4 years, 1 month ago (2016-11-10 20:14:25 UTC) #21
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/58909542197b704efe10526c169e4b502f799b57
Cr-Commit-Position: refs/heads/master@{#431331}

Powered by Google App Engine
This is Rietveld 408576698