Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 1 | # |
| 2 | # Makefile for the linux kernel. |
| 3 | # |
Sam Ravnborg | 88e4d25 | 2007-10-17 22:06:30 +0200 | [diff] [blame] | 4 | |
Luis R. Rodriguez | 8d152e7 | 2016-04-13 17:04:34 -0700 | [diff] [blame] | 5 | extra-y := head_$(BITS).o |
| 6 | extra-y += head$(BITS).o |
Luis R. Rodriguez | f2d8529 | 2016-04-13 17:04:43 -0700 | [diff] [blame] | 7 | extra-y += ebda.o |
Luis R. Rodriguez | 8d152e7 | 2016-04-13 17:04:34 -0700 | [diff] [blame] | 8 | extra-y += platform-quirks.o |
| 9 | extra-y += vmlinux.lds |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 10 | |
| 11 | CPPFLAGS_vmlinux.lds += -U$(UTS_MACHINE) |
Ingo Molnar | e43eb7b | 2008-02-14 08:38:49 +0100 | [diff] [blame] | 12 | |
Steven Rostedt | 606576c | 2008-10-06 19:06:12 -0400 | [diff] [blame] | 13 | ifdef CONFIG_FUNCTION_TRACER |
Ingo Molnar | 34646bc | 2008-07-09 15:42:09 +0200 | [diff] [blame] | 14 | # Do not profile debug and lowlevel utilities |
Steven Rostedt | 89e1be5 | 2011-05-27 23:11:24 -0400 | [diff] [blame] | 15 | CFLAGS_REMOVE_tsc.o = -pg |
Jeremy Fitzhardinge | d5de884 | 2008-07-23 13:28:58 -0700 | [diff] [blame] | 16 | CFLAGS_REMOVE_paravirt-spinlocks.o = -pg |
Jeremy Fitzhardinge | 9ecd4e1 | 2010-09-22 17:07:27 -0700 | [diff] [blame] | 17 | CFLAGS_REMOVE_pvclock.o = -pg |
Steven Rostedt | 258af47 | 2010-09-22 22:22:25 -0400 | [diff] [blame] | 18 | CFLAGS_REMOVE_kvmclock.o = -pg |
Steven Rostedt | 15adc04 | 2008-10-23 09:33:08 -0400 | [diff] [blame] | 19 | CFLAGS_REMOVE_ftrace.o = -pg |
Ingo Molnar | 6cf87ef | 2008-11-04 10:42:23 +0100 | [diff] [blame] | 20 | CFLAGS_REMOVE_early_printk.o = -pg |
Kirill A. Shutemov | bb43dbc | 2017-06-27 14:59:48 +0300 | [diff] [blame] | 21 | CFLAGS_REMOVE_head64.o = -pg |
Steven Rostedt | 7fa09f2 | 2008-05-14 21:30:32 -0400 | [diff] [blame] | 22 | endif |
| 23 | |
Josh Poimboeuf | c0dd671686 | 2016-02-28 22:22:34 -0600 | [diff] [blame] | 24 | KASAN_SANITIZE_head$(BITS).o := n |
| 25 | KASAN_SANITIZE_dumpstack.o := n |
| 26 | KASAN_SANITIZE_dumpstack_$(BITS).o := n |
Alexander Potapenko | cd11016 | 2016-03-25 14:22:08 -0700 | [diff] [blame] | 27 | KASAN_SANITIZE_stacktrace.o := n |
Josh Poimboeuf | c0dd671686 | 2016-02-28 22:22:34 -0600 | [diff] [blame] | 28 | |
| 29 | OBJECT_FILES_NON_STANDARD_head_$(BITS).o := y |
| 30 | OBJECT_FILES_NON_STANDARD_relocate_kernel_$(BITS).o := y |
Steven Rostedt (VMware) | db65d7b | 2017-03-23 10:33:48 -0400 | [diff] [blame] | 31 | OBJECT_FILES_NON_STANDARD_ftrace_$(BITS).o := y |
Josh Poimboeuf | c0dd671686 | 2016-02-28 22:22:34 -0600 | [diff] [blame] | 32 | OBJECT_FILES_NON_STANDARD_test_nx.o := y |
Josh Poimboeuf | c207aee | 2017-06-28 10:11:06 -0500 | [diff] [blame] | 33 | OBJECT_FILES_NON_STANDARD_paravirt_patch_$(BITS).o := y |
Andrey Ryabinin | ef7f0d6 | 2015-02-13 14:39:25 -0800 | [diff] [blame] | 34 | |
Dmitry Vyukov | 5c9a875 | 2016-03-22 14:27:30 -0700 | [diff] [blame] | 35 | # If instrumentation of this dir is enabled, boot hangs during first second. |
| 36 | # Probably could be more selective here, but note that files related to irqs, |
| 37 | # boot, dumpstack/stacktrace, etc are either non-interesting or can lead to |
| 38 | # non-deterministic coverage. |
| 39 | KCOV_INSTRUMENT := n |
| 40 | |
Steven Rostedt (Red Hat) | 83ab851 | 2013-06-21 10:29:05 -0400 | [diff] [blame] | 41 | CFLAGS_irq.o := -I$(src)/../include/asm/trace |
| 42 | |
Ingo Molnar | 905a36a | 2015-06-03 13:37:36 +0200 | [diff] [blame] | 43 | obj-y := process_$(BITS).o signal.o |
Brian Gerst | c0bfd26 | 2015-06-22 07:55:10 -0400 | [diff] [blame] | 44 | obj-$(CONFIG_COMPAT) += signal_compat.o |
Thomas Gleixner | d8ed9d4 | 2017-08-28 08:47:43 +0200 | [diff] [blame] | 45 | obj-y += traps.o idt.o irq.o irq_$(BITS).o dumpstack_$(BITS).o |
Andy Lutomirski | a5b9e5a | 2015-07-30 14:31:34 -0700 | [diff] [blame] | 46 | obj-y += time.o ioport.o dumpstack.o nmi.o |
| 47 | obj-$(CONFIG_MODIFY_LDT_SYSCALL) += ldt.o |
Jason Baron | d9f5ab7 | 2010-09-17 11:09:22 -0400 | [diff] [blame] | 48 | obj-y += setup.o x86_init.o i8259.o irqinit.o jump_label.o |
Peter Zijlstra | e360adb | 2010-10-14 14:01:34 +0800 | [diff] [blame] | 49 | obj-$(CONFIG_IRQ_WORK) += irq_work.o |
Dan Williams | 5d94e81 | 2011-03-08 10:36:19 -0800 | [diff] [blame] | 50 | obj-y += probe_roms.o |
Steven Rostedt (VMware) | 1fa9d67 | 2017-03-23 10:33:53 -0400 | [diff] [blame] | 51 | obj-$(CONFIG_X86_64) += sys_x86_64.o |
H. Peter Anvin | 197725d | 2014-05-04 10:00:49 -0700 | [diff] [blame] | 52 | obj-$(CONFIG_X86_ESPFIX64) += espfix_64.o |
Dave Young | 5039e31 | 2013-12-20 18:02:21 +0800 | [diff] [blame] | 53 | obj-$(CONFIG_SYSFS) += ksysfs.o |
Yinghai Lu | 064d25f | 2008-06-16 19:58:28 -0700 | [diff] [blame] | 54 | obj-y += bootflag.o e820.o |
David Rientjes | 4061d68 | 2011-03-22 16:34:57 -0700 | [diff] [blame] | 55 | obj-y += pci-dma.o quirks.o topology.o kdebugfs.o |
K.Prasad | 0067f12 | 2009-06-01 23:43:57 +0530 | [diff] [blame] | 56 | obj-y += alternative.o i8253.o pci-nommu.o hw_breakpoint.o |
Bin Gao | 7da7c15 | 2013-10-21 09:16:33 -0700 | [diff] [blame] | 57 | obj-y += tsc.o tsc_msr.o io_delay.o rtc.o |
Konrad Rzeszutek Wilk | 5bef80a | 2010-08-26 13:57:58 -0400 | [diff] [blame] | 58 | obj-y += pci-iommu_table.o |
Bjorn Helgaas | 30919b0 | 2010-12-16 10:38:51 -0700 | [diff] [blame] | 59 | obj-y += resource.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 60 | |
Suresh Siddha | 61c4628 | 2008-03-10 15:28:04 -0700 | [diff] [blame] | 61 | obj-y += process.o |
Ingo Molnar | ce4c4c2 | 2015-04-22 10:39:11 +0200 | [diff] [blame] | 62 | obj-y += fpu/ |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 63 | obj-y += ptrace.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 64 | obj-$(CONFIG_X86_32) += tls.o |
| 65 | obj-$(CONFIG_IA32_EMULATION) += tls.o |
| 66 | obj-y += step.o |
Joseph Cihula | 3162534 | 2009-06-30 19:30:59 -0700 | [diff] [blame] | 67 | obj-$(CONFIG_INTEL_TXT) += tboot.o |
David Rientjes | 4061d68 | 2011-03-22 16:34:57 -0700 | [diff] [blame] | 68 | obj-$(CONFIG_ISA_DMA_API) += i8237.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 69 | obj-$(CONFIG_STACKTRACE) += stacktrace.o |
| 70 | obj-y += cpu/ |
| 71 | obj-y += acpi/ |
Ingo Molnar | f095df0 | 2009-01-27 17:17:55 +0100 | [diff] [blame] | 72 | obj-y += reboot.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 73 | obj-$(CONFIG_X86_MSR) += msr.o |
| 74 | obj-$(CONFIG_X86_CPUID) += cpuid.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 75 | obj-$(CONFIG_PCI) += early-quirks.o |
Sam Ravnborg | 3a900d8 | 2008-02-04 16:47:55 +0100 | [diff] [blame] | 76 | apm-y := apm_32.o |
| 77 | obj-$(CONFIG_APM) += apm.o |
Ingo Molnar | 3e5095d | 2009-01-27 17:07:08 +0100 | [diff] [blame] | 78 | obj-$(CONFIG_SMP) += smp.o |
Henrik Kretzschmar | ec8df88 | 2011-03-11 08:02:35 +0100 | [diff] [blame] | 79 | obj-$(CONFIG_SMP) += smpboot.o |
Thomas Gleixner | 8b223bc | 2016-11-19 13:47:36 +0000 | [diff] [blame] | 80 | obj-$(CONFIG_X86_TSC) += tsc_sync.o |
Brian Gerst | 996db81 | 2009-01-27 12:56:47 +0900 | [diff] [blame] | 81 | obj-$(CONFIG_SMP) += setup_percpu.o |
Alexey Starikovskiy | 85bddde | 2008-04-04 23:43:18 +0400 | [diff] [blame] | 82 | obj-$(CONFIG_X86_MPPARSE) += mpparse.o |
Ingo Molnar | 9be1b56 | 2009-02-17 23:12:48 +0100 | [diff] [blame] | 83 | obj-y += apic/ |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 84 | obj-$(CONFIG_X86_REBOOTFIXUPS) += reboot_fixups_32.o |
Steven Rostedt | 3d08339 | 2008-05-12 21:20:42 +0200 | [diff] [blame] | 85 | obj-$(CONFIG_DYNAMIC_FTRACE) += ftrace.o |
Jessica Yu | d4c3e6e | 2016-08-17 20:58:29 -0400 | [diff] [blame] | 86 | obj-$(CONFIG_LIVEPATCH) += livepatch.o |
Steven Rostedt (VMware) | 1fa9d67 | 2017-03-23 10:33:53 -0400 | [diff] [blame] | 87 | obj-$(CONFIG_FUNCTION_TRACER) += ftrace_$(BITS).o |
Ingo Molnar | ccd50df | 2009-03-13 17:02:17 +0100 | [diff] [blame] | 88 | obj-$(CONFIG_FUNCTION_GRAPH_TRACER) += ftrace.o |
| 89 | obj-$(CONFIG_FTRACE_SYSCALLS) += ftrace.o |
David Sharp | 8cbd9cc | 2012-11-13 12:18:21 -0800 | [diff] [blame] | 90 | obj-$(CONFIG_X86_TSC) += trace_clock.o |
Dave Young | 2965faa | 2015-09-09 15:38:55 -0700 | [diff] [blame] | 91 | obj-$(CONFIG_KEXEC_CORE) += machine_kexec_$(BITS).o |
| 92 | obj-$(CONFIG_KEXEC_CORE) += relocate_kernel_$(BITS).o crash.o |
Vivek Goyal | 74ca317 | 2014-08-29 15:18:46 -0700 | [diff] [blame] | 93 | obj-$(CONFIG_KEXEC_FILE) += kexec-bzimage64.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 94 | obj-$(CONFIG_CRASH_DUMP) += crash_dump_$(BITS).o |
Masami Hiramatsu | f684199 | 2012-09-28 17:15:22 +0900 | [diff] [blame] | 95 | obj-y += kprobes/ |
Amerigo Wang | 0fdc83b | 2009-06-03 21:46:19 -0400 | [diff] [blame] | 96 | obj-$(CONFIG_MODULES) += module.o |
Borislav Petkov | 4d067d8 | 2013-05-09 12:02:29 +0200 | [diff] [blame] | 97 | obj-$(CONFIG_DOUBLEFAULT) += doublefault.o |
Ingo Molnar | 82da3ff | 2008-04-17 20:05:37 +0200 | [diff] [blame] | 98 | obj-$(CONFIG_KGDB) += kgdb.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 99 | obj-$(CONFIG_VM86) += vm86_32.o |
| 100 | obj-$(CONFIG_EARLY_PRINTK) += early_printk.o |
| 101 | |
| 102 | obj-$(CONFIG_HPET_TIMER) += hpet.o |
Jacob Pan | bb24c47 | 2009-09-02 07:37:17 -0700 | [diff] [blame] | 103 | obj-$(CONFIG_APB_TIMER) += apb_timer.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 104 | |
Andreas Herrmann | 23ac4ae | 2010-09-17 18:03:43 +0200 | [diff] [blame] | 105 | obj-$(CONFIG_AMD_NB) += amd_nb.o |
Don Zickus | 99e8b9c | 2011-10-13 15:14:26 -0400 | [diff] [blame] | 106 | obj-$(CONFIG_DEBUG_NMI_SELFTEST) += nmi_selftest.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 107 | |
Marcelo Tosatti | 90993cd | 2012-08-16 17:00:19 -0300 | [diff] [blame] | 108 | obj-$(CONFIG_KVM_GUEST) += kvm.o kvmclock.o |
Jeremy Fitzhardinge | b4ecc12 | 2009-05-13 17:16:55 -0700 | [diff] [blame] | 109 | obj-$(CONFIG_PARAVIRT) += paravirt.o paravirt_patch_$(BITS).o |
| 110 | obj-$(CONFIG_PARAVIRT_SPINLOCKS)+= paravirt-spinlocks.o |
Gerd Hoffmann | 7af192c | 2008-06-03 16:17:29 +0200 | [diff] [blame] | 111 | obj-$(CONFIG_PARAVIRT_CLOCK) += pvclock.o |
Dan Williams | 7a67832 | 2015-08-19 00:34:34 -0400 | [diff] [blame] | 112 | obj-$(CONFIG_X86_PMEM_LEGACY_DEVICE) += pmem.o |
Michael Opdenacker | 6792689 | 2008-01-30 13:33:18 +0100 | [diff] [blame] | 113 | |
Thomas Gleixner | f7eaf6e | 2017-08-28 08:47:20 +0200 | [diff] [blame] | 114 | obj-$(CONFIG_EISA) += eisa.o |
Stas Sergeev | e5e1d3c | 2008-05-07 12:39:56 +0200 | [diff] [blame] | 115 | obj-$(CONFIG_PCSPKR_PLATFORM) += pcspeaker.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 116 | |
Arjan van de Ven | b43d196 | 2008-10-05 12:21:32 -0700 | [diff] [blame] | 117 | obj-$(CONFIG_X86_CHECK_BIOS_CORRUPTION) += check.o |
| 118 | |
Ian Campbell | b041cf2 | 2009-01-23 10:56:16 +0000 | [diff] [blame] | 119 | obj-$(CONFIG_SWIOTLB) += pci-swiotlb.o |
Sebastian Andrzej Siewior | da6b737 | 2011-02-22 21:07:37 +0100 | [diff] [blame] | 120 | obj-$(CONFIG_OF) += devicetree.o |
Srikar Dronamraju | 2b14449 | 2012-02-09 14:56:42 +0530 | [diff] [blame] | 121 | obj-$(CONFIG_UPROBES) += uprobes.o |
David Herrmann | e3263ab | 2013-08-02 14:05:22 +0200 | [diff] [blame] | 122 | obj-y += sysfb.o |
| 123 | obj-$(CONFIG_X86_SYSFB) += sysfb_simplefb.o |
David Herrmann | 2995e50 | 2013-08-02 14:05:23 +0200 | [diff] [blame] | 124 | obj-$(CONFIG_EFI) += sysfb_efi.o |
Jeremy Fitzhardinge | cfb80c9 | 2008-12-16 12:17:36 -0800 | [diff] [blame] | 125 | |
Jiri Olsa | c5e6319 | 2012-08-07 15:20:36 +0200 | [diff] [blame] | 126 | obj-$(CONFIG_PERF_EVENTS) += perf_regs.o |
Seiji Aguchi | cf910e8 | 2013-06-20 11:46:53 -0400 | [diff] [blame] | 127 | obj-$(CONFIG_TRACING) += tracepoint.o |
Tim Chen | de966cf | 2016-11-29 10:43:27 -0800 | [diff] [blame] | 128 | obj-$(CONFIG_SCHED_MC_PRIO) += itmt.o |
Jiri Olsa | c5e6319 | 2012-08-07 15:20:36 +0200 | [diff] [blame] | 129 | |
Josh Poimboeuf | 11af847 | 2017-10-13 15:02:00 -0500 | [diff] [blame^] | 130 | obj-$(CONFIG_UNWINDER_ORC) += unwind_orc.o |
| 131 | obj-$(CONFIG_UNWINDER_FRAME_POINTER) += unwind_frame.o |
| 132 | obj-$(CONFIG_UNWINDER_GUESS) += unwind_guess.o |
Josh Poimboeuf | 7c7900f | 2016-09-16 14:18:12 -0500 | [diff] [blame] | 133 | |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 134 | ### |
| 135 | # 64 bit specific files |
| 136 | ifeq ($(CONFIG_X86_64),y) |
Ingo Molnar | f62bae5 | 2009-02-17 18:09:24 +0100 | [diff] [blame] | 137 | obj-$(CONFIG_AUDIT) += audit_64.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 138 | |
Joerg Roedel | fffcda1 | 2011-05-10 17:22:06 +0200 | [diff] [blame] | 139 | obj-$(CONFIG_GART_IOMMU) += amd_gart_64.o aperture_64.o |
Ingo Molnar | f62bae5 | 2009-02-17 18:09:24 +0100 | [diff] [blame] | 140 | obj-$(CONFIG_CALGARY_IOMMU) += pci-calgary_64.o tce_64.o |
Yinghai Lu | d39398a | 2008-02-26 11:04:17 -0800 | [diff] [blame] | 141 | |
Ingo Molnar | f62bae5 | 2009-02-17 18:09:24 +0100 | [diff] [blame] | 142 | obj-$(CONFIG_PCI_MMCONFIG) += mmconf-fam10h_64.o |
Ravikiran G Thirumalai | 7051113 | 2009-03-23 23:14:29 -0700 | [diff] [blame] | 143 | obj-y += vsmp_64.o |
Sam Ravnborg | 6b0c3d4 | 2008-01-30 13:32:27 +0100 | [diff] [blame] | 144 | endif |