[PATCH -next v7 4/7] arm64: entry: Use preempt_count() and need_resched() helper

Ada Couprie Diaz ada.coupriediaz at arm.com
Tue Aug 5 08:06:40 PDT 2025


On 29/07/2025 02:54, Jinjie Ruan wrote:

> The generic entry code uses preempt_count() and need_resched() helpers to
> check if it should do preempt_schedule_irq(). Currently, arm64 use its own
> check logic, that is "READ_ONCE(current_thread_info()->preempt_count == 0",
> which is equivalent to "preempt_count() == 0 && need_resched()".
>
> In preparation for moving arm64 over to the generic entry code, use
> these helpers to replace arm64's own code and move it ahead.
>
> No functional changes.
>
> Signed-off-by: Jinjie Ruan <ruanjinjie at huawei.com>
> ---
Reviewed-by: Ada Couprie Diaz <ada.coupriediaz at arm.com>




More information about the linux-arm-kernel mailing list