[arm:ktext 16/19] arch/arm64/mm/ktext.c:96:17: error: implicit declaration of function 'clean_dcache_range_nopatch'

Catalin Marinas catalin.marinas at arm.com
Wed Sep 7 07:22:38 PDT 2022


Hi Russell,

Sorry, holidays and lots of emails to go through.

On Fri, Aug 12, 2022 at 12:46:55PM +0100, Russell King wrote:
> What do you think would be the best way to fix the issue with
> clean_dcache_range_nopatch() in this patch set? I see two possible
> solutions to it:
> 
> 1) duplicate clean_dcache_range_nopatch() in arch/arm64/mm/ktext.c
> 2) make clean_dcache_range_nopatch() globally visible so ktext.c
>    can call it.
> 
> Neither of these feels like a great solution.
> 
> I've thought about moving the code into arch/arm64/kernel/alternative.c
> but that means making other stuff globally visible instead. So it seems
> to be a case of what is the lesser of all the evils.
> 
> The patch can be viewed at:
> http://git.armlinux.org.uk/cgit/linux-arm.git/commit/?h=ktext&id=b8557d9117093ebe17320d36dadd47fc742820c9

I'd prefer the second option above. It's easier to maintain in case we
have to change this function (errata etc.)

You could also pass a function pointer to ktext_replication_* to call
for cache maintenance but I'm not sure it's worth it.

-- 
Catalin



More information about the linux-arm-kernel mailing list