adds new lantiq kernel. once the codebase is fully tested and know to be working...
[openwrt/openwrt.git] / target / linux / lantiq / patches / 110-machine.patch
1 --- a/arch/mips/lantiq/setup.c
2 +++ b/arch/mips/lantiq/setup.c
3 @@ -13,7 +13,8 @@
4 #include <linux/ioport.h>
5
6 #include <lantiq.h>
7 -#include <lantiq_regs.h>
8 +
9 +#include <machine.h>
10
11 void __init
12 plat_mem_setup(void)
13 @@ -46,3 +47,25 @@ plat_mem_setup(void)
14 memsize *= 1024 * 1024;
15 add_memory_region(0x00000000, memsize, BOOT_MEM_RAM);
16 }
17 +
18 +static int __init
19 +lq_machine_setup(void)
20 +{
21 + mips_machine_setup();
22 + return 0;
23 +}
24 +
25 +static void __init
26 +mach_generic_init(void)
27 +{
28 +}
29 +
30 +MIPS_MACHINE(LANTIQ_MACH_GENERIC,
31 + "Generic",
32 + "Generic",
33 + mach_generic_init);
34 +
35 +arch_initcall(lq_machine_setup);
36 +
37 +/* for backward compatibility, define "board=" as alias for "machtype=" */
38 +__setup("board=", mips_machtype_setup);
39 --- /dev/null
40 +++ b/arch/mips/include/asm/mach-lantiq/machine.h
41 @@ -0,0 +1,14 @@
42 +#include <asm/mips_machine.h>
43 +
44 +enum lantiq_mach_type {
45 + LANTIQ_MACH_GENERIC,
46 +
47 + /* FALCON */
48 + LANTIQ_MACH_EASY98000, /* Falcon Eval Board, NOR Flash */
49 + LANTIQ_MACH_EASY98020, /* Falcon Reference Board */
50 +
51 + /* XWAY */
52 + LANTIQ_MACH_EASY4010, /* Twinpass evalkit */
53 + LANTIQ_MACH_EASY50712, /* Danube evalkit */
54 + LANTIQ_MACH_EASY50812, /* AR9 eval board */
55 +};