[PATCH v3] arm: Fix memory attribute inconsistencies when using fixmap

Russell King - ARM Linux linux at armlinux.org.uk
Wed Apr 5 15:42:45 PDT 2017


On Tue, Apr 04, 2017 at 08:31:27AM +0100, Ard Biesheuvel wrote:
> diff --git a/arch/arm/include/asm/mmu.h b/arch/arm/include/asm/mmu.h
> index a5b47421059d..80dfeb8ce8f2 100644
> --- a/arch/arm/include/asm/mmu.h
> +++ b/arch/arm/include/asm/mmu.h
> @@ -1,6 +1,8 @@
>  #ifndef __ARM_MMU_H
>  #define __ARM_MMU_H
>  
> +struct machine_desc;
> +
>  #ifdef CONFIG_MMU
>  
>  typedef struct {
> @@ -24,6 +26,8 @@ typedef struct {
>  #define ASID(mm)	(0)
>  #endif
>  
> +void early_mm_init(const struct machine_desc *mdesc);
> +
>  #else
>  
>  /*
> @@ -35,6 +39,8 @@ typedef struct {
>  	unsigned long	end_brk;
>  } mm_context_t;
>  
> +static inline void early_mm_init(const struct machine_desc *mdesc) { }
> +

Why are we stuffing this into mmu.h?  mmu.h is not the header file for
arch/arm/mm/mmu.c - although they have the same base filename, they are
not really related.

asm/mmu.h is supposed to be a kernel-wide include file for the mm_context_t
thing, and should not be filled with arch-private stuff.

Please find a better location for this.

-- 
RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
according to speedtest.net.



More information about the linux-arm-kernel mailing list