Deleted Added
full compact
ofw_machdep.c (190681) ofw_machdep.c (192067)
1/*-
2 * Copyright (C) 1996 Wolfgang Solfrank.
3 * Copyright (C) 1996 TooLs GmbH.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

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

27 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
28 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
29 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 *
31 * $NetBSD: ofw_machdep.c,v 1.5 2000/05/23 13:25:43 tsubai Exp $
32 */
33
34#include <sys/cdefs.h>
1/*-
2 * Copyright (C) 1996 Wolfgang Solfrank.
3 * Copyright (C) 1996 TooLs GmbH.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

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

27 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
28 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
29 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 *
31 * $NetBSD: ofw_machdep.c,v 1.5 2000/05/23 13:25:43 tsubai Exp $
32 */
33
34#include <sys/cdefs.h>
35__FBSDID("$FreeBSD: head/sys/powerpc/aim/ofw_machdep.c 190681 2009-04-04 00:22:44Z nwhitehorn $");
35__FBSDID("$FreeBSD: head/sys/powerpc/aim/ofw_machdep.c 192067 2009-05-14 00:34:26Z nwhitehorn $");
36
37#include <sys/param.h>
38#include <sys/bus.h>
39#include <sys/systm.h>
40#include <sys/conf.h>
41#include <sys/disk.h>
42#include <sys/fcntl.h>
43#include <sys/malloc.h>

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

50#include <dev/ofw/ofw_bus.h>
51
52#include <vm/vm.h>
53#include <vm/vm_param.h>
54#include <vm/vm_page.h>
55
56#include <machine/bus.h>
57#include <machine/md_var.h>
36
37#include <sys/param.h>
38#include <sys/bus.h>
39#include <sys/systm.h>
40#include <sys/conf.h>
41#include <sys/disk.h>
42#include <sys/fcntl.h>
43#include <sys/malloc.h>

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

50#include <dev/ofw/ofw_bus.h>
51
52#include <vm/vm.h>
53#include <vm/vm_param.h>
54#include <vm/vm_page.h>
55
56#include <machine/bus.h>
57#include <machine/md_var.h>
58#include <machine/powerpc.h>
58#include <machine/platform.h>
59#include <machine/ofw_machdep.h>
60
61#define OFMEM_REGIONS 32
62static struct mem_region OFmem[OFMEM_REGIONS + 1], OFavail[OFMEM_REGIONS + 3];
63static struct mem_region OFfree[OFMEM_REGIONS + 3];
64
65struct mem_region64 {
66 vm_offset_t mr_start_hi;

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

139/*
140 * This is called during powerpc_init, before the system is really initialized.
141 * It shall provide the total and the available regions of RAM.
142 * Both lists must have a zero-size entry as terminator.
143 * The available regions need not take the kernel into account, but needs
144 * to provide space for two additional entry beyond the terminating one.
145 */
146void
59#include <machine/ofw_machdep.h>
60
61#define OFMEM_REGIONS 32
62static struct mem_region OFmem[OFMEM_REGIONS + 1], OFavail[OFMEM_REGIONS + 3];
63static struct mem_region OFfree[OFMEM_REGIONS + 3];
64
65struct mem_region64 {
66 vm_offset_t mr_start_hi;

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

139/*
140 * This is called during powerpc_init, before the system is really initialized.
141 * It shall provide the total and the available regions of RAM.
142 * Both lists must have a zero-size entry as terminator.
143 * The available regions need not take the kernel into account, but needs
144 * to provide space for two additional entry beyond the terminating one.
145 */
146void
147mem_regions(struct mem_region **memp, int *memsz,
147ofw_mem_regions(struct mem_region **memp, int *memsz,
148 struct mem_region **availp, int *availsz)
149{
150 phandle_t phandle;
151 int asz, msz, fsz;
152 int i, j;
153 int still_merging;
154 cell_t address_cells;
155

--- 387 unchanged lines hidden ---
148 struct mem_region **availp, int *availsz)
149{
150 phandle_t phandle;
151 int asz, msz, fsz;
152 int i, j;
153 int still_merging;
154 cell_t address_cells;
155

--- 387 unchanged lines hidden ---