From d51b06e19a88643a4f83de2c7de268986668a96a Mon Sep 17 00:00:00 2001 From: jonathan Date: Thu, 11 Jan 1996 05:59:23 +0000 Subject: [PATCH] Add lots of debugging to the TurboChannel autoconfiguration code. --- sys/arch/pmax/tc/ds-tc-conf.c | 67 ++++++++++++++++++++--------------- 1 file changed, 38 insertions(+), 29 deletions(-) diff --git a/sys/arch/pmax/tc/ds-tc-conf.c b/sys/arch/pmax/tc/ds-tc-conf.c index 316554ecdf1d..c3418d6d0717 100644 --- a/sys/arch/pmax/tc/ds-tc-conf.c +++ b/sys/arch/pmax/tc/ds-tc-conf.c @@ -1,4 +1,4 @@ -/* $NetBSD: ds-tc-conf.c,v 1.5 1996/01/03 20:39:16 jonathan Exp $ */ +/* $NetBSD: ds-tc-conf.c,v 1.6 1996/01/11 05:59:23 jonathan Exp $ */ /* * Copyright (c) 1995 Jonathan Stone @@ -11,21 +11,38 @@ * We can share one configuration-struct table and use two slot-address * tables to handle the fact that the turbochannel slot size and base * addresses are different on the two machines. - * (thankfully the IOASIC subslots are all the same size.) + * (thankfully, the IOCTL ASIC subslots are all the same size on all + * DECstations with IOASICs.) The devices are listed in the order in which + * we should probe and attach them. */ #define C(x) ((void *)(u_long)x) +#if 0 +#define TC_SCSI "PMAZ-AA " +#define TC_ETHER "PMAD-AA " +#else +#define TC_SCSI NULL +#define TC_ETHER NULL +#endif struct confargs tc3_devs[4] = { /* name slot offset intpri */ - { "IOCTL ", 3, 0x0, -1, }, /* offset 0x040000 ?*/ - { NULL, 2, 0x0, 2, }, - { NULL, 1, 0x0, 1, }, - { NULL, 0, 0x0, 0, } + { "IOCTL ", 3, 0x0, -1, }, /* IOCTL asic, builtin */ + { NULL, 2, 0x0, 2, }, /* option slot 2 */ + { NULL, 1, 0x0, 1, }, /* option slot 1 */ + { NULL, 0, 0x0, 0, } /* option slot 0 */ }; -/* 3MAXPLUS slot addreseses */ +/* + * The only builtin Turbonchannel device on the kn03 and kmin + * is the IOCTL asic, which is mapped into TC slot 3. + */ +struct tc_builtin tc_kn03_builtins[] = { + { "IOCTL ", 3, 0x0, C(3), /*C(3)*/ } +}; + +/* 3MAXPLUS TC slot addresses */ static struct tc_slotdesc tc_kn03_slots [4] = { { KV(KN03_PHYS_TC_0_START), C(0) }, /* slot0 - tc option slot 0 */ { KV(KN03_PHYS_TC_1_START), C(1) }, /* slot1 - tc option slot 1 */ @@ -53,8 +70,8 @@ struct tc_cpu_desc kn03_tc_desc = static struct tc_slotdesc tc_kmin_slots [] = { { KV(KMIN_PHYS_TC_0_START), C(0) }, /* slot0 - tc option slot 0 */ { KV(KMIN_PHYS_TC_1_START), C(1) }, /* slot1 - tc option slot 1 */ - { KV(KMIN_PHYS_TC_2_START), C(3) }, /* slot2 - tc option slot 2 */ - { KV(KMIN_PHYS_TC_3_START), C(4) } /* slot3 - IO asic on b'board */ + { KV(KMIN_PHYS_TC_2_START), C(2) }, /* slot2 - tc option slot 2 */ + { KV(KMIN_PHYS_TC_3_START), C(3) } /* slot3 - IO asic on b'board */ }; int tc_kmin_nslots = @@ -107,14 +124,6 @@ struct tc_cpu_desc xine_tc_desc = /************************************************************************/ -#if 0 -#define TC_SCSI "PMAZ-AA " -#define TC_ETHER "PMAD-AA " -#else -#define TC_SCSI NULL -#define TC_ETHER NULL -#endif - /* 3MAX (kn02) turbochannel slots */ struct confargs kn02_devs[8] = { /* The 3max supposedly has "KN02 " at 0xbffc0410 */ @@ -123,7 +132,7 @@ struct confargs kn02_devs[8] = { { KN02_ASIC_NAME, 7, 0x0, -1, }, /* System CSR and subslots */ { TC_ETHER, 6, 0x0, 6, }, /* slot 6: Ether on cpu board*/ { TC_SCSI, 5, 0x0, 5, }, /* slot 5: SCSI on cpu board */ -/*XXX*/ { NULL, 4, -1, 0, }, /* slot 3 reserved */ +/*XXX*/ { NULL, 4, -1, 0, }, /* slot 4 reserved */ /*XXX*/ { NULL, 3, -1, 0, }, /* slot 3 reserved */ { NULL, 2, 0x0, 2, }, /* slot 2 - TC option slot 2 */ { NULL, 1, 0x0, 1, }, /* slot 1 - TC option slot 1 */ @@ -132,14 +141,14 @@ struct confargs kn02_devs[8] = { /* slot addreseses */ static struct tc_slotdesc tc_kn02_slots [8] = { - { KV(KN02_PHYS_TC_0_START), }, /* slot 0 - tc option slot 0 */ - { KV(KN02_PHYS_TC_1_START), }, /* slot 1 - tc option slot 1 */ - { KV(KN02_PHYS_TC_2_START), }, /* slot 2 - tc option slot 2 */ - { KV(KN02_PHYS_TC_3_START), }, /* slot 3 - reserved */ - { KV(KN02_PHYS_TC_4_START), }, /* slot 4 - reserved */ - { KV(KN02_PHYS_TC_5_START), }, /* slot 5 - SCSI on cpu board */ - { KV(KN02_PHYS_TC_6_START), }, /* slot 6 - Ether on cpu board */ - { KV(KN02_PHYS_TC_7_START), } /* slot 7 - system devices */ + { KV(KN02_PHYS_TC_0_START), C(0)}, /* slot 0 - tc option slot 0 */ + { KV(KN02_PHYS_TC_1_START), C(1), }, /* slot 1 - tc option slot 1 */ + { KV(KN02_PHYS_TC_2_START), C(2), }, /* slot 2 - tc option slot 2 */ + { KV(KN02_PHYS_TC_3_START), C(3), }, /* slot 3 - reserved */ + { KV(KN02_PHYS_TC_4_START), C(4), }, /* slot 4 - reserved */ + { KV(KN02_PHYS_TC_5_START), C(5), }, /* slot 5 - SCSI on b`board */ + { KV(KN02_PHYS_TC_6_START), C(6), }, /* slot 6 - b'board Ether */ + { KV(KN02_PHYS_TC_7_START), C(7), } /* slot 7 - system devices */ }; @@ -153,9 +162,9 @@ int tc_kn02_nslots = #define TC_KN02_DEV_SCSI 5 struct tc_builtin tc_kn02_builtins[] = { - { KN02_ROM_NAME,7, 0x00000000, C(TC_KN02_DEV_IOASIC), }, - { TC_ETHER, 6, 0x00000000, C(TC_KN02_DEV_ETHER), }, - { TC_SCSI, 5, 0x00000000, C(TC_KN02_DEV_SCSI), }, + { KN02_ROM_NAME,7, 0x0, C(TC_KN02_DEV_IOASIC) /* C(7)*/ }, + { TC_ETHER, 6, 0x0, C(TC_KN02_DEV_ETHER) /* C(6)*/ }, + { TC_SCSI, 5, 0x0, C(TC_KN02_DEV_SCSI) /* C(5)*/ }, };