public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Fix Blackfin HARDWARE_PM support
@ 2008-01-15 17:42 Mathieu Desnoyers
  2008-01-15 20:22 ` Robin Getz
  2008-01-16  2:25 ` Bryan Wu
  0 siblings, 2 replies; 3+ messages in thread
From: Mathieu Desnoyers @ 2008-01-15 17:42 UTC (permalink / raw)
  To: Linus Torvalds, Adrian Bunk, Randy Dunlap, bryan.wu, Robin Getz
  Cc: linux-kernel

This patch restores the blackfin Hardware Performance Monitor Profiling
support that was killed by
commit 09cadedbdc01f1a4bea1f427d4fb4642eaa19da9.

Since there seems to be no good reason to behave differently from other
architectures, it now automatically selects the hardware performance counters
whenever the profiling is activated.

mach-common/irqpanic.c: pm_overflow
calls pm_overflow_handler which is in oprofile/op_model_bf533.c. I doubt that
setting HARDWARE_PM as "m" will work at all, since the pm_overflow_handler
should be in the core kernel image because it is called by irqpanic.c.

Therefore, I change HARDWARE_PM from a tristate to a bool.

The whole arch/$(ARCH)/oprofile/ is built depending on CONFIG_OPROFILE. Since
part of the HARDWARE_PM support files sits in this directory, it makes sense to
also depend on OPROFILE, not only PROFILING. Since OPROFILE already depends on
PROFILING, it is correct to only depend on OPROFILE only.

Thanks to Adrian Bunk for finding this bug and providing an initial
patch.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
CC: Linus Torvalds <torvalds@linux-foundation.org>
CC: Adrian Bunk <adrian.bunk@movial.fi>
CC: Randy Dunlap <randy.dunlap@oracle.com>
CC: bryan.wu@analog.com
CC: Robin Getz <rgetz@blackfin.uclinux.org>
---
 arch/blackfin/Kconfig |    4 ++++
 1 file changed, 4 insertions(+)

Index: linux-2.6-lttng/arch/blackfin/Kconfig
===================================================================
--- linux-2.6-lttng.orig/arch/blackfin/Kconfig	2007-12-29 11:00:05.000000000 -0500
+++ linux-2.6-lttng/arch/blackfin/Kconfig	2007-12-29 11:25:39.000000000 -0500
@@ -65,6 +65,10 @@ config GENERIC_CALIBRATE_DELAY
 	bool
 	default y
 
+config HARDWARE_PM
+	def_bool y
+	depends on OPROFILE
+
 source "init/Kconfig"
 source "kernel/Kconfig.preempt"
 


-- 
Mathieu Desnoyers
Computer Engineering Ph.D. Student, Ecole Polytechnique de Montreal
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F  BA06 3F25 A8FE 3BAE 9A68

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

end of thread, other threads:[~2008-01-16  2:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-15 17:42 Fix Blackfin HARDWARE_PM support Mathieu Desnoyers
2008-01-15 20:22 ` Robin Getz
2008-01-16  2:25 ` Bryan Wu

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