From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 62610421F1E for ; Tue, 16 Jun 2026 09:51:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781603505; cv=none; b=S1JVGeQW8FGbY6DBRHsaSChGDqLzHuLDnESGse1Eg8TH2yFNJr66VGTY50FabwlnQ7ONaKfgmyCvhkyvmtQRxPxse0l5cWxzFObmqqMlvn1FcM/zdq1sMksoNNkBWwk8zIx2OxO6ieX+j/zlMSXbzexm/2qx1SzB8NGlNuLUNgM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781603505; c=relaxed/simple; bh=nNOYqJKg+E9DtF5cabxttmgFZLNw1VZag7YLT39Q2eA=; h=Subject:To:Cc:From:Date:Message-ID:MIME-Version:Content-Type; b=AL5ucy/jaGoUIohgN+nY+pNERvyl0/lqlTUtm+Gv+4uHAMkDvG/lK9gqcRYDD17IvzO11ObxPUwfOehq5YNse4Nqme4DsjFz2d0yAQL/HYOXjSoYoPj9CLu9KC5CDIeZdFokQjXkn0+EmhhZ9x0TRP0ud2OmK3rncQS+r3+VeJE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=OI29wn2G; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="OI29wn2G" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 07A991F00A3A; Tue, 16 Jun 2026 09:51:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1781603504; bh=ShppHeUljh+kOCQ+z4aC/5IYGwqFdmTXYohWq+5vbH8=; h=Subject:To:Cc:From:Date; b=OI29wn2G6WfNBoCQAua/BGmsOOxe0IopFL0p0fai2uO7ALvcdpkmE4MHP9/wnKdtC f/nWiR6viDEAEfyhCo3ZkLsZYb/JUwHYieQwIRcZ6THlxWsbpZ2wdXHBFTgmTadgWr hnQ6x/DK598tCZdZ9yr7VfrpdGdPthhxXZvn84oY= Subject: FAILED: patch "[PATCH] debugobjects: Do not fill_pool() if pi_blocked_on" failed to apply to 5.10-stable tree To: koike@igalia.com,tglx@kernel.org Cc: From: Date: Tue, 16 Jun 2026 15:20:13 +0530 Message-ID: <2026061612-grievance-elm-4367@gregkh> Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit The patch below does not apply to the 5.10-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-5.10.y git checkout FETCH_HEAD git cherry-pick -x 5f41161059fd0f1bbf18c90f3180e38cc45a14eb # git commit -s git send-email --to '' --in-reply-to '2026061612-grievance-elm-4367@gregkh' --subject-prefix 'PATCH 5.10.y' 'HEAD^..' Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From 5f41161059fd0f1bbf18c90f3180e38cc45a14eb Mon Sep 17 00:00:00 2001 From: Helen Koike Date: Mon, 11 May 2026 18:53:05 -0300 Subject: [PATCH] debugobjects: Do not fill_pool() if pi_blocked_on On RT enabled kernels, fill_pool() ends up calling rtlock_lock(), which asserts if current::pi_blocked_on is set, because a task can obviously only block on one lock as otherwise the priority inheritenace chain gets corrupted. Prevent this by expanding the conditional to take current::pi_blocked_on into account. Fixes: 4bedcc28469a ("debugobjects: Make them PREEMPT_RT aware") Reported-by: syzbot+b8ca586b9fc235f0c0df@syzkaller.appspotmail.com Signed-off-by: Helen Koike Signed-off-by: Thomas Gleixner Link: https://patch.msgid.link/20260511215359.3351259-1-koike@igalia.com Closes: https://syzkaller.appspot.com/bug?extid=b8ca586b9fc235f0c0df diff --git a/lib/debugobjects.c b/lib/debugobjects.c index 12e2e42e6a31..772ddabcbe7d 100644 --- a/lib/debugobjects.c +++ b/lib/debugobjects.c @@ -711,6 +711,15 @@ static struct debug_obj *lookup_object_or_alloc(void *addr, struct debug_bucket return NULL; } +static inline bool debug_objects_is_pi_blocked_on(void) +{ +#ifdef CONFIG_RT_MUTEXES + return current->pi_blocked_on != NULL; +#else + return false; +#endif +} + static void debug_objects_fill_pool(void) { if (!static_branch_likely(&obj_cache_enabled)) @@ -727,11 +736,12 @@ static void debug_objects_fill_pool(void) /* * On RT enabled kernels the pool refill must happen in preemptible - * context -- for !RT kernels we rely on the fact that spinlock_t and - * raw_spinlock_t are basically the same type and this lock-type - * inversion works just fine. + * context and not enqueued on an rt_mutex -- for !RT kernels we rely + * on the fact that spinlock_t and raw_spinlock_t are basically the + * same type and this lock-type inversion works just fine. */ - if (!IS_ENABLED(CONFIG_PREEMPT_RT) || preemptible() || system_state < SYSTEM_SCHEDULING) { + if (!IS_ENABLED(CONFIG_PREEMPT_RT) || system_state < SYSTEM_SCHEDULING || + (preemptible() && !debug_objects_is_pi_blocked_on())) { /* * Annotate away the spinlock_t inside raw_spinlock_t warning * by temporarily raising the wait-type to LD_WAIT_CONFIG, matching