Received: by 2002:a05:6a10:a852:0:0:0:0 with SMTP id d18csp3727121pxy; Tue, 4 May 2021 08:36:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxRvXRBvNKcx9rQr32ahojf4AVfiHH3IDsn5VlD+Cpo81ejtsBDnV7tvNyTyeeAPshpDEjW X-Received: by 2002:a63:4f50:: with SMTP id p16mr2711763pgl.245.1620142602168; Tue, 04 May 2021 08:36:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620142602; cv=none; d=google.com; s=arc-20160816; b=A/W7iLsbeKxFYgqBkAkoY9Lkno1XD5doLylzjRqjKbKjZituSF7DwVvqpumkuN0sD7 fupTIQaErWionspmqH11S1UDCXoFO5q6aCHFqQ+MAqxrUwE6XTB/w2J0sillkoMf0OzB MxNMOuqsmMm2JQvBK3Iku4Y/SK/R8BGuyj102/1QLaehM0W2VJo+mvSvzByrymM1m6tl vcxd2OLDbZ5lE3UKnj8fmFJMtqG7DxUVdRlnxwJDAvBLZwg3pKrMn06+NDNrcp6px6sK zGPvGyp9yIodZXdFnuC0BteMtE0zF96P4+qKhuBGyvER1IDGr3b03+d7UIZcThHPlo1Z ww7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-language:content-transfer-encoding :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:ironport-sdr:ironport-sdr; bh=mwRenKfGJJHfnAoX0BXRpZhEKJBEZaUP54rKTetvENA=; b=g8O3gElmaqaHv/mqg8IWUk1bnYrt6n/z8Gip00mZZdgReDljkZXzLpZInqLcDdOj6d 3br7GhmUMBGAzQDhj6nsx5N5v9/HJD6EnwRCyjohDzgqha8lNn8Iiw2ynPJXe2tJmmUx wOk4rlSbP/wBB3EZPUjsLfyBjMppnsTm7GvJkfCPOdjZusiLX/3+3+yxtVF8gbvJ+lO9 eKFwxtokuOdr2Y55ij4QnInqJGGg8CqFBYuwFX//2BqHBjtsUgAlAnkGBZZNwN9ZOQ1/ tiy5svjk4kVBiLy4/LI3oiaYEuvGzERx2txKjw1HwbvE7mCdqlwGF/M2i6UGBzvoFU+O SN/g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m3si3726868pgq.343.2021.05.04.08.36.29; Tue, 04 May 2021 08:36:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230447AbhEDPfK (ORCPT + 99 others); Tue, 4 May 2021 11:35:10 -0400 Received: from mga12.intel.com ([192.55.52.136]:63269 "EHLO mga12.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230112AbhEDPfJ (ORCPT ); Tue, 4 May 2021 11:35:09 -0400 IronPort-SDR: c1beQtbq4vXTdqQV4EwhTSx6vCpn53YNaMliRQKMIaf0vsUxfGml1+kMFtsxf3yEgfTqTCWsed k4pejmIYg7GA== X-IronPort-AV: E=McAfee;i="6200,9189,9974"; a="177547955" X-IronPort-AV: E=Sophos;i="5.82,272,1613462400"; d="scan'208";a="177547955" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 May 2021 08:34:14 -0700 IronPort-SDR: KulzZHe3YtLAXjSxtUelZ9opEwFO35+T05pzWl2uTlqinDA3g9oZjpQ2dAIs4byJZf/Ps938c7 Y9T5F6dxvtNA== X-IronPort-AV: E=Sophos;i="5.82,272,1613462400"; d="scan'208";a="463271730" Received: from akleen-mobl1.amr.corp.intel.com (HELO [10.209.47.237]) ([10.209.47.237]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 May 2021 08:34:13 -0700 Subject: Re: [PATCH] stackdepot: Use a raw spinlock in stack depot To: Dmitry Vyukov Cc: LKML , Andrey Ryabinin , Alexander Potapenko , Andrey Konovalov , Peter Zijlstra , Andrew Morton , kasan-dev References: <20210504024358.894950-1-ak@linux.intel.com> From: Andi Kleen Message-ID: <77634a8e-74ab-4e95-530e-c2c46db8baa7@linux.intel.com> Date: Tue, 4 May 2021 08:34:13 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > So why is this a false positive that we just need to silence? > I see LOCKDEP is saying we are doing something wrong, and your > description just describes how we are doing something wrong :) > If this is a special false positive case, it would be good to have a > comment on DEFINE_RAW_SPINLOCK explaining why we are using it. > > I wonder why we never saw this on syzbot. Is it an RT kernel or some > other special config? This happened in a special configuration that triggered ACPI errors at boot time. It's probably not something that is normally executed, as well as syzbot is probably not exercising bootup anyways. > A similar issue was discussed recently for RT kernel: > https://groups.google.com/g/kasan-dev/c/MyHh8ov-ciU/m/nahiuqFLAQAJ > And I think it may be fixable in the same way -- make stackdepot not > allocate in contexts where it's not OK to allocate. Yes that's a good idea. I've seen also other errors about the allocator triggered by stack depot being in the wrong context. Probably doing that would be the right fix. But I actually tried to switch depot to GFP_ATOMIC allocations (from GFP_NOWAIT), but it didn't help, so I'm not fully sure what needs to be changed. -Andi