mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] x86/events/amd/iommu: make iommu_pmu const and __initconst
@ 2017-09-19 11:10 Bhumika Goyal
  2017-10-19 14:19 ` [tip:x86/cleanups] x86/events/amd/iommu: Make " tip-bot for Bhumika Goyal
  0 siblings, 1 reply; 2+ messages in thread
From: Bhumika Goyal @ 2017-09-19 11:10 UTC (permalink / raw)
  To: julia.lawall, tglx, mingo, hpa, x86, linux-kernel; +Cc: Bhumika Goyal

Make this const as it is only used during a copy operation. Also, make
it __initconst as it is only used during the init phase and after this
it is not referenced anywhere.

Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
---
 arch/x86/events/amd/iommu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/events/amd/iommu.c b/arch/x86/events/amd/iommu.c
index 3641e24..38b5d41 100644
--- a/arch/x86/events/amd/iommu.c
+++ b/arch/x86/events/amd/iommu.c
@@ -405,7 +405,7 @@ static __init int _init_events_attrs(void)
 	NULL,
 };
 
-static struct pmu iommu_pmu = {
+static const struct pmu iommu_pmu __initconst = {
 	.event_init	= perf_iommu_event_init,
 	.add		= perf_iommu_add,
 	.del		= perf_iommu_del,
-- 
1.9.1

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-10-19 14:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-19 11:10 [PATCH] x86/events/amd/iommu: make iommu_pmu const and __initconst Bhumika Goyal
2017-10-19 14:19 ` [tip:x86/cleanups] x86/events/amd/iommu: Make " tip-bot for Bhumika Goyal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome