home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!sun4nl!hgatenl!tedux!F_HOME!ontnix2!leo
- From: leo@ontnix2.ahwau.ahold.nl (Leo Weppelman)
- Newsgroups: comp.sys.m68k
- Subject: problems with m68882
- Keywords: m68882
- Message-ID: <219@F_HOME.ahwau.ahold.nl>
- Date: 4 Sep 92 06:29:49 GMT
- Sender: usenet@F_HOME.ahwau.ahold.nl
- Lines: 37
- Nntp-Posting-Host: ontnix
-
- I am working on an multi-tasking kernel on my Atari-TT. It contains an
- 68030 main processor and an 68882 coprocessor on 33Mhz.
-
- I am getting coprocessor protocol violations at random but especially
- when a lot of interrupts occur (i.e. during disk accesses).
-
- I added the the following functions to the kernel to support floating
- point support:
- - when a process is created, an frestore is performed on a null frame
- (a long value of 0). This should reset the coprocessor for that process.
- - Just before I switch to a new process context, I carry out the following
- instruction sequence:
- move #proc_fpu_save, a0
- fsave (a0)
- btst (a0)
- beq no_more
- fmove fp0-fp7, x(a0) /* I don't know the exact offset */
- fmove fpcr/fpiar/fpsr, x2(a0)
- nomore:
- rts
- - when a process resumes executing, the fpu context is restored with
- code simular to the above code fragment.
-
- Is there somebody out there who can tell me what I am doing wrong here.
- I am pretty sure that my kernel code does not use floating point (exept
- for the above mentioned fragments).
- I don't understand the exact problem I am having. According to the manuals
- interrupts shouldn't be a problem.
-
- I also have a second question, the manual (as contained in the 68000 family
- reference) says that when handling floating point exeptions I should
- sometimes set (or reset) bit 27 of the BUI in the save-context. Does
- anybody know why and when I should set this bit and the location of the
- BIU in the saved context.
-
- Thanks in advance, Leo (email: leo@ahwau.ahold.nl)
-
-