summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNiklas Hallqvist <niklas@cvs.openbsd.org>2000-06-20 05:01:12 +0000
committerNiklas Hallqvist <niklas@cvs.openbsd.org>2000-06-20 05:01:12 +0000
commitb3cbb64300132c2ff5f523c43c3d991f2aa05bc0 (patch)
treecba4a489ca01ab017771c2bc27d77c5a705036b5
parent5cb91ac157b9d0e11b1dcad65f12455df72d9f71 (diff)
Almost make a Megahertz card working, still rx probs though
-rw-r--r--sys/dev/pcmcia/if_sm_pcmcia.c6
-rw-r--r--sys/dev/pcmcia/pcmcia_cis_quirks.c62
2 files changed, 60 insertions, 8 deletions
diff --git a/sys/dev/pcmcia/if_sm_pcmcia.c b/sys/dev/pcmcia/if_sm_pcmcia.c
index 6b80cc5cf9e..e3a294c1131 100644
--- a/sys/dev/pcmcia/if_sm_pcmcia.c
+++ b/sys/dev/pcmcia/if_sm_pcmcia.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_sm_pcmcia.c,v 1.12 2000/04/24 19:43:36 niklas Exp $ */
+/* $OpenBSD: if_sm_pcmcia.c,v 1.13 2000/06/20 05:01:11 niklas Exp $ */
/* $NetBSD: if_sm_pcmcia.c,v 1.11 1998/08/15 20:47:32 thorpej Exp $ */
/*-
@@ -117,10 +117,10 @@ struct sm_pcmcia_product {
} sm_pcmcia_prod[] = {
{ PCMCIA_VENDOR_MEGAHERTZ2, PCMCIA_PRODUCT_MEGAHERTZ2_XJACK,
0 },
-
+ { PCMCIA_VENDOR_MEGAHERTZ2, PCMCIA_PRODUCT_MEGAHERTZ2_XJEM1144,
+ 0 },
{ PCMCIA_VENDOR_NEWMEDIA, PCMCIA_PRODUCT_NEWMEDIA_BASICS,
0 },
-
{ PCMCIA_VENDOR_SMC, PCMCIA_PRODUCT_SMC_8020,
0 }
};
diff --git a/sys/dev/pcmcia/pcmcia_cis_quirks.c b/sys/dev/pcmcia/pcmcia_cis_quirks.c
index 9d4c22922e6..96ebcaeafdf 100644
--- a/sys/dev/pcmcia/pcmcia_cis_quirks.c
+++ b/sys/dev/pcmcia/pcmcia_cis_quirks.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcmcia_cis_quirks.c,v 1.3 1999/10/06 13:35:47 fgsch Exp $ */
+/* $OpenBSD: pcmcia_cis_quirks.c,v 1.4 2000/06/20 05:01:11 niklas Exp $ */
/* $NetBSD: pcmcia_cis_quirks.c,v 1.3 1998/12/29 09:00:28 marc Exp $ */
/*
@@ -89,6 +89,47 @@ static struct pcmcia_config_entry pcmcia_3cxem556_func1_cfe0 = {
0, /* maxtwins */
};
+struct pcmcia_function pcmcia_megahertz_xjem1144_func0 = {
+ 0, /* function number */
+ PCMCIA_FUNCTION_NETWORK,
+ 0x07, /* last cfe number */
+ 0x200, /* ccr_base */
+ 0x63, /* ccr_mask */
+};
+
+struct pcmcia_config_entry pcmcia_megahertz_xjem1144_func0_cfe0 = {
+ 0x07, /* cfe number */
+ PCMCIA_CFE_IO8 | PCMCIA_CFE_IO16 | PCMCIA_CFE_IRQLEVEL,
+ PCMCIA_IFTYPE_IO,
+ 1, /* num_iospace */
+ 4, /* iomask */
+ { { 0x0010, 0 } }, /* iospace */
+ 0xffff, /* irqmask */
+ 0, /* num_memspace */
+ { }, /* memspace */
+ 0, /* maxtwins */
+};
+
+static struct pcmcia_function pcmcia_megahertz_xjem1144_func1 = {
+ 1, /* function number */
+ PCMCIA_FUNCTION_SERIAL,
+ 0x35, /* last cfe number */
+ 0x300, /* ccr_base */
+ 0x3, /* ccr_mask */
+};
+
+static struct pcmcia_config_entry pcmcia_megahertz_xjem1144_func1_cfe0 = {
+ 0x35, /* cfe number */
+ PCMCIA_CFE_IO8 | PCMCIA_CFE_IRQLEVEL, PCMCIA_IFTYPE_IO,
+ 1, /* num_iospace */
+ 0, /* iomask */
+ { { 0x0008, 0x2f8 } }, /* iospace */
+ 0xffff, /* irqmask */
+ 0, /* num_memspace */
+ { }, /* memspace */
+ 0, /* maxtwins */
+};
+
static struct pcmcia_function pcmcia_sveclancard_func0 = {
0, /* function number */
PCMCIA_FUNCTION_NETWORK,
@@ -112,15 +153,26 @@ static struct pcmcia_config_entry pcmcia_sveclancard_func0_cfe0 = {
};
static struct pcmcia_cis_quirk pcmcia_cis_quirks[] = {
- { PCMCIA_VENDOR_3COM, PCMCIA_PRODUCT_3COM_3CXEM556, PCMCIA_CIS_INVALID,
+ { PCMCIA_VENDOR_3COM, PCMCIA_PRODUCT_3COM_3CXEM556, PCMCIA_CIS_INVALID,
&pcmcia_3cxem556_func0, &pcmcia_3cxem556_func0_cfe0 },
{ PCMCIA_VENDOR_3COM, PCMCIA_PRODUCT_3COM_3CXEM556, PCMCIA_CIS_INVALID,
&pcmcia_3cxem556_func1, &pcmcia_3cxem556_func1_cfe0 },
- { PCMCIA_VENDOR_3COM, PCMCIA_PRODUCT_3COM_3CXEM556B, PCMCIA_CIS_INVALID,
+ { PCMCIA_VENDOR_3COM, PCMCIA_PRODUCT_3COM_3CXEM556B,
+ PCMCIA_CIS_INVALID,
&pcmcia_3cxem556_func0, &pcmcia_3cxem556_func0_cfe0 },
- { PCMCIA_VENDOR_3COM, PCMCIA_PRODUCT_3COM_3CXEM556B, PCMCIA_CIS_INVALID,
+ { PCMCIA_VENDOR_3COM, PCMCIA_PRODUCT_3COM_3CXEM556B,
+ PCMCIA_CIS_INVALID,
&pcmcia_3cxem556_func1, &pcmcia_3cxem556_func1_cfe0 },
- { PCMCIA_VENDOR_INVALID, PCMCIA_PRODUCT_INVALID, PCMCIA_CIS_SVEC_LANCARD,
+ { PCMCIA_VENDOR_MEGAHERTZ2, PCMCIA_PRODUCT_MEGAHERTZ2_XJEM1144,
+ PCMCIA_CIS_INVALID,
+ &pcmcia_megahertz_xjem1144_func0,
+ &pcmcia_megahertz_xjem1144_func0_cfe0 },
+ { PCMCIA_VENDOR_MEGAHERTZ2, PCMCIA_PRODUCT_MEGAHERTZ2_XJEM1144,
+ PCMCIA_CIS_INVALID,
+ &pcmcia_megahertz_xjem1144_func1,
+ &pcmcia_megahertz_xjem1144_func1_cfe0 },
+ { PCMCIA_VENDOR_INVALID, PCMCIA_PRODUCT_INVALID,
+ PCMCIA_CIS_SVEC_LANCARD,
&pcmcia_sveclancard_func0, &pcmcia_sveclancard_func0_cfe0 },
};