From nobody Wed Oct 05 10:13:41 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Mj9QG0wNHz4dt6c; Wed, 5 Oct 2022 10:13:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Mj9QG0M0Xz3FWd; Wed, 5 Oct 2022 10:13:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1664964822; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=L0Z89EN3SvqVzU7lr8zW6ua2ab5SerHPSuggxz22loM=; b=BMAT7GWkEyrY7crsNcugozesXN2wB9/IpY0Gxj7fl0D75cmxMPJsgw/QWOkcxHUdeQ181W Y2X9aP2PrYSCga7WU8HOcQzkgYj93S2srUWo58HPm7Ma+YMQMdSatYuVX2pdwCq4ROMuLa YC7an7Q+mVjpxQNLpw0D+EqeROdzd2LkTczN1oHuUmwtg6OmX0D2I2IOhcA/H3JjK7xb+0 sLa+0y08R3ppA/mIQ4TuUfAtncuTW1/HQXrIcmwTeOvIwCMK25VfxwX6fZ8U6OW24eM4EF XO4edDoXGORhnJe8dtAmdjO8wS5Bqi5VFVsmwlEKqau7h2b0TiHIPJjjJnl3JA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Mj9QF6W9jzsHd; Wed, 5 Oct 2022 10:13:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 295ADfYa080521; Wed, 5 Oct 2022 10:13:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 295ADf7P080520; Wed, 5 Oct 2022 10:13:41 GMT (envelope-from git) Date: Wed, 5 Oct 2022 10:13:41 GMT Message-Id: <202210051013.295ADf7P080520@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Hans Petter Selasky Subject: git: 55a3bd000d97 - main - usb(4): Make sure the enumeration thread doesn't loop too fast. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: hselasky X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 55a3bd000d9799f431c207e359466484ac63c137 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1664964822; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=L0Z89EN3SvqVzU7lr8zW6ua2ab5SerHPSuggxz22loM=; b=AlrlOFwqGMFgIWXGixkaAM8NSKGag2Vlx4KLnwrANm51q0Ofz804BqoVbBTz1MTNYOKe0w mVDtL7QS4qbc+bbtqFXr0c67y3y6r5qrs8XjJbg6ODCb4XJ8QIDfeOdn+XDnfFEoK8FwHW vrzYKM6ZZo2T/p5eZ8N9HY5w4GLnZmjVw+Nq5WVb8XoEiUxfkxk8KOjuC8HsQGQg8z2Sfa O1Dh18Z10dwM8cWk6JB8mGxCaLNZhjZPZ/xW7zMaFwvkbIbkRt46pZbp/SoxGE/JOKMutw UofJ+/UdKfdqaE2aePAexQCbdTa6axsQPajS5mKUJirLtr3BFjvuhAwDuvx8SA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1664964822; a=rsa-sha256; cv=none; b=Z6ZYYdMoWOrwU9UB5Lb7yUceq3AMNARxUHVS9F3SadUPIad2ukyuTm7U1S02Y5ZNELmjl0 N8tWfagJlCbqrcs86I13bXGQqTzuEzYhPpY7aPIIKHTiPGvE5VJC+aw6U5yjdPsLt5PI9V iydyWlJQC+iZ7KDR5Z3FcbhK8tpXpfF0hdhCwRDmY6DUNc+u7cPDfefkEdKR2sj2Y8VADv JmEf1FUoFRoQq899uIrybx2HYlV6uMXthicfQfb4v7Ejahh4XQNg3kzKvNne9tCw6Kcbkp ZZE4xWVYJNztQZ0UAJb8u6bmQVoY3KS3JaS4sPnBNwCUtSNKfkpNBJO6SKg6hQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by hselasky: URL: https://cgit.FreeBSD.org/src/commit/?id=55a3bd000d9799f431c207e359466484ac63c137 commit 55a3bd000d9799f431c207e359466484ac63c137 Author: Hans Petter Selasky AuthorDate: 2022-06-09 13:15:49 +0000 Commit: Hans Petter Selasky CommitDate: 2022-10-05 10:12:33 +0000 usb(4): Make sure the enumeration thread doesn't loop too fast. MFC after: 1 week Sponsored by: NVIDIA Networking --- sys/dev/usb/controller/usb_controller.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/dev/usb/controller/usb_controller.c b/sys/dev/usb/controller/usb_controller.c index 0897af0492cb..959f54a4583f 100644 --- a/sys/dev/usb/controller/usb_controller.c +++ b/sys/dev/usb/controller/usb_controller.c @@ -414,6 +414,9 @@ usb_bus_explore(struct usb_proc_msg *pm) #if USB_HAVE_ROOT_MOUNT_HOLD usb_root_mount_rel(bus); #endif + + /* Nice the enumeration a bit, to avoid looping too fast. */ + usb_pause_mtx(&bus->bus_mtx, USB_MS_TO_TICKS(16)); } /*------------------------------------------------------------------------*