OSDN Git Service

x86/intel_rdt/cqm: Add mount,umount support
authorVikas Shivappa <vikas.shivappa@linux.intel.com>
Tue, 25 Jul 2017 21:14:41 +0000 (14:14 -0700)
committerThomas Gleixner <tglx@linutronix.de>
Tue, 1 Aug 2017 20:41:27 +0000 (22:41 +0200)
commit4af4a88e0c9246990f95c88eeba781265f27c58e
treef9f85cf01d25aec85ce75035c2d08df4ab54ea51
parentf3cbeacaa06e2b8c2f3ce8531e9aa3fe1f2762cd
x86/intel_rdt/cqm: Add mount,umount support

Add monitoring support during mount and unmount. Since root directory is
a "ctrl_mon" directory which can control and monitor resources create
the "mon_groups" directory which can hold monitor groups and a
"mon_data" directory which would hold all monitoring data like the rest
of resource groups.

The mount succeeds if either of monitoring or control/allocation is
enabled. If only monitoring is enabled user can still create monitor
groups under the "/sys/fs/resctrl/mon_groups/" and any mkdir under root
would fail. If only control/allocation is enabled all of the monitoring
related directories/files would not exist and resctrl would work in
legacy mode.

Signed-off-by: Vikas Shivappa <vikas.shivappa@linux.intel.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: ravi.v.shankar@intel.com
Cc: tony.luck@intel.com
Cc: fenghua.yu@intel.com
Cc: peterz@infradead.org
Cc: eranian@google.com
Cc: vikas.shivappa@intel.com
Cc: ak@linux.intel.com
Cc: davidcc@google.com
Cc: reinette.chatre@intel.com
Link: http://lkml.kernel.org/r/1501017287-28083-23-git-send-email-vikas.shivappa@linux.intel.com
arch/x86/kernel/cpu/intel_rdt.h
arch/x86/kernel/cpu/intel_rdt_monitor.c
arch/x86/kernel/cpu/intel_rdt_rdtgroup.c