summaryrefslogtreecommitdiffstats
path: root/sys/pci/pci.c
diff options
context:
space:
mode:
authordg <dg@FreeBSD.org>1995-03-17 04:27:21 +0000
committerdg <dg@FreeBSD.org>1995-03-17 04:27:21 +0000
commitb553215b12e7b5a5694196a76a7eeaaab7c61e4e (patch)
tree70ee5f641c6ef0c9cab22daae6a9b2a8ede50326 /sys/pci/pci.c
parent865b8325a4b6237f192b4c21e221c3c003e8bef1 (diff)
downloadFreeBSD-src-b553215b12e7b5a5694196a76a7eeaaab7c61e4e.zip
FreeBSD-src-b553215b12e7b5a5694196a76a7eeaaab7c61e4e.tar.gz
Added a new field to the pci_device struct called pd_shutdown to specify
a device specific shutdown routine for devconf. Assign the value of this to the kern_devconf struct. Implement a device shutdown routine for if_de that disables the device. This will stop the device from corrupting memory after a reboot.
Diffstat (limited to 'sys/pci/pci.c')
-rw-r--r--sys/pci/pci.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/sys/pci/pci.c b/sys/pci/pci.c
index 377aaa7..aa51596 100644
--- a/sys/pci/pci.c
+++ b/sys/pci/pci.c
@@ -1,6 +1,6 @@
/**************************************************************************
**
-** $Id: pci.c,v 1.17 1995/02/27 17:17:13 se Exp $
+** $Id: pci.c,v 1.18 1995/03/02 21:51:53 se Exp $
**
** General subroutines for the PCI bus on 80*86 systems.
** pci_configure ()
@@ -63,10 +63,6 @@
#include <vm/vm.h>
#include <vm/vm_param.h>
-#include <pci/pcivar.h>
-#include <pci/pcireg.h>
-#include <pci/pcibus.h>
-
#include <machine/pmap.h>
#ifdef __FreeBSD2__
#include <sys/devconf.h>
@@ -91,6 +87,11 @@ extern pmap_t pmap_kernel(void);
static vm_offset_t pmap_mapdev (vm_offset_t paddr, vm_size_t vsize);
#endif /* __FreeBSD2__ */
+#include <pci/pcivar.h>
+#include <pci/pcireg.h>
+#include <pci/pcibus.h>
+
+
/*========================================================
**
@@ -407,6 +408,7 @@ void pci_configure()
pdcp -> pdc_kdc.kdc_parentdata = &pdcp->pdc_pi;
pdcp -> pdc_kdc.kdc_state = DC_UNKNOWN;
pdcp -> pdc_kdc.kdc_description = name;
+ pdcp -> pdc_kdc.kdc_shutdown = dvp->pd_shutdown;
/*
** And register this device
OpenPOWER on IntegriCloud