From 410d857972044bf841c93ab098cad5faf98bd33b Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Thu, 15 Dec 2005 16:30:41 +0000 Subject: [PATCH] Remove linux_mib_destroy() (which I actually added in between 5.0 and 5.1) which existed to cleanup the linux_osname mutex. Now that MTX_SYSINIT() has grown a SYSUNINIT to destroy mutexes on unload, the extra destroy here was redundant and resulted in panics in debug kernels. MFC after: 1 week Reported by: Goran Gajic ggajic at afrodita dot rcub dot bg dot ac dot yu --- sys/alpha/linux/linux_sysvec.c | 1 - sys/amd64/linux32/linux32_sysvec.c | 1 - sys/compat/linux/linux_mib.c | 7 ------- sys/compat/linux/linux_mib.h | 2 -- sys/i386/linux/linux_sysvec.c | 1 - 5 files changed, 12 deletions(-) diff --git a/sys/alpha/linux/linux_sysvec.c b/sys/alpha/linux/linux_sysvec.c index b6ce778471a0..4ec29578d1fc 100644 --- a/sys/alpha/linux/linux_sysvec.c +++ b/sys/alpha/linux/linux_sysvec.c @@ -265,7 +265,6 @@ linux_elf_modevent(module_t mod, int type, void *data) linux_ioctl_unregister_handler(*lihp); if (bootverbose) printf("Linux ELF exec handler removed\n"); - linux_mib_destroy(); } else printf("Could not deinstall ELF interpreter entry\n"); break; diff --git a/sys/amd64/linux32/linux32_sysvec.c b/sys/amd64/linux32/linux32_sysvec.c index d1b1eedddefa..c69b5318464c 100644 --- a/sys/amd64/linux32/linux32_sysvec.c +++ b/sys/amd64/linux32/linux32_sysvec.c @@ -1083,7 +1083,6 @@ linux_elf_modevent(module_t mod, int type, void *data) linux_ioctl_unregister_handler(*lihp); if (bootverbose) printf("Linux ELF exec handler removed\n"); - linux_mib_destroy(); } else printf("Could not deinstall ELF interpreter entry\n"); break; diff --git a/sys/compat/linux/linux_mib.c b/sys/compat/linux/linux_mib.c index 916e8ea3c317..0721d529bea0 100644 --- a/sys/compat/linux/linux_mib.c +++ b/sys/compat/linux/linux_mib.c @@ -155,13 +155,6 @@ linux_get_prison(struct thread *td) return (pr); } -void -linux_mib_destroy(void) -{ - - mtx_destroy(&osname_lock); -} - void linux_get_osname(struct thread *td, char *dst) { diff --git a/sys/compat/linux/linux_mib.h b/sys/compat/linux/linux_mib.h index b68e57fd3238..42d9d899266b 100644 --- a/sys/compat/linux/linux_mib.h +++ b/sys/compat/linux/linux_mib.h @@ -31,8 +31,6 @@ #ifndef _LINUX_MIB_H_ #define _LINUX_MIB_H_ -void linux_mib_destroy(void); - void linux_get_osname(struct thread *td, char *dst); int linux_set_osname(struct thread *td, char *osname); diff --git a/sys/i386/linux/linux_sysvec.c b/sys/i386/linux/linux_sysvec.c index e2df7f6c2e28..f28371dc5218 100644 --- a/sys/i386/linux/linux_sysvec.c +++ b/sys/i386/linux/linux_sysvec.c @@ -925,7 +925,6 @@ linux_elf_modevent(module_t mod, int type, void *data) linux_ioctl_unregister_handler(*lihp); if (bootverbose) printf("Linux ELF exec handler removed\n"); - linux_mib_destroy(); } else printf("Could not deinstall ELF interpreter entry\n"); break;