Deleted Added
full compact
ar71xx_machdep.c (202954) ar71xx_machdep.c (211476)
1/*-
2 * Copyright (c) 2009 Oleksandr Tymoshenko
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 11 unchanged lines hidden (view full) ---

20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 */
26
27#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2009 Oleksandr Tymoshenko
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 11 unchanged lines hidden (view full) ---

20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 */
26
27#include <sys/cdefs.h>
28__FBSDID("$FreeBSD: head/sys/mips/atheros/ar71xx_machdep.c 202954 2010-01-25 00:44:05Z gonzo $");
28__FBSDID("$FreeBSD: head/sys/mips/atheros/ar71xx_machdep.c 211476 2010-08-19 02:03:12Z adrian $");
29
30#include <sys/param.h>
31#include <machine/cpuregs.h>
32
33#include <mips/sentry5/s5reg.h>
34
35#include "opt_ddb.h"
36

--- 15 unchanged lines hidden (view full) ---

52#include <machine/cpu.h>
53#include <machine/hwfunc.h>
54#include <machine/md_var.h>
55#include <machine/trap.h>
56#include <machine/vmparam.h>
57
58#include <mips/atheros/ar71xxreg.h>
59
29
30#include <sys/param.h>
31#include <machine/cpuregs.h>
32
33#include <mips/sentry5/s5reg.h>
34
35#include "opt_ddb.h"
36

--- 15 unchanged lines hidden (view full) ---

52#include <machine/cpu.h>
53#include <machine/hwfunc.h>
54#include <machine/md_var.h>
55#include <machine/trap.h>
56#include <machine/vmparam.h>
57
58#include <mips/atheros/ar71xxreg.h>
59
60#include <mips/atheros/ar71xx_setup.h>
61#include <mips/atheros/ar71xx_cpudef.h>
62
60extern char edata[], end[];
61
62uint32_t ar711_base_mac[ETHER_ADDR_LEN];
63/* 4KB static data aread to keep a copy of the bootload env until
64 the dynamic kenv is setup */
65char boot1_env[4096];
66
67/*

--- 129 unchanged lines hidden (view full) ---

197 physmem = realmem;
198
199 /*
200 * ns8250 uart code uses DELAY so ticker should be inititalized
201 * before cninit. And tick_init_params refers to hz, so * init_param1
202 * should be called first.
203 */
204 init_param1();
63extern char edata[], end[];
64
65uint32_t ar711_base_mac[ETHER_ADDR_LEN];
66/* 4KB static data aread to keep a copy of the bootload env until
67 the dynamic kenv is setup */
68char boot1_env[4096];
69
70/*

--- 129 unchanged lines hidden (view full) ---

200 physmem = realmem;
201
202 /*
203 * ns8250 uart code uses DELAY so ticker should be inititalized
204 * before cninit. And tick_init_params refers to hz, so * init_param1
205 * should be called first.
206 */
207 init_param1();
208
209 /* Detect the system type - this is needed for subsequent chipset-specific calls */
210 ar71xx_detect_sys_type();
211 ar71xx_detect_sys_frequency();
212
205 platform_counter_freq = ar71xx_cpu_freq();
206 mips_timer_init_params(platform_counter_freq, 1);
207 cninit();
208 init_static_kenv(boot1_env, sizeof(boot1_env));
209
213 platform_counter_freq = ar71xx_cpu_freq();
214 mips_timer_init_params(platform_counter_freq, 1);
215 cninit();
216 init_static_kenv(boot1_env, sizeof(boot1_env));
217
218 printf("CPU platform: %s\n", ar71xx_get_system_type());
219 printf("CPU Frequency=%d MHz\n", u_ar71xx_cpu_freq / 1000000);
220 printf("CPU DDR Frequency=%d MHz\n", u_ar71xx_ddr_freq / 1000000);
221 printf("CPU AHB Frequency=%d MHz\n", u_ar71xx_ahb_freq / 1000000);
222
210 printf("platform frequency: %lld\n", platform_counter_freq);
211 printf("arguments: \n");
212 printf(" a0 = %08x\n", a0);
213 printf(" a1 = %08x\n", a1);
214 printf(" a2 = %08x\n", a2);
215 printf(" a3 = %08x\n", a3);
216
217 printf("Cmd line:");

--- 52 unchanged lines hidden ---
223 printf("platform frequency: %lld\n", platform_counter_freq);
224 printf("arguments: \n");
225 printf(" a0 = %08x\n", a0);
226 printf(" a1 = %08x\n", a1);
227 printf(" a2 = %08x\n", a2);
228 printf(" a3 = %08x\n", a3);
229
230 printf("Cmd line:");

--- 52 unchanged lines hidden ---