dgn3500 support with eeprom loading from sysfs
[openwrt/staging/florian.git] / target / linux / lantiq / patches-3.2 / 0017-MIPS-lantiq-enable-oprofile-support-on-lantiq-target.patch
1 From 476a5cd7924926236c2356654da639fea90a8fea Mon Sep 17 00:00:00 2001
2 From: John Crispin <blogic@openwrt.org>
3 Date: Wed, 24 Aug 2011 13:28:55 +0200
4 Subject: [PATCH 17/73] MIPS: lantiq: enable oprofile support on lantiq
5 targets
6
7 This patch sets the performance counters irq and HAVE_OPROFILE flag for Lantiq
8 SoCs.
9
10 Signed-off-by: John Crispin <blogic@openwrt.org>
11 ---
12 arch/mips/Kconfig | 1 +
13 arch/mips/lantiq/irq.c | 5 +++++
14 2 files changed, 6 insertions(+), 0 deletions(-)
15
16 --- a/arch/mips/Kconfig
17 +++ b/arch/mips/Kconfig
18 @@ -226,6 +226,7 @@ config LANTIQ
19 select SWAP_IO_SPACE
20 select BOOT_RAW
21 select HAVE_CLK
22 + select HAVE_OPROFILE
23 select MIPS_MACHINE
24
25 config LASAT
26 --- a/arch/mips/lantiq/irq.c
27 +++ b/arch/mips/lantiq/irq.c
28 @@ -40,6 +40,9 @@
29
30 #define MAX_EIU 6
31
32 +/* the performance counter */
33 +#define LTQ_PERF_IRQ (INT_NUM_IM4_IRL0 + 31)
34 +
35 /* irqs generated by device attached to the EBU need to be acked in
36 * a special manner
37 */
38 @@ -318,6 +321,8 @@ void __init arch_init_irq(void)
39 set_c0_status(IE_SW0 | IE_SW1 | IE_IRQ0 | IE_IRQ1 |
40 IE_IRQ2 | IE_IRQ3 | IE_IRQ4 | IE_IRQ5);
41 #endif
42 +
43 + cp0_perfcount_irq = LTQ_PERF_IRQ;
44 }
45
46 unsigned int __cpuinit get_c0_compare_int(void)