All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Christophe Leroy (CS GROUP)" <chleroy@kernel.org>
To: Aboorva Devarajan <aboorvad@linux.ibm.com>,
	Mukesh Kumar Chaurasiya <mchauras@linux.ibm.com>
Cc: Shrikanth Hegde <sshegde@linux.ibm.com>,
	linux-kernel@vger.kernel.org,
	Ritesh Harjani <ritesh.list@gmail.com>,
	Madhavan Srinivasan <maddy@linux.ibm.com>,
	linuxppc-dev@lists.ozlabs.org
Subject: Re: [PATCH] powerpc/entry: Fix double accounting of user time on interrupt entry
Date: Thu, 3 Sep 2026 06:51:17 +0200	[thread overview]
Message-ID: <8130e76e-931b-415c-bdfb-4e9ae1e39968@kernel.org> (raw)
In-Reply-To: <742182de86c038f6b8a01a6c418469e7f8255595.camel@linux.ibm.com>

Hi Aboorva,

Le 02/09/2026 à 21:44, Aboorva Devarajan a écrit :
> 
> The history is as follows:
> 
> Commit 09a9d3a8499d ("powerpc: introduce arch_enter_from_user_mode")
> introduced the arch_enter_from_user_mode() function with the accounting,
> but the function was not called at that point. Commit 893082ac769b
> ("powerpc: Prepare for IRQ entry exit") introduced arch_interrupt_enter_prepare()
> and copied the accounting from interrupt_enter_prepare() into it, but the
> new helper was not used either. Both changes were preparatory and did not
> change the accounting behavior.
> 
> Commit bee25f97ad24 ("powerpc: Enable GENERIC_ENTRY feature") made both paths
> active. The syscall path removed its open-coded account_cpu_user_entry() and
> started accounting through arch_enter_from_user_mode(). But the interrupt path
> started using arch_interrupt_enter_prepare() followed by irqentry_enter(),
> which also invokes arch_enter_from_user_mode(), while the accounting in
> arch_interrupt_enter_prepare() remained. This resulted in the same user-time
> interval being accounted twice for interrupts taken from user mode.
> 
> I used bee25f97ad24 ("powerpc: Enable GENERIC_ENTRY feature") as the Fixes
> tag because 893082ac769b only introduced the accounting call while
> arch_interrupt_enter_prepare() was unused. bee25f97ad24 is where the duplicate
> accounting actually became functional.
> 
> Would it be ok to keep bee25f97ad24 as the Fixes tag? Please let me know if
> you think 893082ac769b would be more appropriate.

Ok, lets keep bee25f97ad24, I guess a bisect would land here. Anyway 
they all appear for the first time in v7.2

Christophe


  reply	other threads:[~2026-09-03  4:51 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-02  5:06 [PATCH] powerpc/entry: Fix double accounting of user time on interrupt entry Aboorva Devarajan
2026-09-02  5:31 ` Mukesh Kumar Chaurasiya
2026-09-02 17:45   ` Aboorva Devarajan
2026-09-02  5:36 ` Christophe Leroy (CS GROUP)
2026-09-02 19:44   ` Aboorva Devarajan
2026-09-03  4:51     ` Christophe Leroy (CS GROUP) [this message]
2026-09-02  7:07 ` Shrikanth Hegde
2026-09-02 20:14   ` Aboorva Devarajan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8130e76e-931b-415c-bdfb-4e9ae1e39968@kernel.org \
    --to=chleroy@kernel.org \
    --cc=aboorvad@linux.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=maddy@linux.ibm.com \
    --cc=mchauras@linux.ibm.com \
    --cc=ritesh.list@gmail.com \
    --cc=sshegde@linux.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.