11da177e4SLinus Torvalds# 21da177e4SLinus Torvalds# Makefile for the linux kernel. 31da177e4SLinus Torvalds# 41da177e4SLinus Torvalds 5b9ee979eSJoe Perchesobj-y = fork.o exec_domain.o panic.o \ 65cee9645SThomas Gleixner cpu.o exit.o softirq.o resource.o \ 75cee9645SThomas Gleixner sysctl.o sysctl_binary.o capability.o ptrace.o user.o \ 8e73f8959SOleg Nesterov signal.o sys.o kmod.o workqueue.o pid.o task_work.o \ 95cee9645SThomas Gleixner extable.o params.o \ 105cee9645SThomas Gleixner kthread.o sys_ni.o nsproxy.o \ 1115d94b82SRobin Holt notifier.o ksysfs.o cred.o reboot.o \ 122813893fSIulia Manda async.o range.o smpboot.o 132813893fSIulia Manda 142813893fSIulia Mandaobj-$(CONFIG_MULTIUSER) += groups.o 15029632fbSPeter Zijlstra 16606576ceSSteven Rostedtifdef CONFIG_FUNCTION_TRACER 17e11b956eSLi Bin# Do not trace internal ftrace files 18c0a80c0cSHeiko CarstensCFLAGS_REMOVE_irq_work.o = $(CC_FLAGS_FTRACE) 191d09daa5SSteven Rostedtendif 201d09daa5SSteven Rostedt 215c9a8750SDmitry Vyukov# Prevents flicker of uninteresting __do_softirq()/__local_bh_disable_ip() 225c9a8750SDmitry Vyukov# in coverage traces. 235c9a8750SDmitry VyukovKCOV_INSTRUMENT_softirq.o := n 245c9a8750SDmitry Vyukov# These are called from save_stack_trace() on slub debug path, 255c9a8750SDmitry Vyukov# and produce insane amounts of uninteresting coverage. 265c9a8750SDmitry VyukovKCOV_INSTRUMENT_module.o := n 275c9a8750SDmitry VyukovKCOV_INSTRUMENT_extable.o := n 285c9a8750SDmitry Vyukov# Don't self-instrument. 295c9a8750SDmitry VyukovKCOV_INSTRUMENT_kcov.o := n 305c9a8750SDmitry VyukovKASAN_SANITIZE_kcov.o := n 315c9a8750SDmitry Vyukov 3258edae3aSAndi Kleen# cond_syscall is currently not LTO compatible 3358edae3aSAndi KleenCFLAGS_sys_ni.o = $(DISABLE_LTO) 3458edae3aSAndi Kleen 35391e43daSPeter Zijlstraobj-y += sched/ 3601768b42SPeter Zijlstraobj-y += locking/ 37dae5cbc2SRafael J. Wysockiobj-y += power/ 38b9ee979eSJoe Perchesobj-y += printk/ 390244ad00SMartin Schwidefskyobj-y += irq/ 404102adabSPaul E. McKenneyobj-y += rcu/ 41b700e7f0SSeth Jenningsobj-y += livepatch/ 42391e43daSPeter Zijlstra 431e142b29SCyrill Gorcunovobj-$(CONFIG_CHECKPOINT_RESTORE) += kcmp.o 448174f150SMatt Helsleyobj-$(CONFIG_FREEZER) += freezer.o 45b03f6489SAdrian Bunkobj-$(CONFIG_PROFILING) += profile.o 468637c099SIngo Molnarobj-$(CONFIG_STACKTRACE) += stacktrace.o 47ad596171Sjohn stultzobj-y += time/ 481da177e4SLinus Torvaldsobj-$(CONFIG_FUTEX) += futex.o 4934f192c6SIngo Molnarifeq ($(CONFIG_COMPAT),y) 5034f192c6SIngo Molnarobj-$(CONFIG_FUTEX) += futex_compat.o 5134f192c6SIngo Molnarendif 521da177e4SLinus Torvaldsobj-$(CONFIG_GENERIC_ISA_DMA) += dma.o 53351f8f8eSAmerigo Wangobj-$(CONFIG_SMP) += smp.o 549316fcacSAndrew Mortonifneq ($(CONFIG_SMP),y) 5553ce3d95SAndrew Mortonobj-y += up.o 5653ce3d95SAndrew Mortonendif 571da177e4SLinus Torvaldsobj-$(CONFIG_UID16) += uid16.o 581da177e4SLinus Torvaldsobj-$(CONFIG_MODULES) += module.o 59b56e5a17SDavid Howellsobj-$(CONFIG_MODULE_SIG) += module_signing.o 601da177e4SLinus Torvaldsobj-$(CONFIG_KALLSYMS) += kallsyms.o 611da177e4SLinus Torvaldsobj-$(CONFIG_BSD_PROCESS_ACCT) += acct.o 622965faa5SDave Youngobj-$(CONFIG_KEXEC_CORE) += kexec_core.o 63dc009d92SEric W. Biedermanobj-$(CONFIG_KEXEC) += kexec.o 64a43cac0dSDave Youngobj-$(CONFIG_KEXEC_FILE) += kexec_file.o 656dab2778SArjan van de Venobj-$(CONFIG_BACKTRACE_SELF_TEST) += backtracetest.o 661da177e4SLinus Torvaldsobj-$(CONFIG_COMPAT) += compat.o 67ddbcc7e8SPaul Menageobj-$(CONFIG_CGROUPS) += cgroup.o 68dc52ddc0SMatt Helsleyobj-$(CONFIG_CGROUP_FREEZER) += cgroup_freezer.o 6949b786eaSAleksa Saraiobj-$(CONFIG_CGROUP_PIDS) += cgroup_pids.o 701da177e4SLinus Torvaldsobj-$(CONFIG_CPUSETS) += cpuset.o 71aee16ce7SPavel Emelyanovobj-$(CONFIG_UTS_NS) += utsname.o 72aee16ce7SPavel Emelyanovobj-$(CONFIG_USER_NS) += user_namespace.o 7374bd59bbSPavel Emelyanovobj-$(CONFIG_PID_NS) += pid_namespace.o 741da177e4SLinus Torvaldsobj-$(CONFIG_IKCONFIG) += configs.o 75bbf1bb3eSTejun Heoobj-$(CONFIG_SMP) += stop_machine.o 768c1c9356SAnanth N Mavinakayanahalliobj-$(CONFIG_KPROBES_SANITY_TEST) += test_kprobes.o 77939a67fcSEric Parisobj-$(CONFIG_AUDIT) += audit.o auditfilter.o 781da177e4SLinus Torvaldsobj-$(CONFIG_AUDITSYSCALL) += auditsc.o 797f492942SRichard Guy Briggsobj-$(CONFIG_AUDIT_WATCH) += audit_watch.o audit_fsnotify.o 8074c3cbe3SAl Viroobj-$(CONFIG_AUDIT_TREE) += audit_tree.o 81939a67fcSEric Parisobj-$(CONFIG_GCOV_KERNEL) += gcov/ 825c9a8750SDmitry Vyukovobj-$(CONFIG_KCOV) += kcov.o 831da177e4SLinus Torvaldsobj-$(CONFIG_KPROBES) += kprobes.o 84c4338209SJason Wesselobj-$(CONFIG_KGDB) += debug/ 85e162b39aSMandeep Singh Bainesobj-$(CONFIG_DETECT_HUNG_TASK) += hung_task.o 8658687acbSDon Zickusobj-$(CONFIG_LOCKUP_DETECTOR) += watchdog.o 871da177e4SLinus Torvaldsobj-$(CONFIG_SECCOMP) += seccomp.o 88b86ff981SJens Axboeobj-$(CONFIG_RELAY) += relay.o 8939732acdSEric W. Biedermanobj-$(CONFIG_SYSCTL) += utsname_sysctl.o 90ca74e92bSShailabh Nagarobj-$(CONFIG_TASK_DELAY_ACCT) += delayacct.o 91f3cef7a9SJay Lanobj-$(CONFIG_TASKSTATS) += taskstats.o tsacct.o 9297e1c18eSMathieu Desnoyersobj-$(CONFIG_TRACEPOINTS) += tracepoint.o 939745512cSArjan van de Venobj-$(CONFIG_LATENCYTOP) += latencytop.o 94*f43edca7SRalf Baechleobj-$(CONFIG_ELFCORE) += elfcore.o 95606576ceSSteven Rostedtobj-$(CONFIG_FUNCTION_TRACER) += trace/ 96bc0c38d1SSteven Rostedtobj-$(CONFIG_TRACING) += trace/ 97ea632e9fSJosh Triplettobj-$(CONFIG_TRACE_CLOCK) += trace/ 981155de47SPaul Mundtobj-$(CONFIG_RING_BUFFER) += trace/ 99870915e0SMathieu Desnoyersobj-$(CONFIG_TRACEPOINTS) += trace/ 100e360adbeSPeter Zijlstraobj-$(CONFIG_IRQ_WORK) += irq_work.o 101ab10023eSColin Crossobj-$(CONFIG_CPU_PM) += cpu_pm.o 102f89b7755SAlexei Starovoitovobj-$(CONFIG_BPF) += bpf/ 103fae85b7cSBorislav Petkov 104fae85b7cSBorislav Petkovobj-$(CONFIG_PERF_EVENTS) += events/ 105fae85b7cSBorislav Petkov 1067a041097SAvi Kivityobj-$(CONFIG_USER_RETURN_NOTIFIER) += user-return-notifier.o 10716295becSSteffen Klassertobj-$(CONFIG_PADATA) += padata.o 10893a72052SOlaf Heringobj-$(CONFIG_CRASH_DUMP) += crash_dump.o 109b77f0f3cSJason Baronobj-$(CONFIG_JUMP_LABEL) += jump_label.o 11091d1aa43SFrederic Weisbeckerobj-$(CONFIG_CONTEXT_TRACKING) += context_tracking.o 11151b1130eSPaul E. McKenneyobj-$(CONFIG_TORTURE_TEST) += torture.o 1125b25b13aSMathieu Desnoyersobj-$(CONFIG_MEMBARRIER) += membarrier.o 1131da177e4SLinus Torvalds 11492281deeSDan Williamsobj-$(CONFIG_HAS_IOMEM) += memremap.o 11592281deeSDan Williams 1161da177e4SLinus Torvalds$(obj)/configs.o: $(obj)/config_data.h 1171da177e4SLinus Torvalds 1181da177e4SLinus Torvalds# config_data.h contains the same information as ikconfig.h but gzipped. 1191da177e4SLinus Torvalds# Info from config_data can be extracted from /proc/config* 1201da177e4SLinus Torvaldstargets += config_data.gz 12141263fc6SBen Gardiner$(obj)/config_data.gz: $(KCONFIG_CONFIG) FORCE 1221da177e4SLinus Torvalds $(call if_changed,gzip) 1231da177e4SLinus Torvalds 1248370edeaSVivek Goyal filechk_ikconfiggz = (echo "static const char kernel_config_data[] __used = MAGIC_START"; cat $< | scripts/basic/bin2c; echo "MAGIC_END;") 1251da177e4SLinus Torvaldstargets += config_data.h 1261da177e4SLinus Torvalds$(obj)/config_data.h: $(obj)/config_data.gz FORCE 127e78e8f2dSPeter Foley $(call filechk,ikconfiggz) 128