Received: by 2002:a05:6520:4211:b029:f4:110d:56bc with SMTP id o17csp1585243lkv; Wed, 19 May 2021 13:23:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyIMOCEJMTlc6xd1xdVxoL2OlskqJzuIpuNWmLaMfn0mNpjSABkF9dik7uLLHcRWkS2Yq+J X-Received: by 2002:a6b:f60e:: with SMTP id n14mr1485148ioh.179.1621455832728; Wed, 19 May 2021 13:23:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621455832; cv=none; d=google.com; s=arc-20160816; b=pG4X8EhrWHraK572y3LCwBa4C4sfCNb6D9cjoXPixJUmU5EHIPfEQ8+KsFrEpueoML AOmHfgE2PDEJYllNvsgypKCzOcDs9C7M9XY8USIbIVUM9GHS1mmZBrKezhC0XdZj7f6N CczRLpDkSrNK/qx+tolXEUMXSMoJ82DsFVliU9fGqXjinCxO+rE6pBGXlVyji/wgWorx 9FeUZPuE3y0OtVKNpP83hD2ru0QwfwkKtADYYzgmtTIpaKN+3dG0QzXXbA5xSx7PUXt8 8cgVHTHdbo6QHZNOoMxpTj+amyLCrEyC0L8ZzCW/iOY1nQAhYPgMgxefbiRVG2AfAeH8 roKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=pa6BrMj2NYTUx+FQfaM5GghsBa5Z3C6LhlWK7oeSwIQ=; b=GejAnggn4N5klgM18CH6s0QOYS56sdeQTsEl4Yo5eG6WpWnKvJrkBfrL+M3uILdeS8 nZQYk60WcuythFokv96TswW3Zzur5IsNkyZVWstP+CUgv9KHzO0hUJa+mlnwW1UMi13C rqelJejH+14tR/5CTigfsEK4qraa1O8ofi8T7M4AY1n/NI2Tmk1h3SR4ieAS2QG/MnyF XKGDakmp8L5JxBKs7C7Zr4ad3IIK/uNrPdJOXl2yTi8iv9b6qAq6SMnkyTIFFk/NZ2gc KoPJoFg/OWm0WCGs/h9b1CzdWRGkPUv1WJWUbVlBDHWAIFAX8mVjov1KbJHuLblJMHxR P60g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=CZmwYV3j; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 16si353163iou.15.2021.05.19.13.23.39; Wed, 19 May 2021 13:23:52 -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; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=CZmwYV3j; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232432AbhEST71 (ORCPT + 99 others); Wed, 19 May 2021 15:59:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60000 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232333AbhEST70 (ORCPT ); Wed, 19 May 2021 15:59:26 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C6334C06175F; Wed, 19 May 2021 12:58:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To: Subject:Sender:Reply-To:Content-ID:Content-Description; bh=pa6BrMj2NYTUx+FQfaM5GghsBa5Z3C6LhlWK7oeSwIQ=; b=CZmwYV3jYiu3u0QlcRAzcgEYp6 N70ofExUBfFF1kwX1ipFzqpMyNGFnVPdiIvNBX2RaByyNGtsyQLk5GMGgB9+JWslTH6SmFTM3yHty 3zvHdENLmlK1Mb9rPy4qYAuKRRMX63GFMGjnGlN28JXX7oTwMpK92hkCp8O8RBaMMs6+wz0Njge8m A6B/mGSWKhyjhnrQ1SvZT14sQWAJoP5aJ+hasMUL07tBlbP8vUWujWFQ1Gwghl2HhebyRezgKhiMW 6Nbz+I/HWUOeReYO64FxZZGh3DQReLpnehy6prRR+2T22B4xPr7pMyATUFTU1qb8PfN/lrxnLhNqt DH+NzPPQ==; Received: from [2601:1c0:6280:3f0::7376] by bombadil.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1ljSKO-00Fklp-OW; Wed, 19 May 2021 19:58:00 +0000 Subject: Re: [syzbot] BUG: MAX_LOCKDEP_KEYS too low! (2) To: Dmitry Vyukov , syzbot , Peter Zijlstra , Tetsuo Handa Cc: "Jason A. Donenfeld" , David Miller , Jakub Kicinski , LKML , netdev , syzkaller-bugs , WireGuard mailing list References: <0000000000003687bd05c2b2401d@google.com> From: Randy Dunlap Message-ID: Date: Wed, 19 May 2021 12:57:58 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/19/21 12:48 PM, Dmitry Vyukov wrote: > On Wed, May 19, 2021 at 7:35 PM syzbot > wrote: >> >> Hello, >> >> syzbot found the following issue on: >> >> HEAD commit: b81ac784 net: cdc_eem: fix URL to CDC EEM 1.0 spec >> git tree: net >> console output: https://syzkaller.appspot.com/x/log.txt?x=15a257c3d00000 >> kernel config: https://syzkaller.appspot.com/x/.config?x=5b86a12e0d1933b5 >> dashboard link: https://syzkaller.appspot.com/bug?extid=a70a6358abd2c3f9550f >> >> Unfortunately, I don't have any reproducer for this issue yet. >> >> IMPORTANT: if you fix the issue, please add the following tag to the commit: >> Reported-by: syzbot+a70a6358abd2c3f9550f@syzkaller.appspotmail.com >> >> BUG: MAX_LOCKDEP_KEYS too low! > include/linux/lockdep.h #define MAX_LOCKDEP_KEYS_BITS 13 #define MAX_LOCKDEP_KEYS (1UL << MAX_LOCKDEP_KEYS_BITS) Documentation/locking/lockdep-design.rst: Troubleshooting: ---------------- The validator tracks a maximum of MAX_LOCKDEP_KEYS number of lock classes. Exceeding this number will trigger the following lockdep warning:: (DEBUG_LOCKS_WARN_ON(id >= MAX_LOCKDEP_KEYS)) By default, MAX_LOCKDEP_KEYS is currently set to 8191, and typical desktop systems have less than 1,000 lock classes, so this warning normally results from lock-class leakage or failure to properly initialize locks. These two problems are illustrated below: > > What config controls this? I don't see "MAX_LOCKDEP_KEYS too low" in > any of the config descriptions... > Here is what syzbot used: > > CONFIG_LOCKDEP=y > CONFIG_LOCKDEP_BITS=16 > CONFIG_LOCKDEP_CHAINS_BITS=17 > CONFIG_LOCKDEP_STACK_TRACE_BITS=20 > CONFIG_LOCKDEP_STACK_TRACE_HASH_BITS=14 > CONFIG_LOCKDEP_CIRCULAR_QUEUE_BITS=12 > > We already bumped most of these. > The log contains dump of the lockdep debug files, is there any offender? > > Also looking at the log I noticed a memory safety bug in lockdep implementation: ... -- ~Randy