Module Name: src
Committed By: thorpej
Date: Sun Mar 31 19:11:21 UTC 2024
Modified Files:
src/sys/arch/alpha/alpha: dec_6600.c
src/sys/arch/alpha/include: rpb.h
Log Message:
In dec_6600_device_register(): If we're running on a DS10, set the
"pciide-disable-dma" property on the on-board "aceride" to true. This
is intended to be a temporary measure until the issue that makes it not
work correctly is found and fixed.
To generate a diff of this commit:
cvs rdiff -u -r1.37 -r1.38 src/sys/arch/alpha/alpha/dec_6600.c
cvs rdiff -u -r1.44 -r1.45 src/sys/arch/alpha/include/rpb.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/alpha/alpha/dec_6600.c
diff -u src/sys/arch/alpha/alpha/dec_6600.c:1.37 src/sys/arch/alpha/alpha/dec_6600.c:1.38
--- src/sys/arch/alpha/alpha/dec_6600.c:1.37 Sun Mar 31 19:06:30 2024
+++ src/sys/arch/alpha/alpha/dec_6600.c Sun Mar 31 19:11:21 2024
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_6600.c,v 1.37 2024/03/31 19:06:30 thorpej Exp $ */
+/* $NetBSD: dec_6600.c,v 1.38 2024/03/31 19:11:21 thorpej Exp $ */
/*
* Copyright (c) 1995, 1996, 1997 Carnegie-Mellon University.
@@ -31,7 +31,7 @@
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
-__KERNEL_RCSID(0, "$NetBSD: dec_6600.c,v 1.37 2024/03/31 19:06:30 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_6600.c,v 1.38 2024/03/31 19:11:21 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -101,15 +101,36 @@ static const char *kgdb_devlist[] = {
};
#endif /* KGDB */
+static const struct alpha_variation_table dec_6600_variations[] = {
+ { SV_ST_DP264, "AlphaPC DP264" },
+ { SV_ST_CLIPPER, "AlphaServer ES40 (\"Clipper\")" },
+ { SV_ST_GOLDRUSH, "AlphaServer DS20 (\"GoldRush\")" },
+ { SV_ST_WEBBRICK, "AlphaServer DS10 (\"WebBrick\")" },
+ { SV_ST_SHARK, "AlphaServer DS20L (\"Shark\")" },
+ { 0, NULL },
+};
+
+static const struct alpha_variation_table dec_titan_variations[] = {
+ { 0, NULL },
+};
+
void
dec_6600_init(void)
{
+ uint64_t variation;
- platform.family = "6600";
+ platform.family = (hwrpb->rpb_type == ST_DEC_TITAN) ? "Titan"
+ : "6600";
if ((platform.model = alpha_dsr_sysname()) == NULL) {
- /* XXX Don't know the system variations, yet. */
- platform.model = alpha_unknown_sysname();
+ const struct alpha_variation_table *vartab =
+ (hwrpb->rpb_type == ST_DEC_TITAN) ? dec_titan_variations
+ : dec_6600_variations;
+ variation = hwrpb->rpb_variation & SV_ST_MASK;
+ if ((platform.model = alpha_variation_name(variation,
+ vartab)) == NULL) {
+ platform.model = alpha_unknown_sysname();
+ }
}
platform.iobus = "tsc";
@@ -203,6 +224,37 @@ dec_6600_device_register(device_t dev, v
struct bootdev_data *b = bootdev_data;
device_t parent = device_parent(dev);
+ /*
+ * First section: Deal with system-specific quirks.
+ */
+
+ if ((hwrpb->rpb_variation & SV_ST_MASK) == SV_ST_WEBBRICK) {
+ /*
+ * DMA on the on-board ALI IDE controller is not
+ * working correctly; disable it for now to let
+ * the systems at least hobble along.
+ *
+ * N.B. There's only one Pchip on a DS10, do there
+ * is not need to determine which hose we have here.
+ *
+ * XXX This is meant to be temporary until we can find
+ * XXX and fix the issue with bus-master DMA.
+ */
+ if (device_is_a(parent, "pci") && device_is_a(dev, "aceride")) {
+ struct pci_attach_args *pa = aux;
+
+ if (pa->pa_bus == 0 && pa->pa_device == 13 &&
+ pa->pa_function == 0) {
+ prop_dictionary_set_bool(device_properties(dev),
+ "pciide-disable-dma", true);
+ }
+ }
+ }
+
+ /*
+ * Second section: Boot device detection.
+ */
+
if (b == NULL || found)
return;
Index: src/sys/arch/alpha/include/rpb.h
diff -u src/sys/arch/alpha/include/rpb.h:1.44 src/sys/arch/alpha/include/rpb.h:1.45
--- src/sys/arch/alpha/include/rpb.h:1.44 Sat Oct 3 17:33:23 2020
+++ src/sys/arch/alpha/include/rpb.h Sun Mar 31 19:11:21 2024
@@ -1,4 +1,4 @@
-/* $NetBSD: rpb.h,v 1.44 2020/10/03 17:33:23 thorpej Exp $ */
+/* $NetBSD: rpb.h,v 1.45 2024/03/31 19:11:21 thorpej Exp $ */
/*
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@@ -185,6 +185,23 @@ struct rpb {
*/
#define SV_ST_MIATA_1_5 0x00004c00 /* Miata 1.5 */
+/*
+ * System types for the Tsunami family.
+ * XXX These are not very complete!
+ */
+#define SV_ST_DP264 0x00000400 /* AlphaPC DP264 */
+#define SV_ST_WARHOL 0x00000800
+#define SV_ST_WINDJAMMER 0x00000c00
+#define SV_ST_MONET 0x00001000
+#define SV_ST_CLIPPER 0x00001400 /* AlphaServer ES40 */
+#define SV_ST_GOLDRUSH 0x00001800 /* AlphaServer DS20 */
+#define SV_ST_WEBBRICK 0x00001c00 /* AlphaServer DS10 */
+#define SV_ST_CATAMARAN 0x00002000
+#define SV_ST_BRISBANE 0x00002400
+#define SV_ST_MALBOURNE 0x00002800
+#define SV_ST_FLYINGCLIPPER 0x00002c00
+#define SV_ST_SHARK 0x00003000 /* AlphaServer DS20L */
+
uint64_t rpb_variation; /* 58 */
char rpb_revision[8]; /* 60; only first 4 valid */