diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2010-08-31 17:13:49 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2010-08-31 17:13:49 +0000 |
commit | 9da4ff9be0005fda5ba6d021ccff292caaca62f6 (patch) | |
tree | b3bdf7cd5c66003daeb0f71ac899d004c887677e /sys/dev/pci/if_em.c | |
parent | f4451ac9824b3e8c645bc2be6cfca6659bf11fcc (diff) |
Add DVACT_QUIECE support. This is called before splhigh() and before
DVACT_SUSPEND, therefore DVACT_QUIECE can do standard sleeping operations
to get ready.
Discussed quite a while back with kettenis and jakemsr, oga suddenly needed
it as well and wrote half of it, so it was time to finish it.
proofread by miod.
Diffstat (limited to 'sys/dev/pci/if_em.c')
-rw-r--r-- | sys/dev/pci/if_em.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/dev/pci/if_em.c b/sys/dev/pci/if_em.c index afc810ed9c7..10991235aed 100644 --- a/sys/dev/pci/if_em.c +++ b/sys/dev/pci/if_em.c @@ -31,7 +31,7 @@ POSSIBILITY OF SUCH DAMAGE. ***************************************************************************/ -/* $OpenBSD: if_em.c,v 1.245 2010/08/27 15:56:09 deraadt Exp $ */ +/* $OpenBSD: if_em.c,v 1.246 2010/08/31 17:13:44 deraadt Exp $ */ /* $FreeBSD: if_em.c,v 1.46 2004/09/29 18:28:28 mlaier Exp $ */ #include <dev/pci/if_em.h> @@ -1880,6 +1880,9 @@ em_activate(struct device *self, int act) int rv = 0; switch (act) { + case DVACT_QUIESCE: + rv = config_activate_children(self, act); + break; case DVACT_SUSPEND: if (ifp->if_flags & IFF_RUNNING) em_stop(sc, 0); @@ -1892,7 +1895,7 @@ em_activate(struct device *self, int act) em_init(sc); break; } - return rv; + return (rv); } void |