summaryrefslogtreecommitdiff
path: root/target/linux/adm5120/files/arch/mips
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2008-01-30 15:25:48 +0000
committerGabor Juhos <juhosg@openwrt.org>2008-01-30 15:25:48 +0000
commit128bb0967a612a4359d29173f4d11a1716e5bf2a (patch)
treed4aa6c5844db9d0bef508776694aac64ebe22352 /target/linux/adm5120/files/arch/mips
parent9bfca5ce18c5d02afc66a1c61fd85288d7af5d9e (diff)
downloadmtk-20170518-128bb0967a612a4359d29173f4d11a1716e5bf2a.zip
mtk-20170518-128bb0967a612a4359d29173f4d11a1716e5bf2a.tar.gz
mtk-20170518-128bb0967a612a4359d29173f4d11a1716e5bf2a.tar.bz2
add preliminary support for 2.6.24
SVN-Revision: 10329
Diffstat (limited to 'target/linux/adm5120/files/arch/mips')
-rw-r--r--target/linux/adm5120/files/arch/mips/adm5120/setup.c6
-rw-r--r--target/linux/adm5120/files/arch/mips/adm5120/time.c5
2 files changed, 9 insertions, 2 deletions
diff --git a/target/linux/adm5120/files/arch/mips/adm5120/setup.c b/target/linux/adm5120/files/arch/mips/adm5120/setup.c
index ca50985..9046057 100644
--- a/target/linux/adm5120/files/arch/mips/adm5120/setup.c
+++ b/target/linux/adm5120/files/arch/mips/adm5120/setup.c
@@ -23,6 +23,7 @@
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/io.h>
+#include <linux/version.h>
#include <asm/reboot.h>
#include <asm/time.h>
@@ -59,7 +60,10 @@ void __init plat_mem_setup(void)
adm5120_mem_init();
adm5120_report();
- board_time_init = adm5120_time_init;
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,24))
+extern void plat_time_init(void) __init;
+ board_time_init = plat_time_init;
+#endif
_machine_restart = adm5120_restart;
_machine_halt = adm5120_halt;
diff --git a/target/linux/adm5120/files/arch/mips/adm5120/time.c b/target/linux/adm5120/files/arch/mips/adm5120/time.c
index b36cea6..66eb1ce 100644
--- a/target/linux/adm5120/files/arch/mips/adm5120/time.c
+++ b/target/linux/adm5120/files/arch/mips/adm5120/time.c
@@ -21,6 +21,7 @@
#include <linux/init.h>
#include <linux/interrupt.h>
#include <linux/timex.h>
+#include <linux/version.h>
#include <asm/irq.h>
#include <asm/cpu.h>
@@ -29,11 +30,12 @@
#include <adm5120_info.h>
#include <adm5120_irq.h>
-void __init adm5120_time_init(void)
+void __init plat_time_init(void)
{
mips_hpt_frequency = adm5120_speed / 2;
}
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,24))
void __init plat_timer_setup(struct irqaction *irq)
{
clear_c0_status(ST0_BEV);
@@ -41,3 +43,4 @@ void __init plat_timer_setup(struct irqaction *irq)
/* Install ISR for CPU Counter interrupt */
setup_irq(ADM5120_IRQ_COUNTER, irq);
}
+#endif