diff options
| author | Andrew R. Reiter <arr@FreeBSD.org> | 2002-06-26 15:53:11 +0000 |
|---|---|---|
| committer | Andrew R. Reiter <arr@FreeBSD.org> | 2002-06-26 15:53:11 +0000 |
| commit | 57d14ec550feef1d04216ca888476f0f60b03e4d (patch) | |
| tree | fba6e1d839a1cf392605add682212ac40682f11b /sys/compat/linux/linux_ioctl.c | |
| parent | 145ec10619485ebb3401ee497d78837f06bbdfaf (diff) | |
Notes
Diffstat (limited to 'sys/compat/linux/linux_ioctl.c')
| -rw-r--r-- | sys/compat/linux/linux_ioctl.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/sys/compat/linux/linux_ioctl.c b/sys/compat/linux/linux_ioctl.c index 3b97b44acf8a..77e294280622 100644 --- a/sys/compat/linux/linux_ioctl.c +++ b/sys/compat/linux/linux_ioctl.c @@ -2027,15 +2027,10 @@ linux_ioctl_socket(struct thread *td, struct linux_ioctl_args *args) ifp = NULL; error = 0; - mtx_lock(&Giant); - if ((error = fget(td, args->fd, &fp)) != 0) { - mtx_unlock(&Giant); + if ((error = fget(td, args->fd, &fp)) != 0) return (error); - } type = fp->f_type; fdrop(fp, td); - mtx_unlock(&Giant); - if (type != DTYPE_SOCKET) { /* not a socket - probably a tap / vmnet device */ switch (args->cmd) { @@ -2243,14 +2238,10 @@ linux_ioctl_private(struct thread *td, struct linux_ioctl_args *args) struct file *fp; int error, type; - mtx_lock(&Giant); - if ((error = fget(td, args->fd, &fp)) != 0) { - mtx_unlock(&Giant); + if ((error = fget(td, args->fd, &fp)) != 0) return (error); - } type = fp->f_type; fdrop(fp, td); - mtx_unlock(&Giant); if (type == DTYPE_SOCKET) return (linux_ioctl_socket(td, args)); return (ENOIOCTL); |
