From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E42C9C433F5 for ; Thu, 2 Dec 2021 10:20:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1356906AbhLBKXb (ORCPT ); Thu, 2 Dec 2021 05:23:31 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35394 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240883AbhLBKX2 (ORCPT ); Thu, 2 Dec 2021 05:23:28 -0500 Received: from mail-oi1-x22a.google.com (mail-oi1-x22a.google.com [IPv6:2607:f8b0:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D59BAC06174A for ; Thu, 2 Dec 2021 02:20:05 -0800 (PST) Received: by mail-oi1-x22a.google.com with SMTP id r26so54458686oiw.5 for ; Thu, 02 Dec 2021 02:20:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=tGFdOsPHZbg5ZrN3mTG563B5p/8mDhvFf9ZIRnX08E0=; b=ZeYS9d2OygJnhsv2FYlogJyJkqhwA4k5l7mBOQWW8i1x3UeuO35zBAtNQbjkFFWONC cPMbhy1GX08aSFaqVkxg3EBWgaNOzkdmct3LgB2zJexHPYNK1up1QNW5dyd9fnlUIp0L b5gcZVG0Dof2IMvsP5RfwDCB0jeNGM1h9GBeydhmb4ytJNikt9Q546XKEUNrZ1qJzmFs JoSbFtYRC3sgohVbSc8R7FFe87ePq8H11NybKRjSJYnRAcTyoadOffN8lS+QZQuMWLSr s+EHRjJL9DVBByHVjTVMjKDVVN/hJzFUPNmzMnC/v/4eJz3hMNMEsAmx5t6PymKv1Wq9 h/hA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=tGFdOsPHZbg5ZrN3mTG563B5p/8mDhvFf9ZIRnX08E0=; b=bc0KRTRulB2fRRfXhasTzOmNB9EkE1NeuK6+gbeL/Cw0DOOMAzT5eWAPeuhRE+Qm2u 0KDvoqd4AxX4MPixQk+Q+4gXZgBIyQB2e/nmh3ZrFHJE1p6TF6j39kvGfprWYCRsLehl EMNmdbSvea27qcXdYjARViIjON/bmKW06593azGyh2gNe/KE5hqvHlG+eixFKc2MUxtU TzQ4J31QDK815PDu9r9lI2Rtf4ZKwKQ6BBogW+jWbfz/Q1W1E5nCx01CCCCJL24aVTpB vHFdYSPp9WcUjGxWwjNyMalf+U95nz5AMnigTnI++KHOg2GO5BTBhLdSFd23/dEaGsHZ bFpA== X-Gm-Message-State: AOAM530uQFf024hi1LMqNzTscxP9LE41sYFuCPrG42hFQUdAnMpqokua Czwjco6pcKeCC57HcIYE8bLqoJfzinhRf92g7fX4CA== X-Google-Smtp-Source: ABdhPJwa1yVCgKcC6MV/TyO3EMTg46+Swe5XhTdhQHJt+UoIGdOS6EqlW08isu7+R5XRSKEGsLWl1rk/kql7xJsZmKM= X-Received: by 2002:aca:af50:: with SMTP id y77mr3803774oie.134.1638440405007; Thu, 02 Dec 2021 02:20:05 -0800 (PST) MIME-Version: 1.0 References: <20211129145732.27000-1-wangkefeng.wang@huawei.com> <811af0bc-0c99-37f6-a39a-095418b10661@huawei.com> In-Reply-To: From: Marco Elver Date: Thu, 2 Dec 2021 11:19:52 +0100 Message-ID: Subject: Re: [PATCH v2] arm64: Enable KCSAN To: Kefeng Wang Cc: Mark Rutland , Catalin Marinas , Will Deacon , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, joey.gouly@arm.com Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2 Dec 2021 at 11:16, Marco Elver wrote: [...] > > Reported by Kernel Concurrency Sanitizer on: > > CPU: 7 PID: 2530 Comm: syz-executor.11 Not tainted 5.10.0+ #113 > > Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.13.0-1ubuntu1.104/01/2014 > > ================================================================== > > BUG: KCSAN: data-race in rwsem_spin_on_owner+0xf4/0x180 > > > > race at unknown origin, with read to 0xffff9767d3becfac of 4 bytes by task 18119 on cpu 0: > > rwsem_spin_on_owner+0xf4/0x180 > > rwsem_optimistic_spin+0x48/0x480 > > rwsem_down_read_slowpath+0x4a0/0x670 > > down_read+0x69/0x190 > > process_vm_rw+0x41e/0x840 > > __x64_sys_process_vm_writev+0x76/0x90 > > do_syscall_64+0x37/0x50 > > entry_SYSCALL_64_after_hwframe+0x44/0xa9 [...] > I actually have a "fix" for the data race in rwsem_spin_on_owner, that > also shows where the other racing access comes from... which reminds me: > https://lkml.kernel.org/r/20211202101238.33546-1-elver@google.com Reading be hard ... that patch is for mutex_spin_on_owner. But the other racing access is the same. Thanks, -- Marco From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 672DAC433F5 for ; Thu, 2 Dec 2021 10:21:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=CcOvZHOgkYjwElQpVRGWmvuwEgX0DkN7tU1j3pzqJKk=; b=aQD3g/sPhZAhRs imWkO8OMmCSbe1AhASxsWWlXAKp0/3UpW7hFefm/OaERidwtkqPscekpOeLu6aLGK1Wt0yG2dqf1s k0T2pwG3wcLPZzTxiJ+QqfF8+f5ernlB0rI9Vdqr068QZTEIUQ3WaI7RjNOlTaRzuuIa0484dHYQs M/MheimKfu8kKs9poOwPwrtwyUI0vqkpKgzEO2lPpUnukq2zqaAAdSxlpugpI0oePpyPV2jP1MxWg mPWMB5c3H4xXhBgjdG+X/SobzdsM5mymTIDg3Y8tWpQxQDN3pgJiLUYzmZaZkK1mH5et8ayLwMGIa crNs5jLe/5JFrT/G8YTA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1msjCF-00Bnqk-Uo; Thu, 02 Dec 2021 10:20:12 +0000 Received: from mail-oi1-x235.google.com ([2607:f8b0:4864:20::235]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1msjCB-00Bnpx-JQ for linux-arm-kernel@lists.infradead.org; Thu, 02 Dec 2021 10:20:09 +0000 Received: by mail-oi1-x235.google.com with SMTP id t23so54533547oiw.3 for ; Thu, 02 Dec 2021 02:20:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=tGFdOsPHZbg5ZrN3mTG563B5p/8mDhvFf9ZIRnX08E0=; b=ZeYS9d2OygJnhsv2FYlogJyJkqhwA4k5l7mBOQWW8i1x3UeuO35zBAtNQbjkFFWONC cPMbhy1GX08aSFaqVkxg3EBWgaNOzkdmct3LgB2zJexHPYNK1up1QNW5dyd9fnlUIp0L b5gcZVG0Dof2IMvsP5RfwDCB0jeNGM1h9GBeydhmb4ytJNikt9Q546XKEUNrZ1qJzmFs JoSbFtYRC3sgohVbSc8R7FFe87ePq8H11NybKRjSJYnRAcTyoadOffN8lS+QZQuMWLSr s+EHRjJL9DVBByHVjTVMjKDVVN/hJzFUPNmzMnC/v/4eJz3hMNMEsAmx5t6PymKv1Wq9 h/hA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=tGFdOsPHZbg5ZrN3mTG563B5p/8mDhvFf9ZIRnX08E0=; b=XFVLxrZ7KSWGwkH4jFD2C13eyKSPaPu0GEC8GG5DA3rc1rZW+NEUjSTE0vowRii6rj ASW99vQ7of2bYXS2ygO/7UhDqqWQttxTipe6/wS6P2+KL+JjtgDj5C7hXRaZ5JS2fiha LYiJrQ/YToHm4GOpFddh67Vcj2yyjiuHDUIKakwVm90J8E2Gph0lSPHSibgHUAB+TFyb j2zT8SQulgtxBeqzxtqOK7Q2rGeAmQeUJCTIr8JSrC6rVFl4XgiocCE0nfvtm3UgOpy6 yWOfy6GjrR8bil5uMfaYxKBcXRgkvDKFtIs6t1UT1OXEmeC1ApLXOUHgOxU928IgWRE2 E9HQ== X-Gm-Message-State: AOAM532fBy1jyX25Rmzie9Te+8CKlzLsVkU2nXxXadpxSsd2IsGaWCHi RnKenoRhnBPXvAs6f8r9PH9uUrSXjuSjTnzlYqzOFw== X-Google-Smtp-Source: ABdhPJwa1yVCgKcC6MV/TyO3EMTg46+Swe5XhTdhQHJt+UoIGdOS6EqlW08isu7+R5XRSKEGsLWl1rk/kql7xJsZmKM= X-Received: by 2002:aca:af50:: with SMTP id y77mr3803774oie.134.1638440405007; Thu, 02 Dec 2021 02:20:05 -0800 (PST) MIME-Version: 1.0 References: <20211129145732.27000-1-wangkefeng.wang@huawei.com> <811af0bc-0c99-37f6-a39a-095418b10661@huawei.com> In-Reply-To: From: Marco Elver Date: Thu, 2 Dec 2021 11:19:52 +0100 Message-ID: Subject: Re: [PATCH v2] arm64: Enable KCSAN To: Kefeng Wang Cc: Mark Rutland , Catalin Marinas , Will Deacon , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, joey.gouly@arm.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211202_022007_673760_823FD1E7 X-CRM114-Status: GOOD ( 11.62 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, 2 Dec 2021 at 11:16, Marco Elver wrote: [...] > > Reported by Kernel Concurrency Sanitizer on: > > CPU: 7 PID: 2530 Comm: syz-executor.11 Not tainted 5.10.0+ #113 > > Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.13.0-1ubuntu1.104/01/2014 > > ================================================================== > > BUG: KCSAN: data-race in rwsem_spin_on_owner+0xf4/0x180 > > > > race at unknown origin, with read to 0xffff9767d3becfac of 4 bytes by task 18119 on cpu 0: > > rwsem_spin_on_owner+0xf4/0x180 > > rwsem_optimistic_spin+0x48/0x480 > > rwsem_down_read_slowpath+0x4a0/0x670 > > down_read+0x69/0x190 > > process_vm_rw+0x41e/0x840 > > __x64_sys_process_vm_writev+0x76/0x90 > > do_syscall_64+0x37/0x50 > > entry_SYSCALL_64_after_hwframe+0x44/0xa9 [...] > I actually have a "fix" for the data race in rwsem_spin_on_owner, that > also shows where the other racing access comes from... which reminds me: > https://lkml.kernel.org/r/20211202101238.33546-1-elver@google.com Reading be hard ... that patch is for mutex_spin_on_owner. But the other racing access is the same. Thanks, -- Marco _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel