CVS commit: [netbsd-5-2] src/sys/dev/mii

2015-11-07 Thread Soren Jacobsen
Module Name:src
Committed By:   snj
Date:   Sat Nov  7 20:37:09 UTC 2015

Modified Files:
src/sys/dev/mii [netbsd-5-2]: atphy.c

Log Message:
Pull up following revision(s) (requested by msaitoh in ticket #1978):
sys/dev/mii/atphy.c: revision 1.17
Fix incorrect argument of mii_anar(). Fixes PR#50206.


To generate a diff of this commit:
cvs rdiff -u -r1.5.2.2 -r1.5.2.2.6.1 src/sys/dev/mii/atphy.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/mii/atphy.c
diff -u src/sys/dev/mii/atphy.c:1.5.2.2 src/sys/dev/mii/atphy.c:1.5.2.2.6.1
--- src/sys/dev/mii/atphy.c:1.5.2.2	Sun May  3 23:45:47 2009
+++ src/sys/dev/mii/atphy.c	Sat Nov  7 20:37:09 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: atphy.c,v 1.5.2.2 2009/05/03 23:45:47 snj Exp $ */
+/*	$NetBSD: atphy.c,v 1.5.2.2.6.1 2015/11/07 20:37:09 snj Exp $ */
 /*	$OpenBSD: atphy.c,v 1.1 2008/09/25 20:47:16 brad Exp $	*/
 
 /*-
@@ -33,7 +33,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: atphy.c,v 1.5.2.2 2009/05/03 23:45:47 snj Exp $");
+__KERNEL_RCSID(0, "$NetBSD: atphy.c,v 1.5.2.2.6.1 2015/11/07 20:37:09 snj Exp $");
 
 #include 
 #include 
@@ -202,7 +202,7 @@ atphy_service(struct mii_softc *sc, stru
 			return EINVAL;
 		}
 
-		anar = mii_anar(ife->ifm_media);
+		anar = mii_anar(IFM_SUBTYPE(ife->ifm_media));
 		if (((ife->ifm_media & IFM_GMASK) & IFM_FDX) != 0) {
 			bmcr |= BMCR_FDX;
 			/* Enable pause. */



CVS commit: [netbsd-5-2] src/sys/dev/usb

2015-02-11 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Wed Feb 11 15:40:12 UTC 2015

Modified Files:
src/sys/dev/usb [netbsd-5-2]: usbdi.c

Log Message:
Pull up following revision(s) (requested by aymeric in ticket #1948):
sys/dev/usb/usbdi.c: revision 1.163
clip xfer-actlen also in the !DIAGNOSTIC case


To generate a diff of this commit:
cvs rdiff -u -r1.124.4.2 -r1.124.4.2.6.1 src/sys/dev/usb/usbdi.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/usbdi.c
diff -u src/sys/dev/usb/usbdi.c:1.124.4.2 src/sys/dev/usb/usbdi.c:1.124.4.2.6.1
--- src/sys/dev/usb/usbdi.c:1.124.4.2	Wed Jan 27 20:56:45 2010
+++ src/sys/dev/usb/usbdi.c	Wed Feb 11 15:40:12 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: usbdi.c,v 1.124.4.2 2010/01/27 20:56:45 sborrill Exp $	*/
+/*	$NetBSD: usbdi.c,v 1.124.4.2.6.1 2015/02/11 15:40:12 martin Exp $	*/
 /*	$FreeBSD: src/sys/dev/usb/usbdi.c,v 1.28 1999/11/17 22:33:49 n_hibma Exp $	*/
 
 /*
@@ -32,7 +32,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: usbdi.c,v 1.124.4.2 2010/01/27 20:56:45 sborrill Exp $);
+__KERNEL_RCSID(0, $NetBSD: usbdi.c,v 1.124.4.2.6.1 2015/02/11 15:40:12 martin Exp $);
 
 #include opt_compat_netbsd.h
 
@@ -773,13 +773,13 @@ usb_transfer_complete(usbd_xfer_handle x
 
 	if (!(xfer-flags  USBD_NO_COPY)  xfer-actlen != 0 
 	usbd_xfer_isread(xfer)) {
-#ifdef DIAGNOSTIC
 		if (xfer-actlen  xfer-length) {
+#ifdef DIAGNOSTIC
 			printf(usb_transfer_complete: actlen  len %d  %d\n,
 			   xfer-actlen, xfer-length);
+#endif
 			xfer-actlen = xfer-length;
 		}
-#endif
 		memcpy(xfer-buffer, KERNADDR(dmap, 0), xfer-actlen);
 	}
 



CVS commit: [netbsd-5-2] src/sys/dev/raidframe

2014-11-20 Thread Stephen Borrill
Module Name:src
Committed By:   sborrill
Date:   Thu Nov 20 12:25:10 UTC 2014

Modified Files:
src/sys/dev/raidframe [netbsd-5-2]: raidframevar.h rf_netbsdkintf.c
rf_reconstruct.c

Log Message:
Pull up the following revisions(s) (requested by oster in ticket #1933):
sys/dev/raidframe/raidframevar.h:   revision 1.17
sys/dev/raidframe/rf_netbsdkintf.c: revision 1.316
sys/dev/raidframe/rf_reconstruct.c: revision 1.121 via patch

Fix a long-standing bug related to rebooting while a reconstruct-to-spare
is underway but not yet complete. Fixes PR kern/49244.


To generate a diff of this commit:
cvs rdiff -u -r1.12.10.3 -r1.12.10.3.2.1 src/sys/dev/raidframe/raidframevar.h
cvs rdiff -u -r1.250.4.13 -r1.250.4.13.2.1 \
src/sys/dev/raidframe/rf_netbsdkintf.c
cvs rdiff -u -r1.105.4.6 -r1.105.4.6.2.1 \
src/sys/dev/raidframe/rf_reconstruct.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/raidframe/raidframevar.h
diff -u src/sys/dev/raidframe/raidframevar.h:1.12.10.3 src/sys/dev/raidframe/raidframevar.h:1.12.10.3.2.1
--- src/sys/dev/raidframe/raidframevar.h:1.12.10.3	Wed Jun 13 14:00:49 2012
+++ src/sys/dev/raidframe/raidframevar.h	Thu Nov 20 12:25:10 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: raidframevar.h,v 1.12.10.3 2012/06/13 14:00:49 sborrill Exp $ */
+/*	$NetBSD: raidframevar.h,v 1.12.10.3.2.1 2014/11/20 12:25:10 sborrill Exp $ */
 /*-
  * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -384,17 +384,17 @@ struct RF_SparetWait_s {
  * IF YOU ADD A STATE, CHECK TO SEE IF YOU NEED TO MODIFY RF_DEAD_DISK().
  */
 enum RF_DiskStatus_e {
-rf_ds_optimal,  /* no problems */
-rf_ds_failed,   /* reconstruction ongoing */
-rf_ds_reconstructing,   /* reconstruction complete to spare, dead disk
- * not yet replaced */
-rf_ds_dist_spared,  /* reconstruction complete to distributed
+	rf_ds_optimal,  /* no problems */
+	rf_ds_failed,   /* disk has failed */
+	rf_ds_reconstructing,   /* reconstruction ongoing */
+	rf_ds_dist_spared,  /* reconstruction complete to distributed
  * spare space, dead disk not yet replaced */
-rf_ds_spared,   /* reconstruction complete to distributed
- * spare space, dead disk not yet replaced */
-rf_ds_spare,/* an available spare disk */
-rf_ds_used_spare/* a spare which has been used, and hence is
+	rf_ds_spared,   /* reconstruction complete, dead disk not 
+   yet replaced */
+	rf_ds_spare,/* an available spare disk */
+	rf_ds_used_spare,   /* a spare which has been used, and hence is
  * not available */
+	rf_ds_rebuilding_spare	/* a spare which is being rebuilt to */
 };
 typedef enum RF_DiskStatus_e RF_DiskStatus_t;
 

Index: src/sys/dev/raidframe/rf_netbsdkintf.c
diff -u src/sys/dev/raidframe/rf_netbsdkintf.c:1.250.4.13 src/sys/dev/raidframe/rf_netbsdkintf.c:1.250.4.13.2.1
--- src/sys/dev/raidframe/rf_netbsdkintf.c:1.250.4.13	Wed Oct 24 03:03:53 2012
+++ src/sys/dev/raidframe/rf_netbsdkintf.c	Thu Nov 20 12:25:10 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: rf_netbsdkintf.c,v 1.250.4.13 2012/10/24 03:03:53 riz Exp $	*/
+/*	$NetBSD: rf_netbsdkintf.c,v 1.250.4.13.2.1 2014/11/20 12:25:10 sborrill Exp $	*/
 /*-
  * Copyright (c) 1996, 1997, 1998, 2008 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -139,7 +139,7 @@
  ***/
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rf_netbsdkintf.c,v 1.250.4.13 2012/10/24 03:03:53 riz Exp $);
+__KERNEL_RCSID(0, $NetBSD: rf_netbsdkintf.c,v 1.250.4.13.2.1 2014/11/20 12:25:10 sborrill Exp $);
 
 #include sys/param.h
 #include sys/errno.h
@@ -1466,6 +1466,10 @@ raidioctl(dev_t dev, u_long cmd, void *d
 		}
 		for (j = d_cfg-cols, i = 0; i  d_cfg-nspares; i++, j++) {
 			d_cfg-spares[i] = raidPtr-Disks[j];
+			if (d_cfg-spares[i].status == rf_ds_rebuilding_spare) {
+/* XXX: raidctl(8) expects to see this as a used spare */
+d_cfg-spares[i].status = rf_ds_used_spare;
+			}
 		}
 		retcode = copyout(d_cfg, *ucfgp, sizeof(RF_DeviceConfig_t));
 		RF_Free(d_cfg, sizeof(RF_DeviceConfig_t));

Index: src/sys/dev/raidframe/rf_reconstruct.c
diff -u src/sys/dev/raidframe/rf_reconstruct.c:1.105.4.6 src/sys/dev/raidframe/rf_reconstruct.c:1.105.4.6.2.1
--- src/sys/dev/raidframe/rf_reconstruct.c:1.105.4.6	Wed Jun 13 14:00:49 2012
+++ src/sys/dev/raidframe/rf_reconstruct.c	Thu Nov 20 12:25:10 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: rf_reconstruct.c,v 1.105.4.6 2012/06/13 14:00:49 sborrill Exp $	*/
+/*	$NetBSD: rf_reconstruct.c,v 1.105.4.6.2.1 2014/11/20 12:25:10 sborrill Exp $	*/
 /*
  * Copyright (c) 1995 Carnegie-Mellon University.
  * All 

CVS commit: [netbsd-5-2] src/sys/dev/pci

2014-08-27 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Wed Aug 27 06:17:06 UTC 2014

Modified Files:
src/sys/dev/pci [netbsd-5-2]: pci_usrreq.c

Log Message:
Pull up following revision(s) (requested by riastradh in ticket #1922):
sys/dev/pci/pci_usrreq.c1.26 via patch

Fix to make pci(4) reject unaligned configuration register reads and writes
before feeding them to a kassert in pci_conf_read/write or to a trap in the
hardware itself.


To generate a diff of this commit:
cvs rdiff -u -r1.16.6.3 -r1.16.6.3.6.1 src/sys/dev/pci/pci_usrreq.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/pci/pci_usrreq.c
diff -u src/sys/dev/pci/pci_usrreq.c:1.16.6.3 src/sys/dev/pci/pci_usrreq.c:1.16.6.3.6.1
--- src/sys/dev/pci/pci_usrreq.c:1.16.6.3	Tue Sep 15 06:48:49 2009
+++ src/sys/dev/pci/pci_usrreq.c	Wed Aug 27 06:17:06 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: pci_usrreq.c,v 1.16.6.3 2009/09/15 06:48:49 snj Exp $	*/
+/*	$NetBSD: pci_usrreq.c,v 1.16.6.3.6.1 2014/08/27 06:17:06 msaitoh Exp $	*/
 
 /*
  * Copyright 2001 Wasabi Systems, Inc.
@@ -40,7 +40,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: pci_usrreq.c,v 1.16.6.3 2009/09/15 06:48:49 snj Exp $);
+__KERNEL_RCSID(0, $NetBSD: pci_usrreq.c,v 1.16.6.3.6.1 2014/08/27 06:17:06 msaitoh Exp $);
 
 #include sys/param.h
 #include sys/conf.h
@@ -83,7 +83,7 @@ pciioctl(dev_t dev, u_long cmd, void *da
 	case PCI_IOC_BDF_CFGREAD:
 	case PCI_IOC_BDF_CFGWRITE:
 		if (bdfr-bus  255 || bdfr-device = sc-sc_maxndevs ||
-		bdfr-function  7)
+		bdfr-function  7 || ISSET(bdfr-cfgreg.reg, 3))
 			return (EINVAL);
 		tag = pci_make_tag(sc-sc_pc, bdfr-bus, bdfr-device,
 		bdfr-function);



CVS commit: [netbsd-5-2] src/sys/dev

2013-06-09 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Sun Jun  9 16:20:29 UTC 2013

Modified Files:
src/sys/dev [netbsd-5-2]: fss.c

Log Message:
Pull up following revision(s) (requested by gdt in ticket #1853):
sys/dev/fss.c: revision 1.84
Take fss_device_lock first when closing a fss device.
Fixes PR kern/47514 (Multiple dump -X triggers kernel panic in fss_ioctl)


To generate a diff of this commit:
cvs rdiff -u -r1.60.4.6 -r1.60.4.6.2.1 src/sys/dev/fss.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/fss.c
diff -u src/sys/dev/fss.c:1.60.4.6 src/sys/dev/fss.c:1.60.4.6.2.1
--- src/sys/dev/fss.c:1.60.4.6	Thu Aug 23 08:59:47 2012
+++ src/sys/dev/fss.c	Sun Jun  9 16:20:29 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: fss.c,v 1.60.4.6 2012/08/23 08:59:47 bouyer Exp $	*/
+/*	$NetBSD: fss.c,v 1.60.4.6.2.1 2013/06/09 16:20:29 msaitoh Exp $	*/
 
 /*-
  * Copyright (c) 2003 The NetBSD Foundation, Inc.
@@ -36,7 +36,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: fss.c,v 1.60.4.6 2012/08/23 08:59:47 bouyer Exp $);
+__KERNEL_RCSID(0, $NetBSD: fss.c,v 1.60.4.6.2.1 2013/06/09 16:20:29 msaitoh Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -221,11 +221,13 @@ fss_close(dev_t dev, int flags, int mode
 	mflag = (mode == S_IFCHR ? FSS_CDEV_OPEN : FSS_BDEV_OPEN);
 	error = 0;
 
+	mutex_enter(fss_device_lock);
 restart:
 	mutex_enter(sc-sc_slock);
 	if ((sc-sc_flags  (FSS_CDEV_OPEN|FSS_BDEV_OPEN)) != mflag) {
 		sc-sc_flags = ~mflag;
 		mutex_exit(sc-sc_slock);
+		mutex_exit(fss_device_lock);
 		return 0;
 	}
 	if ((sc-sc_flags  FSS_ACTIVE) != 0 
@@ -237,12 +239,9 @@ restart:
 	}
 	if ((sc-sc_flags  FSS_ACTIVE) != 0) {
 		mutex_exit(sc-sc_slock);
+		mutex_exit(fss_device_lock);
 		return error;
 	}
-	if (! mutex_tryenter(fss_device_lock)) {
-		mutex_exit(sc-sc_slock);
-		goto restart;
-	}
 
 	KASSERT((sc-sc_flags  FSS_ACTIVE) == 0);
 	KASSERT((sc-sc_flags  (FSS_CDEV_OPEN|FSS_BDEV_OPEN)) == mflag);



CVS commit: [netbsd-5-2] src/sys/dev

2013-01-13 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sun Jan 13 16:13:09 UTC 2013

Modified Files:
src/sys/dev [netbsd-5-2]: lockstat.c

Log Message:
Pull up following revision(s) (requested by msaitoh in ticket #1826):
sys/dev/lockstat.c: revision 1.16
Fix off by one.


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.15.48.1 src/sys/dev/lockstat.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/lockstat.c
diff -u src/sys/dev/lockstat.c:1.15 src/sys/dev/lockstat.c:1.15.48.1
--- src/sys/dev/lockstat.c:1.15	Mon Apr 28 20:23:46 2008
+++ src/sys/dev/lockstat.c	Sun Jan 13 16:13:09 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: lockstat.c,v 1.15 2008/04/28 20:23:46 martin Exp $	*/
+/*	$NetBSD: lockstat.c,v 1.15.48.1 2013/01/13 16:13:09 bouyer Exp $	*/
 
 /*-
  * Copyright (c) 2006, 2007 The NetBSD Foundation, Inc.
@@ -40,7 +40,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: lockstat.c,v 1.15 2008/04/28 20:23:46 martin Exp $);
+__KERNEL_RCSID(0, $NetBSD: lockstat.c,v 1.15.48.1 2013/01/13 16:13:09 bouyer Exp $);
 
 #include sys/types.h
 #include sys/param.h
@@ -270,7 +270,7 @@ lockstat_stop(lsdisable_t *ld)
 
 	cpuno = 0;
 	for (CPU_INFO_FOREACH(cii, ci)) {
-		if (cpuno  sizeof(ld-ld_freq) / sizeof(ld-ld_freq[0])) {
+		if (cpuno = sizeof(ld-ld_freq) / sizeof(ld-ld_freq[0])) {
 			log(LOG_WARNING, lockstat: too many CPUs\n);
 			break;
 		}



CVS commit: [netbsd-5-2] src/sys/dev/raidframe

2013-01-13 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sun Jan 13 16:15:12 UTC 2013

Modified Files:
src/sys/dev/raidframe [netbsd-5-2]: rf_driver.c

Log Message:
Pull up following revision(s) (requested by msaitoh in ticket #1827):
sys/dev/raidframe/rf_driver.c: revision 1.131
Fix off by one read.


To generate a diff of this commit:
cvs rdiff -u -r1.118.10.2 -r1.118.10.2.6.1 src/sys/dev/raidframe/rf_driver.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/raidframe/rf_driver.c
diff -u src/sys/dev/raidframe/rf_driver.c:1.118.10.2 src/sys/dev/raidframe/rf_driver.c:1.118.10.2.6.1
--- src/sys/dev/raidframe/rf_driver.c:1.118.10.2	Thu Dec 10 22:59:16 2009
+++ src/sys/dev/raidframe/rf_driver.c	Sun Jan 13 16:15:12 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: rf_driver.c,v 1.118.10.2 2009/12/10 22:59:16 snj Exp $	*/
+/*	$NetBSD: rf_driver.c,v 1.118.10.2.6.1 2013/01/13 16:15:12 bouyer Exp $	*/
 /*-
  * Copyright (c) 1999 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -66,7 +66,7 @@
 
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rf_driver.c,v 1.118.10.2 2009/12/10 22:59:16 snj Exp $);
+__KERNEL_RCSID(0, $NetBSD: rf_driver.c,v 1.118.10.2.6.1 2013/01/13 16:15:12 bouyer Exp $);
 
 #include opt_raid_diagnostic.h
 
@@ -868,7 +868,7 @@ rf_ConfigureDebug(RF_Config_t *cfgPtr)
 	int i;
 
 	rf_ResetDebugOptions();
-	for (i = 0; cfgPtr-debugVars[i][0]  i  RF_MAXDBGV; i++) {
+	for (i = 0; i  RF_MAXDBGV  cfgPtr-debugVars[i][0]; i++) {
 		name_p = rf_find_non_white(cfgPtr-debugVars[i][0]);
 		white_p = rf_find_white(name_p);	/* skip to start of 2nd
 			 * word */



CVS commit: [netbsd-5-2] src/sys/dev/usb

2013-01-13 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sun Jan 13 16:30:17 UTC 2013

Modified Files:
src/sys/dev/usb [netbsd-5-2]: ubsa_common.c

Log Message:
Pull up following revision(s) (requested by msaitoh in ticket #1830):
sys/dev/usb/ubsa_common.c: revision 1.9
Fix off by one read error.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.4.26.1 src/sys/dev/usb/ubsa_common.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/ubsa_common.c
diff -u src/sys/dev/usb/ubsa_common.c:1.4 src/sys/dev/usb/ubsa_common.c:1.4.26.1
--- src/sys/dev/usb/ubsa_common.c:1.4	Sat May 24 16:40:58 2008
+++ src/sys/dev/usb/ubsa_common.c	Sun Jan 13 16:30:17 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: ubsa_common.c,v 1.4 2008/05/24 16:40:58 cube Exp $	*/
+/*	$NetBSD: ubsa_common.c,v 1.4.26.1 2013/01/13 16:30:17 bouyer Exp $	*/
 /*-
  * Copyright (c) 2002, Alexander Kabaev kan.FreeBSD.org.
  * All rights reserved.
@@ -54,7 +54,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: ubsa_common.c,v 1.4 2008/05/24 16:40:58 cube Exp $);
+__KERNEL_RCSID(0, $NetBSD: ubsa_common.c,v 1.4.26.1 2013/01/13 16:30:17 bouyer Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -112,7 +112,7 @@ ubsa_request(struct ubsa_softc *sc, int 
 	else
 		req.bmRequestType = UT_WRITE_VENDOR_DEVICE;
 
-	if (portno  UBSA_MAXCONN) {
+	if (portno = UBSA_MAXCONN) {
 		printf(%s: ubsa_request: invalid port(%d)#\n,
 			USBDEVNAME(sc-sc_dev), portno);
 		return USBD_INVAL;