From owner-freebsd-hackers@freebsd.org Sat Mar 9 10:36:15 2019 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9DD631540E58 for ; Sat, 9 Mar 2019 10:36:15 +0000 (UTC) (envelope-from darius@dons.net.au) Received: from ipmail02.adl2.internode.on.net (ipmail02.adl2.internode.on.net [150.101.137.139]) by mx1.freebsd.org (Postfix) with ESMTP id 3E0308115D for ; Sat, 9 Mar 2019 10:36:11 +0000 (UTC) (envelope-from darius@dons.net.au) Received: from 124-148-131-52.dyn.iinet.net.au (HELO midget.dons.net.au) ([124.148.131.52]) by ipmail02.adl2.internode.on.net with ESMTP; 09 Mar 2019 21:00:56 +1030 Received: from midget.dons.net.au (localhost [127.0.0.1]) by midget.dons.net.au (8.15.2/8.15.2) with ESMTPS id x29AUhwe080338 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Sat, 9 Mar 2019 21:00:52 +1030 (ACDT) (envelope-from darius@dons.net.au) Received: (from mailnull@localhost) by midget.dons.net.au (8.15.2/8.15.2/Submit) id x29ATVuT076664 for ; Sat, 9 Mar 2019 20:59:31 +1030 (ACDT) (envelope-from darius@dons.net.au) X-Authentication-Warning: midget.dons.net.au: mailnull set sender to using -f Received: from [10.0.2.26] ([10.0.2.26]) by ns.dons.net.au (envelope-sender ) (MIMEDefang) with ESMTP id x29ATUqq076662; Sat, 09 Mar 2019 20:59:31 +1030 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 12.2 \(3445.102.3\)) Subject: Re: USB stack getting confused From: "O'Connor, Daniel" In-Reply-To: Date: Sat, 9 Mar 2019 20:59:30 +1030 Cc: FreeBSD Hackers Content-Transfer-Encoding: quoted-printable Message-Id: <3B29D870-41F9-46AF-B9F3-03106DEC417D@dons.net.au> References: To: Hans Petter Selasky X-Mailer: Apple Mail (2.3445.102.3) X-Spam-Score: -1 () No, score=-1.0 required=5.0 tests=ALL_TRUSTED autolearn=unavailable autolearn_force=no version=3.4.1 X-Scanned-By: MIMEDefang 2.83 on 10.0.2.1 X-Rspamd-Queue-Id: 3E0308115D X-Spamd-Bar: ++++ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [4.41 / 15.00]; MV_CASE(0.50)[]; HAS_XAW(0.00)[]; TO_DN_ALL(0.00)[]; MX_GOOD(-0.01)[cached: midget.dons.net.au]; RCPT_COUNT_TWO(0.00)[2]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; RCVD_IN_DNSWL_LOW(-0.10)[139.137.101.150.list.dnswl.org : 127.0.5.1]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:4739, ipnet:150.101.0.0/16, country:AU]; MIME_TRACE(0.00)[0:+]; MID_RHS_MATCH_FROM(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[52.131.148.124.zen.spamhaus.org : 127.0.0.11]; ARC_NA(0.00)[]; RCVD_COUNT_FIVE(0.00)[5]; IP_SCORE(0.27)[ipnet: 150.101.0.0/16(1.06), asn: 4739(0.33), country: AU(-0.04)]; FROM_HAS_DN(0.00)[]; NEURAL_SPAM_SHORT(0.93)[0.931,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; AUTH_NA(1.00)[]; NEURAL_SPAM_MEDIUM(0.90)[0.901,0]; DMARC_NA(0.00)[dons.net.au]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(0.92)[0.916,0]; R_SPF_NA(0.00)[] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 09 Mar 2019 10:36:15 -0000 > On 9 Mar 2019, at 19:30, Hans Petter Selasky wrote: > On 3/9/19 12:08 AM, O'Connor, Daniel wrote: >> My program normally runs continually doing acquisitions of data for N = seconds, doing some checks and restarting. After a while (~30 1 minute = acquisitions or ~8 30 minute ones) my program can't 'see' the device (it = uses libusb10) any more (it reconnects each acquisition for $REASONS). = Also pretty weirdly usbconfig can't see it either(!). >=20 > What is printed in dmesg? Maybe the device has a problem. There is nothing in dmesg - no disconnect / reconnect etc. If I hold the user space process in gdb 'forever' (eg over night) = usbconfig doesn't see the device, but the moment I quit the user space = process it can be seen again. -- Daniel O'Connor "The nice thing about standards is that there are so many of them to choose from." -- Andrew Tanenbaum