Received: by 2002:a05:6358:bb9e:b0:b9:5105:a5b4 with SMTP id df30csp2000813rwb; Sun, 4 Sep 2022 06:27:49 -0700 (PDT) X-Google-Smtp-Source: AA6agR6XRoveD48eWlMCBl2EyeSGrlw15DsV4oNUmGw7Gng37ypCPLwFglf8BtZPCrsgt77dYflx X-Received: by 2002:a05:6402:449a:b0:442:c81c:b938 with SMTP id er26-20020a056402449a00b00442c81cb938mr40227768edb.289.1662298068942; Sun, 04 Sep 2022 06:27:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662298068; cv=none; d=google.com; s=arc-20160816; b=RRK7ZXKRwwIxzrH1udgVVPMx1ZhG7yO1VMSlPBbs56W77GqGf/R9g525HXmKBUH8sR juoWcqyNiPxLz1FNjXUB3l3yfkY3meyccDjs5saq7aylr9gKF3u0U7fUA47atz4J0nOA 05weCh+d2Oh4NQOiSLJciAxy6EpFZCK0wOfuF+bGU3lDnXXigMlzeR95wOax7TC32op8 0DnW7RiYJGRnoOOApMUzHvAMjDMpV0kQ8+ZOaGQw9eJDhaxMaJ8q8UdLhu0M4osYg3OA 77p3WAP7qyBOSZBymwUo/nsSIOfZoYRX2a3wYXk0+hfS+78lEdlYdeAym9Dhxr5JEVyk XVfQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=zm+EyzwIQUGPDwFnMMoLTrR9COFLYicTA4/koBenuTc=; b=wlF7YlK1EamLszhU+JGa4jUljLn2peERbvT9UJEPKSbwkz2YD+/PCiZHP1fynwYHO0 T9XKiDVSjSYW79SVhYUh8OmKmBGcdmSRvgx10+M5FOqekyMe8rJWYDioTWpMHTdiEqOA Euz8SjNlM9YQ8fFQr9BFTEBLkmyK/RrzT9TXRftKDXlQeIGwYLuwRR6gnENDllua0yVi vS6biCwS3+z8nn1tB/IVj12mSGDbL4BgRDQMkqyNVsygBEF6GJXxTDJfYi6RRXtm/gkn 4ep6mRxSAYSzUl+WSm5AcUz+oWDkN5kirnFXG6bfPyEJ0HoVUjuGZ23mgD64O1wJvC6J pn7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=b6+N4hNr; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l18-20020a170906795200b00722e51021b3si6527612ejo.74.2022.09.04.06.27.23; Sun, 04 Sep 2022 06:27:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=b6+N4hNr; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233768AbiIDNVW (ORCPT + 99 others); Sun, 4 Sep 2022 09:21:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33724 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229748AbiIDNVU (ORCPT ); Sun, 4 Sep 2022 09:21:20 -0400 Received: from mail-vs1-xe2f.google.com (mail-vs1-xe2f.google.com [IPv6:2607:f8b0:4864:20::e2f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B8DEF303E8; Sun, 4 Sep 2022 06:21:19 -0700 (PDT) Received: by mail-vs1-xe2f.google.com with SMTP id k2so6537866vsk.8; Sun, 04 Sep 2022 06:21:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date; bh=zm+EyzwIQUGPDwFnMMoLTrR9COFLYicTA4/koBenuTc=; b=b6+N4hNrgd/gwbt5oOVeNZuwJR+TKHHQTg3dog//QrbCMyNOeDYTfcg02r/phrrZpA WClzq/CZsyp7IOzAaZ4rE2nXfo0mD3g/pt3tz65NSNlW9YHcdQKUZzzMpcwNt+qule/x VxB7mDGI/0TTcjT2rbGmlob/sfViC8FWwISqW5xHsXRFseBwkLWf1vVlhNH8ick5cYUE aT1IcwBnICVufrkheKnZkfsEc2BO0wtsZjvhOGV0bds5H9eCQO0II/hg83uWpC44Q+rH W+WrbCuVfZjvUassAMGNxjHfRTvGnLy1UvHVwjGkZ2vsvQKgkF7OgOf0xFK1+lU6UpC/ 6B5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=zm+EyzwIQUGPDwFnMMoLTrR9COFLYicTA4/koBenuTc=; b=z5AcCMpuLMSAV9GzlYmBGNnoVjZcUKYOiQ8MetqWMHTz7WRUxgqbiz5S9LAZ2Q4lN+ 5pJ//lduH6XqfapUqyTX7UM8XIqrxUQ0vbpbj0LKS7B3BlWquBJYsQaB6Jdvm2eQInBh rJAzDKMkVikdAaIvU0/sO5TVAMqmZ3nNBj8v3fzmrN4JqKpjZtanoFem6I6gSnfy/145 38WWOWcKzAahmop3pGidTriK6EQSA9wkT6rSoj7YCMCB7MKqckhksiEScXGm8EVMFa9v icZcBCrYSMbevTtRI4xd2WJIhRKG/Z+1UYbTlQVKCGhL9m5lmVxY4jjFFWzFY6z4PJey zsOw== X-Gm-Message-State: ACgBeo3I840KxQ46VLWEZO4TnmPLO5Kc1YqWkQahqiyktfhTmcYa+luA CpchoJVZARSboKrYYNeJhriL4MbJehhmG/iGsKgWuFCYLcw1Lg== X-Received: by 2002:a67:d901:0:b0:390:d093:591a with SMTP id t1-20020a67d901000000b00390d093591amr12463484vsj.81.1662297678763; Sun, 04 Sep 2022 06:21:18 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Rondreis Date: Sun, 4 Sep 2022 21:21:07 +0800 Message-ID: Subject: Re: KASAN: use-after-free Read in configfs_composite_bind To: Greg KH Cc: linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE 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 Thanks for your reply! I ran the reproducer again on the master branch(commit id: 7726d4c3e60bfe206738894267414a5f10510f1a) and it didn't crash. The reason for not using the latest version is I can't attach more than one gadget at a time using `configfs` and `dummy_hcd`. When I attach the second gadget with a different `udc` it always fails and the kernel message says: ``` [ 1625.254858] Error: Driver 'configfs-gadget' is already registered, aborting... [ 1625.271018] UDC core: g1: driver registration failed: -16 ``` I'm not sure if this is a new feature from version v5.19(v5.18, commit id: 4b0986a3613c92f4ec1bdc7f60ec66fea135991f works very well) or a potential bug, or my mistake... The kernel config is: https://pastebin.com/raw/SLmNMMRd The shell to attach gadgets is: https://pastebin.com/raw/2eDPNip3 The kernel log is: https://pastebin.com/raw/MaDwMQWk Best wishes! Rondreis