summaryrefslogtreecommitdiffhomepage
path: root/pkg
AgeCommit message (Collapse)Author
2020-11-18Merge release-20201109.0-69-g9d148627f (automated)gVisor bot
2020-11-18Introduce stack.WritePacketToRemote, remove LinkEndpoint.WriteRawPacketBruno Dal Bo
Redefine stack.WritePacket into stack.WritePacketToRemote which lets the NIC decide whether to append link headers. PiperOrigin-RevId: 343071742
2020-11-17Remove sniffer from gonet_test.Bhasker Hariharan
This was added by mistake in cl/342868552. PiperOrigin-RevId: 343021431
2020-11-18Merge release-20201109.0-67-g0e32d98f3 (automated)gVisor bot
2020-11-17Fix endpoint.Read() when endpoint is in StateError.Bhasker Hariharan
If the endpoint is in StateError but e.hardErrorLocked() returns nil then return ErrClosedForRecieve. This can happen if a concurrent write on the same endpoint was in progress when the endpoint transitioned to an error state. PiperOrigin-RevId: 343018257
2020-11-18Merge release-20201109.0-66-gee6dd8cb9 (automated)gVisor bot
2020-11-17Merge pull request #4840 from lubinszARM:pr_fpsimd_1gVisor bot
PiperOrigin-RevId: 343000335
2020-11-18Merge release-20201109.0-64-g05223889b (automated)gVisor bot
2020-11-17fs/fuse: don't dereference fuse.DeviceFD.fs if it is nilAndrei Vagin
PiperOrigin-RevId: 342992936
2020-11-17Merge release-20201109.0-63-g949742be8 (automated)gVisor bot
2020-11-17Allow short writes from gofers.Nicolas Lacasse
They were returning io.ErrShortWrite, but that is not handled at higher levels and resulted in a panic. We can just return the short write directly from the p9 call without ErrShortWrite. PiperOrigin-RevId: 342960441
2020-11-17Merge release-20201109.0-62-g10ba578c0 (automated)gVisor bot
2020-11-17Merge release-20201109.0-61-ge2d9a68ee (automated)gVisor bot
2020-11-17tmpfs: make sure that a dentry will not be destroyed before the open() callAndrei Vagin
If we don't hold a reference, the dentry can be destroyed by another thread. Reported-by: syzbot+f2132e50060c41f6d41f@syzkaller.appspotmail.com PiperOrigin-RevId: 342951940
2020-11-17Add support for TTY in multi-containerFabricio Voznika
Fixes #2714 PiperOrigin-RevId: 342950412
2020-11-17Merge release-20201109.0-60-g7492ed6bd (automated)gVisor bot
2020-11-17Add per-sniffer instance log prefixBruno Dal Bo
A prefix associated with a sniffer instance can help debug situations where more than one NIC (i.e. more than one sniffer) exists. PiperOrigin-RevId: 342950027
2020-11-17Add consistent precondition formatting for verityChong Cai
Also add the lock order for verity fs, and add a lock to protect dentry hash. PiperOrigin-RevId: 342946537
2020-11-17Merge release-20201109.0-58-gc1e1e7a9a (automated)gVisor bot
2020-11-17Merge pull request #4836 from lubinszARM:pr_exception_el0_el1gVisor bot
PiperOrigin-RevId: 342943430
2020-11-17Merge release-20201109.0-56-g05d2a26f7 (automated)gVisor bot
2020-11-17Fix possible deadlock in UDP.Write().Bhasker Hariharan
In UDP endpoint.Write() sendUDP is called with e.mu Rlocked. But if this happens to send a datagram over loopback which ends up generating an ICMP response of say ErrNoPortReachable, the handling of the response in HandleControlPacket also acquires e.mu using RLock. This is mostly fine unless there is a competing caller trying to acquire e.mu in exclusive mode using Lock(). This will deadlock as a caller waiting in Lock() disallows an new RLocks() to ensure it can actually acquire the Lock. This is documented here https://golang.org/pkg/sync/#RWMutex. This change releases the endpoint mutex before calling sendUDP to resolve the possibility of the deadlock. Reported-by: syzbot+537989797548c66e8ee3@syzkaller.appspotmail.com Reported-by: syzbot+eb0b73b4ab486f7673ba@syzkaller.appspotmail.com PiperOrigin-RevId: 342894148
2020-11-17Merge release-20201109.0-55-gfb9a649f3 (automated)gVisor bot
2020-11-17Fix SO_ERROR behavior for TCP in gVisor.Bhasker Hariharan
Fixes the behaviour of SO_ERROR for tcp sockets where in linux it returns sk->sk_err and if sk->sk_err is 0 then it returns sk->sk_soft_err. In gVisor TCP we endpoint.HardError is the equivalent of sk->sk_err and endpoint.LastError holds soft errors. This change brings this into alignment with Linux such that both hard/soft errors are cleared when retrieved using getsockopt(.. SO_ERROR) is called on a socket. Fixes #3812 PiperOrigin-RevId: 342868552
2020-11-17arm64 kvm: optimize all fpsimd related codeRobin Luk
Optimize and bug fix all fpsimd related code. Signed-off-by: Robin Luk <lubin.lu@antgroup.com>
2020-11-17arm64 kvm: add the processing functions for all el0/el1 exceptionsRobin Luk
I added 2 unified processing functions for all exceptions of el/el0 Signed-off-by: Robin Luk <lubin.lu@antgroup.com>
2020-11-17Merge release-20201109.0-54-g938aabeec (automated)gVisor bot
2020-11-16Minor flipcall refactoring.Jamie Liu
PiperOrigin-RevId: 342768550
2020-11-17Merge release-20201109.0-53-g267560d15 (automated)gVisor bot
2020-11-16Reset watchdog timer between sendfile() iterations.Jamie Liu
As part of this, change Task.interrupted() to not drain Task.interruptChan, and do so explicitly using new function Task.unsetInterrupted() instead. PiperOrigin-RevId: 342768365
2020-11-17Merge release-20201109.0-52-gd48610795 (automated)gVisor bot
2020-11-16Allow RLIMIT_RSS to be setFabricio Voznika
Closes #4746 PiperOrigin-RevId: 342747165
2020-11-16Merge release-20201109.0-51-gcc5cfce4c (automated)gVisor bot
2020-11-16Remove ARP address workaroundGhanan Gowripalan
- Make AddressableEndpoint optional for NetworkEndpoint. Not all NetworkEndpoints need to support addressing (e.g. ARP), so AddressableEndpoint should only be implemented for protocols that support addressing such as IPv4 and IPv6. With this change, tcpip.ErrNotSupported will be returned by the stack when attempting to modify addresses on a network endpoint that does not support addressing. Now that packets are fully handled at the network layer, and (with this change) addresses are optional for network endpoints, we no longer need the workaround for ARP where a fake ARP address was added to each NIC that performs ARP so that packets would be delivered to the ARP layer. PiperOrigin-RevId: 342722547
2020-11-16Merge release-20201109.0-49-g758e45618 (automated)gVisor bot
2020-11-16Clean up fragmentation.ProcessToshi Kikuchi
- Pass a PacketBuffer directly instead of releaseCB - No longer pass a VectorisedView, which is included in the PacketBuffer - Make it an error if data size is not equal to (last - first + 1) - Set the callback for the reassembly timeout on NewFragmentation PiperOrigin-RevId: 342702432
2020-11-16Merge release-20201109.0-48-ga73877ac9 (automated)gVisor bot
2020-11-16Automated rollback of changelist 342312166Bhasker Hariharan
PiperOrigin-RevId: 342700744
2020-11-16Merge release-20201109.0-47-g840a133c6 (automated)gVisor bot
2020-11-16Automated rollback of changelist 340274194Dean Deng
PiperOrigin-RevId: 342669574
2020-11-14Merge release-20201030.0-96-g182c12601 (automated)gVisor bot
2020-11-13Log task goroutine IDs in the sentry watchdog.Jamie Liu
PiperOrigin-RevId: 342373580
2020-11-14Merge release-20201030.0-95-g0fee59c8c (automated)gVisor bot
2020-11-13Requested Comment/Message wording changesJulian Elischer
PiperOrigin-RevId: 342366891
2020-11-13Merge release-20201030.0-94-ga1cb52447 (automated)gVisor bot
2020-11-13Check for misuse of kernel.Task as context.Context.Jamie Liu
Checks in Task.block() and Task.Value() are conditional on race detection being enabled, since these functions are relatively hot. Checks in Task.SleepStart() and Task.UninterruptibleSleepStart() are enabled unconditionally, since these functions are not thought to lie on any critical paths, and misuse of these functions is required for b/168241471 to manifest. PiperOrigin-RevId: 342342175
2020-11-13Merge release-20201030.0-93-g89517eca4 (automated)gVisor bot
2020-11-13Have fuse.DeviceFD hold reference on fuse.filesystem.Jamie Liu
This is actually just b/168751672 again; cl/332394146 was incorrectly reverted by cl/341411151. Document the reference holder to reduce the likelihood that this happens again. Also document a few other bugs observed in the process. PiperOrigin-RevId: 342339144
2020-11-13Merge release-20201030.0-92-g839dd9700 (automated)gVisor bot
2020-11-13RACK: Detect DSACKNayana Bidari
Detect if the ACK is a duplicate and update in RACK. PiperOrigin-RevId: 342332569