diff --git a/sys/conf/files.mips b/sys/conf/files.mips index b19944e5e6a..1a7f7d54a35 100644 --- a/sys/conf/files.mips +++ b/sys/conf/files.mips @@ -50,6 +50,7 @@ mips/mips/vm_machdep.c standard # misc opt-in bits kern/kern_clocksource.c standard kern/link_elf_obj.c standard +kern/subr_atomic64.c optional mips | mipsel | mipshf | mipselhf kern/subr_busdma_bufalloc.c standard kern/subr_dummy_vdso_tc.c standard kern/subr_sfbuf.c optional mips | mipsel | mipsn32 diff --git a/sys/mips/include/atomic.h b/sys/mips/include/atomic.h index 2745b9662ea..ad8abf3498f 100644 --- a/sys/mips/include/atomic.h +++ b/sys/mips/include/atomic.h @@ -38,6 +38,10 @@ #include +#if !defined(__mips_n64) && !defined(__mips_n32) +#include +#endif + /* * Note: All the 64-bit atomic operations are only atomic when running * in 64-bit mode. It is assumed that code compiled for n32 and n64