gvisor/pkg
Nicolas Lacasse d321f575e2 Fix lock order violation.
overlayFileOperations.Readdir was holding overlay.copyMu while calling
DirentReaddir, which then attempts to take take the corresponding Dirent.mu,
causing a lock order violation. (See lock order documentation in
fs/copy_up.go.)

We only actually need to hold copyMu during readdirEntries(), so holding the
lock is moved in there, thus avoiding the lock order violation.

A new lock was added to protect overlayFileOperations.dirCache. We were
inadvertently relying on copyMu to protect this.  There is no reason it should
not have its own lock.

PiperOrigin-RevId: 228542473
Change-Id: I03c3a368c8cbc0b5a79d50cc486fc94adaddc1c2
2019-01-09 10:29:36 -08:00
..
abi Rename linux.Errno.Error to linux.Errno.String. 2019-01-03 13:53:43 -08:00
amutex Mark amutex_test as flaky. 2018-10-31 19:33:09 -07:00
atomicbitops Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
binary Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
bits Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
bpf Use correct company name in copyright header 2018-10-19 16:35:11 -07:00
compressio Internal Change 2018-12-21 14:29:35 -08:00
control Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
cpuid Clean up cpuid_parse_test 2018-10-30 15:56:12 -07:00
dhcp Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
eventchannel Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
fd Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
fdnotifier Move fdnotifier package to reduce internal confusion. 2018-12-14 18:05:01 -08:00
gate Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
ilist Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
linewriter Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
log Add new log format that is compatible with Kubernetes 2018-11-01 17:44:58 -07:00
metric Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
p9 Use correct company name in copyright header 2018-11-05 17:23:56 -08:00
rand Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
refs Use correct company name in copyright header 2018-10-19 16:35:11 -07:00
seccomp Add BPFAction type with Stringer 2018-12-18 10:28:28 -08:00
secio Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
segment Use correct company name in copyright header 2018-10-19 16:35:11 -07:00
sentry Fix lock order violation. 2019-01-09 10:29:36 -08:00
sleep Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
state Internal Change 2018-12-21 14:29:35 -08:00
sync Reference upstream licenses 2018-11-20 14:05:16 -08:00
syserr Allow creating syserr.Errors at runtime. 2019-01-03 15:10:31 -08:00
syserror Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
tcpip Implement Stringer for tcpip.StatCounter 2019-01-08 12:35:35 -08:00
tmutex Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
unet Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
urpc Track paths and provide a rename hook. 2018-10-23 00:20:15 -07:00
waiter Move fdnotifier package to reduce internal confusion. 2018-12-14 18:05:01 -08:00