Re: [PATCH v3 2/2] arm64: Unconditionally override SYM_FUNC macros
From: Will Deacon <will@kernel.org>
Date: 2021-12-14 14:11:58
On Mon, Dec 13, 2021 at 07:21:25PM +0000, Mark Brown wrote:
On Mon, Dec 13, 2021 at 06:46:54PM +0000, Will Deacon wrote:quoted
On Wed, Dec 08, 2021 at 04:08:19PM +0000, Mark Brown wrote:quoted
quoted
--- a/arch/arm64/include/asm/linkage.h +++ b/arch/arm64/include/asm/linkage.h@@ -8,10 +8,18 @@ #define BTI_C bti c ; +#else + +#define BTI_C + +#endifquoted
Why do we need this hunk? Having the hint instruction should be fine, no?We could unconditionally insert the hint but that would be a step back from what we currently have and would mean that hand written assembly would be that little bit worse than what the compiler outputs. If this had been causing us issues I could see simplifying but I'm not aware of any - the issues I'm aware of have been due to not adding the landing pads in SYM_CODE, not SYM_FUNC.
I don't have a strong opinion here, so whatever you like. I just tend to think that most people will have BTI enabled and there's something to be said for having an instruction always emitted when you have a token in assembly code. Will _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel