From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 13372405C5C for ; Mon, 18 May 2026 23:10:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1779145814; cv=none; b=W9UDIOx5F3aBqmaD6vOjoqhVCBIRkJ900me7NQEcbVqpUNaYgBDcZ6KihrfZp/69SEIyggH0zJ4g5Nh/4Rn5ltDS9SDYa0TD18QCZI0NfMtc/aGAYCWUPJM4kb0ahz/GHLwgYG8DRt9p7NiMB12bZV+yK9Pefmh0DMdHyLOiAHc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1779145814; c=relaxed/simple; bh=kFs9cGA5D8Y5A8Mj8dKGofIM8Wn7Nb2XZEFQbOuFPtQ=; h=Date:From:To:Cc:Subject:Message-Id:In-Reply-To:References: Mime-Version:Content-Type; b=S26pDcKQxJgFGYNA9WON27BCS4CtSLIvF2C3CPxkflcr7YcDEgWYgxDd9TtIIFU2nKhkGKf762D6ANuoyzuNp+LPvAPd5wPU/FPu8vHhFJSkyqmpvOmkkK24pAIAU8bOKHiPLDvCEqocp+uBWExH5YPkvbZ4VQzZzwDt2sp7vi0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b=Y7ln+Flb; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="Y7ln+Flb" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 92F88C2BCB7; Mon, 18 May 2026 23:10:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1779145813; bh=kFs9cGA5D8Y5A8Mj8dKGofIM8Wn7Nb2XZEFQbOuFPtQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Y7ln+FlbD4PcqCP5yEbB8+z9u5uBHbtgzePE+vl7CzyYQT84HWwiQ9gFE3LdDE6WW kycw/NZCllnvk1C46CYmm/7XuZd4/1gGAZY+2PMKxUmLlIyJqXgGZsAFZqA5FQ/ybP A4/bo86f6tQGFw3JxCxiqBCw9jBmvbMGP4A9+vLw= Date: Mon, 18 May 2026 16:10:12 -0700 From: Andrew Morton To: "Uladzislau Rezki (Sony)" Cc: linux-mm@kvack.org, Baoquan He , LKML , Ido Schimmel , syzbot+8b12fc6e0fb139765b58@syzkaller.appspotmail.com Subject: Re: [PATCH] mm/vmalloc: Do not trigger BUG() on BH disabled context Message-Id: <20260518161012.6f92f9aca2a4db3776c536e1@linux-foundation.org> In-Reply-To: <20260515153009.2296191-1-urezki@gmail.com> References: <20260515153009.2296191-1-urezki@gmail.com> X-Mailer: Sylpheed 3.8.0beta1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Fri, 15 May 2026 17:30:09 +0200 "Uladzislau Rezki (Sony)" wrote: > __get_vm_area_node() currently triggers a BUG() if in_interrupt() > returns true. However, in_interrupt() also reports true when BH > are disabled. > > The bridge code can call rhashtable_lookup_insert_fast() with > bottom halves disabled: > > __vlan_add() > -> br_fdb_add_local() > spin_lock_bh(&br->hash_lock); <-- Disable BH > -> fdb_add_local() > -> fdb_create() > -> rhashtable_lookup_insert_fast() > -> kvmalloc() > -> vmalloc() > -> __get_vm_area_node() > -> BUG_ON(in_interrupt()) > spin_unlock_bh(&br->hash_lock) > > this triggers the BUG() despite the caller not being in NMI or > hard IRQ context. > > Replace the in_interrupt() check with in_nmi() || in_hardirq(). > > Cc: Ido Schimmel > Fixes: c6307674ed82 ("mm: kvmalloc: add non-blocking support for vmalloc") Was added in 6.19 so I assumed we want cc:stable on this. > Reported-by: syzbot+8b12fc6e0fb139765b58@syzkaller.appspotmail.com > Closes: https://lore.kernel.org/all/69ff8c7c.050a0220.1036b8.000b.GAE@google.com/ > Signed-off-by: Uladzislau Rezki (Sony)