oprofile, x86: updates for AMD family 15h systems
cover oprofile, x86: updates for AMD family 15h systems
(resending due to mail corruption)
This patch set adds support for AMD family 15h systems. It adds cpu detection code for family 15h and implements support for 6 counters.
Suravee already sent updates for the oprofile userland to the oprofile mailing list.
Please review. If the patches are fine I will apply them to the oprofile git repostitory on kernel.org.
Thanks,
-Robert
PATCH 1/2 oprofile, x86: Add support for AMD family 15h
This patch adds support for AMD family 15h (Interlagos/Valencia/ Zambezi) cpus.
--- arch/x86/oprofile/nmi_int.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)
arch/x86/oprofile/nmi_int.c +3 -0
@@ -732,6 +732,9 @@ int __init op_nmi_init(struct oprofile_operations *ops)case 0x14 : cpu_type ="x86-64/family14h" ;break ; +case 0x15 : + cpu_type ="x86-64/family15h" ; +break ;default :return -ENODEV ; }
Signature · 1 line
1.7.3.2
PATCH 2/2 oprofile, x86: Add support for 6 counters (AMD family 15h)
In reply to Robert RichterThis patch adds support for up to 6 hardware counters for AMD family 15h cpus. There is a new MSR range for hardware counters beginning at MSRC001_0200 Performance Event Select (PERF_CTL0).
--- arch/x86/include/asm/msr-index.h | 4 +++ arch/x86/oprofile/op_model_amd.c | 54 +++++++++++++++++++++++++------------ 2 files changed, 40 insertions(+), 18 deletions(-)
arch/x86/include/asm/msr-index.h +4 -0
@@ -123,6 +123,10 @@#define MSR_AMD64_IBSCTL 0xc001103a#define MSR_AMD64_IBSBRTARGET 0xc001103b +/* Fam 15h MSRs */ +#define MSR_F15H_PERF_CTL 0xc0010200 +#define MSR_F15H_PERF_CTR 0xc0010201 +/* Fam 10h MSRs */ #define MSR_FAM10H_MMIO_CONF_BASE 0xc0010058#define FAM10H_MMIO_CONF_ENABLE (1<<0)
arch/x86/oprofile/op_model_amd.c +36 -18
143 lines not on this page · raw message
Signature · 1 line
1.7.3.2
Quoted 10 lines · Robert Richter
(resending due to mail corruption)
This patch set adds support for AMD family 15h systems. It adds cpu detection code for family 15h and implements support for 6 counters.
Suravee already sent updates for the oprofile userland to the oprofile mailing list.
Please review. If the patches are fine I will apply them to the oprofile git repostitory on kernel.org.
I applied the patches to
git://git.kernel.org/pub/scm/linux/kernel/git/rric/oprofile.git core
-Robert
Signature · 2 lines
Advanced Micro Devices, Inc. Operating System Research Center