crosvm/seccomp/x86_64/block_device.policy
Daniel Verkamp 6eadef77a3 sys_util: add WriteZeroesAt trait
Add a variant of WriteZeroes that allows the caller to specify the
offset explicitly instead of using the file's cursor.  This gets rid of
one of the last bits of shared state between disk file users, which will
help in implementing multi-queue support.

Additionally, modify the WriteZeroes trait to use a generic
implementation based on WriteZeroesAt + Seek when possible.

BUG=chromium:858815
TEST=Boot Termina in crosvm

Change-Id: If710159771aeeb55f4f7746dd4354b6c042144e8
Signed-off-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/1913519
2019-11-27 21:22:37 +00:00

20 lines
388 B
Text

# Copyright 2017 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
@include /usr/share/policy/crosvm/common_device.policy
fallocate: 1
fdatasync: 1
fstat: 1
fsync: 1
ftruncate: 1
lseek: 1
pread64: 1
preadv: 1
pwrite64: 1
pwritev: 1
timerfd_create: 1
timerfd_gettime: 1
timerfd_settime: 1