1. For each chip, files that include mpu support need to add a
conditional to two included files

#ifdef CONFIG_ARM_MPU
#  include "mpu.h"
#  include "<chip>_mpuinit.h"
#endif

Wouldn't it make more sense to put #ifdef CONFIG_ARM_MPU inside of mpu.h and <chip>_mpuinit.h.  That way, the problem is fixed in one place for all time.

I personally think this is harder to read, but wanted to get other's
opinions.

I agree

Another option would be to remove the inline qualifier and move the functions into a .c file.

Greg



Reply via email to