summaryrefslogtreecommitdiffstats
path: root/sys/compat/linux/linux_misc.c
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2003-03-13 22:45:43 +0000
committerjhb <jhb@FreeBSD.org>2003-03-13 22:45:43 +0000
commit34c953a7727e28704114630ad33222b9800cb199 (patch)
tree3d9830747caf0da273c7bb49c9d4666c52ee45ce /sys/compat/linux/linux_misc.c
parent129be1daea4bcf956a4f29af69b443113059a502 (diff)
downloadFreeBSD-src-34c953a7727e28704114630ad33222b9800cb199.zip
FreeBSD-src-34c953a7727e28704114630ad33222b9800cb199.tar.gz
- Change the linux_[gs]et_os{name, release, s_version}() functions to
take a thread instead of a proc for their first argument. - Add a mutex to protect the system-wide Linux osname, osrelease, and oss_version variables. - Change linux_get_prison() to take a thread instead of a proc for its first argument and to use td_ucred rather than p_ucred. This is ok because a thread's prison does not change even though it's ucred might. - Also, change linux_get_prison() to return a struct prison * instead of a struct linux_prison * since it returns with the struct prison locked and this makes it easier to safely unlock the prison when we are done messing with it.
Diffstat (limited to 'sys/compat/linux/linux_misc.c')
-rw-r--r--sys/compat/linux/linux_misc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/compat/linux/linux_misc.c b/sys/compat/linux/linux_misc.c
index c16ae88..8e86706 100644
--- a/sys/compat/linux/linux_misc.c
+++ b/sys/compat/linux/linux_misc.c
@@ -697,8 +697,8 @@ linux_newuname(struct thread *td, struct linux_newuname_args *args)
printf(ARGS(newuname, "*"));
#endif
- linux_get_osname(td->td_proc, osname);
- linux_get_osrelease(td->td_proc, osrelease);
+ linux_get_osname(td, osname);
+ linux_get_osrelease(td, osrelease);
bzero(&utsname, sizeof(utsname));
strlcpy(utsname.sysname, osname, LINUX_MAX_UTSNAME);
OpenPOWER on IntegriCloud