From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (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 1B7443955D9 for ; Mon, 1 Jun 2026 09:56:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.92.199 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780307772; cv=none; b=Pbqfwl6/fOlHZ4SV1yTNmVu7oXXIqeE4G5DDzsxhQaHirN/yVz8GpdgjYfbUScHdHD6/WYi+EhYAQGkTOFAoxoV0rhly4/7IDIEtxv7X7kd8XnFE3bwxFHVfuw09RLnu1DgQfINHnX/lMOZzXDtSwp5veuG88l1t744rANlXWXw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780307772; c=relaxed/simple; bh=QDPhTJKgso2Ire1FWeQyRyp329kQlaHBKdj+oUWBnPc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=RHxiSMzBr1gc3HklKBTcTdwX/GwSOGz9ATmnEIdcBEhh19l+j4RZUM9ZHocQLF0H+7Zy3s3a+/qL9G1QWDaAmm+Z8tDHWas2RtS4Eas9FW+IsaVdoXK/4pRLemLMbnjAC3HVH2zZmIxdJ8mGWkY85bxpMR9UZkePhCELavI0kxg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org; spf=pass smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=ktCYaxpp; arc=none smtp.client-ip=90.155.92.199 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="ktCYaxpp" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=ZlMyHu3BbzXPD3yTxJTwuhSJEfIF8/AcS4QYjKsn584=; b=ktCYaxpp58lXdrmnQHlo87Gp1s N6MDXY6IPPxiXE/N3ALh3O6z6PiGKjQd4H7MS/rQU8v45IydRc4GeOVmaZgFnNMVjuNjnAkvpvily IzAW2iLH4R0uw6fqE7OrKnDGnGYYgfyz6swYKwyuJmtdCp02MkrFYN6H2eMhc71DhBRrAzwdoaruh G4Qt8BSpsq82ackG+GgoW+H4sZ4yYQo48X/K+55QQ/HkAdgz6ADpFSqElT9HotGFXzTl5hQNKpCY+ 8PEkRw48oT6ep+1xcpYZNwm7etR0JNyjcp3wnZdpLRb2kV1B4IDvSdWVXc5GUmCNaI95rTo9ELCvS AuuQqy9w==; Received: from 77-249-17-252.cable.dynamic.v4.ziggo.nl ([77.249.17.252] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.99.1 #2 (Red Hat Linux)) id 1wTzNJ-00000006JL6-3shb; Mon, 01 Jun 2026 09:56:02 +0000 Received: by noisy.programming.kicks-ass.net (Postfix, from userid 1000) id 9C602300454; Mon, 01 Jun 2026 11:56:01 +0200 (CEST) Date: Mon, 1 Jun 2026 11:56:01 +0200 From: Peter Zijlstra To: Shrikanth Hegde Cc: Venkat Rao Bagalkote , Madhavan Srinivasan , Mukesh Kumar Chaurasiya , Ritesh Harjani , linuxppc-dev , LKML , Srikar Dronamraju Subject: Re: [linux-next20260529] kernel BUG at kernel/sched/core.c:7512! Message-ID: <20260601095601.GN3102624@noisy.programming.kicks-ass.net> References: <7904105b-9dfa-4efd-a5ef-bc0276ed255d@linux.ibm.com> <2f8c3d75-de2c-48bf-bd05-46b816d55c69@linux.ibm.com> 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-Disposition: inline In-Reply-To: <2f8c3d75-de2c-48bf-bd05-46b816d55c69@linux.ibm.com> On Mon, Jun 01, 2026 at 02:46:24PM +0530, Shrikanth Hegde wrote: > Ritesh, Mukesh, Is below possible scenario? > > do_page_fault seems to enable irq's in the interrupt handler? > is that expected? if so, one might see > > -- do_page_fault (enter kernel mode) > -- enables interrupts > -- gets interrupt - Sets need_resched. > -- irqentry_exit - Sees it is kernel mode. Just checks preempt count > and calls preempt_schedule_irq, which catches both > preempt_count and !irqs_disabled. Hence the panic? > > Should do_page_fault do preempt_disable when it enables the interrupts? No, it is expected for page-fault to be able to schedule. Specifically, it must be able to sleep to support loading pages from disk. Please check the value of preempt_count() (does it perchance have HARDIRQ_OFFSET?). Also, if the fault handler does enable IRQs, it must also disable them again once done. Notably, I see ___do_page_fault() do interrupt_cond_loadl_irq_enable(), but I'm not seeing a local_irq_disable() to match!