Skip to content

Commit fa7d949

Browse files
babumogersuryasaimadhu
authored andcommitted
x86/resctrl: Rename and move rdt files to a separate directory
New generation of AMD processors add support for RDT (or QOS) features. Together, these features will be called RESCTRL. With more than one vendors supporting these features, it seems more appropriate to rename these files. Create a new directory with the name 'resctrl' and move all the intel_rdt files to the new directory. This way all the resctrl related code resides inside one directory. [ bp: Add SPDX identifier to the Makefile ] Suggested-by: Borislav Petkov <[email protected]> Signed-off-by: Babu Moger <[email protected]> Signed-off-by: Borislav Petkov <[email protected]> Cc: Andrew Morton <[email protected]> Cc: Andy Lutomirski <[email protected]> Cc: Arnd Bergmann <[email protected]> Cc: Brijesh Singh <[email protected]> Cc: "Chang S. Bae" <[email protected]> Cc: David Miller <[email protected]> Cc: David Woodhouse <[email protected]> Cc: Dmitry Safonov <[email protected]> Cc: Fenghua Yu <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Cc: "H. Peter Anvin" <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Jann Horn <[email protected]> Cc: Joerg Roedel <[email protected]> Cc: Jonathan Corbet <[email protected]> Cc: Josh Poimboeuf <[email protected]> Cc: Kate Stewart <[email protected]> Cc: "Kirill A. Shutemov" <[email protected]> Cc: <[email protected]> Cc: Mauro Carvalho Chehab <[email protected]> Cc: Paolo Bonzini <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Philippe Ombredanne <[email protected]> Cc: Pu Wen <[email protected]> Cc: <[email protected]> Cc: "Rafael J. Wysocki" <[email protected]> Cc: Reinette Chatre <[email protected]> Cc: Rian Hunter <[email protected]> Cc: Sherry Hurwitz <[email protected]> Cc: Suravee Suthikulpanit <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Thomas Lendacky <[email protected]> Cc: Tony Luck <[email protected]> Cc: Vitaly Kuznetsov <[email protected]> Cc: <[email protected]> Link: https://lkml.kernel.org/r/[email protected]
1 parent 9ff0119 commit fa7d949

File tree

12 files changed

+20
-19
lines changed

12 files changed

+20
-19
lines changed

arch/x86/kernel/cpu/Makefile

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,10 @@ obj-$(CONFIG_CPU_SUP_CENTAUR) += centaur.o
3636
obj-$(CONFIG_CPU_SUP_TRANSMETA_32) += transmeta.o
3737
obj-$(CONFIG_CPU_SUP_UMC_32) += umc.o
3838

39-
obj-$(CONFIG_INTEL_RDT) += intel_rdt.o intel_rdt_rdtgroup.o intel_rdt_monitor.o
40-
obj-$(CONFIG_INTEL_RDT) += intel_rdt_ctrlmondata.o intel_rdt_pseudo_lock.o
41-
CFLAGS_intel_rdt_pseudo_lock.o = -I$(src)
42-
4339
obj-$(CONFIG_X86_MCE) += mcheck/
4440
obj-$(CONFIG_MTRR) += mtrr/
4541
obj-$(CONFIG_MICROCODE) += microcode/
42+
obj-$(CONFIG_INTEL_RDT) += resctrl/
4643

4744
obj-$(CONFIG_X86_LOCAL_APIC) += perfctr-watchdog.o
4845

arch/x86/kernel/cpu/resctrl/Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# SPDX-License-Identifier: GPL-2.0
2+
obj-$(CONFIG_INTEL_RDT) += core.o rdtgroup.o monitor.o
3+
obj-$(CONFIG_INTEL_RDT) += ctrlmondata.o pseudo_lock.o
4+
CFLAGS_pseudo_lock.o = -I$(src)

arch/x86/kernel/cpu/intel_rdt.c renamed to arch/x86/kernel/cpu/resctrl/core.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@
3030
#include <linux/cpuhotplug.h>
3131

3232
#include <asm/intel-family.h>
33-
#include <asm/intel_rdt_sched.h>
34-
#include "intel_rdt.h"
33+
#include <asm/resctrl_sched.h>
34+
#include "internal.h"
3535

3636
#define MBA_IS_LINEAR 0x4
3737
#define MBA_MAX_MBPS U32_MAX

arch/x86/kernel/cpu/intel_rdt_ctrlmondata.c renamed to arch/x86/kernel/cpu/resctrl/ctrlmondata.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
#include <linux/kernfs.h>
2727
#include <linux/seq_file.h>
2828
#include <linux/slab.h>
29-
#include "intel_rdt.h"
29+
#include "internal.h"
3030

3131
/*
3232
* Check whether MBA bandwidth percentage value is correct. The value is

arch/x86/kernel/cpu/intel_rdt.h renamed to arch/x86/kernel/cpu/resctrl/internal.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/* SPDX-License-Identifier: GPL-2.0 */
2-
#ifndef _ASM_X86_INTEL_RDT_H
3-
#define _ASM_X86_INTEL_RDT_H
2+
#ifndef _ASM_X86_RESCTRL_INTERNAL_H
3+
#define _ASM_X86_RESCTRL_INTERNAL_H
44

55
#include <linux/sched.h>
66
#include <linux/kernfs.h>
@@ -568,4 +568,4 @@ void cqm_handle_limbo(struct work_struct *work);
568568
bool has_busy_rmid(struct rdt_resource *r, struct rdt_domain *d);
569569
void __check_limbo(struct rdt_domain *d, bool force_free);
570570

571-
#endif /* _ASM_X86_INTEL_RDT_H */
571+
#endif /* _ASM_X86_RESCTRL_INTERNAL_H */

arch/x86/kernel/cpu/intel_rdt_monitor.c renamed to arch/x86/kernel/cpu/resctrl/monitor.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
#include <linux/module.h>
2727
#include <linux/slab.h>
2828
#include <asm/cpu_device_id.h>
29-
#include "intel_rdt.h"
29+
#include "internal.h"
3030

3131
#define MSR_IA32_QM_CTR 0x0c8e
3232
#define MSR_IA32_QM_EVTSEL 0x0c8d

arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c renamed to arch/x86/kernel/cpu/resctrl/pseudo_lock.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@
2424

2525
#include <asm/cacheflush.h>
2626
#include <asm/intel-family.h>
27-
#include <asm/intel_rdt_sched.h>
27+
#include <asm/resctrl_sched.h>
2828
#include <asm/perf_event.h>
2929

3030
#include "../../events/perf_event.h" /* For X86_CONFIG() */
31-
#include "intel_rdt.h"
31+
#include "internal.h"
3232

3333
#define CREATE_TRACE_POINTS
34-
#include "intel_rdt_pseudo_lock_event.h"
34+
#include "pseudo_lock_event.h"
3535

3636
/*
3737
* MSR_MISC_FEATURE_CONTROL register enables the modification of hardware

arch/x86/kernel/cpu/intel_rdt_pseudo_lock_event.h renamed to arch/x86/kernel/cpu/resctrl/pseudo_lock_event.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,5 @@ TRACE_EVENT(pseudo_lock_l3,
3939

4040
#undef TRACE_INCLUDE_PATH
4141
#define TRACE_INCLUDE_PATH .
42-
#define TRACE_INCLUDE_FILE intel_rdt_pseudo_lock_event
42+
#define TRACE_INCLUDE_FILE pseudo_lock_event
4343
#include <trace/define_trace.h>

arch/x86/kernel/cpu/intel_rdt_rdtgroup.c renamed to arch/x86/kernel/cpu/resctrl/rdtgroup.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@
3535

3636
#include <uapi/linux/magic.h>
3737

38-
#include <asm/intel_rdt_sched.h>
39-
#include "intel_rdt.h"
38+
#include <asm/resctrl_sched.h>
39+
#include "internal.h"
4040

4141
DEFINE_STATIC_KEY_FALSE(rdt_enable_key);
4242
DEFINE_STATIC_KEY_FALSE(rdt_mon_enable_key);

arch/x86/kernel/process_32.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
#include <asm/debugreg.h>
5757
#include <asm/switch_to.h>
5858
#include <asm/vm86.h>
59-
#include <asm/intel_rdt_sched.h>
59+
#include <asm/resctrl_sched.h>
6060
#include <asm/proto.h>
6161

6262
void __show_regs(struct pt_regs *regs, enum show_regs_mode mode)

arch/x86/kernel/process_64.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
#include <asm/switch_to.h>
5353
#include <asm/xen/hypervisor.h>
5454
#include <asm/vdso.h>
55-
#include <asm/intel_rdt_sched.h>
55+
#include <asm/resctrl_sched.h>
5656
#include <asm/unistd.h>
5757
#include <asm/fsgsbase.h>
5858
#ifdef CONFIG_IA32_EMULATION

0 commit comments

Comments
 (0)