From 8a7580c3feca1841fe1e418e7368e09cd790a002 Mon Sep 17 00:00:00 2001 From: Poul-Henning Kamp Date: Sun, 16 Jul 1995 10:45:06 +0000 Subject: [PATCH] Reviewed by: phk Submitted by: Andrew McRae Some initial commits from the pcmcia stuff, to make life easier for the testers. We will use the name "pccard" since that is really the buzzword at present. --- sys/amd64/amd64/autoconf.c | 11 ++++++++++- sys/conf/files | 2 ++ sys/i386/i386/autoconf.c | 11 ++++++++++- sys/i386/i386/conf.c | 24 ++++++++++++++++++++---- 4 files changed, 42 insertions(+), 6 deletions(-) diff --git a/sys/amd64/amd64/autoconf.c b/sys/amd64/amd64/autoconf.c index f0648c9f444..96e9a05823a 100644 --- a/sys/amd64/amd64/autoconf.c +++ b/sys/amd64/amd64/autoconf.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * from: @(#)autoconf.c 7.1 (Berkeley) 5/9/91 - * $Id: autoconf.c,v 1.32 1995/05/29 04:08:13 davidg Exp $ + * $Id: autoconf.c,v 1.33 1995/05/30 07:59:14 rgrimes Exp $ */ /* @@ -96,6 +96,11 @@ u_char end_mfs_root[] = "MFS Filesystem had better STOP here"; #include #endif +#include "crd.h" +#if NCRD > 0 +void pccard_configure(); +#endif + #ifdef CD9660 /* We need to try out all our potential CDROM drives, so we need a table. */ static struct { @@ -169,6 +174,10 @@ configure() pci_configure(); #endif +#if NCRD > 0 + pccard_configure(); +#endif + configure_finish(); #ifdef MFS_ROOT diff --git a/sys/conf/files b/sys/conf/files index 19f7e6e1753..79e90f94f55 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -277,6 +277,8 @@ nfs/nfs_subs.c optional nfs nfs/nfs_syscalls.c optional nfs nfs/nfs_vfsops.c optional nfs nfs/nfs_vnops.c optional nfs +pccard/pccard.c optional crd +pccard/pcic.c optional pcic device-driver pci/aic7870.c optional ahc device-driver pci/if_de.c optional de device-driver pci/ncr.c optional ncr device-driver diff --git a/sys/i386/i386/autoconf.c b/sys/i386/i386/autoconf.c index f0648c9f444..96e9a05823a 100644 --- a/sys/i386/i386/autoconf.c +++ b/sys/i386/i386/autoconf.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * from: @(#)autoconf.c 7.1 (Berkeley) 5/9/91 - * $Id: autoconf.c,v 1.32 1995/05/29 04:08:13 davidg Exp $ + * $Id: autoconf.c,v 1.33 1995/05/30 07:59:14 rgrimes Exp $ */ /* @@ -96,6 +96,11 @@ u_char end_mfs_root[] = "MFS Filesystem had better STOP here"; #include #endif +#include "crd.h" +#if NCRD > 0 +void pccard_configure(); +#endif + #ifdef CD9660 /* We need to try out all our potential CDROM drives, so we need a table. */ static struct { @@ -169,6 +174,10 @@ configure() pci_configure(); #endif +#if NCRD > 0 + pccard_configure(); +#endif + configure_finish(); #ifdef MFS_ROOT diff --git a/sys/i386/i386/conf.c b/sys/i386/i386/conf.c index 48011f7663c..3fddb174c85 100644 --- a/sys/i386/i386/conf.c +++ b/sys/i386/i386/conf.c @@ -42,7 +42,7 @@ * SUCH DAMAGE. * * from: @(#)conf.c 5.8 (Berkeley) 5/12/91 - * $Id: conf.c,v 1.85 1995/05/30 07:59:16 rgrimes Exp $ + * $Id: conf.c,v 1.86 1995/07/11 17:20:20 bde Exp $ */ #include @@ -826,6 +826,22 @@ d_ioctl_t gscioctl; #define gscioctl nxioctl #endif +#include "crd.h" +#if NCRD > 0 +d_open_t crdopen; +d_close_t crdclose; +d_rdwr_t crdread, crdwrite; +d_ioctl_t crdioctl; +d_select_t crdselect; +#else +#define crdopen nxopen +#define crdclose nxclose +#define crdread nxread +#define crdwrite nxwrite +#define crdioctl nxioctl + +#endif + #include "joy.h" #if NJOY > 0 d_open_t joyopen; @@ -1178,9 +1194,9 @@ struct cdevsw cdevsw[] = { sscopen, sscclose, sscread, sscwrite, /*49*/ sscioctl, nostop, nullreset, nodevtotty,/* scsi super */ sscselect, sscmmap, sscstrategy }, - { nxopen, nxclose, nxread, nxwrite, /*50*/ - nxioctl, nxstop, nxreset, nodevtotty,/* pcmcia */ - nxselect, nxmmap, NULL }, + { crdopen, crdclose, crdread, crdwrite, /*50*/ + crdioctl, nostop, nullreset, nodevtotty,/* pcmcia */ + crdselect, nommap, NULL }, { joyopen, joyclose, joyread, nowrite, /*51*/ joyioctl, nostop, nullreset, nodevtotty,/*joystick */ seltrue, nommap, NULL},