Module Name:    src
Committed By:   maya
Date:           Thu Dec 15 17:21:21 UTC 2016

Modified Files:
        src/sys/dev/usb: uftdi.c

Log Message:
allow suspend with uftdi(4). it works fine.


To generate a diff of this commit:
cvs rdiff -u -r1.63 -r1.64 src/sys/dev/usb/uftdi.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/usb/uftdi.c
diff -u src/sys/dev/usb/uftdi.c:1.63 src/sys/dev/usb/uftdi.c:1.64
--- src/sys/dev/usb/uftdi.c:1.63	Fri Nov 25 12:56:29 2016
+++ src/sys/dev/usb/uftdi.c	Thu Dec 15 17:21:21 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: uftdi.c,v 1.63 2016/11/25 12:56:29 skrll Exp $	*/
+/*	$NetBSD: uftdi.c,v 1.64 2016/12/15 17:21:21 maya Exp $	*/
 
 /*
  * Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uftdi.c,v 1.63 2016/11/25 12:56:29 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uftdi.c,v 1.64 2016/12/15 17:21:21 maya Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -341,6 +341,9 @@ uftdi_attach(device_t parent, device_t s
 
 	usbd_add_drv_event(USB_EVENT_DRIVER_ATTACH, sc->sc_udev, sc->sc_dev);
 
+	if (!pmf_device_register(self, NULL, NULL))
+		aprint_error_dev(self, "couldn't establish power handler\n");
+
 	return;
 
 bad:

Reply via email to