From 428e04c9612d8206ab9e778d7eb3465bc39cc044 Mon Sep 17 00:00:00 2001 From: Juha Tukkinen Date: Tue, 8 Nov 2011 15:40:22 +0200 Subject: gcov-kernel: Add ARM eABI support Based on work by George G. Davis . See http://lwn.net/Articles/390419/ Change-Id: I8df700d20a154e179f8cf6cdfe4015efc5d384f2 Signed-off-by: Juha Tukkinen Reviewed-on: http://git-master/r/62998 Reviewed-by: Peter De Schrijver Reviewed-by: Scott Williams Reviewed-by: Yu-Huan Hsu Rebase-Id: R2607a46c8bd1e521abe44a57a5ccf7317333d6c9 --- kernel/gcov/Kconfig | 8 +++++++- kernel/module.c | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'kernel') diff --git a/kernel/gcov/Kconfig b/kernel/gcov/Kconfig index a92028196cc1..824b741925bb 100644 --- a/kernel/gcov/Kconfig +++ b/kernel/gcov/Kconfig @@ -35,7 +35,7 @@ config GCOV_KERNEL config GCOV_PROFILE_ALL bool "Profile entire Kernel" depends on GCOV_KERNEL - depends on SUPERH || S390 || X86 || (PPC && EXPERIMENTAL) || MICROBLAZE + depends on SUPERH || S390 || X86 || (PPC && EXPERIMENTAL) || MICROBLAZE || ARM default n ---help--- This options activates profiling for the entire kernel. @@ -46,4 +46,10 @@ config GCOV_PROFILE_ALL larger and run slower. Also be sure to exclude files from profiling which are not linked to the kernel image to prevent linker errors. +config GCOV_CTORS + string + depends on CONSTRUCTORS + default ".init_array" if ARM && AEABI + default ".ctors" + endmenu diff --git a/kernel/module.c b/kernel/module.c index 04379f92f843..e0ddcece2be4 100644 --- a/kernel/module.c +++ b/kernel/module.c @@ -2528,7 +2528,7 @@ static void find_module_sections(struct module *mod, struct load_info *info) mod->unused_gpl_crcs = section_addr(info, "__kcrctab_unused_gpl"); #endif #ifdef CONFIG_CONSTRUCTORS - mod->ctors = section_objs(info, ".ctors", + mod->ctors = section_objs(info, CONFIG_GCOV_CTORS, sizeof(*mod->ctors), &mod->num_ctors); #endif -- cgit v1.2.3