Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/usb Simplify activation hook. (sc_dying must die!)
details: https://anonhg.NetBSD.org/src/rev/7df44c2c1b94
branches: trunk
changeset: 748998:7df44c2c1b94
user: dyoung <dyoung%NetBSD.org@localhost>
date: Thu Nov 12 19:53:14 2009 +0000
description:
Simplify activation hook. (sc_dying must die!)
diffstat:
sys/dev/usb/moscom.c | 15 +++++----------
1 files changed, 5 insertions(+), 10 deletions(-)
diffs (41 lines):
diff -r cc66969c2eda -r 7df44c2c1b94 sys/dev/usb/moscom.c
--- a/sys/dev/usb/moscom.c Thu Nov 12 19:52:14 2009 +0000
+++ b/sys/dev/usb/moscom.c Thu Nov 12 19:53:14 2009 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: moscom.c,v 1.2 2009/09/23 19:07:19 plunky Exp $ */
+/* $NetBSD: moscom.c,v 1.3 2009/11/12 19:53:14 dyoung Exp $ */
/* $OpenBSD: moscom.c,v 1.11 2007/10/11 18:33:14 deraadt Exp $ */
/*
@@ -18,7 +18,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: moscom.c,v 1.2 2009/09/23 19:07:19 plunky Exp $");
+__KERNEL_RCSID(0, "$NetBSD: moscom.c,v 1.3 2009/11/12 19:53:14 dyoung Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -300,19 +300,14 @@
moscom_activate(device_t self, enum devact act)
{
struct moscom_softc *sc = device_private(self);
- int rv = 0;
switch (act) {
- case DVACT_ACTIVATE:
- return (EOPNOTSUPP);
-
case DVACT_DEACTIVATE:
- if (sc->sc_subdev != NULL)
- rv = config_deactivate(sc->sc_subdev);
sc->sc_dying = 1;
- break;
+ return 0;
+ default:
+ return EOPNOTSUPP;
}
- return (rv);
}
int
Home |
Main Index |
Thread Index |
Old Index