Re: [PATCH v3 00/11] arm64: BTI kernel and vDSO support

Will Deacon
2020-05-07T15:55:34Z

On Thu, May 07, 2020 at 04:48:54PM +0100, Mark Brown wrote:
> On Thu, May 07, 2020 at 04:18:48PM +0100, Will Deacon wrote:
> > On Thu, May 07, 2020 at 04:09:06PM +0100, Mark Brown wrote:
>
> > > Can you share a .config?
>
> > allmodconfig
>
> Right, I'm seeing it here now - it's when CONFIG_GCOV_KERNEL is enabled
> and happens for clang-10 as well but not a GCC 10 prerelease build.

Interesting. Is that because GCC doesn't emit out-of-line GCOV functions,
or does it emit PAC/BTI instructions for them instead? (you can disassemble
one of the problematic opjects to have a look).

> Adding
>
> depends !(CC_IS_CLANG && GCOV_KERNEL)
>
> avoids the warning but obviously we should actually fix the issue.

I can't immediately see how to fix it, so your hack above might be the best
bet for now. I'm just a little wary that it might not be limited to GCOV,
but rather anything where the compiler provides a form of runtime.

Anyway, I'll try your hack and see if I run into any more issues.

Cheers,

Will