package: fix insmod on install
[openwrt.git] / target / linux / ramips / patches-3.8 / 0125-MIPS-ralink-add-memory-definition-for-RT3883.patch
1 From de85c6c3e2d5ed9c721a282d91af504a845e1fad Mon Sep 17 00:00:00 2001
2 From: John Crispin <blogic@openwrt.org>
3 Date: Sat, 13 Apr 2013 20:23:19 +0200
4 Subject: [PATCH 125/137] MIPS: ralink: add memory definition for RT3883
5
6 Populate struct soc_info with the data that describes our RAM window.
7
8 Signed-off-by: John Crispin <blogic@openwrt.org>
9 Patchwork: http://patchwork.linux-mips.org/patch/5182/
10 ---
11  arch/mips/include/asm/mach-ralink/rt3883.h |    4 ++++
12  arch/mips/ralink/rt3883.c                  |    4 ++++
13  2 files changed, 8 insertions(+)
14
15 --- a/arch/mips/include/asm/mach-ralink/rt3883.h
16 +++ b/arch/mips/include/asm/mach-ralink/rt3883.h
17 @@ -245,4 +245,8 @@
18  #define RT3883_FLASH_CFG_WIDTH_16BIT   0x1
19  #define RT3883_FLASH_CFG_WIDTH_32BIT   0x2
20  
21 +#define RT3883_SDRAM_BASE              0x00000000
22 +#define RT3883_MEM_SIZE_MIN            2
23 +#define RT3883_MEM_SIZE_MAX            256
24 +
25  #endif /* _RT3883_REGS_H_ */
26 --- a/arch/mips/ralink/rt3883.c
27 +++ b/arch/mips/ralink/rt3883.c
28 @@ -239,4 +239,8 @@ void prom_soc_init(struct ralink_soc_inf
29                 name,
30                 (id >> RT3883_REVID_VER_ID_SHIFT) & RT3883_REVID_VER_ID_MASK,
31                 (id & RT3883_REVID_ECO_ID_MASK));
32 +
33 +       soc_info->mem_base = RT3883_SDRAM_BASE;
34 +       soc_info->mem_size_min = RT3883_MEM_SIZE_MIN;
35 +       soc_info->mem_size_max = RT3883_MEM_SIZE_MAX;
36  }