mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
iouringfs: Pet the watchdog during ProcessSubmissions.
This loop can take a long time. Since we're blocking on IO outside Task.Block, we need to periodically check for interrupts and update pet the watchdog. Reported-by: syzbot+3fd282d7e4e5c83fc196@syzkaller.appspotmail.com PiperOrigin-RevId: 494009269
This commit is contained in:
committed by
gVisor bot
parent
110c3d76e4
commit
a005752d88
@@ -337,6 +337,12 @@ func (fd *FileDescription) ProcessSubmissions(t *kernel.Task, toSubmit uint32, m
|
||||
submitted := uint32(0)
|
||||
|
||||
for toSubmit > submitted {
|
||||
// This loop can take a long time to process, so periodically check for
|
||||
// interrupts. This also pets the watchdog.
|
||||
if t.Interrupted() {
|
||||
return -1, linuxerr.EINTR
|
||||
}
|
||||
|
||||
if fetchRB {
|
||||
view, err = fd.ioRingsBuf.view(fd.ioRings.SizeBytes())
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user