From nobody Fri Oct 07 00:27:06 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 4Mk8Jj1kC9z4ds8d; Fri, 7 Oct 2022 00:27:17 +0000 (UTC) (envelope-from koobs.freebsd@gmail.com) Received: from mail-pl1-x629.google.com (mail-pl1-x629.google.com [IPv6:2607:f8b0:4864:20::629]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Mk8Jh43f1z443S; Fri, 7 Oct 2022 00:27:16 +0000 (UTC) (envelope-from koobs.freebsd@gmail.com) Received: by mail-pl1-x629.google.com with SMTP id l1so3124445pld.13; Thu, 06 Oct 2022 17:27:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:reply-to:user-agent:mime-version:date :message-id:sender:from:to:cc:subject:date:message-id:reply-to; bh=E60+zOIz1zpV4y1LEKQwpl6YRl2cUq3MMqUYK6Bg4z4=; b=JX//y4Ia2XffCShkFUuwUYYAGkOpqZFlXAa0OPKSsYx4RM+/5ZEEMJSuprK/mUBeQ3 YIC449BxhGp8Vul6sz7/gr4h6Km4smTVaB8CEHi/Gu1o5rjFzEJmg/Ru48wph42EUdxz emziFfpfgdVcXjOOvi9RRbaMSP48tpYBbjUb6SnD0um5gQ3CdBdcA8oEpT8K8apwNnZ9 mCWymDYyTggZlhwrIFkotIDehq2HoaQnY4RBsP3sols/1TNEXGuyjKp6qzQfFRSa4sRb ejYU4+I+291xk7w+8zQbllIj4X/tn85JsRq9p+PIUn9B+Ix/38QP1jK+PNxsTSJEl/8U O2tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:reply-to:user-agent:mime-version:date :message-id:sender:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=E60+zOIz1zpV4y1LEKQwpl6YRl2cUq3MMqUYK6Bg4z4=; b=zO3iSRfgw1xDsutKeNuc+w1+C91YGGxDr9ISS+Cju5yOzmcU+JJYTdfbaTnef6cHNv azpgz5LTUPkTvzVWAJUMXkpcEDgqOB5W3tfo6DtKAObH0hBiPlg62t4LMZ4BQv4Z4T7S xbFs16KMJvwb+iw3qlBNpUxPN+ReK1vLmNHTvUz9u0llxRGrh8Nwz49byEu0EHPROi9L NT2Gj/UWlurjUzmv5AS4VL18fZrYOnMJoWbklVqHw8SN1Rd7LO5EIhFNuEdC12fPqLSr 405neS4SSzZyH21bHaeYLzPm9wX0iNkPEs4Jjs5C9Iizvr91TNLEDUgoLffsyP3QvEHL Xflw== X-Gm-Message-State: ACrzQf3O9GNk5dfUOimVMFQPqrEbVaZ0b7MphpmC5eZhxZm5jFnKBPws 8m66CvA8mD0tw1o8eM8cTHQgARWWkoc= X-Google-Smtp-Source: AMsMyM4cdkKbm0FTPRhMSR8T+saiyOWX+a3AxIDuNqdJ5DTM4SYWTwahPfFTFgXBNombk8PcCF2ZYA== X-Received: by 2002:a17:902:7295:b0:17d:5176:fe6e with SMTP id d21-20020a170902729500b0017d5176fe6emr2017607pll.147.1665102435148; Thu, 06 Oct 2022 17:27:15 -0700 (PDT) Received: from ?IPV6:2403:5807:1b:1:2918:b74c:8e11:74cd? ([2403:5807:1b:1:2918:b74c:8e11:74cd]) by smtp.gmail.com with ESMTPSA id y15-20020a17090264cf00b0017b224969d6sm223957pli.76.2022.10.06.17.27.12 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 06 Oct 2022 17:27:14 -0700 (PDT) Message-ID: <42ae3a83-bb0b-315c-ddfd-919c109a11d2@FreeBSD.org> Date: Fri, 7 Oct 2022 11:27:06 +1100 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 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:107.0) Gecko/20100101 Thunderbird/107.0a1 Reply-To: koobs@FreeBSD.org Subject: Re: git: 55a3bd000d97 - main - usb(4): Make sure the enumeration thread doesn't loop too fast. Content-Language: en-US To: Hans Petter Selasky , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202210051013.295ADf7P080520@gitrepo.freebsd.org> From: Kubilay Kocak In-Reply-To: <202210051013.295ADf7P080520@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4Mk8Jh43f1z443S X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20210112 header.b="JX//y4Ia"; dmarc=none; spf=pass (mx1.freebsd.org: domain of koobs.freebsd@gmail.com designates 2607:f8b0:4864:20::629 as permitted sender) smtp.mailfrom=koobs.freebsd@gmail.com X-Spamd-Result: default: False [-3.17 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.97)[-0.965]; FORGED_SENDER(0.30)[koobs@FreeBSD.org,koobsfreebsd@gmail.com]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20210112]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36:c]; MIME_GOOD(-0.10)[text/plain]; FROM_NEQ_ENVFROM(0.00)[koobs@FreeBSD.org,koobsfreebsd@gmail.com]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; HAS_REPLYTO(0.00)[koobs@FreeBSD.org]; DMARC_NA(0.00)[freebsd.org]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; ARC_NA(0.00)[]; TAGGED_FROM(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::629:from]; REPLYTO_ADDR_EQ_FROM(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; TO_DN_SOME(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; DKIM_TRACE(0.00)[gmail.com:+]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FREEMAIL_ENVFROM(0.00)[gmail.com]; MLMMJ_DEST(0.00)[dev-commits-src-all@freebsd.org,dev-commits-src-main@freebsd.org] X-ThisMailContainsUnwantedMimeParts: N On 5/10/2022 9:13 pm, Hans Petter Selasky wrote: > 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)); > } > > /*------------------------------------------------------------------------* > Is it possible to sysctl (ideally runtime tunable) this setting?