# Re: \[PATCH v2 06/19\] arm64: entry: add a call\_on\_irq\_stack helper

- From: Mark Rutland \<mark.rutland@arm.com\>
- Date: 2021-05-19 14:48:31 
- List: linux-arm-kernel
- Page: https://ratatoskr.run/linux-arm-kernel/2021/05/8807306
- Thread: https://ratatoskr.run/linux-arm-kernel/2021/05/8807285/t.md

```text
On Wed, May 19, 2021 at 01:38:49PM +0100, Mark Rutland wrote:
> +/*
> + * void call_on_irq_stack(struct pt_regs *regs,
> + * 		          void (*func)(struct pt_regs *));
> + *
> + * Calls func(regs) using this CPU's irq stack and shadow irq stack.
> + */
> +SYM_FUNC_START(call_on_irq_stack)
> +#ifdef CONFIG_SHADOW_CALL_STACK
> +	stp	scs_sp, xzr, [sp, #-16]!
> +	adr_this_cpu scs_sp, irq_shadow_call_stack, x17

The Kbuild test robot spotted this was leading to a link failure, since
`irq_shadow_call_stack` does not exist. I've updated this to:

	ldr_this_cpu scs_sp, irq_shadow_call_stack_ptr, x17

... which matches how irq_stack_entry acquires the shadow stack pointer
today (and passes a boot test).

Thanks,
Mark.

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
```
