Received: by 2002:a05:7412:e79e:b0:f3:1519:9f41 with SMTP id o30csp223970rdd; Wed, 22 Nov 2023 14:07:44 -0800 (PST) X-Google-Smtp-Source: AGHT+IFcGomHoyQRe5RXoaLxL/aX/fdAWOfKGXE6Q55f/YW2EsdmxroSF9hH7ks4HkC5LyI1oTDu X-Received: by 2002:a05:6a20:9e4d:b0:187:9521:92a7 with SMTP id mt13-20020a056a209e4d00b00187952192a7mr4119424pzb.18.1700690864325; Wed, 22 Nov 2023 14:07:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700690864; cv=none; d=google.com; s=arc-20160816; b=qiVl+qj63mcrOzEMOrJQ3aaZAT7mmdA6zPFpB5G2r0Sq0zejTv0zIYLO44wdnCVtiH 0ybzedyuIeIetjnP7pJtZ7unAvBsjddhkXOPVcDjBZJJNP+lCYyEIQt0/bS03BycPRFZ LAOqfwX+FXl5YTeFxLv1h/eRCTR/9j8UZlu9t2Ge4e+yEZkpPfK5dTP0HwhY8kBF+p7Q I753InkblY2VPlvvUuHw68pNgcoNmiRiX+qI9JECi0XIBmCcqJM2WUmSjmUUPLKXYF7V SzrSiG7PcOzeYYzIzKqbMcPvkhLmgUZbu59Cd6VidV4ti5uVdkSmr1xa30C74R5HCUEC 1y4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=PN0Scm/t2jrNVzELlo3wD0Gc8RW2r/3Ec6OpO9OYqpY=; fh=Zga5VTHhzC90FUmOpfzd2goyCSxmB0OOrcN7eFp7WuY=; b=CPW4xy5zwHVcneuSg47QRcuvEQh14a0OpaawilUNqBEorASFoFbuvlbL4Kkz9H+qh5 v9MAxvXzqbRzkLI5Q90R96GCMPOm/YXOkowjNK3AKYRAHVjHe/DnUCmTXiXb25wQ4NT8 GkAG3WKx/TpDfB6xnp8ATU3R5hrfRjENcfmhlrzbotDxiGzWKxJYciwUkJNrV0AxO/93 GzY86jHA0TJviBjNB+3z57pW3O1J9gixH8CtCrddewCqbengPt1RjFi5w8kw3LDDpxwZ IFcHuFGd9aSI94UxhtuzUmNW1+dttxVysYYRI+XehgI5bUTJXqqwTMw6O7e4nOCQqpGx dJxg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kaT6RmOH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id mt4-20020a17090b230400b0027762d380f7si503247pjb.8.2023.11.22.14.07.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Nov 2023 14:07:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kaT6RmOH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 07B038269C6B; Wed, 22 Nov 2023 14:07:28 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231392AbjKVWHV (ORCPT + 99 others); Wed, 22 Nov 2023 17:07:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58858 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229879AbjKVWHU (ORCPT ); Wed, 22 Nov 2023 17:07:20 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 86518B9 for ; Wed, 22 Nov 2023 14:07:17 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DA48BC433C7; Wed, 22 Nov 2023 22:07:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1700690837; bh=879KXznwiWs4VGcvpRH7TOoxpdcEDnzryeA43aJHal4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=kaT6RmOHm1SuksgdO9VhP1QwTnHKvyx8n67Cii1r36lgGYVlDcNxr7FYHE35gVehs xfyobqvZnZlB30qpmihQfFmaGsdPzR6aKL5xVXJGEkB9y3NbQP2QqSHceBd/DIk09b ZrtrBxmS9TGT0BDxUb0y1nFPPuErhcScijaWpyvo= Date: Wed, 22 Nov 2023 22:07:15 +0000 From: Greg KH To: Roy Luo Cc: stern@rowland.harvard.edu, badhri@google.com, quic_kriskura@quicinc.com, francesco.dolcini@toradex.com, quic_eserrao@quicinc.com, ivan.orlov0322@gmail.com, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v1] USB: gadget: core: adjust uevent timing on gadget unbind Message-ID: <2023112253-fresh-blazing-baae@gregkh> References: <20231122220001.539770-1-royluo@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231122220001.539770-1-royluo@google.com> X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Wed, 22 Nov 2023 14:07:28 -0800 (PST) On Wed, Nov 22, 2023 at 10:00:01PM +0000, Roy Luo wrote: > The KOBJ_CHANGE uevent is sent before gadget unbind is actually > executed, resulting in inaccurate uevent emitted at incorrect timing > (the uevent would have USB_UDC_DRIVER variable set while it would > soon be removed). > Move the KOBJ_CHANGE uevent to the end of the unbind function so that > uevent is sent only after the change has been made. > > Signed-off-by: Roy Luo > --- > drivers/usb/gadget/udc/core.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > What commit does this fix?