diff options
Diffstat (limited to 'sys/dev/pcmcia')
-rw-r--r-- | sys/dev/pcmcia/files.pcmcia | 4 | ||||
-rw-r--r-- | sys/dev/pcmcia/pcmcia.c | 8 | ||||
-rw-r--r-- | sys/dev/pcmcia/pcmciachip.h | 13 |
3 files changed, 20 insertions, 5 deletions
diff --git a/sys/dev/pcmcia/files.pcmcia b/sys/dev/pcmcia/files.pcmcia index a852cbc6322..c54a35d137a 100644 --- a/sys/dev/pcmcia/files.pcmcia +++ b/sys/dev/pcmcia/files.pcmcia @@ -1,4 +1,4 @@ -# $OpenBSD: files.pcmcia,v 1.28 2000/04/03 01:02:00 mickey Exp $ +# $OpenBSD: files.pcmcia,v 1.29 2000/04/08 05:50:51 aaron Exp $ # $NetBSD: files.pcmcia,v 1.9 1998/06/21 18:45:41 christos Exp $ # # Config.new file and device description for machine-independent PCMCIA code. @@ -10,7 +10,7 @@ file dev/pcmcia/pcmcia_cis.c pcmcia file dev/pcmcia/pcmcia_cis_quirks.c pcmcia # device declaration in sys/conf/files -attach pcmcia at pcic +attach pcmcia at pcmciabus # 3Com 3c589 Ethernet, 3c562 multifunction Ethernet, and 3CXEM556 # multifunction Ethernet controllers diff --git a/sys/dev/pcmcia/pcmcia.c b/sys/dev/pcmcia/pcmcia.c index 24d2aefff23..f9b5710d5a0 100644 --- a/sys/dev/pcmcia/pcmcia.c +++ b/sys/dev/pcmcia/pcmcia.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pcmcia.c,v 1.25 2000/02/05 22:10:50 deraadt Exp $ */ +/* $OpenBSD: pcmcia.c,v 1.26 2000/04/08 05:50:51 aaron Exp $ */ /* $NetBSD: pcmcia.c,v 1.9 1998/08/13 02:10:55 eeh Exp $ */ /* @@ -102,6 +102,12 @@ pcmcia_match(parent, match, aux) struct device *parent; void *match, *aux; { + struct cfdata *cf = match; + struct pcmciabus_attach_args *paa = aux; + + if (strcmp(paa->paa_busname, cf->cf_driver->cd_name)) + return 0; + /* If the autoconfiguration got this far, there's a socket here. */ return (1); } diff --git a/sys/dev/pcmcia/pcmciachip.h b/sys/dev/pcmcia/pcmciachip.h index bbe25659f85..65821a53138 100644 --- a/sys/dev/pcmcia/pcmciachip.h +++ b/sys/dev/pcmcia/pcmciachip.h @@ -1,5 +1,5 @@ -/* $OpenBSD: pcmciachip.h,v 1.2 1999/08/08 01:00:14 niklas Exp $ */ -/* $NetBSD: pcmciachip.h,v 1.2 1997/10/16 23:27:36 thorpej Exp $ */ +/* $OpenBSD: pcmciachip.h,v 1.3 2000/04/08 05:50:51 aaron Exp $ */ +/* $NetBSD: pcmciachip.h,v 1.5 2000/01/13 08:58:51 joda Exp $ */ /* * Copyright (c) 1997 Marc Horowitz. All rights reserved. @@ -48,6 +48,11 @@ typedef int pcmcia_mem_handle_t; #define PCMCIA_MEM_ATTR 1 #define PCMCIA_MEM_COMMON 2 +#define PCMCIA_WIDTH_MEM8 8 +#define PCMCIA_WIDTH_MEM16 16 + +#define PCMCIA_WIDTH_MEM_MASK 24 + #define PCMCIA_WIDTH_AUTO 0 #define PCMCIA_WIDTH_IO8 1 #define PCMCIA_WIDTH_IO16 2 @@ -84,6 +89,9 @@ struct pcmcia_chip_functions { /* card enable/disable */ void (*socket_enable) __P((pcmcia_chipset_handle_t)); void (*socket_disable) __P((pcmcia_chipset_handle_t)); + + /* card detection */ + int (*card_detect) __P((pcmcia_chipset_handle_t)); }; /* Memory space functions. */ @@ -130,6 +138,7 @@ struct pcmcia_chip_functions { ((*(tag)->socket_disable)((handle))) struct pcmciabus_attach_args { + char *paa_busname; /* Bus name */ pcmcia_chipset_tag_t pct; pcmcia_chipset_handle_t pch; bus_addr_t iobase; /* start i/o space allocation here */ |