Deleted Added
full compact
s5_machdep.c (202849) s5_machdep.c (202954)
1/*-
2 * Copyright (c) 2007 Bruce M. Simpson.
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) 2007 Bruce M. Simpson.
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/sentry5/s5_machdep.c 202849 2010-01-23 00:18:12Z imp $");
28__FBSDID("$FreeBSD: head/sys/mips/sentry5/s5_machdep.c 202954 2010-01-25 00:44:05Z gonzo $");
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

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

114
115 phys_avail[i] = addr;
116 if (i == 0 && addr == 0) {
117 /*
118 * If this is the first physical memory segment probed
119 * from CFE, omit the region at the start of physical
120 * memory where the kernel has been loaded.
121 */
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

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

114
115 phys_avail[i] = addr;
116 if (i == 0 && addr == 0) {
117 /*
118 * If this is the first physical memory segment probed
119 * from CFE, omit the region at the start of physical
120 * memory where the kernel has been loaded.
121 */
122 phys_avail[i] += MIPS_KSEG0_TO_PHYS((vm_offset_t)&end);
122 phys_avail[i] += MIPS_KSEG0_TO_PHYS(kernel_kseg0_end);
123 }
124 phys_avail[i + 1] = addr + len;
125 physmem += len;
126 }
127
128 realmem = btoc(physmem);
129#endif
130

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

182void
183platform_start(__register_t a0, __register_t a1, __register_t a2,
184 __register_t a3)
185{
186 vm_offset_t kernend;
187 uint64_t platform_counter_freq;
188
189 /* clear the BSS and SBSS segments */
123 }
124 phys_avail[i + 1] = addr + len;
125 physmem += len;
126 }
127
128 realmem = btoc(physmem);
129#endif
130

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

182void
183platform_start(__register_t a0, __register_t a1, __register_t a2,
184 __register_t a3)
185{
186 vm_offset_t kernend;
187 uint64_t platform_counter_freq;
188
189 /* clear the BSS and SBSS segments */
190 kernend = round_page((vm_offset_t)&end);
190 kernend = (vm_offset_t)&end;
191 memset(&edata, 0, kernend - (vm_offset_t)(&edata));
192
191 memset(&edata, 0, kernend - (vm_offset_t)(&edata));
192
193 mips_postboot_fixup();
194
193 /* Initialize pcpu stuff */
194 mips_pcpu0_init();
195
196#ifdef CFE
197 /*
198 * Initialize CFE firmware trampolines before
199 * we initialize the low-level console.
200 *

--- 47 unchanged lines hidden ---
195 /* Initialize pcpu stuff */
196 mips_pcpu0_init();
197
198#ifdef CFE
199 /*
200 * Initialize CFE firmware trampolines before
201 * we initialize the low-level console.
202 *

--- 47 unchanged lines hidden ---