diff options
| author | Linux Build Service Account <lnxbuild@localhost> | 2019-12-06 12:51:54 -0800 |
|---|---|---|
| committer | Linux Build Service Account <lnxbuild@localhost> | 2019-12-06 12:51:54 -0800 |
| commit | 33dc678e7692f04ecc1eeddeb1cca8a809bc1727 (patch) | |
| tree | 7ac214cbb1f5256e0738cd6423f01e364b942bd4 /lib | |
| parent | feb565e67fc2b2f2a95890577120141be5886594 (diff) | |
| parent | 72078891843ce0d5b8e95040d09ba92913916af9 (diff) | |
Merge 72078891843ce0d5b8e95040d09ba92913916af9 on remote branch
Change-Id: I219a5f0e8bd6ee3be3ba0d49230dde908d35dc25
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/dump_stack.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/dump_stack.c b/lib/dump_stack.c index c30d07e99dba..72de6444934d 100644 --- a/lib/dump_stack.c +++ b/lib/dump_stack.c @@ -44,7 +44,12 @@ retry: was_locked = 1; } else { local_irq_restore(flags); - cpu_relax(); + /* + * Wait for the lock to release before jumping to + * atomic_cmpxchg() in order to mitigate the thundering herd + * problem. + */ + do { cpu_relax(); } while (atomic_read(&dump_lock) != -1); goto retry; } |
