Skip to contentSkip to conversation

ia64: remove perfmon

PATCH Applied Christoph Hellwig 3 participants 3 messages Sep 11, 2020 ptrace support

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ia64: remove perfmon

perfmon has been marked broken and thus been disabled for all builds for more than two years. Remove it entirely.

---
 arch/ia64/Kconfig                     |    9 -
 arch/ia64/configs/bigsur_defconfig    |    1 -
 arch/ia64/configs/generic_defconfig   |    1 -
 arch/ia64/configs/gensparse_defconfig |    1 -
 arch/ia64/configs/tiger_defconfig     |    1 -
 arch/ia64/configs/zx1_defconfig       |    1 -
 arch/ia64/include/asm/processor.h     |   10 -
 arch/ia64/include/asm/switch_to.h     |   10 +-
 arch/ia64/kernel/Makefile             |    3 +-
 arch/ia64/kernel/irq_ia64.c           |    7 -
 arch/ia64/kernel/perfmon.c            | 6703 -------------------------
 arch/ia64/kernel/process.c            |   53 -
 arch/ia64/kernel/ptrace.c             |   24 -
 arch/ia64/kernel/smpboot.c            |    8 -
 arch/ia64/kernel/syscalls/syscall.tbl |    2 +-
 arch/ia64/lib/Makefile                |    1 -
 arch/ia64/lib/carta_random.S          |   55 -
 arch/ia64/oprofile/Makefile           |    1 -
 arch/ia64/oprofile/init.c             |   12 +-
 arch/ia64/oprofile/perfmon.c          |   99 -
 20 files changed, 4 insertions(+), 6998 deletions(-)
 delete mode 100644 arch/ia64/kernel/perfmon.c
 delete mode 100644 arch/ia64/lib/carta_random.S
 delete mode 100644 arch/ia64/oprofile/perfmon.c
arch/ia64/Kconfig +0 -9
index 5b4ec80bf5863a..c4c4092733895a 100644
@@ -362,15 +362,6 @@ config ARCH_PROC_KCORE_TEXT
 config IA64_MCA_RECOVERY
 	tristate "MCA recovery from errors other than TLB."
 
-config PERFMON
-	bool "Performance monitor support"
-	depends on BROKEN
-	help
-	  Selects whether support for the IA-64 performance monitor hardware
-	  is included in the kernel.  This makes some kernel data-structures a
-	  little bigger and slows down execution a bit, but it is generally
-	  a good idea to turn this on.  If you're unsure, say Y.
-
 config IA64_PALINFO
 	tristate "/proc/pal support"
 	help
arch/ia64/configs/bigsur_defconfig +0 -1
index f3ba813a5b809b..2ae6d9a32a8d81 100644
@@ -11,7 +11,6 @@ CONFIG_SMP=y
 CONFIG_NR_CPUS=2
 CONFIG_PREEMPT=y
 # CONFIG_VIRTUAL_MEM_MAP is not set
-CONFIG_PERFMON=y
 CONFIG_IA64_PALINFO=y
 CONFIG_EFI_VARS=y
 CONFIG_BINFMT_MISC=m
arch/ia64/configs/generic_defconfig +0 -1
index cb267a07c57f71..19a0809cbacca1 100644
@@ -18,7 +18,6 @@ CONFIG_IA64_CYCLONE=y
 CONFIG_SMP=y
 CONFIG_HOTPLUG_CPU=y
 CONFIG_IA64_MCA_RECOVERY=y
-CONFIG_PERFMON=y
 CONFIG_IA64_PALINFO=y
 CONFIG_KEXEC=y
 CONFIG_CRASH_DUMP=y
arch/ia64/configs/gensparse_defconfig +0 -1
index 7e25f2f031b6d3..69322bf27aa39d 100644
@@ -17,7 +17,6 @@ CONFIG_NR_CPUS=512
 CONFIG_HOTPLUG_CPU=y
 CONFIG_SPARSEMEM_MANUAL=y
 CONFIG_IA64_MCA_RECOVERY=y
-CONFIG_PERFMON=y
 CONFIG_IA64_PALINFO=y
 CONFIG_EFI_VARS=y
 CONFIG_BINFMT_MISC=m
arch/ia64/configs/tiger_defconfig +0 -1
index 3f486d5bdc2d56..bb510e9cc2f51d 100644
@@ -21,7 +21,6 @@ CONFIG_HOTPLUG_CPU=y
 CONFIG_PERMIT_BSP_REMOVE=y
 CONFIG_FORCE_CPEI_RETARGET=y
 CONFIG_IA64_MCA_RECOVERY=y
-CONFIG_PERFMON=y
 CONFIG_IA64_PALINFO=y
 CONFIG_KEXEC=y
 CONFIG_EFI_VARS=y
arch/ia64/configs/zx1_defconfig +0 -1
index 261e98e1f5fe6f..b43acc97854148 100644
@@ -10,7 +10,6 @@ CONFIG_NR_CPUS=16
 CONFIG_HOTPLUG_CPU=y
 CONFIG_FLATMEM_MANUAL=y
 CONFIG_IA64_MCA_RECOVERY=y
-CONFIG_PERFMON=y
 CONFIG_IA64_PALINFO=y
 CONFIG_CRASH_DUMP=y
 CONFIG_EFI_VARS=y
arch/ia64/include/asm/processor.h +0 -10
index 95a2ec37400fb7..2d8bcdc27d7f85 100644
@@ -280,15 +280,6 @@ struct thread_struct {
 	__u64 map_base;			/* base address for get_unmapped_area() */
 	__u64 rbs_bot;			/* the base address for the RBS */
 	int last_fph_cpu;		/* CPU that may hold the contents of f32-f127 */
-
-#ifdef CONFIG_PERFMON
-	void *pfm_context;		     /* pointer to detailed PMU context */
-	unsigned long pfm_needs_checking;    /* when >0, pending perfmon work on kernel exit */
-# define INIT_THREAD_PM		.pfm_context =		NULL,     \
-				.pfm_needs_checking =	0UL,
-#else
-# define INIT_THREAD_PM
-#endif
 	unsigned long dbr[IA64_NUM_DBG_REGS];
 	unsigned long ibr[IA64_NUM_DBG_REGS];
 	struct ia64_fpreg fph[96];	/* saved/loaded on demand */
@@ -301,7 +292,6 @@ struct thread_struct {
 	.map_base =	DEFAULT_MAP_BASE,			\
 	.rbs_bot =	STACK_TOP - DEFAULT_USER_STACK_SIZE,	\
 	.last_fph_cpu =  -1,					\
-	INIT_THREAD_PM						\
 	.dbr =		{0, },					\
 	.ibr =		{0, },					\
 	.fph =		{{{{0}}}, }				\
arch/ia64/include/asm/switch_to.h +1 -9
index 9011e90a6b97c1..a5a4e09468fa91 100644
@@ -31,16 +31,8 @@ extern struct task_struct *ia64_switch_to (void *next_task);
 extern void ia64_save_extra (struct task_struct *task);
 extern void ia64_load_extra (struct task_struct *task);
 
-#ifdef CONFIG_PERFMON
-  DECLARE_PER_CPU(unsigned long, pfm_syst_info);
-# define PERFMON_IS_SYSWIDE() (__this_cpu_read(pfm_syst_info) & 0x1)
-#else
-# define PERFMON_IS_SYSWIDE() (0)
-#endif
-
 #define IA64_HAS_EXTRA_STATE(t)							\
-	((t)->thread.flags & (IA64_THREAD_DBG_VALID|IA64_THREAD_PM_VALID)	\
-	 || PERFMON_IS_SYSWIDE())
+	((t)->thread.flags & (IA64_THREAD_DBG_VALID|IA64_THREAD_PM_VALID))
 
 #define __switch_to(prev,next,last) do {							 \
 	if (IA64_HAS_EXTRA_STATE(prev))								 \
arch/ia64/kernel/Makefile +1 -2
index 1a8df6669eee65..81901c5e542664 100644
@@ -10,7 +10,7 @@ endif
 extra-y	:= head.o vmlinux.lds
 
 obj-y := entry.o efi.o efi_stub.o gate-data.o fsys.o ia64_ksyms.o irq.o irq_ia64.o	\
-	 irq_lsapic.o ivt.o pal.o patch.o process.o perfmon.o ptrace.o sal.o		\
+	 irq_lsapic.o ivt.o pal.o patch.o process.o ptrace.o sal.o		\
 	 salinfo.o setup.o signal.o sys_ia64.o time.o traps.o unaligned.o \
 	 unwind.o mca.o mca_asm.o topology.o dma-mapping.o iosapic.o acpi.o \
 	 acpi-ext.o
@@ -21,7 +21,6 @@ obj-$(CONFIG_IA64_PALINFO)	+= palinfo.o
 obj-$(CONFIG_MODULES)		+= module.o
 obj-$(CONFIG_SMP)		+= smp.o smpboot.o
 obj-$(CONFIG_NUMA)		+= numa.o
-obj-$(CONFIG_PERFMON)		+= perfmon_default_smpl.o
 obj-$(CONFIG_IA64_CYCLONE)	+= cyclone.o
 obj-$(CONFIG_IA64_MCA_RECOVERY)	+= mca_recovery.o
 obj-$(CONFIG_KPROBES)		+= kprobes.o
arch/ia64/kernel/irq_ia64.c +0 -7
index 6fff934150ebbf..46e33c5cb53dc6 100644
@@ -40,10 +40,6 @@
 #include <asm/hw_irq.h>
 #include <asm/tlbflush.h>
 
-#ifdef CONFIG_PERFMON
-# include <asm/perfmon.h>
-#endif
-
 #define IRQ_DEBUG	0
 
 #define IRQ_VECTOR_UNASSIGNED	(0)
@@ -627,9 +623,6 @@ init_IRQ (void)
 				    "irq_move");
 	}
 #endif
-#ifdef CONFIG_PERFMON
-	pfm_init_percpu();
-#endif
 }
 
 void
arch/ia64/kernel/perfmon.c deleted +0 -6703

2,877 lines not on this page · raw message

arch/ia64/kernel/process.c +0 -53

53 lines not on this page · raw message

arch/ia64/kernel/ptrace.c +0 -24
index 33ca9fa0fbf555..75c070aed81e08 100644

Lines of this file are not shown. View the raw message.

arch/ia64/kernel/smpboot.c +0 -8
index c29c600d79674c..093040f7e626a1 100644

Lines of this file are not shown. View the raw message.

arch/ia64/kernel/syscalls/syscall.tbl +1 -1
index f52a41f4c340b8..4799c96c325f14 100644

Lines of this file are not shown. View the raw message.

arch/ia64/lib/Makefile +0 -1
index 82118b38532fdf..081fcba01dc0c0 100644

Lines of this file are not shown. View the raw message.

arch/ia64/lib/carta_random.S deleted +0 -55

55 lines not on this page · raw message

arch/ia64/oprofile/Makefile +0 -1
index cd134d6643bfff..fc7944d462f459 100644

Lines of this file are not shown. View the raw message.

arch/ia64/oprofile/init.c +1 -11
index 31b545c3546085..a692ba16a07ba4 100644

Lines of this file are not shown. View the raw message.

arch/ia64/oprofile/perfmon.c deleted +0 -99

99 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.28.0

Part of the diff is not shown here. View the raw message.

#1 lore raw
Quoted 2 lines · Christoph Hellwig

perfmon has been marked broken and thus been disabled for all builds for more than two years. Remove it entirely.

Enthusiastically-ACKed-by Al Viro <[email protected]>