FreeBSD on e500mc 36bit physical addressing
Aleksey Fedorov
aleksey.v.fedorov at gmail.com
Sun Sep 23 12:44:12 UTC 2012
> Hi Aleksey,
> FreeBSD/powerpc does not support the 36-bit physical addr space for Book-E PowerPC as of yet.
>
> Rafal
>
I make some changes to start in 36-bit mode. Now the problem is
'interrupts' property handling during fdtbus probing.
I use dts file from linux. Does FreeBSD require some special dts file
layout compared to linux?
Debug output from kenel boot:
GDB: no debug ports present
KDB: debugger backends: ddb
KDB: current backend: ddb
mmu_booke_bootstrap: entered
msgbufp at 0xc0751000 end = 0xc0769000
ptbl_bufs at 0xc0769000 end = 0xc076f000
kernel ptbls: 224
kernel pdir at 0xc076f000 end = 0xc092f000
data_end: 0xc092f000
updated data_end: 0xc1000000
zero_page_va = 0xc1000000
zero_page_idle_va = 0xc1001000
copy_page_src_va = 0xc1002000
copy_page_dst_va = 0xc1003000
ptbl_buf_pool_vabase = 0xc1004000 end = 0xc2004000
kernel image and allocated data:
kernload = 0x0000000001000000
kernstart = 0xc0000000
kernsize = 0x01000000
processing avail regions:
0000000000100000-0000000100000000 -> 0000000000100000-0000000001000000 = f00000
0000000002000000-0000000100000000 ->
0000000002000000-0000000100000000 = fe000000
fill in phys_avail:
region: 0x0000000000100000 - 0x0000000000ffc000 (0x0000000000efc000)
region: 0x0000000002000000 - 0x0000000100000000 (0x00000000fe000000)
Maxmem = 0x0000000000100000
phys_avail_count = 2
physsz = 0x00000000feefc000 physmem = 1044220 (0x000feefc)
kernel_pmap = 0xc06820ac
kptbl_min = 768, kernel_ptbls = 224
kernel pdir range: 0xc0000000 - 0xf7ffffff
kstack_sz = 0x00004000
kstack0_phys at 0x0000000000ffc000 - 0x0000000001000000
kstack0 at 0xc2005000 - 0xc2009000
virtual_avail = c2009000
virtual_end = f8000000
mmu_booke_bootstrap: exit
L1 D-cache enabled
L1 I-cache enabled
powerpc_smp_first_cpu: cpuid 0
powerpc_smp_next_cpu: cpuid 1
powerpc_smp_next_cpu: cpuid 2
powerpc_smp_next_cpu: cpuid 3
powerpc_smp_next_cpu: cpuid 4
powerpc_smp_next_cpu: cpuid 5
powerpc_smp_next_cpu: cpuid 6
powerpc_smp_next_cpu: cpuid 7
Copyright (c) 1992-2012 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 10.0-CURRENT #134 r239991=44c70c6-dirty: Sun Sep 23 16:18:53 MSK 2012
avf at avfh:/usr/obj/powerpc.powerpc/root/freebsd-head/sys/N710 powerpc
WARNING: WITNESS option enabled, expect reduced performance.
Preloaded elf kernel "/boot/kernel/kernel" at 0xc074f000.
cpu0: Freescale e500mc core revision 2.0
cpu0: Features 84000000<PPC32,MMU>
cpu0: HID0 c0800080<EMCP,b1,DOZE,EN_MAS7_UPDATE>
real memory = 4277125120 (4078 MB)
Physical memory chunk(s):
0x0000000000100000 - 0x0000000000ffbfff, 15712256 bytes (3836 pages)
0x0000000002000000 - 0x00000000fafc4fff, 4177285120 bytes (1019845 pages)
avail memory = 4189515776 (3995 MB)
powerpc_smp_first_cpu: cpuid 0
powerpc_smp_next_cpu: cpuid 1
powerpc_smp_next_cpu: cpuid 2
powerpc_smp_next_cpu: cpuid 3
powerpc_smp_next_cpu: cpuid 4
powerpc_smp_next_cpu: cpuid 5
powerpc_smp_next_cpu: cpuid 6
powerpc_smp_next_cpu: cpuid 7
FreeBSD/SMP: Multiprocessor System Detected: 8 CPUs
cpu0: dev=0 (BSP)
cpu1: dev=1
cpu2: dev=2
cpu3: dev=3
cpu4: dev=4
cpu5: dev=5
cpu6: dev=6
cpu7: dev=7
random device not loaded; using insecure entropy
random: <entropy source, Software, Yarrow>
nfslock: pseudo-device
crypto: <crypto core>
mem: <memory>
openfirm: <Open Firmware control device>
null: <null device, zero device>
nexus0
fdtbus_identify(): fdtbus_identify(driver=0xc04d717c, parent=0xc9e74400)
fdtbus_probe(): fdtbus_probe(dev=0xc9d24a00); pass=2147483647
fdtbus_probe(): fdtbus_probe(dev=0xc9d24a00); pass=2147483647
fdtbus0: <FDT main bus> on nexus0
newbus_device_from_fdt_node(): skipping instantiating FDT device='chosen'
newbus_device_from_fdt_node(): skipping instantiating FDT device='aliases'
fdt_reg_to_rl64(): addr_cells = 2, size_cells = 2
fdt_reg_to_rl64(): tuples = -1, tuple size = 16
newbus_device_create(): added child name='cpus', node=0x1070
newbus_device_from_fdt_node(): skipping instantiating FDT device='memory'
fdt_reg_to_rl64(): addr_cells = 2, size_cells = 2
fdt_reg_to_rl64(): tuples = -1, tuple size = 16
newbus_device_create(): added child name='bman-portals at ff4000000', node=0x1650
fdt_reg_to_rl64(): addr_cells = 2, size_cells = 2
fdt_reg_to_rl64(): tuples = -1, tuple size = 16
newbus_device_create(): added child name='qman-portals at ff4200000', node=0x1da4
fdt_reg_to_rl64(): addr_cells = 2, size_cells = 2
fdt_reg_to_rl64(): tuples = 1, tuple size = 16
fdt_reg_to_rl64(): reg addr start = c00089b0, end = c00099af, count = 1000
newbus_device_create(): added child name='soc at ffe000000', node=0x30b8
fdt_reg_to_rl64(): addr_cells = 2, size_cells = 2
fdt_reg_to_rl64(): tuples = 1, tuple size = 16
fdt_reg_to_rl64(): reg addr start = c012c9b0, end = c012d9af, count = 1000
fdt_intr_to_rl(): no intr-parent phandle
fdt_intr_to_rl(): no intr-cells defined, defaulting to 1
fdt_intr_to_rl(): intr_num=4
unknown: could not process 'interrupts' property for 'localbus at ffe124000'
fatal kernel trap:
exception = 0x2 (data storage interrupt)
virtual address = 0x00000004
srr0 = 0xc00a7a54
srr1 = 0x00001200
curthread = 0xc0504bd0
pid = 0, comm = kernel
[ thread pid 0 tid 100000 ]
Stopped at newbus_device_destroy+0x2c: lwz r3, r3, 0x4
db>
localbus at ffe124000 node in dts file is:
localbus at ffe124000 {
compatible = "fsl,p4080-elbc", "fsl,elbc", "simple-bus";
reg = <0xf 0xfe124000 0 0x1000>;
interrupts = <25 2 0 0>;
interrupt-parent = <&mpic>;
#address-cells = <2>;
#size-cells = <1>;
ranges = <0 0 0xf 0xe8000000 0x08000000
3 0 0xf 0xffdf0000 0x00008000>;
flash at 0,0 {
compatible = "cfi-flash";
reg = <0 0 0x08000000>;
bank-width = <2>;
device-width = <2>;
};
board-control at 3,0 {
compatible = "fsl,n710cpld";
reg = <3 0 0x20>;
};
};
mpic node is:
mpic: pic at 40000 {
clock-frequency = <0>;
interrupt-controller;
#address-cells = <0>;
#interrupt-cells = <4>;
reg = <0x40000 0x40000>;
compatible = "chrp,open-pic";
device_type = "open-pic";
big-endian;
message at 1400 {
compatible = "fsl,mpic-msg";
interrupts = <
0xb0 2 0 0
0xb1 2 0 0
0xb2 2 0 0
0xb3 2 0 0>;
};
};
Why fdt_intr_to_rl() can't find interrupt-parent mpic?
More information about the freebsd-ppc
mailing list