NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: kern/50430: syscall_disestablish() can remove active syscalls
The following reply was made to PR kern/50430; it has been noted by GNATS.
From: christos%zoulas.com@localhost (Christos Zoulas)
To: Masao Uebayashi <uebayasi%gmail.com@localhost>
Cc: gnats-bugs%netbsd.org@localhost, kern-bug-people%netbsd.org@localhost,
gnats-admin%netbsd.org@localhost, netbsd-bugs%netbsd.org@localhost,
Paul Goyette <paul%whooppee.com@localhost>
Subject: Re: kern/50430: syscall_disestablish() can remove active syscalls
Date: Mon, 16 Nov 2015 08:10:01 -0500
On Nov 16, 5:08pm, uebayasi%gmail.com@localhost (Masao Uebayashi) wrote:
-- Subject: Re: kern/50430: syscall_disestablish() can remove active syscalls
| On Mon, Nov 16, 2015 at 6:45 AM, Christos Zoulas <christos%zoulas.com@localhost> wrote:
| > On Nov 15, 8:25pm, mrg%eterna.com.au@localhost (matthew green) wrote:
| > -- Subject: re: kern/50430: syscall_disestablish() can remove active syscalls
| >
| > | until bug is fixed, can we disable the autounload?
| >
| > Sure, that sounds prudent. It is difficult to fix properly. One way to do
| > this would be to mark all lwps that have used compat syscalls with a bit
| > depending on the module they have used, and refuse to unload the module
| > until the lwp is gone.
| >
| > - when load a module that has compat syscalls, assign to it a bit.
| > - mark a flags field of all syscalls that were loaded with that module
| > with that bit.
| > - or the lwp flags with the syscall flags on each syscall.
| > - when it is time to unload check that no lwp has that bit in the flags set.
| > - instead of keeping l_sysent, keep l_sysmodflags or something.
|
| What happens if signal handler does longjmp(3) and interrupted syscall
| never returns?
It does not matter. The flag is never cleared (even when that does not
happen). Once an lwp executes a syscall from a compat module, that module
cannot be unloaded until the lwp exits.
christos
Home |
Main Index |
Thread Index |
Old Index