hikalium / liumos

A toy operating system which supports NVDIMM natively.
MIT License
272 stars 24 forks source link

QEMU #16

Open hikalium opened 5 years ago

hikalium commented 5 years ago

QEMU 3.1.50 (on t03.hikalium.com)

483471443512d42dff2f04f2793c94540ba59359

hikalium commented 5 years ago
2019-02-18 0 15 05

483471443512d42dff2f04f2793c94540ba59359

hikalium commented 5 years ago

QEMU emulator version 3.1.50 (v3.1.0-1836-g1e36232994) on macOS hosts does not support x2APIC...(even if -accel=hvf, -cpu=host)

hikalium commented 5 years ago
> show madt
show madt
MADT(type=0x0) Processor 0x0 local_apic_id = 0x0 Enabled
MADT(type=0x0) Processor 0x1 local_apic_id = 0x1 Enabled
MADT(type=0x0) Processor 0x2 local_apic_id = 0x2 Enabled
MADT(type=0x0) Processor 0x3 local_apic_id = 0x3 Enabled
MADT(type=0x1) IOAPIC id=0x0 base=0xFEC00000 gsi_base=0x0
MADT(type=0x2) IRQ override: 0x0 -> 0x2 polarity=same_as_bus_spec trigger=same_as_bus_spec
MADT(type=0x2) IRQ override: 0x5 -> 0x5 polarity=active-high trigger=level
MADT(type=0x2) IRQ override: 0x9 -> 0x9 polarity=active-high trigger=level
MADT(type=0x2) IRQ override: 0xA -> 0xA polarity=active-high trigger=level
MADT(type=0x2) IRQ override: 0xB -> 0xB polarity=active-high trigger=level
MADT(type=0x4) LAPIC NMI uid=0xFF polarity=same_as_bus_spec trigger=same_as_bus_spec LINT#=0x1
> show mmap
show mmap
Map entries: 0x36
0x00000000_00000000 - 0x00000000_00001000 Type 0x3 Virt 0x0 Attr 0xF (0x1 pages)
0x00000000_00001000 - 0x00000000_000A0000 Type 0x7 Virt 0x0 Attr 0xF (0x9F pages)
0x00000000_00100000 - 0x00000000_00800000 Type 0x7 Virt 0x0 Attr 0xF (0x700 pages)
0x00000000_00800000 - 0x00000000_00808000 Type 0xA Virt 0x0 Attr 0xF (0x8 pages)
0x00000000_00808000 - 0x00000000_00810000 Type 0x7 Virt 0x0 Attr 0xF (0x8 pages)
0x00000000_00810000 - 0x00000000_00900000 Type 0xA Virt 0x0 Attr 0xF (0xF0 pages)
0x00000000_00900000 - 0x00000000_01400000 Type 0x4 Virt 0x0 Attr 0xF (0xB00 pages)
0x00000000_01400000 - 0x00000000_7BF1E000 Type 0x7 Virt 0x0 Attr 0xF (0x7AB1E pages)
0x00000000_7BF1E000 - 0x00000000_7BF3E000 Type 0x4 Virt 0x0 Attr 0xF (0x20 pages)
0x00000000_7BF3E000 - 0x00000000_7E31E000 Type 0x7 Virt 0x0 Attr 0xF (0x23E0 pages)
0x00000000_7E31E000 - 0x00000000_7E3DF000 Type 0x2 Virt 0x0 Attr 0xF (0xC1 pages)
0x00000000_7E3DF000 - 0x00000000_7E860000 Type 0x4 Virt 0x0 Attr 0xF (0x481 pages)
0x00000000_7E860000 - 0x00000000_7E873000 Type 0xA Virt 0x0 Attr 0xF (0x13 pages)
0x00000000_7E873000 - 0x00000000_7E886000 Type 0x0 Virt 0x0 Attr 0xF (0x13 pages)
0x00000000_7E886000 - 0x00000000_7E88A000 Type 0x9 Virt 0x0 Attr 0xF (0x4 pages)
0x00000000_7E88A000 - 0x00000000_7E890000 Type 0x7 Virt 0x0 Attr 0xF (0x6 pages)
0x00000000_7E890000 - 0x00000000_7E895000 Type 0x2 Virt 0x0 Attr 0xF (0x5 pages)
0x00000000_7E895000 - 0x00000000_7E896000 Type 0x9 Virt 0x0 Attr 0xF (0x1 pages)
0x00000000_7E896000 - 0x00000000_7E89A000 Type 0xA Virt 0x0 Attr 0xF (0x4 pages)
0x00000000_7E89A000 - 0x00000000_7E8AA000 Type 0x0 Virt 0x0 Attr 0xF (0x10 pages)
0x00000000_7E8AA000 - 0x00000000_7EA5F000 Type 0x3 Virt 0x0 Attr 0xF (0x1B5 pages)
0x00000000_7EA5F000 - 0x00000000_7EA64000 Type 0x6 Virt 0x0 Attr 0x800000000000000F (0x5 pages)
0x00000000_7EA64000 - 0x00000000_7EA6C000 Type 0x5 Virt 0x0 Attr 0x800000000000000F (0x8 pages)
0x00000000_7EA6C000 - 0x00000000_7EA71000 Type 0x6 Virt 0x0 Attr 0x800000000000000F (0x5 pages)
0x00000000_7EA71000 - 0x00000000_7EA77000 Type 0x5 Virt 0x0 Attr 0x800000000000000F (0x6 pages)
0x00000000_7EA77000 - 0x00000000_7EA7C000 Type 0x6 Virt 0x0 Attr 0x800000000000000F (0x5 pages)
0x00000000_7EA7C000 - 0x00000000_7EA85000 Type 0x5 Virt 0x0 Attr 0x800000000000000F (0x9 pages)
0x00000000_7EA85000 - 0x00000000_7EA8A000 Type 0x6 Virt 0x0 Attr 0x800000000000000F (0x5 pages)
0x00000000_7EA8A000 - 0x00000000_7EA91000 Type 0x5 Virt 0x0 Attr 0x800000000000000F (0x7 pages)
0x00000000_7EA91000 - 0x00000000_7EB1B000 Type 0x6 Virt 0x0 Attr 0x800000000000000F (0x8A pages)
0x00000000_7EB1B000 - 0x00000000_7ED37000 Type 0x7 Virt 0x0 Attr 0xF (0x21C pages)
0x00000000_7ED37000 - 0x00000000_7EE29000 Type 0x4 Virt 0x0 Attr 0xF (0xF2 pages)
0x00000000_7EE29000 - 0x00000000_7EE2F000 Type 0x7 Virt 0x0 Attr 0xF (0x6 pages)
0x00000000_7EE2F000 - 0x00000000_7EE3A000 Type 0x4 Virt 0x0 Attr 0xF (0xB pages)
0x00000000_7EE3A000 - 0x00000000_7EE3B000 Type 0x7 Virt 0x0 Attr 0xF (0x1 pages)
0x00000000_7EE3B000 - 0x00000000_7FA1B000 Type 0x4 Virt 0x0 Attr 0xF (0xBE0 pages)
0x00000000_7FA1B000 - 0x00000000_7FB9B000 Type 0x3 Virt 0x0 Attr 0xF (0x180 pages)
0x00000000_7FB9B000 - 0x00000000_7FBCB000 Type 0x5 Virt 0x0 Attr 0x800000000000000F (0x30 pages)
0x00000000_7FBCB000 - 0x00000000_7FBEF000 Type 0x6 Virt 0x0 Attr 0x800000000000000F (0x24 pages)
0x00000000_7FBEF000 - 0x00000000_7FBF3000 Type 0x0 Virt 0x0 Attr 0xF (0x4 pages)
0x00000000_7FBF3000 - 0x00000000_7FBFB000 Type 0x9 Virt 0x0 Attr 0xF (0x8 pages)
0x00000000_7FBFB000 - 0x00000000_7FBFF000 Type 0xA Virt 0x0 Attr 0xF (0x4 pages)
0x00000000_7FBFF000 - 0x00000000_7FE00000 Type 0x4 Virt 0x0 Attr 0xF (0x201 pages)
0x00000000_7FE00000 - 0x00000000_7FE41000 Type 0x7 Virt 0x0 Attr 0xF (0x41 pages)
0x00000000_7FE41000 - 0x00000000_7FE61000 Type 0x4 Virt 0x0 Attr 0xF (0x20 pages)
0x00000000_7FE61000 - 0x00000000_7FE8F000 Type 0x3 Virt 0x0 Attr 0xF (0x2E pages)
0x00000000_7FE8F000 - 0x00000000_7FEB0000 Type 0x4 Virt 0x0 Attr 0xF (0x21 pages)
0x00000000_7FEB0000 - 0x00000000_7FEDC000 Type 0x3 Virt 0x0 Attr 0xF (0x2C pages)
0x00000000_7FEDC000 - 0x00000000_7FF60000 Type 0x6 Virt 0x0 Attr 0x800000000000000F (0x84 pages)
0x00000000_7FF60000 - 0x00000000_80000000 Type 0xA Virt 0x0 Attr 0xF (0xA0 pages)
0x00000001_00000000 - 0x00000001_40000000 Type 0x7 Virt 0x0 Attr 0xF (0x40000 pages)
0x00000001_40000000 - 0x00000001_40010000 Type 0x1 Virt 0x0 Attr 0xF (0x10 pages)
0x00000001_40010000 - 0x00000002_80000000 Type 0x7 Virt 0x0 Attr 0xF (0x13FFF0 pages)
0x00000000_80000000 - 0x00000000_90000000 Type 0x0 Virt 0x0 Attr 0x1 (0x10000 pages)
hikalium commented 5 years ago

Memory map buffer needed: 0xA80 bytes QEMU emulator version 3.1.50 (v3.1.0-1836-g1e36232994)

hikalium commented 5 years ago
> show nfit
NFIT found
NFIT Size in bytes: 0xE0
SPARange #: 0x2
  Base: 0x280000000
  Length: 0x80000000
  attr: 8008 = NV WB
  type: ByteAddressablePersistentMemory
Region Mapping
  NFIT Device Handle #: 0x1
  NVDIMM phys ID: 0x0
  NVDIMM region ID: 0x0
  SPARange struct index: 0x2
  ControlRegion struct index: 0x3
  region size: 0x80000000
  region offset: 0x0
  NVDIMM phys addr region base: 0x0
  NVDIMM interleave_structure_index: 0x0
  NVDIMM interleave ways: 0x1
  NVDIMM state flags: 0x0
Control Region Struct #: 0x3
NFIT end