diff options
author | phk <phk@FreeBSD.org> | 1997-04-20 07:21:12 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1997-04-20 07:21:12 +0000 |
commit | 8f01634fd18fbc0abdbe3f2186b89f67998ffd0f (patch) | |
tree | daa98ba282f80feba3d6e385196c44b71e398a79 /sys/pccard/pccard.c | |
parent | 1be613d0b3ea5dd90581c66eab4a08a0f51a12d8 (diff) | |
download | FreeBSD-src-8f01634fd18fbc0abdbe3f2186b89f67998ffd0f.zip FreeBSD-src-8f01634fd18fbc0abdbe3f2186b89f67998ffd0f.tar.gz |
1. i82365.h: Chip identifiers should not be #ifdef PC98. Add identifier
(pt. unused) for TI PCI1130.
2. pccard.c: PCIC_RESUME_RESET is now (also) a sysctl. (Never make it
a #ifdef if it can be made a sysctl!)
3. pcic.c: make getb() and putb() proper member functions of struct
pcic_slot. Add a couple of missing casts.
Diffstat (limited to 'sys/pccard/pccard.c')
-rw-r--r-- | sys/pccard/pccard.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/sys/pccard/pccard.c b/sys/pccard/pccard.c index 17a9757..541b4af 100644 --- a/sys/pccard/pccard.c +++ b/sys/pccard/pccard.c @@ -35,6 +35,7 @@ #include <sys/fcntl.h> #include <sys/proc.h> #include <sys/malloc.h> +#include <sys/sysctl.h> #include <sys/conf.h> #ifdef DEVFS #include <sys/devfsext.h> @@ -56,6 +57,17 @@ #include <machine/clock.h> #include <machine/md_var.h> +SYSCTL_NODE(_machdep, OID_AUTO, pccard, CTLFLAG_RW, 0, "pccard"); + +static int pcic_resume_reset = +#ifdef PCIC_RESUME_RESET + 1; +#else + 0; +#endif + +SYSCTL_INT(_machdep_pccard, OID_AUTO, pcic_resume_reset, CTLFLAG_RW, + &pcic_resume_reset, 0, ""); #define PCCARD_MEMSIZE (4*1024) @@ -344,9 +356,8 @@ slot_resume(void *arg) struct slot *sp = arg; struct pccard_dev *dp; -#ifdef PCIC_RESUME_RESET - sp->ctrl->resume(sp); -#endif + if (pcic_resume_reset) + sp->ctrl->resume(sp); if (!sp->suspend_power) sp->ctrl->power(sp); |