Source-Changes-D archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src/sys/arch/aarch64/aarch64



On 22/02/2021 10:40, Ryo Shimizu wrote:

Module Name:	src
Committed By:	jmcneill
Date:		Sun Feb 21 23:37:10 UTC 2021

Modified Files:
	src/sys/arch/aarch64/aarch64: idle_machdep.S

Log Message:
When waking from cpu_idle(), only call dosoftints if ci_intr_depth == 0


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/aarch64/aarch64/idle_machdep.S

I think this condition is not necessary since cpu_idle() is just called from idle_loop(),
and ci_intr_depth is always zero at this time.

After thinking about it, I realized that there is no need to even increment intr_depth.

   curcpu()->ci_ntr_depth = 1;
   ARM_IRQ_HANDLER();
   curcpu()->ci_ntr_depth = 0;


In addition, because of the possibility of kpreemption (but aarch64 has no KPREEMPT yet),
the acquisition of curcpu() is moved to after DISABLE_INTERRUPT and got the following.

[snip]



Is this ok?


Looks good - I wonder if the fact that curcpu is an invariant for the
idlelwp helps here too?

Nick


Home | Main Index | Thread Index | Old Index