linux/arch/mips/kernel
Masahiro Yamada b1992c3772 kbuild: use $(src) instead of $(srctree)/$(src) for source directory
Kbuild conventionally uses $(obj)/ for generated files, and $(src)/ for
checked-in source files. It is merely a convention without any functional
difference. In fact, $(obj) and $(src) are exactly the same, as defined
in scripts/Makefile.build:

    src := $(obj)

When the kernel is built in a separate output directory, $(src) does
not accurately reflect the source directory location. While Kbuild
resolves this discrepancy by specifying VPATH=$(srctree) to search for
source files, it does not cover all cases. For example, when adding a
header search path for local headers, -I$(srctree)/$(src) is typically
passed to the compiler.

This introduces inconsistency between upstream and downstream Makefiles
because $(src) is used instead of $(srctree)/$(src) for the latter.

To address this inconsistency, this commit changes the semantics of
$(src) so that it always points to the directory in the source tree.

Going forward, the variables used in Makefiles will have the following
meanings:

  $(obj)     - directory in the object tree
  $(src)     - directory in the source tree  (changed by this commit)
  $(objtree) - the top of the kernel object tree
  $(srctree) - the top of the kernel source tree

Consequently, $(srctree)/$(src) in upstream Makefiles need to be replaced
with $(src).

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
2024-05-10 04:34:52 +09:00
..
syscalls kbuild: use $(src) instead of $(srctree)/$(src) for source directory 2024-05-10 04:34:52 +09:00
.gitignore .gitignore: add SPDX License Identifier 2020-03-25 11:50:48 +01:00
access-helper.h MIPS: Fix new sparse warnings 2021-04-07 16:11:05 +02:00
asm-offsets.c MIPS: scall: Save thread_info.syscall unconditionally on entry 2024-04-09 16:52:21 +02:00
bmips_5xxx_init.S
bmips_vec.S
branch.c MIPS: kernel: include probes-common.h header in branch.c 2020-09-21 22:14:24 +02:00
cacheinfo.c drivers: base: cacheinfo: Get rid of DEFINE_SMP_CALL_CACHE_FUNCTION() 2021-09-01 10:29:10 +02:00
cevt-bcm1480.c MIPS: Replace setup_irq() by request_irq() 2020-03-05 16:47:35 +01:00
cevt-ds1287.c MIPS: Replace setup_irq() by request_irq() 2020-03-05 16:47:35 +01:00
cevt-gt641xx.c MIPS: Replace setup_irq() by request_irq() 2020-03-05 16:47:35 +01:00
cevt-r4k.c MIPS: cevt-r4k: Offset the value used to clear compare interrupt 2023-02-27 23:45:17 +01:00
cevt-sb1250.c MIPS: Replace setup_irq() by request_irq() 2020-03-05 16:47:35 +01:00
cevt-txx9.c mips: kernel: convert comma to semicolon 2020-12-28 22:32:28 +01:00
cmpxchg.c MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
cps-vec-ns16550.S mips: Add CPS_NS16550_WIDTH config 2020-05-22 09:12:52 +02:00
cps-vec.S MIPS: cps-vec: Use macros for 64bits access 2024-02-20 12:44:59 +01:00
cpu-probe.c Just cleanups and fixes 2024-01-17 11:20:50 -08:00
cpu-r3k-probe.c mips: move cache declarations into header 2023-12-10 17:21:41 -08:00
crash_dump.c vmcore: convert copy_oldmem_page() to take an iov_iter 2022-04-29 14:37:59 -07:00
crash.c
csrc-bcm1480.c
csrc-ioasic.c
csrc-r4k.c mips: csrc-r4k: Mark R4K timer as unstable if CPU freq changes 2020-05-22 09:14:06 +02:00
csrc-sb1250.c
early_printk_8250.c
early_printk.c
elf.c mips: Call lose_fpu(0) before initializing fcr31 in mips_set_personality_nan 2024-01-27 11:08:04 +01:00
entry.S MIPS: Remove TX39XX support 2022-03-01 10:07:22 +01:00
fpu-probe.c MIPS: cpu-probe: move fpu probing/handling into its own file 2020-10-12 12:04:50 +02:00
fpu-probe.h MIPS: cpu-probe: move fpu probing/handling into its own file 2020-10-12 12:04:50 +02:00
ftrace.c MIPS: kernel: Remove not needed set_fs calls 2021-04-06 14:36:56 +02:00
genex.S MIPS: Allow vectored interrupt handler to reside everywhere for 64bit 2023-12-30 15:36:01 +01:00
gpio_txx9.c
head.S MIPS: of: Introduce helper function to get DTB 2021-02-04 13:34:51 +01:00
i8253.c MIPS: Replace setup_irq() by request_irq() 2020-03-05 16:47:35 +01:00
idle.c cpuidle,arch: Mark all regular cpuidle_state:: Enter methods __cpuidle 2023-01-13 11:48:18 +01:00
irq_txx9.c MIPS: Remove TX39XX support 2022-03-01 10:07:22 +01:00
irq-gt641xx.c
irq-msc01.c
irq.c MIPS: Only use current_stack_pointer on GCC 2022-03-14 15:02:53 +01:00
jump_label.c MIPS: jump_label: Fix compat branch range check 2022-11-11 15:46:03 +01:00
kgdb.c MIPS: kernel: Drop kgdb_call_nmi_hook 2021-02-15 12:23:54 +01:00
kprobes.c MIPS: Fix typos 2024-01-08 10:39:12 +01:00
linux32.c mips: add asm/syscalls.h header 2023-12-10 17:21:38 -08:00
machine_kexec.c mips: kexec: include linux/reboot.h 2023-12-10 17:21:42 -08:00
Makefile mips, kexec: fix the incorrect ifdeffery and dependency of CONFIG_KEXEC 2023-12-12 17:20:18 -08:00
mcount.S mips: replace #include <asm/export.h> with #include <linux/export.h> 2023-08-15 10:22:23 +02:00
mips-cm.c mips: cm: Convert __mips_cm_phys_base() to weak function 2024-03-11 14:02:15 +01:00
mips-cpc.c mips: cpc: Fix refcount leak in mips_cpc_default_phys_base 2022-04-26 15:11:25 +02:00
mips-mt-fpaff.c mips: add asm/syscalls.h header 2023-12-10 17:21:38 -08:00
mips-mt.c mips: mt: make mt_class constant 2024-03-07 17:18:50 +01:00
mips-r2-to-r6-emul.c MIPS: Fix build error due to PTR used in more places 2022-01-27 09:04:19 +01:00
module.c mips: move jump_label_apply_nops() declaration to header 2023-12-10 17:21:40 -08:00
octeon_switch.S mips: remove unneeded #include <asm/export.h> 2023-08-15 10:22:23 +02:00
perf_event_mipsxx.c MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
perf_event.c
perf_regs.c MIPS: kernel: Support extracting off-line stack traces from user-space with perf 2021-02-04 21:55:45 +01:00
pm-cps.c MIPS: pm-cps: Use GPR number macros 2024-02-20 12:41:52 +01:00
pm.c
probes-common.h
proc.c MIPS: cpuinfo: Fix a warning for CONFIG_CPUMASK_OFFSTACK 2022-07-14 11:49:40 +02:00
process.c MIPS: kernel: Clear FPU states when setting up kernel threads 2023-12-05 18:47:11 +01:00
prom.c mips: Set dump-stack arch description 2023-12-21 15:33:44 +01:00
ptrace32.c mm: don't include asm/pgtable.h if linux/mm.h is already included 2020-06-09 09:39:13 -07:00
ptrace.c MIPS: scall: Save thread_info.syscall unconditionally on entry 2024-04-09 16:52:21 +02:00
r4k_fpu.S mips: replace #include <asm/export.h> with #include <linux/export.h> 2023-08-15 10:22:23 +02:00
r4k_switch.S
r4k-bugs64.c mips: add missing declarations for trap handlers 2023-12-10 17:21:38 -08:00
r2300_fpu.S mips: replace #include <asm/export.h> with #include <linux/export.h> 2023-08-15 10:22:23 +02:00
r2300_switch.S mips: remove unneeded #include <asm/export.h> 2023-08-15 10:22:23 +02:00
relocate_kernel.S MIPS: Fix typos 2024-01-08 10:39:12 +01:00
relocate.c MIPS: Fix typos 2024-01-08 10:39:12 +01:00
reset.c mips: Use do_kernel_power_off() 2022-05-19 19:30:31 +02:00
rtlx-mt.c mips: mt: make mt_class constant 2024-03-07 17:18:50 +01:00
rtlx.c
scall32-o32.S MIPS: scall: Save thread_info.syscall unconditionally on entry 2024-04-09 16:52:21 +02:00
scall64-n32.S MIPS: scall: Save thread_info.syscall unconditionally on entry 2024-04-09 16:52:21 +02:00
scall64-n64.S MIPS: scall: Save thread_info.syscall unconditionally on entry 2024-04-09 16:52:21 +02:00
scall64-o32.S MIPS: scall: Save thread_info.syscall unconditionally on entry 2024-04-09 16:52:21 +02:00
segment.c mips: kernel: convert to DEFINE_SHOW_ATTRIBUTE 2022-09-19 16:40:17 +02:00
setup.c mips, crash: wrap crash dumping code into crash related ifdefs 2024-02-23 17:48:24 -08:00
signal32.c mips: add asm/syscalls.h header 2023-12-10 17:21:38 -08:00
signal_n32.c mips: signal: move sigcontext declarations to header 2023-12-10 17:21:39 -08:00
signal_o32.c mips: add asm/syscalls.h header 2023-12-10 17:21:38 -08:00
signal-common.h mips: signal: move sigcontext declarations to header 2023-12-10 17:21:39 -08:00
signal.c Just cleanups and fixes 2024-01-17 11:20:50 -08:00
smp-bmips.c mips, kexec: fix the incorrect ifdeffery and dependency of CONFIG_KEXEC 2023-12-12 17:20:18 -08:00
smp-cps.c MIPS: Allows relocation exception vectors everywhere 2024-02-20 12:44:59 +01:00
smp-mt.c MIPS: Rework smt cmdline parameters 2023-06-09 10:34:14 +02:00
smp-up.c
smp.c Quite a lot of kexec work this time around. Many singleton patches in 2024-01-09 11:46:20 -08:00
spinlock_test.c mips: kernel: use DEFINE_DEBUGFS_ATTRIBUTE with debugfs_create_file_unsafe() 2021-03-14 14:09:49 +01:00
spram.c mips: spram: fix missing prototype warning for spram_config 2023-12-10 17:21:41 -08:00
stacktrace.c
sync-r4k.c MIPS: sync-r4k: do slave counter synchronization with disabled HW interrupts 2020-01-22 10:16:18 -08:00
syscall.c mips: add asm/syscalls.h header 2023-12-10 17:21:38 -08:00
sysrq.c tty: sysrq: switch sysrq handlers from int to u8 2023-07-25 19:21:03 +02:00
time.c MIPS: Fix CP0 counter erratum detection for R4k CPUs 2022-04-29 15:52:00 +02:00
topology.c drivers/base/node: consolidate node device subsystem initialization in node_dev_init() 2022-03-22 15:57:10 -07:00
traps.c MIPS: traps: Give more explanations if ebase doesn't belong to KSEG0 2024-02-20 12:44:59 +01:00
unaligned.c mips: add missing declarations for trap handlers 2023-12-10 17:21:38 -08:00
uprobes.c MIPS: uprobes: Restore thread.trap_nr 2023-04-24 13:31:44 +02:00
vdso.c MIPS: vdso: Use generic union vdso_data_store 2024-02-20 20:56:01 +01:00
vmlinux.lds.S MIPS: Define RUNTIME_DISCARD_EXIT in LD script 2023-04-21 23:59:43 +02:00
vpe-mt.c MIPS: Implement microMIPS MT ASE helpers 2024-02-23 10:13:47 +01:00
vpe.c MIPS: Fix typos 2024-01-08 10:39:12 +01:00
watch.c MIPS: Use fallthrough for arch/mips 2020-05-07 11:55:47 +02:00