summary refs log tree commit diff
path: root/seccomp
diff options
context:
space:
mode:
authorDmitry Torokhov <dtor@chromium.org>2019-06-10 16:45:32 -0700
committerDmitry Torokhov <dtor@chromium.org>2019-06-13 15:23:44 +0000
commitbb340d9a94d48514cbe310d05e1ce539aae31264 (patch)
tree402be4a35bfec4ffbafb0f6669cef80e32956ac2 /seccomp
parenta094f91d2cc96e9eeb0681deb81c37e9a85e7a55 (diff)
downloadcrosvm-bb340d9a94d48514cbe310d05e1ce539aae31264.tar
crosvm-bb340d9a94d48514cbe310d05e1ce539aae31264.tar.gz
crosvm-bb340d9a94d48514cbe310d05e1ce539aae31264.tar.bz2
crosvm-bb340d9a94d48514cbe310d05e1ce539aae31264.tar.lz
crosvm-bb340d9a94d48514cbe310d05e1ce539aae31264.tar.xz
crosvm-bb340d9a94d48514cbe310d05e1ce539aae31264.tar.zst
crosvm-bb340d9a94d48514cbe310d05e1ce539aae31264.zip
usb: update xhci policies to allow newer libusb
The updated version of libusb uses USBFS_CONNECTINFO and
USBFS_CONNINFO_EX ioctls, as well as readlink and lseek syscalls,
so let's enable them.

BUG=b:133773289
TEST=Try attaching a USB device to Crostini VM.

Change-Id: Ibdcab2da9abe1c0bb35c989d9d62b44ce403e268
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/1650534
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Tested-by: Dmitry Torokhov <dtor@chromium.org>
Diffstat (limited to 'seccomp')
-rw-r--r--seccomp/arm/xhci.policy6
-rw-r--r--seccomp/x86_64/xhci.policy6
2 files changed, 10 insertions, 2 deletions
diff --git a/seccomp/arm/xhci.policy b/seccomp/arm/xhci.policy
index 239eafd..857cecc 100644
--- a/seccomp/arm/xhci.policy
+++ b/seccomp/arm/xhci.policy
@@ -8,6 +8,7 @@ openat: 1
 stat64: 1
 fcntl64: 1
 lstat64: 1
+readlink: 1
 readlinkat: 1
 getdents64: 1
 getrandom: 1
@@ -35,9 +36,12 @@ uname: 1
 # 0x5514 == USBDEVFS_RESET
 # 0x80045505 == USBDEVFS_SETCONFIGURATION
 # 0x8108551b == USBDEVFS_DISCONNECT_CLAIM
-ioctl: arg1 == 0xc0105500 || arg1 == 0x802c550a || arg1 == 0x8004551a || arg1 == 0x4004550d || arg1 == 0x8004550f || arg1 == 0x80045510 || arg1 == 0x550b || arg1 == 0x5514 || arg1 == 0x80045505 || arg1 == 0x8108551b
+# 0x40085511 == USBDEVFS_CONNECTINFO
+# 0x80305520 == USBDEVFS_CONNINFO_EX
+ioctl: arg1 == 0xc0105500 || arg1 == 0x802c550a || arg1 == 0x8004551a || arg1 == 0x4004550d || arg1 == 0x8004550f || arg1 == 0x80045510 || arg1 == 0x550b || arg1 == 0x5514 || arg1 == 0x80045505 || arg1 == 0x8108551b || arg1 == 0x40085511 || arg1 == 0x80305520
 fstat: 1
 sigaltstack: 1
 recvmsg: 1
 getrandom: 1
 getdents: 1
+lseek: 1
diff --git a/seccomp/x86_64/xhci.policy b/seccomp/x86_64/xhci.policy
index 19a46eb..2d81b74 100644
--- a/seccomp/x86_64/xhci.policy
+++ b/seccomp/x86_64/xhci.policy
@@ -8,6 +8,7 @@ openat: 1
 
 lstat: 1
 gettid: 1
+readlink: 1
 readlinkat: 1
 timerfd_create: 1
 name_to_handle_at: 1
@@ -33,9 +34,12 @@ uname: 1
 # 0x5514 == USBDEVFS_RESET
 # 0x80045505 == USBDEVFS_SETCONFIGURATION
 # 0x8108551b == USBDEVFS_DISCONNECT_CLAIM
-ioctl: arg1 == 0xc0185500 || arg1 == 0x41045508 || arg1 == 0x8004550f || arg1 == 0x4008550d || arg1 == 0x8004551a || arg1 == 0x550b || arg1 == 0x80045510 || arg1 == 0x8038550a || arg1 == 0x5514 || arg1 == 0x80045505 || arg1 == 0x8108551b
+# 0x40085511 == USBDEVFS_CONNECTINFO
+# 0x80305520 == USBDEVFS_CONNINFO_EX
+ioctl: arg1 == 0xc0185500 || arg1 == 0x41045508 || arg1 == 0x8004550f || arg1 == 0x4008550d || arg1 == 0x8004551a || arg1 == 0x550b || arg1 == 0x80045510 || arg1 == 0x8038550a || arg1 == 0x5514 || arg1 == 0x80045505 || arg1 == 0x8108551b || arg1 == 0x40085511 || arg1 == 0x80305520
 fstat: 1
 sigaltstack: 1
 recvmsg: 1
 getrandom: 1
 getdents: 1
+lseek: 1