cleanup and recognize the a1200.

This commit is contained in:
chopps 1994-06-22 16:19:55 +00:00
parent e20de834b6
commit 99b0889a3c
3 changed files with 24 additions and 11 deletions

View File

@ -27,7 +27,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id: autoconf.c,v 1.23 1994/06/13 08:12:30 chopps Exp $
* $Id: autoconf.c,v 1.24 1994/06/22 16:19:55 chopps Exp $
*/
#include <sys/param.h>
#include <sys/systm.h>
@ -198,7 +198,7 @@ mbattach(pdp, dp, auxp)
config_found(dp, "kbd", simple_devprint);
config_found(dp, "grfcc", simple_devprint);
config_found(dp, "fdc", simple_devprint);
if (is_a4000())
if (is_a4000() || is_a1200())
config_found(dp, "idesc", simple_devprint);
config_found(dp, "ztwobus", simple_devprint);
if (is_a3000())
@ -374,6 +374,9 @@ is_a4000()
{
if ((machineid >> 16) == 4000)
return (1); /* It's an A4000 */
if ((machineid >> 16) == 1200)
return (0); /* It's an A1200, so not A4000 */
/* Do I need this any more? */
if ((custom.deniseid & 0xff) == 0xf8)
return (1);
#ifdef DEBUG
@ -384,3 +387,11 @@ is_a4000()
return (0); /* It's not an A4000 */
return (a4000_flag); /* Machine type not set */
}
int
is_a1200()
{
if ((machineid >> 16) == 1200)
return (1); /* It's an A1200 */
return (0); /* Machine type not set */
}

View File

@ -38,7 +38,7 @@
* from: Utah $Hdr: locore.s 1.58 91/04/22$
*
* @(#)locore.s 7.11 (Berkeley) 5/9/91
* $Id: locore.s,v 1.29 1994/06/16 15:05:02 chopps Exp $
* $Id: locore.s,v 1.30 1994/06/22 16:19:58 chopps Exp $
*
* Original (hp300) Author: unknown, maybe Mike Hibler?
* Amiga author: Markus Wild
@ -1362,7 +1362,6 @@ Lres1:
pflusha | flush entire TLB
jra Lres3
Lres2:
| .word 0xf4f8 | cpusha bc
.word 0xf518 | pflusha (68040)
movl #CACHE40_ON,d0
movc d0,cacr | invalidate cache(s)
@ -1526,7 +1525,6 @@ Lmc68851a:
rts
Ltbia040:
.word 0xf518 | pflusha
| .word 0xf478 | cpush dc [cinv or cpush ??]
rts
/*
@ -1556,7 +1554,6 @@ Ltbis040:
moveq #FC_USERD,d0 | select user
movc d0,dfc
.word 0xf508 | pflush a0@
| .word 0xf478 | cpusha dc [cinv or cpush ??]
rts
/*
@ -1581,7 +1578,6 @@ Lmc68851c:
Ltbias040:
| 68040 can't specify supervisor/user on pflusha, so we flush all
.word 0xf518 | pflusha
| .word 0xf478 | cpusha dc [cinv or cpush ??]
rts
/*
@ -1606,7 +1602,6 @@ Lmc68851d:
Ltbiau040:
| 68040 can't specify supervisor/user on pflusha, so we flush all
.word 0xf518 | pflusha
| .word 0xf478 | cpusha dc [cinv or cpush ??]
rts
/*
@ -1775,7 +1770,6 @@ ENTRY(loadustp)
movc d0,cacr | invalidate on-chip d-cache
rts | since pmove flushes TLB
Lldustp040:
.word 0xf478 | cpush dc
.word 0x4e7b,0x0806 | movec d0,URP
rts
@ -2077,7 +2071,6 @@ Lm68881rdone:
/*
* Handle the nitty-gritty of rebooting the machine.
*
* DOES NOT YET WORK !!!!
*/
.globl _doboot
_doboot:
@ -2209,6 +2202,13 @@ Lreload040:
.word 0x4e7b,0x3807 | movc d3,SRP
Lreload2:
moveq #0,d2 | clear unused registers
moveq #0,d3
moveq #0,d6
subl a1,a1
subl a2,a2
subl a3,a3
subl a5,a5
jmp a6@ | start new kernel

View File

@ -38,7 +38,7 @@
* from: Utah $Hdr: machdep.c 1.63 91/04/24$
*
* @(#)machdep.c 7.16 (Berkeley) 6/3/91
* $Id: machdep.c,v 1.32 1994/06/21 03:59:29 chopps Exp $
* $Id: machdep.c,v 1.33 1994/06/22 16:20:01 chopps Exp $
*/
#include <sys/param.h>
@ -440,6 +440,8 @@ identifycpu()
mach = "Amiga 4000";
else if (is_a3000())
mach = "Amiga 3000";
else if (is_a1200())
mach = "Amiga 1200";
else
mach = "Amiga 500/2000";