6 Commits
Author SHA1 Message Date
Rahat MahmoodandgVisor bot 8643fe526e cgroupfs: Implement task migration
PiperOrigin-RevId: 430273113
2022-02-22 12:43:54 -08:00
Fabricio VoznikaandgVisor bot dfcf798425 Fix epoll_ctl(2) regular files and dirs
Linux behaves differently for regular files and dirs for poll(2)/select(2)
compared to epoll_ctl(2). The latter returns EPERM for file and dirs.
I've also changed host FDs to behave like the underlying FD in regards
to epoll to keep it compatible with docker.

Fixes #7134

PiperOrigin-RevId: 429412692
2022-02-17 15:12:36 -08:00
Fabricio VoznikaandgVisor bot 9768009a79 Don't eat error from epoll_ctl EPOLL_CTL_ADD
Docker maps stdin to `/dev/null` which doesn't support epoll. Host FD
was ignoring the error and suceeding the epoll_ctl call from the
container, giving false impressing that epoll would be notified.

This required plumbing failure to all waiter.Waitable.EventRegister
callers and implementers.

Closes #6795

PiperOrigin-RevId: 414797621
2021-12-07 12:36:00 -08:00
Adin ScannellandgVisor bot 91f58d2cc8 Update Waitable API.
Instead of passing the event mask at registratrion time, pass the mask as part
of the waiter. This makes the mask immutable and simplifies the architecture of
waiters. This is also necessary for a future fix that will allow the fdnotifier
to keep persistent entries, as opposed to requiring constant updates.

This change is intended to be a no-op in terms of function. The only exception
is signalfd, where this mask was abused. To handle this case, the operation of
signalfd changed to allow one layer of indirection.

PiperOrigin-RevId: 409702998
2021-11-13 12:54:39 -08:00
Zyad A. Ali 7508a0efee Define mq.View and use it for mqfs.queueFD.
View makes it easier to handle O_RDONLY, O_WRONLY, and ORDWR options in
mq_open(2).

Updates #136
2021-09-28 20:43:52 +02:00
Zyad A. Ali 0061d0e4e5 Implement queueInode and queueFD in mqfs.
Implement inode and file description representing a POSIX message queue,
and other utilities needed to implement file operations.

Updates #136
2021-09-15 21:56:35 +02:00