Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/nick-nhusb]: src/sys/dev/usb Remove tsleep from ulpt(4)



details:   https://anonhg.NetBSD.org/src/rev/d469a6f961cb
branches:  nick-nhusb
changeset: 334610:d469a6f961cb
user:      skrll <skrll%NetBSD.org@localhost>
date:      Sat Jan 28 10:05:09 2017 +0000

description:
Remove tsleep from ulpt(4)

diffstat:

 sys/dev/usb/TODO.usbmp |   3 +--
 sys/dev/usb/ulpt.c     |  10 +++++-----
 2 files changed, 6 insertions(+), 7 deletions(-)

diffs (62 lines):

diff -r 3755a29883ca -r d469a6f961cb sys/dev/usb/TODO.usbmp
--- a/sys/dev/usb/TODO.usbmp    Sat Jan 28 09:43:28 2017 +0000
+++ b/sys/dev/usb/TODO.usbmp    Sat Jan 28 10:05:09 2017 +0000
@@ -1,4 +1,4 @@
-$NetBSD: TODO.usbmp,v 1.8.4.6 2017/01/28 09:43:28 skrll Exp $
+$NetBSD: TODO.usbmp,v 1.8.4.7 2017/01/28 10:05:09 skrll Exp $
 
 
 the majority of the USB MP device interface is documented in usbdivar.h.
@@ -103,7 +103,6 @@
   - udsir.c
   - uirda.c
   - umass_isdata.c
-  - ulpt.c
   - ustir.c
   - uthum.c
   - uyurex.c
diff -r 3755a29883ca -r d469a6f961cb sys/dev/usb/ulpt.c
--- a/sys/dev/usb/ulpt.c        Sat Jan 28 09:43:28 2017 +0000
+++ b/sys/dev/usb/ulpt.c        Sat Jan 28 10:05:09 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ulpt.c,v 1.95.4.11 2016/12/05 10:55:18 skrll Exp $     */
+/*     $NetBSD: ulpt.c,v 1.95.4.12 2017/01/28 10:05:09 skrll Exp $     */
 
 /*
  * Copyright (c) 1998, 2003 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ulpt.c,v 1.95.4.11 2016/12/05 10:55:18 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ulpt.c,v 1.95.4.12 2017/01/28 10:05:09 skrll Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -465,7 +465,7 @@
                }
 
                /* wait 1/4 second, give up if we get a signal */
-               error = tsleep((void *)sc, LPTPRI | PCATCH, "ulptop", STEP);
+               error = kpause("ulptop", true, STEP, NULL);
                if (error != EWOULDBLOCK) {
                        sc->sc_state = 0;
                        goto done;
@@ -704,7 +704,7 @@
                }
 
                /*
-                * XXX Even with the short timeout, this will tsleep,
+                * XXX Even with the short timeout, this will sleep,
                 * but it should be adequately prompt in practice.
                 */
                n = nreq;
@@ -748,7 +748,7 @@
 
                case USBD_INTERRUPTED:
                        /*
-                        * The tsleep in usbd_bulk_transfer was
+                        * The sleep in usbd_bulk_transfer was
                         * interrupted.  Reflect it to the caller so
                         * that reading can be interrupted.
                         */



Home | Main Index | Thread Index | Old Index