Progress on running Haiku on VisionFive 2

I recently got VisionFive 2 RISC-V board and trying to run Haiku on it. Photos of board are here: My progress on real RISC-V hardware - #411 by X512.

Current recommended U-Boot version that come with default Debian distro do not supports USB or NVMe boot yet, so I am using SD card for now. It should be possible to start Haiku booting from SD card with Haiku EFI boot loader and kernel with boot drivers and then continue Haiku booting from USB/NVMe when kernel will load PCI/XHCI/NVMe boot drivers.

Hopefully U-Boot have built-in framebuffer support (but with some update artifacts, maybe some write alignment is needed), so it should be possible to boot into Haiku desktop without writing dedicated video drivers.

I currently managed to boot until “PANIC: did not find any boot partitions!” stage. Next it will be needed to write PCI host controller driver (PLDA PCI (linux/pcie-plda.c at JH7110_VisionFive2_devel · starfive-tech/linux · GitHub)) to get USB/NVMe working and continue booting.

Log:

arch_smp_boot_other_cpus(0x80000000000c8d01, 0xffffffc00209878e)
  hart status:
    hart 0: started
    hart 1: stopped
    hart 2: stopped
    hart 3: stopped
  starting CPU 2
  stack: 0xffffffc0026ea000 - 0xffffffc0026eefff
a  rsctha_rctpiu_nge nCtPrUy 23(2
)
  
stack: 0xffffffc0026ef000 - 0xffffffc0026f3fff
a r csht_acrtpui_negn tCrPyU 2(43
)
 
 
stack: 0xffffffc0026f4000 - 0xffffffc0026f8fff
a r chhar_ctp us_teanttusry:2
(
 4 ) 
 
hart 0: started
    hart 1: started
    hart 2: started
    hart 3: started
arch_enter_kernel(satp: 0x80000000000c8d01, kernelArgs: 0xcc591c48, kernelEntry: 0xffffffc00209878e, sp: 0xffffffc00280b000)
Welcome to kernel debugger output!
Haiku revision: hrev56792+44, debug level: 2
vm_translation_map_init: entry
physical memory ranges:
  40080000 - 47ef1000
  47f0f000 - c0110000
  c0200000 - cb579000
  cb57a000 - cb57d000
  cb580000 - cb581000
  cb585000 - ccda4000
  ccda5000 - 240000000
allocated physical ranges:
  c7a2f000 - c9513000
  c9514000 - cb514000
  cb593000 - ccda4000
  ccda5000 - f0000000
  f2000000 - 100000000
allocated virtual ranges:
  10000000 - 10010000
  c8d02000 - c9513000
  c9514000 - cb571000
  cb579000 - cb57a000
  cb57d000 - cb580000
  cb581000 - cb585000
  cb593000 - f0000000
  f2000000 - 100000000
  ffffffc002000000 - ffffffc006831000
  fffffffe00080000 - 0
kernel args ranges:
  ffffffc002000000 - ffffffc002010000
  ffffffc00226e000 - ffffffc002309000
  ffffffc00235d000 - ffffffc00236d000
  ffffffc002399000 - ffffffc0023a9000
  ffffffc0023cc000 - ffffffc0023dc000
  ffffffc002479000 - ffffffc0024a6000
  ffffffc0024b7000 - ffffffc0024c7000
  ffffffc002507000 - ffffffc002517000
  ffffffc002556000 - ffffffc002566000
  ffffffc00258d000 - ffffffc00259d000
  ffffffc0025ca000 - ffffffc0025da000
  ffffffc00265a000 - ffffffc00266a000
  ffffffc002693000 - ffffffc0026b0000
  ffffffc0026ce000 - ffffffc0026de000
  ffffffc0026f9000 - ffffffc002705000
physMapBase: 0xfffffffe00080000
physMemBase: 0x40080000
mark_page_range_in_use(0x0, 0x40080): start page is before free list
reserve_boot_loader_ranges(): Skipping range: 0x0000000010000000, 65536
reserve_boot_loader_ranges(): Skipping range: 0x00000000c8d02000, 8458240
reserve_boot_loader_ranges(): Skipping range: 0x00000000c9514000, 33935360
reserve_boot_loader_ranges(): Skipping range: 0x00000000cb579000, 4096
reserve_boot_loader_ranges(): Skipping range: 0x00000000cb57d000, 12288
reserve_boot_loader_ranges(): Skipping range: 0x00000000cb581000, 16384
reserve_boot_loader_ranges(): Skipping range: 0x00000000cb593000, 614912000
reserve_boot_loader_ranges(): Skipping range: 0x00000000f2000000, 234881024
vm_translation_map_init_post_area: entry
SBI spec version: 0x1000000
SBI implementation ID: 0x1
SBI implementation version: 0x10002
SBI vendor ID: 0x489
SBI arch ID: 0x8000000000000007
arch_smp_init()
allocate_commpage_entry(2, 16) -> 0x0000000000000200
timerFrequency: 4000000
system_time_conversion_factor: 1073741824
arch_vm_init_end(): 1 virtual ranges to keep:
  start: 0xffffffc002811000, size: 0x4020000
scheduler_init: found 4 logical cpus and 0 cache levels
scheduler switches: single core: false, cpu load tracking: false, core load tracking: true
scheduler: switching to low latency mode
slab memory manager: created area 0xffffffc001001000 (160)
allocate_commpage_entry(3, 56) -> 0x0000000000000210
allocate_commpage_entry(4, 10) -> 0x0000000000000248
register_child_devices: 0 nodes registered
PCI: pci_module_init
register_child_devices: 0 nodes registered
Last message repeated 44 times.
PlicInterruptController::InitDriver
  irqCount: 136
fdt_device_get_interrupt("plic@c000000", 0)
  context 0
    cause: 11
    hartId: 0
fdt_device_get_interrupt("plic@c000000", 1)
  context 1
    cause: 11
    hartId: 1
fdt_device_get_interrupt("plic@c000000", 2)
  context 2
    cause: 9
    hartId: 1
fdt_device_get_interrupt("plic@c000000", 3)
  context 3
    cause: 11
    hartId: 2
fdt_device_get_interrupt("plic@c000000", 4)
  context 4
    cause: 9
    hartId: 2
fdt_device_get_interrupt("plic@c000000", 5)
  context 5
    cause: 11
    hartId: 3
fdt_device_get_interrupt("plic@c000000", 6)
  context 6
    cause: 9
    hartId: 3
fdt_device_get_interrupt("plic@c000000", 7)
  context 7
    cause: 11
    hartId: 4
fdt_device_get_interrupt("plic@c000000", 8)
  context 8
    cause: 9
    hartId: 4
reserve_io_interrupt_vectors: reserved 137 vectors starting from 0
register_child_devices: 0 nodes registered
Last message repeated 231 times.
get_boot_partitions(): boot volume message:
KMessage: buffer: 0xffffffc0026d5d18 (size/capacity: 255/255), flags: 0xa
  field: "partition offset"  (LLNG): 2830090240 (0xa8afc000)
  field: "packaged"          (BOOL): true
  field: "boot method"       (LONG): 0 (0x0)
  field: "disk identifier"   (RAWT): data at 0xffffffc0026d5dc8, 79 bytes
get_boot_partitions(): boot method type: 0
intel: ep_std_ops(0x1)
intel: ep_std_ops(0x2)
intel: pm_std_ops(0x1)
intel: pm_std_ops(0x2)
dos_std_ops()
dos_std_ops()
KDiskDeviceManager::InitialDeviceScan() returned error: No such file or directory
PANIC: did not find any boot partitions! 
Welcome to Kernel Debugging Land...
Thread 17 "main2" running on CPU 2
Stack:
FP: 0xffffffc006878940
FP: 0xffffffc006878960, PC: 0xffffffc0021554b6 <kernel_riscv64> arch_debug_call_with_fault_handler + 32
FP: 0xffffffc0068789b0, PC: 0xffffffc0020d5ecc <kernel_riscv64> debug_call_with_fault_handler.localalias + 128
FP: 0xffffffc006878a40, PC: 0xffffffc0020d724c <kernel_riscv64> _ZL20kernel_debugger_loopPKcS0_Pvi + 320
FP: 0xffffffc006878ab0, PC: 0xffffffc0020d75f2 <kernel_riscv64> _ZL24kernel_debugger_internalPKcS0_Pvi + 284
FP: 0xffffffc006878af0, PC: 0xffffffc0020d7884 <kernel_riscv64> panic + 86
FP: 0xffffffc006878f70, PC: 0xffffffc002121d42 <kernel_riscv64> vfs_mount_boot_file_system + 452
FP: 0xffffffc006878fc0, PC: 0xffffffc002098616 <kernel_riscv64> _ZL5main2Pv + 220
FP: 0xffffffc006878fe0, PC: 0xffffffc0020ba234 <kernel_riscv64> _ZL19common_thread_entryPv + 52
FP: 0x0, PC: 0xffffffc002154288 <kernel_riscv64> arch_thread_entry + 0
initial commands:  syslog | tail 15
Last message repeated 231 times.
get_boot_partitions(): boot volume message:
KMessage: buffer: 0xffffffc0026d5d18 (size/capacity: 255/255), flags: 0xa
  field: "partition offset"  (LLNG): 2830090240 (0xa8afc000)
  field: "packaged"          (BOOL): true
  field: "boot method"       (LONG): 0 (0x0)
  field: "disk identifier"   (RAWT): data at 0xffffffc0026d5dc8, 79 bytes
get_boot_partitions(): boot method type: 0
intel: ep_std_ops(0x1)
intel: ep_std_ops(0x2)
intel: pm_std_ops(0x1)
intel: pm_std_ops(0x2)
dos_std_ops()
dos_std_ops()
KDiskDeviceManager::InitialDeviceScan() returned error: No such file or directory
kdebug>
50 Likes

Great work. Looks like I will have to get another SD card for my VisionFive 2.

2 Likes

PCI bus, MSI interrupts and NVMe disk reading is working.

+PciControllerPlda::InitDriver()
  bus-range: 0 - 255
  interrupt-map:
    bus: 0, dev: 0, fn: 0, childIrq: 1, parentIrq: (5, 1)
    bus: 0, dev: 0, fn: 0, childIrq: 2, parentIrq: (5, 2)
    bus: 0, dev: 0, fn: 0, childIrq: 3, parentIrq: (5, 3)
    bus: 0, dev: 0, fn: 0, childIrq: 4, parentIrq: (5, 4)
  ranges:
    MMIO32 (0x82000000): child: 30000000, parent: 30000000, len: 8000000
    MMIO64 (0xc3000000): child: 900000000, parent: 900000000, len: 40000000
  regs: 2b000000, 01000000
  config: 940000000, 10000000
  skipping device
driver busses/pci/plda/driver_v1 init failed: General system error
register_child_devices: 0 nodes registered
+PciControllerPlda::InitDriver()
  bus-range: 0 - 255
  interrupt-map:
    bus: 0, dev: 0, fn: 0, childIrq: 1, parentIrq: (5, 1)
    bus: 0, dev: 0, fn: 0, childIrq: 2, parentIrq: (5, 2)
    bus: 0, dev: 0, fn: 0, childIrq: 3, parentIrq: (5, 3)
    bus: 0, dev: 0, fn: 0, childIrq: 4, parentIrq: (5, 4)
  ranges:
    MMIO32 (0x82000000): child: 38000000, parent: 38000000, len: 8000000
    MMIO64 (0xc3000000): child: 980000000, parent: 980000000, len: 40000000
  regs: 2c000000, 01000000
  config: 9c0000000, 10000000
fdt_device_get_interrupt("pcie@2C000000", 0)
MsiInterruptCtrlPlda::Init()
  irq: 57
  fMsiPhysAddr: 0x190
MsiInterruptCtrlPlda::InterruptReceivedInt()
allocate_io_interrupt_vectors: allocated 32 vectors starting from 137
  fMsiStartIrq: 137
-PciControllerPlda::InitDriver()
pci_init_deferred()
PCI: FixupDevices: checking bus 1 behind 1556:1111
PCI: dom 0, bus 0, dev  0, func 0, changed PCI bridge control from 0x0000 to 0x0003
PCI: [dom 0, bus  0] bus   0, device  0, function  0: vendor 1556, device 1111, revision 02
PCI:   class_base 06, class_function 04, class_api 00
PCI:   line_size 08, latency 00, header_type 01, BIST 00
PCI:   subsystem_id 0000, subsystem_vendor_id 0080
PCI:   primary_bus 00, secondary_bus 01, subordinate_bus 01, secondary_latency 00
PCI:   I/O window 0000-0fff
PCI:   memory window 38000000-380fffff
PCI:   prefetchable memory window 0000000900000000-00000009000fffff
PCI:   bridge_control 0003, secondary_status 0000
PCI:   interrupt_line 00, interrupt_pin 01
PCI:   ROM base host 00000000, pci 00000000, size ??
PCI:   base reg 0: host 00000000, pci 00000000, size 00004000, flags 0c
PCI:   base reg 1: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   Capabilities: PCIe, MSI, PM
PCI:   Extended capabilities: Vendor Unique, Advanced Error Reporting
PCI: [dom 0, bus  1] bus   1, device  0, function  0: vendor 1987, device 5013, revision 01
PCI:   class_base 01, class_function 08, class_api 02
PCI:   line_size 08, latency 00, header_type 00, BIST 00
PCI:   ROM base host 00000000, pci 00000000, size 00000000
PCI:   cardbus_CIS 00000000, subsystem_id 5013, subsystem_vendor_id 1987
PCI:   interrupt_line 00, interrupt_pin 01, min_grant 00, max_latency 00
PCI:   base reg 0: host 0000000038000000, pci 0000000038000000, size 00004000, flags 04 00
PCI:   base reg 2: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 3: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 4: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 5: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   Capabilities: PCIe, MSI-X, MSI, PM
PCI:   Extended capabilities: Latency Tolerance Reporting, L1 Power Management Substates, Advanced Error Reporting, Secondary PCIe
register_child_devices: 0 nodes registered
Last message repeated 61 times.
get_boot_partitions(): boot volume message:
KMessage: buffer: 0xffffffc0026d9d18 (size/capacity: 255/255), flags: 0xa
  field: "partition offset"  (LLNG): 2830090240 (0xa8afc000)
  field: "packaged"          (BOOL): true
  field: "boot method"       (LONG): 0 (0x0)
  field: "disk identifier"   (RAWT): data at 0xffffffc0026d9dc8, 79 bytes
get_boot_partitions(): boot method type: 0
intel: ep_std_ops(0x1)
intel: ep_std_ops(0x2)
intel: pm_std_ops(0x1)
intel: pm_std_ops(0x2)
dos_std_ops()
dos_std_ops()
publish device: node 0xffffffc0077cd208, path disk/nvme/0/raw, module drivers/disk/nvme_disk/device_v1
register_child_devices: 0 nodes registered
nvme_disk: attached to NVMe device "SPCC M.2 PCIe SSD (7EF607140B6800005305)"
nvme_disk: 	maximum transfer size: 262144
nvme_disk: 	qpair count: 8
nvme_disk: namespace 0
nvme_disk: 	block size: 512, stripe size: 0
msix configured for 1 vectors
msi-x enabled: 0x8008
nvme_disk: using MSI-X
MsiInterruptCtrlPlda::EnableIoInterrupt(137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
slab memory manager: created area 0xffffffc001801000 (1322)
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
DMAResource@0xffffffc00709faa8: low/high 0/ffffffffffffffff, max segment count 126, align 4096, boundary 0, max transfer 262144, max segment size 18446744073709551615
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
intel: ep_std_ops(0x1)
intel: ep_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
EFI header: EFI PART
EFI revision: 10000
header size: 92
header CRC: 10fecf69
absolute block: 1
alternate block: 500118191
first usable block: 34
last usable block: 500118158
disk GUID: 971a5571-e75a-4297-ab81-d82a4f71c2c6
entries block: 2
entry size:  128
entry count: 128
entries CRC: 4511a4b3
EFI header: EFI PART
EFI revision: 10000
header size: 92
header CRC: b7c862a7
absolute block: 500118191
alternate block: 1
first usable block: 34
last usable block: 500118158
disk GUID: 971a5571-e75a-4297-ab81-d82a4f71c2c6
entries block: 500118159
entry size:  128
entry count: 128
entries CRC: 4511a4b3
[  0] partition type: c12a7328-f81f-11d2-ba4b-00a0c93ec93b
      unique id: 035ddb53-1ada-4240-922b-4376e757c98a
      start block: 40
      end block: 65575
      size: 31.999 MB
      attributes: 0
      name: esp
[  3] partition type: 0fc63daf-8483-4772-8e79-3d69d8477de4
      unique id: 2a34702b-93d3-44ff-8129-9c68a8e94119
      start block: 286720
      end block: 249204735
      size: 121541.999 MB
      attributes: 0
      name: root
[  4] partition type: 42465331-3ba3-10f1-802a-4861696b7521
      unique id: 37569eb1-c715-094c-a48e-574bcca7b7da
      start block: 249204736
      end block: 500117503
      size: 122515.999 MB
      attributes: 0
      name: Haiku-nvme
intel: pm_std_ops(0x1)
intel: pm_identify_partition(0, 0: 0, 256060514304, 512)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: Found GPT signature, ignoring.
intel: pm_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
btrfs: [24258499:    17] invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
e[34mexfat:e[0m invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
e[34mext2:e[0m invalid superblock!
identify(0, 0xffffffc0077d6cc0)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
ntfs: error: identify_partition: boot signature doesn't match
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
dos_std_ops()
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
dos_std_ops()
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
efi_gpt_scan_partition(cookie = 0xffffffc00700db60)
intel: ep_std_ops(0x1)
intel: ep_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: pm_std_ops(0x1)
intel: pm_identify_partition(0, 1: 20480, 33554432, 512)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: pm_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
btrfs: [24418457:    17] invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
e[34mexfat:e[0m invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
e[34mext2:e[0m invalid superblock!
identify(0, 0xffffffc0077d6cc0)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
ntfs: error: identify_partition: boot signature doesn't match
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
dos_std_ops()
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
intel: ep_std_ops(0x1)
intel: ep_identify_partition(0, 146800640, 127446024192, 512)
intel: ep_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: pm_std_ops(0x1)
intel: pm_identify_partition(0, 2: 146800640, 127446024192, 512)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: pm_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
btrfs: [24599677:    17] invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
e[34mexfat:e[0m invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
identify(0, 0xffffffc0077d6cc0)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
ntfs: error: identify_partition: boot signature doesn't match
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: ep_std_ops(0x1)
intel: ep_identify_partition(0, 127592824832, 128467337216, 512)
intel: ep_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: pm_std_ops(0x1)
intel: pm_identify_partition(0, 3: 127592824832, 128467337216, 512)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
intel: pm_std_ops(0x2)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
btrfs: [24753080:    17] invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
e[34mexfat:e[0m invalid superblock!
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
e[34mext2:e[0m invalid superblock!
identify(0, 0xffffffc0077d6cc0)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
ntfs: error: identify_partition: boot signature doesn't match
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
device 0: /dev/disk/nvme/0/raw
  media status:      No error
  device flags:      2
  offset:            0
  size:              256060514304 (244198.335 MB)
  content size:      256060514304
  block size:        512
  physical block size: 512
  child count:       3
  index:             -1
  status:            0
  flags:             5
  volume:            -1
  disk system:       partitioning_systems/efi_gpt/v1
  name:              <NULL>
  content name:      <NULL>
  type:              <NULL>
  content type:      GUID Partition Map
  params:            <NULL>
  content params:    <NULL>
  partition 1: /dev/disk/nvme/0/0
    offset:            20480
    size:              33554432 (32 MB)
    content size:      33554432
    block size:        512
    physical block size: 512
    child count:       0
    index:             0
    status:            0
    flags:             2
    volume:            -1
    disk system:       file_systems/fat/v1
    name:              esp
    content name:      esp
    type:              EFI system data
    content type:      FAT32 File System
    params:            <NULL>
    content params:    <NULL>
  partition 2: /dev/disk/nvme/0/1
    offset:            146800640
    size:              127446024192 (121542 MB)
    content size:      3637473280
    block size:        4096
    physical block size: 512
    child count:       0
    index:             1
    status:            0
    flags:             2
    volume:            -1
    disk system:       file_systems/ext2/v1
    name:              root
    content name:      cloudimg-rootfs
    type:              Linux data
    content type:      Ext2 File System
    params:            <NULL>
    content params:    <NULL>
  partition 3: /dev/disk/nvme/0/2
    offset:            127592824832
    size:              128467337216 (122516 MB)
    content size:      128467337216
    block size:        2048
    physical block size: 512
    child count:       0
    index:             2
    status:            0
    flags:             2
    volume:            -1
    disk system:       file_systems/bfs/v1
    name:              Haiku-nvme
    content name:      Haiku-nvme
    type:              Be File System
    content type:      Be File System
    params:            <NULL>
    content params:    <NULL>
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
PANIC: did not find any boot partitions! 
Welcome to Kernel Debugging Land...
Thread 17 "main2" running on CPU 2
Stack:
FP: 0xffffffc00687c940
FP: 0xffffffc00687c960, PC: 0xffffffc0021554b6 <kernel_riscv64> arch_debug_call_with_fault_handler + 32
FP: 0xffffffc00687c9b0, PC: 0xffffffc0020d5ecc <kernel_riscv64> debug_call_with_fault_handler.localalias + 128
FP: 0xffffffc00687ca40, PC: 0xffffffc0020d724c <kernel_riscv64> _ZL20kernel_debugger_loopPKcS0_Pvi + 320
FP: 0xffffffc00687cab0, PC: 0xffffffc0020d75f2 <kernel_riscv64> _ZL24kernel_debugger_internalPKcS0_Pvi + 284
FP: 0xffffffc00687caf0, PC: 0xffffffc0020d7884 <kernel_riscv64> panic + 86
FP: 0xffffffc00687cf70, PC: 0xffffffc002121d42 <kernel_riscv64> vfs_mount_boot_file_system + 452
FP: 0xffffffc00687cfc0, PC: 0xffffffc002098616 <kernel_riscv64> _ZL5main2Pv + 220
FP: 0xffffffc00687cfe0, PC: 0xffffffc0020ba234 <kernel_riscv64> _ZL19common_thread_entryPv + 52
FP: 0x0, PC: 0xffffffc002154288 <kernel_riscv64> arch_thread_entry + 0
initial commands:  syslog | tail 15
    child count:       0
    index:             2
    status:            0
    flags:             2
    volume:            -1
    disk system:       file_systems/bfs/v1
    name:              Haiku-nvme
    content name:      Haiku-nvme
    type:              Be File System
    content type:      Be File System
    params:            <NULL>
    content params:    <NULL>
MsiInterruptCtrlPlda::InterruptReceivedInt()
MSI IRQ: 0 (137)
  istatusLocal: 0x880000
kdebug> 
20 Likes

It booted to GUI!

System is installed to NVMe disk. USB keyboard and mouse are not working yet because USB is attached to second PCI host controller, that is not yet supported. It seems that multiple PCI domain support is needed. Multiple PCI domain support code already exist in Haiku for a long tine, but seems never actually used yet.

57 Likes

awesome progress !!!

hows latency ???

1 Like

Wow, what a speed you have…

Faster then Haiku Beta 5 will come out, who knows!

Great work, hope you get some help for even more progress…

3 Likes

Would it be that difficult to read the post before responding to it?

4 Likes

would it be hard for you to use reading comprehension to maybe interpret the question properly ?

what about LAN port in Vison Five 2? SSH works ?

1 Like

Not yet. Making LAN port working can be actually difficult because it is FDT bus device that need making new driver. Not sure are *BSD developers already made VisionFive 2 Ethernet driver. For first time it seems easier to use USB - Ethernet adapter.

4 Likes

I wonder about Vision Five GPIO PINs it’s compatible with a RPi Pins?

It seems compatible, but I have not tried yet except UART that is used for U-Boot commands and viewing Haiku syslog.

1 Like

Would the Starfive Linux drivers be of help for supporting the LAN port?

1 Like

Or U-Boot code: u-boot/dwc_eth_qos.c at JH7110_VisionFive2_devel · starfive-tech/u-boot · GitHub. It is simpler than Linux driver (~2000 lines of code) and can be used as reference for writing native Haiku driver.

9 Likes

Initializing second PCI domain:

+PciControllerPlda::InitDriver()
  bus-range: 0 - 255
  interrupt-map:
    bus: 0, dev: 0, fn: 0, childIrq: 1, parentIrq: (5, 1)
    bus: 0, dev: 0, fn: 0, childIrq: 2, parentIrq: (5, 2)
    bus: 0, dev: 0, fn: 0, childIrq: 3, parentIrq: (5, 3)
    bus: 0, dev: 0, fn: 0, childIrq: 4, parentIrq: (5, 4)
  ranges:
    MMIO32 (0x82000000): child: 30000000, parent: 30000000, len: 8000000
    MMIO64 (0xc3000000): child: 900000000, parent: 900000000, len: 40000000
  regs: 2b000000, 01000000
  config: 940000000, 10000000
fdt_device_get_interrupt("pcie@2B000000", 0)
stgArfun: 0xc0
stgAwfun: 0xc4
stgRpNep: 0x130
stgLnksta: 0x1b8
  clock[JH7110_NOC_BUS_CLK_STG_AXI]: 1
  clock[JH7110_PCIE0_CLK_TL]: 0
  clock[JH7110_PCIE0_CLK_AXI_MST0]: 0
  clock[JH7110_PCIE0_CLK_APB]: 0
  reset[RSTN_U0_PLDA_PCIE_AXI_MST0]: 0
  reset[RSTN_U0_PLDA_PCIE_AXI_SLV0]: 0
  reset[RSTN_U0_PLDA_PCIE_AXI_SLV]: 0
  reset[RSTN_U0_PLDA_PCIE_BRG]: 0
  reset[RSTN_U0_PLDA_PCIE_CORE]: 0
  reset[RSTN_U0_PLDA_PCIE_APB]: 0
  init clocks and resets
clk-gate: readl(ffffffc000fde180) -> 0x80000000
clk-gate: writel(0x80000000, ffffffc000fde180) -> 
clk-gate: readl(ffffffc000fee028) -> 0x0
clk-gate: writel(0x80000000, ffffffc000fee028) -> 
clk-gate: readl(ffffffc000fee020) -> 0x0
clk-gate: writel(0x80000000, ffffffc000fee020) -> 
clk-gate: readl(ffffffc000fee024) -> 0x0
clk-gate: writel(0x80000000, ffffffc000fee024) -> 
reset: readl(ffffffc0069a1074) -> 0x7ffffe
reset: writel(0x7ff7fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7ff7fe
reset: writel(0x7fe7fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7fe7fe
reset: writel(0x7fc7fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7fc7fe
reset: writel(0x7f87fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7f87fe
reset: writel(0x7f07fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7f07fe
reset: writel(0x7e07fe, ffffffc0069a1074)
pinctrl: readl(ffffffc0069e1058) -> 0x700
pinctrl: writel(0x700, ffffffc0069e1058) -> 
pinctrl: readl(ffffffc0069e1018) -> 0x0
pinctrl: writel(0x0, ffffffc0069e1018) -> 
ATR entry: 0x0940000000 -> 0x0000000000 [0x0010000000] (param: 0x000001)
ATR entry: 0x0030000000 -> 0x0030000000 [0x0008000000] (param: 0x000000)
ATR entry: 0x0900000000 -> 0x0900000000 [0x0040000000] (param: 0x000000)
pinctrl: readl(ffffffc0069e1058) -> 0x700
pinctrl: writel(0x10700, ffffffc0069e1058) -> 
pinctrl: readl(ffffffc0069e1018) -> 0x0
pinctrl: writel(0x0, ffffffc0069e1018) -> 
MsiInterruptCtrlPlda::Init()
  irq: 56
  fMsiPhysAddr: 0x190
allocate_io_interrupt_vectors: allocated 32 vectors starting from 137
  fMsiStartIrq: 137
-PciControllerPlda::InitDriver()
pci_init_deferred()
  count: 0
+PciControllerPlda::InitDriver()
  bus-range: 0 - 255
  interrupt-map:
    bus: 0, dev: 0, fn: 0, childIrq: 1, parentIrq: (5, 1)
    bus: 0, dev: 0, fn: 0, childIrq: 2, parentIrq: (5, 2)
    bus: 0, dev: 0, fn: 0, childIrq: 3, parentIrq: (5, 3)
    bus: 0, dev: 0, fn: 0, childIrq: 4, parentIrq: (5, 4)
  ranges:
    MMIO32 (0x82000000): child: 38000000, parent: 38000000, len: 8000000
    MMIO64 (0xc3000000): child: 980000000, parent: 980000000, len: 40000000
  regs: 2c000000, 01000000
  config: 9c0000000, 10000000
fdt_device_get_interrupt("pcie@2C000000", 0)
stgArfun: 0x270
stgAwfun: 0x274
stgRpNep: 0x2e0
stgLnksta: 0x368
  clock[JH7110_NOC_BUS_CLK_STG_AXI]: 1
  clock[JH7110_PCIE1_CLK_TL]: 0
  clock[JH7110_PCIE1_CLK_AXI_MST0]: 0
  clock[JH7110_PCIE1_CLK_APB]: 0
  reset[RSTN_U1_PLDA_PCIE_AXI_MST0]: 0
  reset[RSTN_U1_PLDA_PCIE_AXI_SLV0]: 0
  reset[RSTN_U1_PLDA_PCIE_AXI_SLV]: 0
  reset[RSTN_U1_PLDA_PCIE_BRG]: 0
  reset[RSTN_U1_PLDA_PCIE_CORE]: 0
  reset[RSTN_U1_PLDA_PCIE_APB]: 0
  init clocks and resets
clk-gate: readl(ffffffc000fde180) -> 0x80000000
clk-gate: writel(0x80000000, ffffffc000fde180) -> 
clk-gate: readl(ffffffc000fee034) -> 0x0
clk-gate: writel(0x80000000, ffffffc000fee034) -> 
clk-gate: readl(ffffffc000fee02c) -> 0x0
clk-gate: writel(0x80000000, ffffffc000fee02c) -> 
clk-gate: readl(ffffffc000fee030) -> 0x0
clk-gate: writel(0x80000000, ffffffc000fee030) -> 
reset: readl(ffffffc0069a1074) -> 0x7e07fe
reset: writel(0x7c07fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7c07fe
reset: writel(0x7807fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7807fe
reset: writel(0x7007fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x7007fe
reset: writel(0x6007fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x6007fe
reset: writel(0x4007fe, ffffffc0069a1074)
reset: readl(ffffffc0069a1074) -> 0x4007fe
reset: writel(0x7fe, ffffffc0069a1074)
pinctrl: readl(ffffffc0069e105c) -> 0x0
pinctrl: writel(0x0, ffffffc0069e105c) -> 
pinctrl: readl(ffffffc0069e101c) -> 0x0
pinctrl: writel(0x0, ffffffc0069e101c) -> 
ATR entry: 0x09c0000000 -> 0x0000000000 [0x0010000000] (param: 0x000001)
ATR entry: 0x0038000000 -> 0x0038000000 [0x0008000000] (param: 0x000000)
ATR entry: 0x0980000000 -> 0x0980000000 [0x0040000000] (param: 0x000000)
pinctrl: readl(ffffffc0069e105c) -> 0x0
pinctrl: writel(0x1, ffffffc0069e105c) -> 
pinctrl: readl(ffffffc0069e101c) -> 0x0
pinctrl: writel(0x0, ffffffc0069e101c) -> 
MsiInterruptCtrlPlda::Init()
  irq: 57
  fMsiPhysAddr: 0x190
allocate_io_interrupt_vectors: allocated 32 vectors starting from 169
  fMsiStartIrq: 169
-PciControllerPlda::InitDriver()
pci_init_deferred()
  count: 1
PCI: EnumerateBus: domain 0, bus 0
PCI: found PCI-PCI bridge: domain 0, bus 0, dev 0, func 0
PCI: original settings: pcicmd 0000, primary-bus 0, secondary-bus 0, subordinate-bus 0
PCI: disabled settings: pcicmd 0000, primary-bus 0, secondary-bus 0, subordinate-bus 0
PCI: configuring PCI-PCI bridge: domain 0, bus 0, dev 0, func 0
PCI: probing settings: pcicmd 0006, primary-bus 0, secondary-bus 1, subordinate-bus 255
PCI: EnumerateBus: domain 0, bus 1
PCI: EnumerateBus done: domain 0, bus 1, last used bus number 1
PCI: configured settings: pcicmd 0006, primary-bus 0, secondary-bus 1, subordinate-bus 1
PCI: EnumerateBus done: domain 0, bus 0, last used bus number 1
PCI: EnumerateBus: domain 1, bus 0
PCI: found PCI-PCI bridge: domain 1, bus 0, dev 0, func 0
PCI: original settings: pcicmd 0000, primary-bus 0, secondary-bus 0, subordinate-bus 0
PCI: disabled settings: pcicmd 0000, primary-bus 0, secondary-bus 0, subordinate-bus 0
PCI: configuring PCI-PCI bridge: domain 1, bus 0, dev 0, func 0
PCI: probing settings: pcicmd 0006, primary-bus 0, secondary-bus 1, subordinate-bus 255
PCI: EnumerateBus: domain 1, bus 1
PCI: EnumerateBus done: domain 1, bus 1, last used bus number 1
PCI: configured settings: pcicmd 0006, primary-bus 0, secondary-bus 1, subordinate-bus 1
PCI: EnumerateBus done: domain 1, bus 0, last used bus number 1
PCI: FixupDevices domain 0, bus 0
PCI: FixupDevices: checking bus 1 behind 1556:1111
PCI: FixupDevices domain 0, bus 1
PCI: FixupDevices domain 1, bus 0
PCI: FixupDevices: checking bus 1 behind 1556:1111
PCI: FixupDevices domain 1, bus 1
PCI: DiscoverBus, domain 0, bus 0
PCI: DiscoverDevice, domain 0, bus 0, dev 0, func 0
PCI: CreateDevice, domain 0, bus 0, dev 0, func 0:
PCI::CreateVirtualBus: domain 0, bus 0 => virtualBus 0
PCI: CreateDevice, vendor 0x1556, device 0x1111, class_base 0x06, class_sub 0x04
PCI: DiscoverBus, domain 0, bus 1
PCI: DiscoverDevice, domain 0, bus 1, dev 0, func 0
PCI: CreateDevice, domain 0, bus 1, dev 0, func 0:
PCI::CreateVirtualBus: domain 0, bus 1 => virtualBus 1
PCI: CreateDevice, vendor 0x1106, device 0x3483, class_base 0x0c, class_sub 0x03
PCI: DiscoverBus, domain 1, bus 0
PCI: DiscoverDevice, domain 1, bus 0, dev 0, func 0
PCI: CreateDevice, domain 1, bus 0, dev 0, func 0:
PCI::CreateVirtualBus: domain 1, bus 0 => virtualBus 2
PCI: CreateDevice, vendor 0x1556, device 0x1111, class_base 0x06, class_sub 0x04
PCI: DiscoverBus, domain 1, bus 1
PCI: DiscoverDevice, domain 1, bus 1, dev 0, func 0
PCI: CreateDevice, domain 1, bus 1, dev 0, func 0:
PCI::CreateVirtualBus: domain 1, bus 1 => virtualBus 3
PCI: CreateDevice, vendor 0x1987, device 0x5013, class_base 0x01, class_sub 0x08
PCI: dom 0, bus 0, dev  0, func 0, changed PCI bridge control from 0x0000 to 0x0003
PCI: dom 1, bus 0, dev  0, func 0, changed PCI bridge control from 0x0000 to 0x0003
PCI::CreateVirtualBus: domain 0, bus 0 already in map => virtualBus 0
PCI:FindHTCapability ERROR 0:0:0 capability 0xa800 not supported
PCI::CreateVirtualBus: domain 0, bus 1 already in map => virtualBus 1
PCI:FindHTCapability ERROR 1:0:0 capability 0xa800 not supported
PCI::CreateVirtualBus: domain 1, bus 0 already in map => virtualBus 2
PCI:FindHTCapability ERROR 0:0:0 capability 0xa800 not supported
PCI::CreateVirtualBus: domain 1, bus 1 already in map => virtualBus 3
PCI:FindHTCapability ERROR 1:0:0 capability 0xa800 not supported
PCI: [dom 0, bus  0] bus   0, device  0, function  0: vendor 1556, device 1111, revision 02
PCI:   class_base 06, class_function 04, class_api 00
PCI:   line_size 00, latency 00, header_type 01, BIST 00
PCI:   subsystem_id 0000, subsystem_vendor_id 0080
PCI:   primary_bus 00, secondary_bus 01, subordinate_bus 01, secondary_latency 00
PCI:   I/O window 0000-0fff
PCI:   memory window 00000000-000fffff
PCI:   prefetchable memory window 0000000000000000-00000000000fffff
PCI:   bridge_control 0003, secondary_status 0000
PCI:   interrupt_line 00, interrupt_pin 01
PCI:   ROM base host 00000000, pci 00000000, size ??
PCI:   base reg 0: host 00000000, pci 00000000, size 00004000, flags 0c
PCI:   base reg 1: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   Capabilities: PCIe, MSI, PM
PCI:   Extended capabilities: Vendor Unique, Advanced Error Reporting
PCI: [dom 0, bus  1] bus   1, device  0, function  0: vendor 1106, device 3483, revision 01
PCI:   class_base 0c, class_function 03, class_api 30
PCI:   line_size 00, latency 00, header_type 00, BIST 00
PCI:   ROM base host 00000000, pci 00000000, size 00000000
PCI:   cardbus_CIS 00000000, subsystem_id 3483, subsystem_vendor_id 1106
PCI:   interrupt_line 00, interrupt_pin 01, min_grant 00, max_latency 00
PCI:   base reg 0: host 0000000000000000, pci 0000000000000000, size 00001000, flags 04 00
PCI:   base reg 2: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 3: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 4: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 5: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   Capabilities: PM, MSI, PCIe
PCI:   Extended capabilities: Advanced Error Reporting
PCI: [dom 1, bus  0] bus   2, device  0, function  0: vendor 1556, device 1111, revision 02
PCI:   class_base 06, class_function 04, class_api 00
PCI:   line_size 00, latency 00, header_type 01, BIST 00
PCI:   subsystem_id 0000, subsystem_vendor_id 0080
PCI:   primary_bus 00, secondary_bus 01, subordinate_bus 01, secondary_latency 00
PCI:   I/O window 0000-0fff
PCI:   memory window 00000000-000fffff
PCI:   prefetchable memory window 0000000000000000-00000000000fffff
PCI:   bridge_control 0003, secondary_status 0000
PCI:   interrupt_line 00, interrupt_pin 01
PCI:   ROM base host 00000000, pci 00000000, size ??
PCI:   base reg 0: host 00000000, pci 00000000, size 00004000, flags 0c
PCI:   base reg 1: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   Capabilities: PCIe, MSI, PM
PCI:   Extended capabilities: Vendor Unique, Advanced Error Reporting
PCI: [dom 1, bus  1] bus   3, device  0, function  0: vendor 1987, device 5013, revision 01
PCI:   class_base 01, class_function 08, class_api 02
PCI:   line_size 00, latency 00, header_type 00, BIST 00
PCI:   ROM base host 00000000, pci 00000000, size 00000000
PCI:   cardbus_CIS 00000000, subsystem_id 5013, subsystem_vendor_id 1987
PCI:   interrupt_line 00, interrupt_pin 01, min_grant 00, max_latency 00
PCI:   base reg 0: host 0000000000000000, pci 0000000000000000, size 00004000, flags 04 00
PCI:   base reg 2: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 3: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 4: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   base reg 5: host 00000000, pci 00000000, size 00000000, flags 00
PCI:   Capabilities: PCIe, MSI-X, MSI, PM
PCI:   Extended capabilities: Latency Tolerance Reporting, L1 Power Management Substates, Advanced Error Reporting, Secondary PCIe
slab memory manager: created area 0xffffffc001801000 (1063)
PANIC: Unexpected exception occurred in kernel mode!
Welcome to Kernel Debugging Land...
Thread 17 "main2" running on CPU 2
Stack:
FP: 0xffffffc00687fc10
FP: 0xffffffc00687fc30, PC: 0xffffffc002155106 <kernel_riscv64> arch_debug_call_with_fault_handler + 32
FP: 0xffffffc00687fc80, PC: 0xffffffc0020d5e20 <kernel_riscv64> debug_call_with_fault_handler.localalias + 128
FP: 0xffffffc00687fd10, PC: 0xffffffc0020d71a0 <kernel_riscv64> _ZL20kernel_debugger_loopPKcS0_Pvi + 320
FP: 0xffffffc00687fd80, PC: 0xffffffc0020d7546 <kernel_riscv64> _ZL24kernel_debugger_internalPKcS0_Pvi + 284
FP: 0xffffffc00687fdc0, PC: 0xffffffc0020d77d8 <kernel_riscv64> panic + 86
FP: 0xffffffc00687fef0, PC: 0xffffffc0021561e6 <kernel_riscv64> STrap + 594
FP: 0xffffffc006880010, PC: 0xffffffc002153f60 <kernel_riscv64> SVec + 96
STrap(exception loadAccessFault)
  sstatus: (ie: {}, pie: {s}, spp: s, fs: dirty, xs: off, sum: 0, mxr: 0, uxl: 2, sd: 1)
  stval: 0xffffffc006837000
   ra: 0xffffffc00255e3e0   t6: 0x0000000000000020   sp: 0xffffffc006880010   gp: 0x0000000000000000
   tp: 0xffffffc0072cb580   t0: 0xffffffc00218e540   t1: 0xffffffc00207d9dc   t2: 0x0000000000000000
   t5: 0x0000000000000000   s1: 0xffffffc001006000   a0: 0x0000000000000428   a1: 0x0000000000010000
   a2: 0x0000000000000090   a3: 0xffffffffffffffff   a4: 0x0000000000000001   a5: 0xffffffc006837000
   a6: 0xffffffc00215ae8c   a7: 0xffffffc002264710   s2: 0x0000000000051000   s3: 0xffffffc00720ed20
   s4: 0xffffffc007756160   s5: 0xffffffc0024b36b0   s6: 0xffffffc0077b88f0   s7: 0xffffffc0068801d0
   s8: 0x0000000000000000   s9: 0x0000000000000018  s10: 0xffffffc002708156  s11: 0xffffffc006880a18
   t3: 0xffffffc0020a96d6   t4: 0x0000000000001000   fp: 0xffffffc0068800a0  epc: 0xffffffc00255e3f4
FP: 0xffffffc0068800a0, PC: 0xffffffc00255e3f4 <xhci> _ZN4XHCIC2EP8pci_infoP22pci_device_module_infoP10pci_deviceP5StackP11device_node.localalias + 340
FP: 0xffffffc0068800f0, PC: 0xffffffc00255eaf8 <xhci> _ZL8init_busP11device_nodePPv + 134
FP: 0xffffffc006880120, PC: 0xffffffc0020e81e2 <kernel_riscv64> _ZN11device_node10InitDriverEv.localalias + 108
FP: 0xffffffc006880160, PC: 0xffffffc0020e9a30 <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 42
FP: 0xffffffc0068801b0, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc006880250, PC: 0xffffffc00255cc78 <xhci> _ZL22register_child_devicesPv + 164
FP: 0xffffffc006880290, PC: 0xffffffc0020e9a5e <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 88
FP: 0xffffffc0068802e0, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc006880330, PC: 0xffffffc00255ca20 <xhci> _ZL15register_deviceP11device_node + 100
FP: 0xffffffc0068803b0, PC: 0xffffffc0020e910c <kernel_riscv64> _ZN11device_node16_RegisterDynamicEPS_.localalias + 220
FP: 0xffffffc0068803f0, PC: 0xffffffc0020e9a9c <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 150
FP: 0xffffffc006880440, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc006880690, PC: 0xffffffc0024afc42 <pci> _ZL31pci_root_register_child_devicesPv + 454
FP: 0xffffffc0068806d0, PC: 0xffffffc0020e9a5e <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 88
FP: 0xffffffc006880720, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc006880790, PC: 0xffffffc0024afa44 <pci> _ZL24pci_root_register_deviceP11device_node + 142
FP: 0xffffffc0068807f0, PC: 0xffffffc0020e8692 <kernel_riscv64> _ZN11device_node14_RegisterFixedERj.localalias + 96
FP: 0xffffffc006880830, PC: 0xffffffc0020e9a50 <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 74
FP: 0xffffffc006880880, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc0068808f0, PC: 0xffffffc0024b6960 <plda> _ZN17PciControllerPlda14RegisterDeviceEP11device_node + 136
FP: 0xffffffc006880970, PC: 0xffffffc0020e910c <kernel_riscv64> _ZN11device_node16_RegisterDynamicEPS_.localalias + 220
FP: 0xffffffc0068809b0, PC: 0xffffffc0020e9a9c <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 150
FP: 0xffffffc006880a00, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc006880ad0, PC: 0xffffffc0023aa43e <fdt> _ZL17fdt_register_nodeP7fdt_busiP11device_nodeRS2_.isra.0 + 632
FP: 0xffffffc006880b10, PC: 0xffffffc0023aa6de <fdt> _ZL12fdt_traverseP7fdt_busRiS1_P11device_node + 42
FP: 0xffffffc006880b50, PC: 0xffffffc0023aa716 <fdt> _ZL12fdt_traverseP7fdt_busRiS1_P11device_node + 98
FP: 0xffffffc006880b90, PC: 0xffffffc0023aa716 <fdt> _ZL12fdt_traverseP7fdt_busRiS1_P11device_node + 98
FP: 0xffffffc006880bc0, PC: 0xffffffc0023aa778 <fdt> _ZL30fdt_bus_register_child_devicesPv + 76
FP: 0xffffffc006880c00, PC: 0xffffffc0020e9a5e <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 88
FP: 0xffffffc006880c50, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc006880cc0, PC: 0xffffffc0023a90ea <fdt> _ZL23fdt_bus_register_deviceP11device_node + 142
FP: 0xffffffc006880d10, PC: 0xffffffc0020e8f2c <kernel_riscv64> _ZN11device_node13_RegisterPathEPKc.localalias + 78
FP: 0xffffffc006880d90, PC: 0xffffffc0020e9146 <kernel_riscv64> _ZN11device_node16_RegisterDynamicEPS_.localalias + 278
FP: 0xffffffc006880dd0, PC: 0xffffffc0020e9a9c <kernel_riscv64> _ZN11device_node8RegisterEPS_.localalias + 150
FP: 0xffffffc006880e20, PC: 0xffffffc0020e9ba4 <kernel_riscv64> _ZL13register_nodeP11device_nodePKcPK11device_attrPK11io_resourcePS0_ + 160
FP: 0xffffffc006880f60, PC: 0xffffffc0020e9cfa <kernel_riscv64> _ZL14init_node_treev + 184
FP: 0xffffffc006880f70, PC: 0xffffffc0020ea4c0 <kernel_riscv64> device_manager_init + 336
FP: 0xffffffc006880fc0, PC: 0xffffffc002098530 <kernel_riscv64> _ZL5main2Pv + 162
FP: 0xffffffc006880fe0, PC: 0xffffffc0020ba188 <kernel_riscv64> _ZL19common_thread_entryPv + 52
FP: 0x0, PC: 0xffffffc002153ed8 <kernel_riscv64> arch_thread_entry + 0
17 Likes

My VF2 just arrive. I’am tested it. Work on Debian. Now I wait for X512 works with a little stable version of Haiku for RiscV.

Cheers!

1 Like

Congrats on getting Haiku booting on the VF2 so quickly X512! Super impressive work yet again.

I’ve ordered one now, overcome with the sheer novelty value of being able to run Haiku on a new and exciting arch. Hopefully you’ll be able to get USB working before mine arrives? :wink:

This has made me wonder. How is it that you’ve been able to get Haiku booting to the desktop and mostly usable on at least two RV boards now but we still don’t have a comparable status ARM port of Haiku when many more devs have had access to ARM boards for much longer than we’ve had RV SBCs?

ARM has never been a good target. ARM has so many different architectures and ways to boot. Each of them being more like its own platform and needing different drivers. It has been a moving target all this time. IIRC Haiku almost booted on gumstix arm boards, but who even remembers them now?

It is starting to become simpler with UEFI, ACPI and devicetrees, ARM chips still need a lot of different drivers. The Risc-V port also made haiku a lot more portable which also helps ARM and other targets.

And the most important part: there needs to be a person willing to spend time and energy on it, it is a hard task and it is hard to stay motivated. So keep motivating and encouraging people…

15 Likes

I finally got Haiku desktop with USB working. Booted from NVMe. Four CPU cores are working.

63 Likes

That is super hot! Would love to try this soon. <3