cvs commit: src/sys/kern kern_sig.c
Julian Elischer
julian at elischer.org
Thu Mar 3 20:22:02 GMT 2005
David Schultz wrote:
>On Thu, Mar 03, 2005, David Xu wrote:
>
>
>>
>>This only partly resolves the problem, if function A call B, B call C,
>>C is unknown to A,
>>and C does a msleep(), problem still lhappens.
>>However, if there needs a flag, I would like PNOSWAP for msleep just
>>like PCATCH
>>does.
>>
>>
>
>You have to worry about that anyway, though. A and B need to know
>that they're not allowed to hold locks across the calls if C calls
>msleep(), for instance. Anyway, your proposal if having a flag
>for msleep() is basically the same as my proposal of having a
>separate function. (The only difference is that adding a separate
>function doesn't break the ABI.) So it sounds like we're more or
>less in agreement here.
>
>
>
>>>The alternative, of course, is to just fix the code that assumes
>>>that swapping doesn't exist.
>>>
>>>
>>>
>>First find all code written in such way, but it is not that easy.
>>
>>
>
>True. If we changed msleep() to disable swapping by default, then
>we wouldn't have to worry about correctness problems related to
>missing some.
>
>
adding the flag to ENABLE swapping would be ABI compatible.
More information about the cvs-src
mailing list