Received: by 2002:a05:7412:518d:b0:e2:908c:2ebd with SMTP id fn13csp412365rdb; Thu, 5 Oct 2023 09:21:08 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGKeULQpCtazRtGjH27BGYSX88xxpz3xUPzsN5Oa/lBdUKAlN5OwycG8sbWE4vmJILDYlnU X-Received: by 2002:a05:6e02:e47:b0:350:e9c6:e765 with SMTP id l7-20020a056e020e4700b00350e9c6e765mr4554799ilk.11.1696522867893; Thu, 05 Oct 2023 09:21:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696522867; cv=none; d=google.com; s=arc-20160816; b=FrO9/BsqT2rhh4mTRGH1mbsx2gdbMTyQUej3fWyxlPQWHjw4o87CCUPLbB3mg/6UvH 44MdcmTkGgp4NRGjnAoejVrBMnA+o1XblW4vQsFoHgfF7inGz7QbUVPzRB6T6WWd0iMQ BE1D9YpwTQZemVtYx0DmcbqBaW90pekrClug0dmpM0AJsKSrZxL+2lMnAiuUYq1GpRK2 76i9B2wCp3EhNXTdw0vsk6Ye+9t3tvUvJduf6OzhJpC1QfhcORBPzWmBOFgJSPbAj7IT ibx6UPLQghnaFE3RBP18bKqipnPKLoBtZ9I/c6k5CaCJExRB5WRwvM15Adg5MgHUz6+V xGXg== 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-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=2cRZ2Bi8xunGJgKPsOzeO2rgl+a5k7uZl5w//1zAc7Q=; fh=DmUjxPh1QGAIVIZj/64lwRen2dY/N2FtRbmntXi7NiQ=; b=lRclDNu9hd0Mj4t2LhiNj/uulPWC5lqL4etMY/Wa9WW7VdQ7d30OatG6HksYrvXpwV BkS51X6IwwZQzLHAPPQn8xpxD6DuMF/r4u9et6GDdqxCrfieRHfU07EVC1zWq2ilwYjI DsxSln0fpzTMwibXCcDIhefciSW7w/6IbBrPQjt7eISfa251mtyK1SWto+xQyKdYb3Qg Tqi+Pr1OCwbLLp8o0zu4zgJNiY/2QWvRDje5DpU/AHPMMBQJN61pwzGdQREXLxJfibD/ 3eua8I+THuA96SNM4yCysAh8d9f6SXSeKO+l9NiE6ML7II66I/xGvmwOA9NLEK3qPXj2 eAYw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=W4X+yrl3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 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 howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id i193-20020a636dca000000b00578f23273a3si1730337pgc.738.2023.10.05.09.21.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Oct 2023 09:21:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=W4X+yrl3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 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 howler.vger.email (Postfix) with ESMTP id 5C9FD87C01BA; Thu, 5 Oct 2023 09:20:47 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242968AbjJEQTf (ORCPT + 99 others); Thu, 5 Oct 2023 12:19:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34730 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236195AbjJEQP7 (ORCPT ); Thu, 5 Oct 2023 12:15:59 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BBD15101BD for ; Thu, 5 Oct 2023 07:17:31 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 42D04C433B9; Thu, 5 Oct 2023 07:11:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1696489877; bh=waTn81+t3Huf4bgZ5kUKfol0AEwKgZ3Oiqv9It1QBkQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=W4X+yrl3VNwQBRtwJ6EnCHhSp5KYbsNS7UxKXHyRxC3eMeHSU0/9k7++LMd5FilsS zmktcYtPQID4HTz0F/X+ck/MGIGvN3fL4eXHguq6R6vKmyLyn3UH0reAowW53HXVqF 8cFUS3YAxruk578mRI53eE2SRSqWkcMvhvM6ROBg= Date: Thu, 5 Oct 2023 09:11:14 +0200 From: Greg Kroah-Hartman To: Avichal Rakesh Cc: Michael Grzeschik , Laurent Pinchart , Daniel Scally , jchowdhary@google.com, etalvala@google.com, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v1 0/3] usb: gadget: uvc: stability fixes on STREAMOFF. Message-ID: <2023100518-everyday-graves-7404@gregkh> References: <20230930184821.310143-1-arakesh@google.com> <0ccb2c13-438d-4715-af79-d5cf536930cc@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <0ccb2c13-438d-4715-af79-d5cf536930cc@google.com> X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net 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 (howler.vger.email [0.0.0.0]); Thu, 05 Oct 2023 09:20:47 -0700 (PDT) On Tue, Oct 03, 2023 at 04:16:00PM -0700, Avichal Rakesh wrote: > Thank you for testing the patch, Michael! > > On 10/3/23 04:09, Michael Grzeschik wrote: > > Hi > > > > On Sat, Sep 30, 2023 at 11:48:18AM -0700, Avichal Rakesh wrote: > >> We have been seeing two main stability issues that uvc gadget driver > >> runs into when stopping streams: > >> 1. Attempting to queue usb_requests to a disabled usb_ep > >> 2. use-after-free issue for inflight usb_requests > >> > >> The three patches below fix the two issues above. Patch 1/3 fixes the > >> first issue, and Patch 2/3 and 3/3 fix the second issue. > >> > >> Avichal Rakesh (3): > >> ?usb: gadget: uvc: prevent use of disabled endpoint > >> ?usb: gadget: uvc: Allocate uvc_requests one at a time > >> ?usb: gadget: uvc: Fix use-after-free for inflight usb_requests > >> > >> drivers/usb/gadget/function/f_uvc.c???? |? 11 +- > >> drivers/usb/gadget/function/f_uvc.h???? |?? 2 +- > >> drivers/usb/gadget/function/uvc.h?????? |?? 6 +- > >> drivers/usb/gadget/function/uvc_v4l2.c? |? 21 ++- > >> drivers/usb/gadget/function/uvc_video.c | 189 +++++++++++++++++------- > >> 5 files changed, 164 insertions(+), 65 deletions(-) > > > > These patches are not applying on gregkh/usb-testing since > > Greg did take my patches first. I have already rebased them. > > Ah, I didn't realize Greg had picked up your changes in his tree. > Rebased the patches in V2. The "v2" series here is almost impossible to follow, sorry. Please send it as a new thread, not as responses to the individual commits, how am I supposed to pick them up that way? And make it v3 please. thanks, greg k-h