# SPDX-License-Identifier: GPL-2.0
#
# Makefile for the Linux/MIPS kernel.
#
extra-y := head.o vmlinux.lds
obj-y += cmpxchg.o cpu-probe.o branch.o elf.o entry.o genex.o idle.o irq.o \
process.o prom.o ptrace.o reset.o setup.o signal.o \
syscall.o time.o topology.o traps.o unaligned.o watch.o \
vdso.o cacheinfo.o
ifdef [31mCONFIG_FUNCTION_TRACER[0m
CFLAGS_REMOVE_ftrace.o = -pg
CFLAGS_REMOVE_early_printk.o = -pg
CFLAGS_REMOVE_perf_event.o = -pg
CFLAGS_REMOVE_perf_event_mipsxx.o = -pg
endif
obj-$([31mCONFIG_CEVT_BCM1480[0m) += cevt-bcm1480.o
obj-$([31mCONFIG_CEVT_R4K[0m) += cevt-r4k.o
obj-$([31mCONFIG_CEVT_DS1287[0m) += cevt-ds1287.o
obj-$([31mCONFIG_CEVT_GT641XX[0m) += cevt-gt641xx.o
obj-$([31mCONFIG_CEVT_SB1250[0m) += cevt-sb1250.o
obj-$([31mCONFIG_CEVT_TXX9[0m) += cevt-txx9.o
obj-$([31mCONFIG_CSRC_BCM1480[0m) += csrc-bcm1480.o
obj-$([31mCONFIG_CSRC_IOASIC[0m) += csrc-ioasic.o
obj-$([31mCONFIG_CSRC_R4K[0m) += csrc-r4k.o
obj-$([31mCONFIG_CSRC_SB1250[0m) += csrc-sb1250.o
obj-$([31mCONFIG_SYNC_R4K[0m) += sync-r4k.o
obj-$([31mCONFIG_DEBUG_FS[0m) += segment.o
obj-$([31mCONFIG_STACKTRACE[0m) += stacktrace.o
obj-$([31mCONFIG_MODULES[0m) += module.o
obj-$([31mCONFIG_FTRACE_SYSCALLS[0m) += ftrace.o
obj-$([31mCONFIG_FUNCTION_TRACER[0m) += mcount.o ftrace.o
sw-y := r4k_switch.o
sw-$([31mCONFIG_CPU_R3000[0m) := r2300_switch.o
sw-$([31mCONFIG_CPU_TX39XX[0m) := r2300_switch.o
sw-$([31mCONFIG_CPU_CAVIUM_OCTEON[0m) := octeon_switch.o
obj-y += $(sw-y)
obj-$([31mCONFIG_CPU_R2300_FPU[0m) += r2300_fpu.o
obj-$([31mCONFIG_CPU_R4K_FPU[0m) += r4k_fpu.o
obj-$([31mCONFIG_SMP[0m) += smp.o
obj-$([31mCONFIG_SMP_UP[0m) += smp-up.o
obj-$([31mCONFIG_CPU_BMIPS[0m) += smp-bmips.o bmips_vec.o bmips_5xxx_init.o
obj-$([31mCONFIG_MIPS_MT[0m) += mips-mt.o
obj-$([31mCONFIG_MIPS_MT_FPAFF[0m) += mips-mt-fpaff.o
obj-$([31mCONFIG_MIPS_MT_SMP[0m) += smp-mt.o
obj-$([31mCONFIG_MIPS_CMP[0m) += smp-cmp.o
obj-$([31mCONFIG_MIPS_CPS[0m) += smp-cps.o cps-vec.o
obj-$([31mCONFIG_MIPS_CPS_NS16550[0m) += cps-vec-ns16550.o
obj-$([31mCONFIG_MIPS_SPRAM[0m) += spram.o
obj-$([31mCONFIG_MIPS_VPE_LOADER[0m) += vpe.o
obj-$([31mCONFIG_MIPS_VPE_LOADER_CMP[0m) += vpe-cmp.o
obj-$([31mCONFIG_MIPS_VPE_LOADER_MT[0m) += vpe-mt.o
obj-$([31mCONFIG_MIPS_VPE_APSP_API[0m) += rtlx.o
obj-$([31mCONFIG_MIPS_VPE_APSP_API_CMP[0m) += rtlx-cmp.o
obj-$([31mCONFIG_MIPS_VPE_APSP_API_MT[0m) += rtlx-mt.o
obj-$([31mCONFIG_IRQ_CPU_RM7K[0m) += irq-rm7000.o
obj-$([31mCONFIG_MIPS_MSC[0m) += irq-msc01.o
obj-$([31mCONFIG_IRQ_TXX9[0m) += irq_txx9.o
obj-$([31mCONFIG_IRQ_GT641XX[0m) += irq-gt641xx.o
obj-$([31mCONFIG_KPROBES[0m) += kprobes.o
obj-$([31mCONFIG_32BIT[0m) += scall32-o32.o
obj-$([31mCONFIG_64BIT[0m) += scall64-n64.o
obj-$([31mCONFIG_MIPS32_COMPAT[0m) += linux32.o ptrace32.o signal32.o
obj-$([31mCONFIG_MIPS32_N32[0m) += binfmt_elfn32.o scall64-n32.o signal_n32.o
obj-$([31mCONFIG_MIPS32_O32[0m) += binfmt_elfo32.o scall64-o32.o signal_o32.o
obj-$([31mCONFIG_KGDB[0m) += kgdb.o
obj-$([31mCONFIG_PROC_FS[0m) += proc.o
obj-$([31mCONFIG_MAGIC_SYSRQ[0m) += sysrq.o
obj-$([31mCONFIG_64BIT[0m) += cpu-bugs64.o
obj-$([31mCONFIG_I8253[0m) += i8253.o
obj-$([31mCONFIG_GPIO_TXX9[0m) += gpio_txx9.o
obj-$([31mCONFIG_RELOCATABLE[0m) += relocate.o
obj-$([31mCONFIG_KEXEC[0m) += machine_kexec.o relocate_kernel.o crash.o
obj-$([31mCONFIG_CRASH_DUMP[0m) += crash_dump.o
obj-$([31mCONFIG_EARLY_PRINTK[0m) += early_printk.o
obj-$([31mCONFIG_EARLY_PRINTK_8250[0m) += early_printk_8250.o
obj-$([31mCONFIG_SPINLOCK_TEST[0m) += spinlock_test.o
obj-$([31mCONFIG_MIPS_MACHINE[0m) += mips_machine.o
obj-$([31mCONFIG_MIPSR2_TO_R6_EMULATOR[0m) += mips-r2-to-r6-emul.o
CFLAGS_cpu-bugs64.o = $(shell if $(CC) $(KBUILD_CFLAGS) -Wa,-mdaddi -c -o /dev/null -x c /dev/null >/dev/null 2>&1; then echo "-DHAVE_AS_SET_DADDI"; fi)
obj-$([31mCONFIG_HAVE_STD_PC_SERIAL_PORT[0m) += 8250-platform.o
obj-$([31mCONFIG_PERF_EVENTS[0m) += perf_event.o
obj-$([31mCONFIG_HW_PERF_EVENTS[0m) += perf_event_mipsxx.o
obj-$([31mCONFIG_JUMP_LABEL[0m) += jump_label.o
obj-$([31mCONFIG_UPROBES[0m) += uprobes.o
obj-$([31mCONFIG_MIPS_CM[0m) += mips-cm.o
obj-$([31mCONFIG_MIPS_CPC[0m) += mips-cpc.o
obj-$([31mCONFIG_CPU_PM[0m) += pm.o
obj-$([31mCONFIG_MIPS_CPS_PM[0m) += pm-cps.o
CPPFLAGS_vmlinux.lds := $(KBUILD_CFLAGS)