371 Commits
Author SHA1 Message Date
Jamie LiuandgVisor bot 5ef032d4df Implement faccessat2.
PiperOrigin-RevId: 425432076
2022-01-31 12:25:27 -08:00
Yaroslav Litvinov b7ccfa5084 Fixes #7086,#6964,#3413,#7001.
Also adds fuse fsync, rename, flock support.
2022-01-27 13:07:42 +02:00
Ghanan GowripalanandgVisor bot beaecd1e3c Support SOL_ICMPV6 -> ICMPV6_FILTER
PiperOrigin-RevId: 417696519
2021-12-21 15:04:13 -08:00
Bhasker HariharanandgVisor bot fe88fe6768 Support custom socket options in hostinet.
PiperOrigin-RevId: 416625574
2021-12-15 12:51:54 -08:00
Ayush RanjanandgVisor bot 0fd9b69d5c Add Checked methods to go_marshal.
This is as per proposal in #6450. I have gated this behind a tag because this
is a very sparsely used feature and otherwise will leads to a lot of unused
generated code.

Secondly, we can not generate the CheckUnmarshal method for dynamic types. So
the dynamic tag would now require its users to additionally implement
CheckUnmarshal method which is more cumbersome.

Fixes #6450

PiperOrigin-RevId: 411197734
2021-11-19 20:16:54 -08:00
Rahat MahmoodandgVisor bot 0417b99c16 Replace StubMarshallable with go_marshal's marshal dynamic generator.
FUSE introduced StubMarshallable to avoid boilerplate around types
that were either marshalled in one direction, or were dynamically
sized. The marshal dynamic generator can deal with these cases with a
small bit of stubbing per type.

This also allows FUSE types to be treated as full marshal.Marshallable
types, addressing gVisor.dev/issue/3698.

Closes #3698.

PiperOrigin-RevId: 410335216
2021-11-16 13:31:29 -08:00
Rahat MahmoodandgVisor bot 8650614c32 Shift buffer correctly when unmarshalling FUSE dirents.
PiperOrigin-RevId: 409547679
2021-11-12 17:38:54 -08:00
Ayush RanjanandgVisor bot ce4f4283ba Make {Un}Marshal{Bytes/Unsafe} return remaining buffer.
Change marshal.Marshallable method signatures to return the remaining buffer.
This makes it easier to implement these method manually. Without this, we would
have to manually do buffer shifting which is error prone.

tools/go_marshal/test:benchmark test does not show change in performance.
Additionally fixed some marshalling bugs in fsimpl/fuse.

Updated multiple callpoints to get rid of redundant slice indexing work and
simplified code using this new signature.

Updates #6450

PiperOrigin-RevId: 407857019
2021-11-05 10:43:49 -07:00
Chong CaiandgVisor bot 8b2e8caad4 Move attestation definitions to standalone package
PiperOrigin-RevId: 405698863
2021-10-26 11:51:06 -07:00
gVisor bot 14f4113924 Merge pull request #6345 from sudo-sturbia:mq/syscalls
PiperOrigin-RevId: 404901660
2021-10-21 16:05:53 -07:00
Chong CaiandgVisor bot 6f4fcc4bac Add a size parameter
PiperOrigin-RevId: 403214414
2021-10-14 16:27:07 -07:00
Ayush RanjanandgVisor bot 6fccc18560 [lisa] Implement lisafs protocol methods in VFS2 gofer client and fsgofer.
Introduces RPC methods in lisafs. Makes that gofer client use lisafs RPCs
instead of p9 when lisafs is enabled.

Implements the handlers for those methods in fsgofer.

Fixes #5465

PiperOrigin-RevId: 398080310
2021-09-21 14:09:18 -07:00
Ghanan GowripalanandgVisor bot 89a0011c10 Support IPV6_RECVPKTINFO on UDP sockets
PiperOrigin-RevId: 397631833
2021-09-19 13:15:28 -07:00
Zyad A. Ali 4fdfb178e7 Add abi definitions for POSIX message queues.
Updates #136
2021-09-15 21:56:35 +02:00
Zyad A. Ali 61cbf77873 Implement mqfs.rootInode.
rootInode represents the root inode for mqueue filesystem (/dev/mqueue).

Updates #136
2021-09-15 21:56:35 +02:00
Chong CaiandgVisor bot 5032f4f57d Add ioctl stub constants
PiperOrigin-RevId: 394331928
2021-09-01 15:51:10 -07:00
gVisor bot b495ae599a Merge pull request #6262 from sudo-sturbia:msgqueue/syscalls3
PiperOrigin-RevId: 391416650
2021-08-17 17:44:26 -07:00
Zyad A. Ali 265deee8cb Implement control operations on msgqueue.
For IPCInfo, update value of MSGSEG constant in abi to avoid overflow in
MsgInfo.MsgSeg. MSGSEG was originaly simplified in abi, and is unused
(by us and within the kernel), so updating it is okay.

Updates #135
2021-08-17 20:31:38 +02:00
Zach KoopmansandgVisor bot ce58d71fd5 [syserror] Remove pkg syserror.
Removes package syserror and moves still relevant code to either linuxerr
or to syserr (to be later removed).

Internal errors are converted from random types to *errors.Error types used
in linuxerr. Internal errors are in linuxerr/internal.go.

PiperOrigin-RevId: 390724202
2021-08-13 17:16:52 -07:00
Zach KoopmansandgVisor bot 02370bbd31 [syserror] Convert remaining syserror definitions to linuxerr.
Convert remaining public errors (e.g. EINTR) from syserror to linuxerr.

PiperOrigin-RevId: 390471763
2021-08-12 15:19:12 -07:00
gVisor bot 8daeda2072 Merge pull request #6108 from sudo-sturbia:msgqueue/syscalls
PiperOrigin-RevId: 386323389
2021-07-22 14:33:18 -07:00
Jamie LiuandgVisor bot d5fb4623ea Replace kernel package types for clone and unshare with linux package types.
PiperOrigin-RevId: 386312456
2021-07-22 13:41:46 -07:00
Jamie LiuandgVisor bot 1ad3822200 Add go:build directives as required by Go 1.17's gofmt.
PiperOrigin-RevId: 385894869
2021-07-20 16:28:45 -07:00
Zyad A. Ali 44c8766d2e Add abi definitions for sysv message queues.
Updates #135
2021-07-13 22:12:02 +02:00
Jamie LiuandgVisor bot 052eb90dc1 Replace kernel.ExitStatus with linux.WaitStatus.
PiperOrigin-RevId: 383705129
2021-07-08 13:39:15 -07:00