aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEdward Tomasz Napierala <trasz@FreeBSD.org>2021-10-17 10:19:51 +0000
committerEdward Tomasz Napierala <trasz@FreeBSD.org>2021-10-17 10:19:56 +0000
commit7e7859e7c2b900fd1b1af6e90ed31d51b9b5514d (patch)
tree89ab8dbe986ccf03db06ee34647a80934dbc42a9
parent1045352f150346ba422b3a3ce6344fc694bc3aa4 (diff)
downloadsrc-7e7859e7c2b900fd1b1af6e90ed31d51b9b5514d.tar.gz
src-7e7859e7c2b900fd1b1af6e90ed31d51b9b5514d.zip
linux: Partially implement TCSBRK
This fixes tcflush(3), unbreaking cheribuild.py under arm64 Focal. Reviewed By: imp Sponsored By: EPSRC Differential Revision: https://reviews.freebsd.org/D32291
-rw-r--r--sys/compat/linux/linux_ioctl.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/compat/linux/linux_ioctl.c b/sys/compat/linux/linux_ioctl.c
index 62cb958aa42f..e3ce41ed38f8 100644
--- a/sys/compat/linux/linux_ioctl.c
+++ b/sys/compat/linux/linux_ioctl.c
@@ -755,7 +755,15 @@ linux_ioctl_termio(struct thread *td, struct linux_ioctl_args *args)
td));
break;
- /* LINUX_TCSBRK */
+ case LINUX_TCSBRK:
+ if (args->arg != 0) {
+ error = (fo_ioctl(fp, TIOCDRAIN, (caddr_t)&bios, td->td_ucred,
+ td));
+ } else {
+ linux_msg(td, "ioctl TCSBRK arg 0 not implemented");
+ error = ENOIOCTL;
+ }
+ break;
case LINUX_TCXONC: {
switch (args->arg) {