NetBSD Problem Report #48172

From www@NetBSD.org  Sun Sep  1 20:08:50 2013
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	(using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "Postmaster NetBSD.org" (verified OK))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 7AB38705E3
	for <gnats-bugs@gnats.NetBSD.org>; Sun,  1 Sep 2013 20:08:50 +0000 (UTC)
Message-Id: <20130901200848.E88E3705E6@mollari.NetBSD.org>
Date: Sun,  1 Sep 2013 20:08:48 +0000 (UTC)
From: rspmn@arcor.de
Reply-To: rspmn@arcor.de
To: gnats-bugs@NetBSD.org
Subject: u3g(4): add 4G Systems XS Stick W14 support
X-Send-Pr-Version: www-1.0

>Number:         48172
>Category:       kern
>Synopsis:       u3g(4): add 4G Systems XS Stick W14 support
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    kern-bug-people
>State:          closed
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Sun Sep 01 20:10:00 +0000 2013
>Closed-Date:    Sat Sep 07 17:47:10 +0000 2013
>Last-Modified:  Sat Sep 07 17:47:10 +0000 2013
>Originator:     Reinhard Speyerer
>Release:        6.1.1
>Organization:
>Environment:
NetBSD neneh 6.1.1 NetBSD 6.1.1 (GENERIC) i386
>Description:
The XSStick W14 is switched to 3G mode by the u3ginit code but since its
USB PID 0x9603 is not contained in u3g_devs no ucom devices are created for it.

>How-To-Repeat:
Insert the XSStick W14 into a USB port of a system running NetBSD 6.1.1
>Fix:
Proposed patch:

--- u3g.c.~1~	2013-08-31 13:00:18.000000000 +0200
+++ u3g.c	2013-09-01 20:52:33.000000000 +0200
@@ -262,2 +262,3 @@
 	{ USB_VENDOR_4GSYSTEMS, USB_PRODUCT_4GSYSTEMS_XSSTICK_P14 },
+	{ USB_VENDOR_4GSYSTEMS, USB_PRODUCT_4GSYSTEMS_XSSTICK_W14 },
 };
--- usbdevs.~1~	2013-09-01 20:26:25.000000000 +0200
+++ usbdevs	2013-09-01 20:51:52.000000000 +0200
@@ -605,2 +605,3 @@
 /* 4G Systems products */
+product 4GSYSTEMS XSSTICK_W14	0x9603	4G Systems XSStick W14
 product 4GSYSTEMS XSSTICK_P14	0x9605	4G Systems XSStick P14

Lacking a kernel build environment this has only be tested using

perl -e 'undef $/; $_ = <>; s/(\x9e\x1c)\x05\x96/$1\x03\x96/; print $_;' /netbsd > /netbsd-w14 && cmp -l /netbsd /netbsd-w14

After booting /netbsd-w14 ucom devices are created and AT commands
can be sent to the XSStick W14:
...
Sep  1 20:31:18 netbsd /netbsd: u3ginit0 at uhub3 port 5: Switching to 3G mode
Sep  1 20:31:19 netbsd /netbsd: u3ginit0: detached
Sep  1 20:31:19 netbsd /netbsd: u3ginit0: at uhub3 port 5 (addr 3) disconnected
Sep  1 20:31:21 netbsd /netbsd: u3g0 at uhub3 port 5 configuration 1 interface 0
Sep  1 20:31:21 netbsd /netbsd: ucom0 at u3g0 portno 0: 3G Modem
Sep  1 20:31:21 netbsd /netbsd: u3g1 at uhub3 port 5 configuration 1 interface 1
Sep  1 20:31:21 netbsd /netbsd: ucom1 at u3g1 portno 1: 3G Modem
Sep  1 20:31:21 netbsd /netbsd: u3g2 at uhub3 port 5 configuration 1 interface 2
Sep  1 20:31:21 netbsd /netbsd: ucom2 at u3g2 portno 2: 3G Modem
...

netbsd# cu -l /dev/ttyU2 -s 460800
Connected
at+cgmi
4G Systems GmbH & Co. KG

OK
at+cgmm
W14

OK

>Release-Note:

>Audit-Trail:
From: "Christos Zoulas" <christos@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/48172 CVS commit: src/sys/dev/usb
Date: Mon, 2 Sep 2013 03:39:03 -0400

 Module Name:	src
 Committed By:	christos
 Date:		Mon Sep  2 07:39:03 UTC 2013

 Modified Files:
 	src/sys/dev/usb: u3g.c usbdevs

 Log Message:
 PR/48172: Reinhard Speyerer: u3g(4): add 4G Systems XS Stick W14 support


 To generate a diff of this commit:
 cvs rdiff -u -r1.29 -r1.30 src/sys/dev/usb/u3g.c
 cvs rdiff -u -r1.652 -r1.653 src/sys/dev/usb/usbdevs

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

State-Changed-From-To: open->pending-pullups
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Tue, 03 Sep 2013 05:01:11 +0000
State-Changed-Why:
christos committed it; pullup-6 #937


From: "Manuel Bouyer" <bouyer@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/48172 CVS commit: [netbsd-6] src/sys/dev/usb
Date: Sat, 7 Sep 2013 16:22:29 +0000

 Module Name:	src
 Committed By:	bouyer
 Date:		Sat Sep  7 16:22:29 UTC 2013

 Modified Files:
 	src/sys/dev/usb [netbsd-6]: u3g.c usbdevs

 Log Message:
 Pull up following revision(s) (requested by dholland in ticket #937):
 	sys/dev/usb/u3g.c: revision 1.30
 	sys/dev/usb/usbdevs: revision 1.653
 PR/48172: Reinhard Speyerer: u3g(4): add 4G Systems XS Stick W14 support


 To generate a diff of this commit:
 cvs rdiff -u -r1.24.2.1 -r1.24.2.2 src/sys/dev/usb/u3g.c
 cvs rdiff -u -r1.607.2.8 -r1.607.2.9 src/sys/dev/usb/usbdevs

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

State-Changed-From-To: pending-pullups->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sat, 07 Sep 2013 17:47:10 +0000
State-Changed-Why:
fixed and pulled up to -6, thanks


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.