Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp4339559rwb; Sun, 13 Nov 2022 04:18:15 -0800 (PST) X-Google-Smtp-Source: AA0mqf7cFo1gRl3NTOCo+6WXQfTPfS3nJ/39hHMoWGGhoBtFJfIW6My8NOT1hbZV2p/w5JI35wPX X-Received: by 2002:a17:902:6ac5:b0:185:5453:5e01 with SMTP id i5-20020a1709026ac500b0018554535e01mr9722464plt.113.1668341895417; Sun, 13 Nov 2022 04:18:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668341895; cv=none; d=google.com; s=arc-20160816; b=Zq/0Wpr3NZh6drtpwBPTXinOts9xcfNLY8OB74GGFNy0oE+19OVkM3z14o6vmvOxNa vEaJcQy19ShbWVhVyMAuFGe/F3RhQ5lxY5y7C42FN0VMw4MxBfHGC7wxJ/P4DWs45DG3 gOSxf+Nm8wrWCKW+mm9P/xKk/EUeYx3br+cK+DLmF0akKzA7yz5Sjdw+m00w9U4lXF0X EwyqHd5X/SHmx2OwiIp6PnEWBRtHjA4oq98yXuM/Q1kLfJtrL+iUn+3g4D6/8Ll+LoA+ 52rHKohIQ4dL3auSo1WZBEPIWkt1dX4plKZCABmZ5ab285cas8GBU5zQWa8djnzJopXb UZug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=zEdIkkHvKR4gk0w43HK5snq1259xyuy3gybMfLvW/jU=; b=mAvdx+OxogO/9JiSNvT4/+qeHSSYsD+ZN38f2ihYxE/R/CDRpO4fjn9gIKTvL0xYNh ESEf02HLxDzFfETvxt/9LAjUJaXbl6ZWT1RhEIBD1TtLW2TfF94TB1NMM7FptHpTe57w RnQ0dAHFKMdjBCjv2BqqHObuvUsi2qJPeNJlMiCfBYMX1MaJGe4pwOErFkmEr+s5hdaH GfXdhkdaF4zc2RepKFaCJeau577oaaUr1271wk/3ysFPb54qOnEk1A9wgsUpbFq4+Ror VFf95lTPQbWN0scLMq2RKuRrK6GFkbajWHUhdIMz1HvgXs81t1GtjgRWCLiqZmkq6qEf gHuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=qFsk+k23; 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 k8-20020a63ff08000000b00470422012f6si7554974pgi.687.2022.11.13.04.18.00; Sun, 13 Nov 2022 04:18:15 -0800 (PST) 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=qFsk+k23; 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 S235299AbiKMLgQ (ORCPT + 90 others); Sun, 13 Nov 2022 06:36:16 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54506 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231252AbiKMLgO (ORCPT ); Sun, 13 Nov 2022 06:36:14 -0500 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 440E81144F; Sun, 13 Nov 2022 03:36:13 -0800 (PST) Received: by mail-wm1-x32a.google.com with SMTP id 5so5498746wmo.1; Sun, 13 Nov 2022 03:36:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=zEdIkkHvKR4gk0w43HK5snq1259xyuy3gybMfLvW/jU=; b=qFsk+k23otSyWR8OV9N0jUvbyfP/DHR7vbI7sW+v9FFuMn5UVHyMXiGDDvtzR1oeWc A1MtxYxQUeNcYyK+jStIBgXVCC6a+/eQjwSDm1jCUjpw1yeTV54MryGZmnHeZ0N8oFIv 1HJhXyvop1bsrcnExO4q0q7C1zeo1BKHna4604/IoTKyzoiz/Frc4qMs3v86Q+eo2iV7 0djE5sHI0PfXrygHfyGbX1gJDJxPkm8PBdV1VjJwIQnyqYmS2DJh9R9vRIeZTkCg5GAZ o+ADsRpZZ2cEFxeTOHPHwJUweZMwlGmz4u+5ze3FsH0JC4/z4PMlejJCTInwztVqXvFq i0rw== 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:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=zEdIkkHvKR4gk0w43HK5snq1259xyuy3gybMfLvW/jU=; b=hRSA7V8BmC8cus3uM1esDWU7RIaDl1Gge5JOC+h1/uERNgu02Is47RtIIZw5nAutEC emaTtuX4z7MX2fsNIDuz5VoLYyND07lcKm3xByC1WMon/M5FLOP+mhgBN/smomPrrVUn UgNtBSYnBz8jZH+X2Ml61K/ylM9Y/zeTLESJzojjqyYp2CGEFGx+sK0X6gwYiUJJuHlR Y3uvlBstw5nkxDUxUXmPQObPSQ+zoHd82Pyk5y4dfWZ4iLor5ZkGotkaN2JQjI3iri6y /I4WJU2LxfV1pnER3+iqlfJxV0LAC6zl043+GLABbWTvt/nKrnc/5fMHXv/QjIn3zpbk p0ng== X-Gm-Message-State: ANoB5pnijEy3nEAjax0PSgXJsqfd9r6KalCPMA2DQ1VKoSwB0oPatnjy zR5ZSVGFaZ0XePHXaLtU6y6fI1RQhZnXSA== X-Received: by 2002:a05:600c:4e4d:b0:3cf:81b1:bc7b with SMTP id e13-20020a05600c4e4d00b003cf81b1bc7bmr5486284wmq.121.1668339371702; Sun, 13 Nov 2022 03:36:11 -0800 (PST) Received: from [89.138.235.186] (89-138-235-186.bb.netvision.net.il. [89.138.235.186]) by smtp.gmail.com with ESMTPSA id z8-20020adfec88000000b00236722ebe66sm6775658wrn.75.2022.11.13.03.36.10 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 13 Nov 2022 03:36:11 -0800 (PST) Message-ID: <100ff22d-8aab-e07a-9aba-0608a05e02a6@gmail.com> Date: Sun, 13 Nov 2022 13:36:08 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.10.0 Subject: Re: [PATCH v2] char: xillybus: Prevent use-after-free due to race condition Content-Language: en-US To: Hyunwoo Kim Cc: gregkh@linuxfoundation.org, arnd@arndb.de, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, stern@rowland.harvard.edu References: <20221030094209.65916-1-eli.billauer@gmail.com> <20221113080558.GA5854@ubuntu> <2a8f59ac-9d49-ffa3-b035-809f2fac38ec@gmail.com> <20221113084740.GA6458@ubuntu> <20221113091415.GA8314@ubuntu> From: Eli Billauer In-Reply-To: <20221113091415.GA8314@ubuntu> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS 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 On 13/11/2022 11:14, Hyunwoo Kim wrote: > > It seems that you only need to move the location of unit_mutex > in xillybus_find_inode(). > Agreed. I'll prepare a follow-up patch to fix this issue as well. Thanks a lot for drawing my attention to this. Eli