>>>>> On Mon, 4 Oct 2004 17:00:02 -0700, Jun Sun <firstname.lastname@example.org> said:
>> It lacks some preempt_disable/preempt_enable which were in
>> preempt-patch for 2.4 kernel. Are these all unnecessary at all?
jsun> They are necessary.
>> For example, fpu-emulation is not preemptive-safe, isn't it?
jsun> That is correct.
jsun> I think the best thing to do right now is to go through 2.4
jsun> preemption patch and pick up the missing ones for 2.6.
Thank you. I think there are some issue to fix.
1. ll/sc emulation (ll_bit, ll_task). This is easy to fix.
2. There is an global variable ieee754_csr in math-emu. This must be
protected by preempt_disable. But math-emu uses put_user/get_user
which can not be used with preempt disabled. (Is it true?)
3. save_fp_context/restore_fp_context is not preemptable. But these
function uses put_user/get_user.
Actually, math-emu/fp_context issues are not only for preemptive
kernel. I suppose bad things can happen if a process going to sleep
on get_user/put_user in math-emu/save_fp_context/restore_fp_context...