aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZubin Mithra <[email protected]>2018-09-12 09:45:10 -0700
committerIngo Molnar <[email protected]>2018-09-12 21:16:16 +0200
commit49e73246cbe6fe0df9cae2db87f31cdc3a0b2b61 (patch)
tree8f45b27f95a32ff5f352d082d0af583c075a7dde
parentcbdd96f5586151e48317d90a403941ec23f12660 (diff)
perf/x86/intel/pt: Annotate 'pt_cap_group' with __ro_after_init
'pt_cap_group' is written to in pt_pmu_hw_init() and not modified after. This makes it a suitable candidate for annotating as __ro_after_init. Signed-off-by: Zubin Mithra <[email protected]> Reviewed-by: Guenter Roeck <[email protected]> Cc: Linus Torvalds <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: [email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Ingo Molnar <[email protected]>
-rw-r--r--arch/x86/events/intel/pt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/events/intel/pt.c b/arch/x86/events/intel/pt.c
index 8d016ce5b80d..3a0aa83cbd07 100644
--- a/arch/x86/events/intel/pt.c
+++ b/arch/x86/events/intel/pt.c
@@ -95,7 +95,7 @@ static ssize_t pt_cap_show(struct device *cdev,
return snprintf(buf, PAGE_SIZE, "%x\n", pt_cap_get(cap));
}
-static struct attribute_group pt_cap_group = {
+static struct attribute_group pt_cap_group __ro_after_init = {
.name = "caps",
};