WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] graphics passthrough with VT-d

To: enming.teo@xxxxxxxxxxxxxxx
Subject: Re: [Xen-devel] graphics passthrough with VT-d
From: "Mr. Teo En Ming (Zhang Enming)" <enming.teo@xxxxxxxxxxxxxxx>
Date: Sat, 29 Aug 2009 22:39:09 +0800
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, timothy.moore@xxxxxxxxxxx
Delivery-date: Sat, 29 Aug 2009 07:40:24 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4A99314C.7030509@xxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <7CB0A101731F44C391569BAEBF727CF9@ASOITIS16> <4A97FDE9.2060302@xxxxxxxxxxxxxxx> <4A980CDE.8060109@xxxxxxxxxxxxxxx> <4A983A73.80602@xxxxxxxxxxxxxxx> <14D9C9E2ED61ED41BC3B37ACDF4E880002CE4F3F9CE5@xxxxxxxxxxxxxxxxxxxxxxx> <4A988FD4.4080602@xxxxxxxxxxxxxxx> <4A98A51D.6070602@xxxxxxxxxxxxxxx> <4A98D1AD.5060703@xxxxxxxxxxxxxxx> <4A990AE9.1080303@xxxxxxxxxxxxxxx> <4A991E57.5030703@xxxxxxxxxxxxxxx> <4A992B24.1070404@xxxxxxxxxxxxxxx> <4A99314C.7030509@xxxxxxxxxxxxxxx>
Reply-to: enming.teo@xxxxxxxxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.1) Gecko/20090814 Fedora/3.0-2.6.b3.fc11 Thunderbird/3.0b3
Dear All,

Here is my "xm dmesg" output:

linux"
(XEN) elf_xen_parse_note: GUEST_VERSION = "2.6"
(XEN) elf_xen_parse_note: XEN_VERSION = "xen-3.0"
(XEN) elf_xen_parse_note: VIRT_BASE = 0xffffffff80000000
(XEN) elf_xen_parse_note: ENTRY = 0xffffffff8166b200
(XEN) elf_xen_parse_note: HYPERCALL_PAGE = 0xffffffff81009000
(XEN) elf_xen_parse_note: FEATURES = "!writable_page_tables|pae_pgdir_above_4gb"
(XEN) elf_xen_parse_note: PAE_MODE = "yes"
(XEN) elf_xen_parse_note: LOADER = "generic"
(XEN) elf_xen_parse_note: unknown xen elf note (0xd)
(XEN) elf_xen_parse_note: SUSPEND_CANCEL = 0x1
(XEN) elf_xen_parse_note: HV_START_LOW = 0xffff800000000000
(XEN) elf_xen_parse_note: PADDR_OFFSET = 0x0
(XEN) elf_xen_addr_calc_check: addresses:
(XEN)     virt_base        = 0xffffffff80000000
(XEN)     elf_paddr_offset = 0x0
(XEN)     virt_offset      = 0xffffffff80000000
(XEN)     virt_kstart      = 0xffffffff81000000
(XEN)     virt_kend        = 0xffffffff81911000
(XEN)     virt_entry       = 0xffffffff8166b200
(XEN)     p2m_base         = 0xffffffffffffffff
(XEN)  Xen  kernel: 64-bit, lsb, compat32
(XEN)  Dom0 kernel: 64-bit, PAE, lsb, paddr 0x1000000 -> 0x1911000
(XEN) PHYSICAL MEMORY ARRANGEMENT:
(XEN)  Dom0 alloc.:   00000001f0000000->00000001f4000000 (1470696 pages to be allocated)
(XEN) VIRTUAL MEMORY ARRANGEMENT:
(XEN)  Loaded kernel: ffffffff81000000->ffffffff81911000
(XEN)  Init. ramdisk: ffffffff81911000->ffffffff82085400
(XEN)  Phys-Mach map: ffffffff82086000->ffffffff82bde740
(XEN)  Start info:    ffffffff82bdf000->ffffffff82bdf4b4
(XEN)  Page tables:   ffffffff82be0000->ffffffff82bfb000
(XEN)  Boot stack:    ffffffff82bfb000->ffffffff82bfc000
(XEN)  TOTAL:         ffffffff80000000->ffffffff83000000
(XEN)  ENTRY ADDRESS: ffffffff8166b200
(XEN) Dom0 has maximum 2 VCPUs
(XEN) elf_load_binary: phdr 0 at 0xffffffff81000000 -> 0xffffffff815bb000
(XEN) elf_load_binary: phdr 1 at 0xffffffff815bb000 -> 0xffffffff8165efe0
(XEN) elf_load_binary: phdr 2 at 0xffffffff8165f000 -> 0xffffffff8165f888
(XEN) elf_load_binary: phdr 3 at 0xffffffff81660000 -> 0xffffffff8179c200
(XEN) elf_load_binary: phdr 4 at 0xffffffff8179d000 -> 0xffffffff817b2c60
(XEN) elf_load_binary: phdr 5 at 0xffffffff817b3000 -> 0xffffffff817b4000
(XEN) Scrubbing Free RAM: .done.
(XEN) Xen trace buffers: disabled
(XEN) Std. Loglevel: All
(XEN) Guest Loglevel: All
(XEN) *** Serial input -> DOM0 (type \047CTRL-a\047 three times to switch input to Xen)
(XEN) Freed 128kB init memory.
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=0, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=1, old_irq=1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000928, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=2, old_irq=0, new_irq=0
(XEN) ioapic_guest_write: old_entry=000009f0, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=3, old_irq=3, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000930, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2262: 
(XEN) ioapic_guest_write: apic=0, pin=4, old_irq=4, new_irq=0
(XEN) ioapic_guest_write: old_entry=000009f1, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to remove IO-APIC pin of in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=5, old_irq=5, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000938, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=6, old_irq=6, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000940, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=7, old_irq=7, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000948, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=8, old_irq=8, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000950, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=9, old_irq=9, new_irq=0
(XEN) ioapic_guest_write: old_entry=00018958, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=10, old_irq=10, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000960, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=11, old_irq=11, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000968, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=12, old_irq=12, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000970, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=13, old_irq=13, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000978, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=14, old_irq=14, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000988, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=15, old_irq=15, new_irq=0
(XEN) ioapic_guest_write: old_entry=00000990, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=16, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=17, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=18, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=19, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=20, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=21, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=22, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=23, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00010900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=0, old_irq=-1, new_irq=0
(XEN) ioapic_guest_write: old_entry=00010000, new_entry=00000900
(XEN) ioapic_guest_write: Attempt to add IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=4, old_irq=4, new_irq=4
(XEN) ioapic_guest_write: old_entry=000009f1, new_entry=00000904
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:871:d0 MCE: wr MC1_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC2_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC3_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC4_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC5_STATUS 0
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:871:d0 MCE: wr MC1_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC2_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC3_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC4_STATUS 0
(XEN) mce.c:871:d0 MCE: wr MC5_STATUS 0
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=4, old_irq=4, new_irq=4
(XEN) ioapic_guest_write: old_entry=000009f1, new_entry=00000904
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=19, old_irq=19, new_irq=19
(XEN) ioapic_guest_write: old_entry=0000a9c8, new_entry=0001a913
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=18, old_irq=18, new_irq=18
(XEN) ioapic_guest_write: old_entry=0000a9d0, new_entry=0001a912
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=23, old_irq=23, new_irq=23
(XEN) ioapic_guest_write: old_entry=0000a9d8, new_entry=0001a917
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=19, old_irq=19, new_irq=19
(XEN) ioapic_guest_write: old_entry=0000a9c8, new_entry=0001a913
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=18, old_irq=18, new_irq=18
(XEN) ioapic_guest_write: old_entry=0000a9d0, new_entry=0001a912
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=18, old_irq=18, new_irq=18
(XEN) ioapic_guest_write: old_entry=0000a9d0, new_entry=0001a912
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=18, old_irq=18, new_irq=18
(XEN) ioapic_guest_write: old_entry=0000a9d0, new_entry=0001a912
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=16, old_irq=16, new_irq=16
(XEN) ioapic_guest_write: old_entry=0000a9b8, new_entry=0001a910
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) io_apic.c:2275: 
(XEN) ioapic_guest_write: apic=0, pin=22, old_irq=22, new_irq=22
(XEN) ioapic_guest_write: old_entry=0000a931, new_entry=0001a916
(XEN) ioapic_guest_write: Attempt to modify IO-APIC pin for in-use IRQ!
(XEN) [VT-D]iommu.c:1288:d0 domain_context_unmap:PCIe: bdf = 1:0.0
(XEN) [VT-D]iommu.c:1174:d0 domain_context_mapping:PCIe: bdf = 1:0.0
(XEN) domctl.c:887:d0 ioport_map:add f_gport=3b0 f_mport=3b0 np=c
(XEN) domctl.c:887:d0 ioport_map:add f_gport=3c0 f_mport=3c0 np=20
(XEN) domctl.c:836:d0 memory_map:add: gfn=a0 mfn=a0 nr_mfns=20
(XEN) [VT-D]io.c:284:d0 VT-d irq bind: m_irq = 1f device = 4 intx = 0
(XEN) HVM1: HVM Loader
(XEN) HVM1: Detected Xen v3.5-unstable
(XEN) HVM1: CPU speed is 2800 MHz
(XEN) irq.c:243: Dom1 PCI link 0 changed 0 -> 5
(XEN) HVM1: PCI-ISA link 0 routed to IRQ5
(XEN) irq.c:243: Dom1 PCI link 1 changed 0 -> 10
(XEN) HVM1: PCI-ISA link 1 routed to IRQ10
(XEN) irq.c:243: Dom1 PCI link 2 changed 0 -> 11
(XEN) HVM1: PCI-ISA link 2 routed to IRQ11
(XEN) irq.c:243: Dom1 PCI link 3 changed 0 -> 5
(XEN) HVM1: PCI-ISA link 3 routed to IRQ5
(XEN) HVM1: pci dev 01:2 INTD->IRQ5
(XEN) HVM1: pci dev 01:3 INTA->IRQ10
(XEN) HVM1: pci dev 02:0 INTA->IRQ11
(XEN) HVM1: pci dev 03:0 INTA->IRQ5
(XEN) HVM1: pci dev 04:0 INTA->IRQ5
(XEN) HVM1: pci dev 04:0 bar 14 size 10000000: e000000c
(XEN) domctl.c:836:d0 memory_map:add: gfn=e0000 mfn=c0000 nr_mfns=10000
(XEN) domctl.c:836:d0 memory_map:add: gfn=f0000 mfn=d0000 nr_mfns=2000
(XEN) HVM1: pci dev 04:0 bar 1c size 02000000: f0000004
(XEN) HVM1: pci dev 02:0 bar 14 size 01000000: f2000008
(XEN) domctl.c:836:d0 memory_map:add: gfn=f3000 mfn=d2000 nr_mfns=1000
(XEN) HVM1: pci dev 04:0 bar 10 size 01000000: f3000000
(XEN) HVM1: pci dev 04:0 bar 30 size 00020000: f4000000
(XEN) HVM1: pci dev 02:0 bar 10 size 00000100: 0000c001
(XEN) HVM1: pci dev 03:0 bar 10 size 00000100: 0000c101
(XEN) HVM1: pci dev 03:0 bar 14 size 00000100: f4020000
(XEN) HVM1: pci dev 04:0 bar 24 size 00000080: 0000c201
(XEN) domctl.c:887:d0 ioport_map:add f_gport=c200 f_mport=d000 np=80
(XEN) HVM1: pci dev 01:2 bar 20 size 00000020: 0000c281
(XEN) HVM1: pci dev 01:1 bar 20 size 00000010: 0000c2a1
(XEN) HVM1: Multiprocessor initialisation:
(XEN) HVM1:  - CPU0 ... 36-bit phys ... fixed MTRRs ... var MTRRs [3/8] ... done.
(XEN) HVM1: Testing HVM environment:
(XEN) HVM1:  - REP INSB across page boundaries ... passed
(XEN) HVM1:  - GS base MSRs and SWAPGS ... passed
(XEN) HVM1: Passed 2 of 2 tests
(XEN) HVM1: Writing SMBIOS tables ...
(XEN) HVM1: Loading ROMBIOS ...
(XEN) HVM1: 11900 bytes of ROMBIOS high-memory extensions:
(XEN) HVM1:   Relocating to 0xfc000000-0xfc002e7c ... done
(XEN) HVM1: Creating MP tables ...
(XEN) HVM1: Loading Gfx Video BIOS from file ...
(XEN) HVM1: Loading PCI Option ROM ...
(XEN) HVM1:  - Manufacturer: http://etherboot.org
(XEN) HVM1:  - Product name: gPXE
(XEN) HVM1: Loading ACPI ...
(XEN) HVM1:  - Lo data: 000ea020-000ea04f
(XEN) HVM1:  - Hi data: fc003000-fc0125cf
(XEN) HVM1: vm86 TSS at fc012800
(XEN) HVM1: BIOS map:
(XEN) HVM1:  c8000-d47ff: Etherboot ROM
(XEN) HVM1:  eb000-eb14e: SMBIOS tables
(XEN) HVM1:  f0000-fffff: Main BIOS
(XEN) HVM1: Invoking ROMBIOS ...
(XEN) HVM1: $Revision: 1.221 $ $Date: 2008/12/07 17:32:29 $
(XEN) HVM1: Bochs BIOS - build: 06/23/99
(XEN) HVM1: $Revision: 1.221 $ $Date: 2008/12/07 17:32:29 $
(XEN) HVM1: Options: apmbios pcibios eltorito PMM 
(XEN) HVM1: 
(XEN) HVM1: ata0-0: PCHS=16383/16/63 translation=lba LCHS=1024/255/63
(XEN) HVM1: ata0 master: QEMU HARDDISK ATA-7 Hard-Disk (51200 MBytes)
(XEN) HVM1: IDE time out
(XEN) HVM1: ata1 master: QEMU DVD-ROM ATAPI-4 CD-Rom/DVD-Rom
(XEN) HVM1: IDE time out
(XEN) HVM1: 
(XEN) HVM1: 
(XEN) HVM1: 
(XEN) HVM1: Press F12 for boot menu.
(XEN) HVM1: 
(XEN) HVM1: Booting from Hard Disk...
(XEN) HVM1: Booting from 0000:7c00
(XEN) HVM1: int13_harddisk: function 15, unmapped device for ELDL=81
(XEN) HVM1: *** int 15h function AX=e980, BX=006e not yet supported!
(XEN) mce.c:694:d1 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:714:d1 MCE: rdmsr MC0_CTL 0xffffffffffffffff
(XEN) mce.c:694:d1 MCE: rdmsr MCG_CAP 0x806
(XEN) irq.c:243: Dom1 PCI link 0 changed 5 -> 0
(XEN) irq.c:243: Dom1 PCI link 1 changed 10 -> 0
(XEN) irq.c:243: Dom1 PCI link 2 changed 11 -> 0
(XEN) irq.c:243: Dom1 PCI link 3 changed 5 -> 0
(XEN) domctl.c:846:d0 memory_map:remove: gfn=f3000 mfn=d2000 nr_mfns=1000
(XEN) domctl.c:846:d0 memory_map:remove: gfn=e0000 mfn=c0000 nr_mfns=10000
(XEN) domctl.c:846:d0 memory_map:remove: gfn=f0000 mfn=d0000 nr_mfns=2000
(XEN) domctl.c:911:d0 ioport_map:remove f_gport=c200 f_mport=d000 np=80
(XEN) domctl.c:836:d0 memory_map:add: gfn=f3000 mfn=d2000 nr_mfns=1000
(XEN) domctl.c:836:d0 memory_map:add: gfn=e0000 mfn=c0000 nr_mfns=10000
(XEN) domctl.c:836:d0 memory_map:add: gfn=f0000 mfn=d0000 nr_mfns=2000
(XEN) domctl.c:887:d0 ioport_map:add f_gport=c200 f_mport=d000 np=80
(XEN) domctl.c:846:d0 memory_map:remove: gfn=f3000 mfn=d2000 nr_mfns=1000
(XEN) domctl.c:846:d0 memory_map:remove: gfn=e0000 mfn=c0000 nr_mfns=10000
(XEN) domctl.c:846:d0 memory_map:remove: gfn=f0000 mfn=d0000 nr_mfns=2000
(XEN) domctl.c:911:d0 ioport_map:remove f_gport=c200 f_mport=d000 np=80
(XEN) domctl.c:836:d0 memory_map:add: gfn=f3000 mfn=d2000 nr_mfns=1000
(XEN) domctl.c:836:d0 memory_map:add: gfn=e0000 mfn=c0000 nr_mfns=10000
(XEN) domctl.c:836:d0 memory_map:add: gfn=f0000 mfn=d0000 nr_mfns=2000
(XEN) domctl.c:887:d0 ioport_map:add f_gport=c200 f_mport=d000 np=80
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806
(XEN) mce.c:694:d0 MCE: rdmsr MCG_CAP 0x806

-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Company Website: http://www.asiasoft.sg/
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore

On 08/29/2009 09:46 PM, Mr. Teo En Ming (Zhang Enming) wrote:
Dear All,

I have attached the patchset to xen-unstable and also the nvidia geforce 8400 gs firmware file here for your convenience.

You can refer to the screenshots at my blog here: http://teo-en-ming-aka-zhang-enming.blogspot.com/2009/08/windows-xp-home-domu-test-results-after.html

It shows that the emulated virtual VGA card is now disabled (not appearing in Windows XP Home DomU's device manager) and only the nVidia Geforce 8400 GS VGA BIOS gets loaded.

-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Company Website: http://www.asiasoft.sg/
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore


On 08/29/2009 09:20 PM, Mr. Teo En Ming (Zhang Enming) wrote:
Dear All,

I have applied the following patches to xen 3.5-unstable

1) intel-gfx-passthru-patch01.patch
2) intel-gfx-passthru-patch02.patch
3) intel-gfx-passthru-patch03.patch
4) enming-patch04.patch

and compiled xen 3.5-unstable successfully (both hypervisor and tools).

i rebooted into this newly compiled Xen hypervisor which supports loading vga bios from firmware file of nVidia Geforce 8400 GS PCI Express x16.

After dom0 has booted up, I executed the following script to hide nVidia Geforce 8400 GS from dom0.

[enming@fedora11-x86-64-host scripts]$ cat bind-devices-pci-stub.sh
#!/bin/sh
echo "10de 06e4" > /sys/bus/pci/drivers/pci-stub/new_id
echo "0000:01:00.0" > /sys/bus/pci/devices/0000:01:00.0/driver/unbind
echo "0000:01:00.0" > /sys/bus/pci/drivers/pci-stub/bind

I also assigned the nVidia Geforce 8400 GS to my Windows XP Home HVM domU.

pci = [ '01:00.0' ]

I also specified gfx_passthru=2.

Do note that I booted up with onboard Intel GMA4500 as the primary video adapter. Hence dom 0 has onboard graphics and Windows XP HVM domU has nvidia graphics.

Then I started Windows XP Home HVM DomU.

Very soon, my Dom 0's display was garbaged and X server on Dom 0 totally froze and became unresponsive. I cannot switch to any ttys.

However, I was still able to vnc into my Windows XP Home HVM Dom U. I had earlier installed a VNC server into my Windows XP guest. After remoting in to my Windows XP DomU through vnc, I found that NVIDIA Geforce 8400 GS cannot be initialized and no resources are available for this graphics card.

-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Company Website: http://www.asiasoft.sg/
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore


On 08/29/2009 08:25 PM, Mr. Teo En Ming (Zhang Enming) wrote:
Hi All,

I have solved the problem encountered below when building tools for xen 3.5-unstable. The compile problem exists because I downloaded and compiled the latest version of Intel ACPI Component Architecture compiler version 20090730. And I used this latest compiler during "make tools" for xen-unstable.

In original xen-unstable source codes cloned from xensoure mercurial repository, the header files ssdt_pm.h and ssdt_tpm.h in source directory tools/firmware/hvmloader/acpi/ are generated by

/*
 *
 * Intel ACPI Component Architecture
 * ASL Optimizing Compiler version 20061109 [May 18 2007]
 * Copyright (C) 2000 - 2006 Intel Corporation
 * Supports ACPI Specification Revision 3.0a
 *
 * Compilation of "ssdt_pm.asl" - Sun Oct 12 23:57:51 2008
 *
 * C source code output
 *
 */

In original ssdt_pm.h, it has "unsigned char AmlCode_PM[] =".

In original ssdt_tpm.h, it has "unsigned char AmlCode_TPM[] =".

Hence there was no problem with "make tools".

But, I downloaded, compiled and used

/*
 *
 * Intel ACPI Component Architecture
 * ASL Optimizing Compiler version 20090730 [Aug 29 2009]
 * Copyright (C) 2000 - 2009 Intel Corporation
 * Supports ACPI Specification Revision 4.0
 *
 * Compilation of "ssdt_pm.asl" - Sat Aug 29 18:55:40 2009
 *
 * C source code output
 *
 */

So the *new* ssdt_pm.h contains:

/*
 *
 * Intel ACPI Component Architecture
 * ASL Optimizing Compiler version 20090730 [Aug 29 2009]
 * Copyright (C) 2000 - 2009 Intel Corporation
 * Supports ACPI Specification Revision 4.0
 *
 * Compilation of "ssdt_pm.asl" - Sat Aug 29 18:55:40 2009
 *
 * C source code output
 *
 */
unsigned char AmlCode[] =
{
    0x53,0x53,0x44,0x54,0xD6,0x05,0x00,0x00,  /* 00000000    "SSDT...." */
    0x02,0xB9,0x58,0x65,0x6E,0x00,0x00,0x00,  /* 00000008    "..Xen..." */
    0x48,0x56,0x4D,0x00,0x00,0x00,0x00,0x00,  /* 00000010    "HVM....." */
    0x00,0x00,0x00,0x00,0x49,0x4E,0x54,0x4C,  /* 00000018    "....INTL" */
    0x30,0x07,0x09,0x20,0x10,0x41,0x5B,0x5C,  /* 00000020    "0.. .A[\" */
    0x5F,0x53,0x42,0x5F,0x5B,0x80,0x44,0x42,  /* 00000028    "_SB_[.DB" */
    0x47,0x41,0x01,0x0B,0x40,0xB0,0x01,0x5B,  /* 00000030    "GA..@..[" */
    0x81,0x0B,0x44,0x42,0x47,0x41,0x01,0x44,  /* 00000038    "..DBGA.D" */
    0x42,0x47,0x31,0x08,0x5B,0x80,0x44,0x42,  /* 00000040    "BG1.[.DB" */
    0x47,0x42,0x01,0x0B,0x44,0xB0,0x01,0x5B,  /* 00000048    "GB..D..[" */
    0x81,0x0B,0x44,0x42,0x47,0x42,0x01,0x44,  /* 00000050    "..DBGB.D" */
    0x42,0x47,0x32,0x08,0x5B,0x80,0x44,0x42,  /* 00000058    "BG2.[.DB" */
    0x47,0x43,0x01,0x0B,0x46,0xB0,0x01,0x5B,  /* 00000060    "GC..F..[" */
    0x81,0x0B,0x44,0x42,0x47,0x43,0x01,0x44,  /* 00000068    "..DBGC.D" */
    0x42,0x47,0x33,0x08,0x5B,0x80,0x44,0x42,  /* 00000070    "BG3.[.DB" */
    0x47,0x44,0x01,0x0B,0x48,0xB0,0x01,0x5B,  /* 00000078    "GD..H..[" */
    0x81,0x0B,0x44,0x42,0x47,0x44,0x01,0x44,  /* 00000080    "..DBGD.D" */
    0x42,0x47,0x34,0x08,0x5B,0x80,0x50,0x52,  /* 00000088    "BG4.[.PR" */
    0x54,0x31,0x01,0x0A,0xB2,0x0A,0x02,0x5B,  /* 00000090    "T1.....[" */
    0x81,0x10,0x50,0x52,0x54,0x31,0x01,0x50,  /* 00000098    "..PRT1.P" */
    0x42,0x32,0x5F,0x08,0x50,0x42,0x32,0x41,  /* 000000A0    "B2_.PB2A" */
    0x08,0x5B,0x80,0x50,0x52,0x54,0x32,0x01,  /* 000000A8    ".[.PRT2." */
    0x0A,0x86,0x01,0x5B,0x81,0x0B,0x50,0x52,  /* 000000B0    "...[..PR" */
    0x54,0x32,0x01,0x50,0x38,0x36,0x5F,0x08,  /* 000000B8    "T2.P86_." */
    0x5B,0x80,0x50,0x52,0x54,0x33,0x01,0x0A,  /* 000000C0    "[.PRT3.." */
    0x88,0x01,0x5B,0x81,0x0B,0x50,0x52,0x54,  /* 000000C8    "..[..PRT" */
    0x33,0x01,0x50,0x38,0x38,0x5F,0x08,0x5B,  /* 000000D0    "3.P88_.[" */
    0x01,0x53,0x59,0x4E,0x43,0x01,0x08,0x42,  /* 000000D8    ".SYNC..B" */
    0x55,0x46,0x30,0x11,0x04,0x0B,0x00,0x01,  /* 000000E0    "UF0....." */
    0x08,0x42,0x55,0x46,0x31,0x11,0x03,0x0A,  /* 000000E8    ".BUF1..." */
    0x08,0x8B,0x42,0x55,0x46,0x31,0x00,0x42,  /* 000000F0    "..BUF1.B" */
    0x55,0x46,0x41,0x8B,0x42,0x55,0x46,0x31,  /* 000000F8    "UFA.BUF1" */
    0x0A,0x04,0x42,0x55,0x46,0x42,0x14,0x14,  /* 00000100    "..BUFB.." */

And the *new* ssdt_tpm.h contains:

/*
 *
 * Intel ACPI Component Architecture
 * ASL Optimizing Compiler version 20090730 [Aug 29 2009]
 * Copyright (C) 2000 - 2009 Intel Corporation
 * Supports ACPI Specification Revision 4.0
 *
 * Compilation of "ssdt_tpm.asl" - Sat Aug 29 18:55:40 2009
 *
 * C source code output
 *
 */
unsigned char AmlCode[] =
{
    0x53,0x53,0x44,0x54,0x4C,0x00,0x00,0x00,  /* 00000000    "SSDTL..." */
    0x02,0x2A,0x58,0x65,0x6E,0x00,0x00,0x00,  /* 00000008    ".*Xen..." */
    0x48,0x56,0x4D,0x00,0x00,0x00,0x00,0x00,  /* 00000010    "HVM....." */
    0x00,0x00,0x00,0x00,0x49,0x4E,0x54,0x4C,  /* 00000018    "....INTL" */
    0x30,0x07,0x09,0x20,0x5B,0x82,0x26,0x54,  /* 00000020    "0.. [.&T" */
    0x50,0x4D,0x5F,0x08,0x5F,0x48,0x49,0x44,  /* 00000028    "PM_._HID" */
    0x0C,0x41,0xD0,0x0C,0x31,0x08,0x5F,0x43,  /* 00000030    ".A..1._C" */
    0x52,0x53,0x11,0x11,0x0A,0x0E,0x86,0x09,  /* 00000038    "RS......" */
    0x00,0x01,0x00,0x00,0xD4,0xFE,0x00,0x50,  /* 00000040    ".......P" */
    0x00,0x00,0x79,0x00,
};

which are both wrong.

In ssdt_pm.h, I have to change "unsigned char AmlCode[]" to "unsigned char AmlCode_PM[]".

In ssdt_tpm.h, I have to change "unsigned char AmlCode[]" to "unsigned char AmlCode_TPM[]".

Then "make tools" is able to complete successfully.

I have created a patch for anybody who may be using the *latest* version of Intel ACPI CA compiler version 20090730 and attached it here.

Patch file filename enming-patch04.patch:

<CODE>

Patch created by Teo En Ming (Zhang Enming) on 29 August 2009 Saturday at 8:00 P.M. Singapore Time
Email #1: enming.teo@xxxxxxxxxxxxxxx
Email #2: space.time.universe@xxxxxxxxx
MSN: teoenming@xxxxxxxxxxx
Mobile Phone: +65-9648-9798

--- ssdt_pm.h    2009-08-29 19:54:52.653088000 +0800
+++ ssdt_pm.h    2009-08-29 19:56:51.813088550 +0800
@@ -10,7 +10,7 @@
  * C source code output
  *
  */
-unsigned char AmlCode[] =
+unsigned char AmlCode_PM[] =
 {
     0x53,0x53,0x44,0x54,0xD6,0x05,0x00,0x00,  /* 00000000    "SSDT...." */
     0x02,0xB9,0x58,0x65,0x6E,0x00,0x00,0x00,  /* 00000008    "..Xen..." */
--- ssdt_tpm.h    2009-08-29 19:55:44.578738954 +0800
+++ ssdt_tpm.h    2009-08-29 19:57:27.896638884 +0800
@@ -10,7 +10,7 @@
  * C source code output
  *
  */
-unsigned char AmlCode[] =
+unsigned char AmlCode_TPM[] =
 {
     0x53,0x53,0x44,0x54,0x4C,0x00,0x00,0x00,  /* 00000000    "SSDTL..." */
     0x02,0x2A,0x58,0x65,0x6E,0x00,0x00,0x00,  /* 00000008    ".*Xen..." */

</CODE>

-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Company Website: http://www.asiasoft.sg/
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore


On 08/29/2009 07:03 PM, Mr. Teo En Ming (Zhang Enming) wrote:
Hi,

I cloned http://xenbits.xensource.com/xen-unstable.hg again today. I tried applying the three Intel gfx passthrough patches to xen-unstable. When I "make tools", I get the same error again:

make[7]: Entering directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader'
make -C acpi all
get-path: will use #!/usr/bin/python2.6 for python programs
make[8]: Entering directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader/acpi'
make iasl
get-path: will use #!/usr/bin/python2.6 for python programs
make[9]: Entering directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader/acpi'
make[9]: `/usr/local/bin/iasl' is up to date.
make[9]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader/acpi'
iasl -tc ssdt_tpm.asl

Intel ACPI Component Architecture
ASL Optimizing Compiler version 20090730 [Aug 29 2009]
Copyright (C) 2000 - 2009 Intel Corporation
Supports ACPI Specification Revision 4.0

ASL Input:  ssdt_tpm.asl - 31 lines, 1111 bytes, 3 keywords
AML Output: SSDT_TPM.aml - 76 bytes, 3 named objects, 0 executable opcodes

Compilation complete. 0 Errors, 0 Warnings, 0 Remarks, 0 Optimizations
mv ssdt_tpm.hex ssdt_tpm.h
rm -f *.aml
make iasl
get-path: will use #!/usr/bin/python2.6 for python programs
make[9]: Entering directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader/acpi'
make[9]: `/usr/local/bin/iasl' is up to date.
make[9]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader/acpi'
iasl -tc ssdt_pm.asl

Intel ACPI Component Architecture
ASL Optimizing Compiler version 20090730 [Aug 29 2009]
Copyright (C) 2000 - 2009 Intel Corporation
Supports ACPI Specification Revision 4.0

ASL Input:  ssdt_pm.asl - 425 lines, 12754 bytes, 192 keywords
AML Output: SSDT_PM.aml - 1494 bytes, 64 named objects, 128 executable opcodes

Compilation complete. 0 Errors, 0 Warnings, 0 Remarks, 31 Optimizations
mv ssdt_pm.hex ssdt_pm.h
rm -f *.aml
gcc   -O1 -fno-omit-frame-pointer -fno-optimize-sibling-calls -m32 -march=i686 -g -fno-strict-aliasing -std=gnu99 -Wall -Wstrict-prototypes -Wno-unused-value -Wdeclaration-after-statement  -D__XEN_TOOLS__ -MMD -MF .build.o.d  -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -mno-tls-direct-seg-refs -Werror -fno-stack-protector -fno-builtin -msoft-float -I. -I.. -I../../../../tools/include -c -o build.o build.c
In file included from build.c:21:
ssdt_pm.h:13: error: redefinition of ‘AmlCode’
ssdt_tpm.h:13: note: previous definition of ‘AmlCode’ was here
build.c: In function ‘construct_secondary_tables’:
build.c:184: error: ‘AmlCode_PM’ undeclared (first use in this function)
build.c:184: error: (Each undeclared identifier is reported only once
build.c:184: error: for each function it appears in.)
build.c:194: error: ‘AmlCode_TPM’ undeclared (first use in this function)
make[8]: *** [build.o] Error 1
make[8]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader/acpi'
make[7]: *** [subdir-all-acpi] Error 2
make[7]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader'
make[6]: *** [subdirs-all] Error 2
make[6]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware/hvmloader'
make[5]: *** [subdir-all-hvmloader] Error 2
make[5]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware'
make[4]: *** [subdirs-all] Error 2
make[4]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools/firmware'
make[2]: *** [subdir-install-firmware] Error 2
make[2]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools'
make[1]: *** [subdirs-install] Error 2
make[1]: Leaving directory `/usr/src/xen-unstable-new.hg-vgapt/tools'
make: *** [install-tools] Error 2

Any ideas about this Advanced Configuration and Power Interface code?

-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Company Website: http://www.asiasoft.sg/
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore


On 08/29/2009 02:58 PM, Mr. Teo En Ming (Zhang Enming) wrote:
Hi

Anybody available today? I know it's Saturday. :-)

-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Company Website: http://www.asiasoft.sg/
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore


On 08/29/2009 11:48 AM, Mr. Teo En Ming (Zhang Enming) wrote:

Dear All,

After applying Intel VGA passthrough patches 1, 2 and 3, I have no problems with "make xen", and "make install-xen". However, I have errors with "make tools".

Here is the error output:

msoft-float -I. -I.. -I../../../../tools/include -c -o build.o build.c
build.c: In function ‘construct_secondary_tables’:
build.c:194: error: ‘AmlCode_TPM’ undeclared (first use in this function)
build.c:194: error: (Each undeclared identifier is reported only once
build.c:194: error: for each function it appears in.)
make[8]: *** [build.o] Error 1
make[8]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools/firmware/hvmloader/acpi'
make[7]: *** [subdir-all-acpi] Error 2
make[7]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools/firmware/hvmloader'
make[6]: *** [subdirs-all] Error 2
make[6]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools/firmware/hvmloader'
make[5]: *** [subdir-all-hvmloader] Error 2
make[5]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools/firmware'
make[4]: *** [subdirs-all] Error 2
make[4]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools/firmware'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools/firmware'
make[2]: *** [subdir-install-firmware] Error 2
make[2]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools'
make[1]: *** [subdirs-install] Error 2
make[1]: Leaving directory `/usr/src/xen-unstable.hg-vgapt/tools'
make: *** [install-tools] Error 2

There is an undeclared identifier in tools/firmware/hvmloader/acpi/build.c source code. Could you guys help me resolve this issue?

I had no problems compiling xen 3.5-unstable before applying the Intel vga passthrough patches and before installing the Intel ACPI Component Architecture compiler.

I have also attached Intel graphics passthrough patches 1, 2 and 3 for your convenience here.

Thank you very much.

Hope I can get this working during the weekends.

-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Company Website: http://www.asiasoft.sg/
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore


On 08/29/2009 10:17 AM, Mr. Teo En Ming (Zhang Enming) wrote:
Hi Tim,

I thought it should be gfx_passthru=2 in domU config?
-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore


On 08/29/2009 06:42 AM, Tim Moore wrote:

Teo,

 

I have also performed the same exercise as yourself and I now have successfully compiled all 3x patches into Xen, Qemu and the BIOS File Loading in the hvmloader, this all compiles find on my system. Suggest you do a "make clean" on the tools and start again !

 

After booting with the patched xen-unstable and adding the gfx-passthru=1 parameter to my HVM DomU, as I suspected - it still doesn't work.

 

I have both a 9500GT and GTX260(primary) in my Intel DX58SO machine, tried passing through either device and my primary display locks up ! (included hiding with pci-stub)

 

I verified that the DomU was functional beforehand, as It also booted successfully without the gfx-passthru parameter (and a vncviewer/cirrus display)

 

Unfortunately, I can't debug further as my Primary display corrupts as soon as the DomU starts. I did notice that in "xm debug" the "Loading Gfx BIOS File.." message was displayed and the DomU did continue to initialise the BIOS tables and such before finally locking. I then (blindly) typed on a corrupt Dom0 console and managed to start kdm and login, so the Dom0 was not completely trashed. But then after a few minutes, the machine totally froze and had to hit the reset switch.

 

I`m no specialist but this looks like the VGA BIOS Re-initialisation is playing havoc with the DomU and possibly the Dom0 graphics. I notice that both are also using IRQ11 which could play a major part. Furthermore, there was a lot of debug output in the qemu and xend.log indicating Base Address Register invalid access and therefore it seems there may be a second obstacle.

 

Hope you have a better success than me !

 

For now, I would try re-compiling a fresh xen-unstable with carefully applied patches .. oh! and don't forget to enable the pci-stub driver for Dom0 (it's not selected by default)

 

Tim

 

From: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx [mailto:xen-devel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of Mr. Teo En Ming (Zhang Enming)
Sent: 28 August 2009 21:14
To: enming.teo@xxxxxxxxxxxxxxx
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx; 'Lin, Ben Y'; 'Kay, Allen M'; 'Jean Guyader'; Keir.Fraser@xxxxxxxxxxxxx; weidong.han@xxxxxxxxx; bengheng@xxxxxxxxxxxxxx
Subject: Re: [Xen-devel] [PATCH 2/2] graphics passthrough with VT-d

 

After applying the 1st and 2nd patch to xen-unstable successfully, I examined the source codes Makefile and hvmloader.c in tools/firmware/hvmloader, compared them to Weidong's 3rd patch and I generated my own 3rd patch. Then I used my own generated 3rd patch to apply patching for loading vga bios from firmware file.
 
Here is my own generated 3rd patch instead of using Weidong's 3rd patch:
 
--- Makefile    2009-08-29 03:24:52.413083774 +0800
+++ Makefile    2009-08-29 03:29:12.763299633 +0800
@@ -50,6 +50,7 @@
 roms.h: ../rombios/BIOS-bochs-latest ../vgabios/VGABIOS-lgpl-latest.bin \
        ../vgabios/VGABIOS-lgpl-latest.cirrus.bin ../etherboot/eb-roms.h
        sh ./mkhex rombios ../rombios/BIOS-bochs-latest > roms.h
+       sh ./mkhex vgabios_pt ../vgabios/vgabios-pt.bin >> roms.h
        sh ./mkhex vgabios_stdvga ../vgabios/VGABIOS-lgpl-latest.bin >> roms.h
        sh ./mkhex vgabios_cirrusvga \
                ../vgabios/VGABIOS-lgpl-latest.cirrus.bin >> roms.h
--- hvmloader.c 2009-08-29 03:26:06.911085797 +0800
+++ hvmloader.c 2009-08-29 03:31:43.172084995 +0800
@@ -688,9 +688,9 @@
         vgabios_sz = round_option_rom(sizeof(vgabios_stdvga));
         break;
     case VGA_pt:
-        printf("Loading VGABIOS of passthroughed gfx ...\n");
-        vgabios_sz =
-            round_option_rom((*(uint8_t *)(VGABIOS_PHYSICAL_ADDRESS+2)) * 512);
+       printf("Loading Gfx Video BIOS from file ...\n");
+       memcpy((void *)VGABIOS_PHYSICAL_ADDRESS, vgabios_pt, sizeof(vgabios_pt));
+       vgabios_sz = round_option_rom(sizeof(vgabios_pt));
         break;
     default:
         printf("No emulated VGA adaptor ...\n");
 
 
I can "make xen" successfully but when I proceeded to "make tools", errors were encountered.
 
Please see attached error output. How can I solve this problem?
 
 
-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore



On 08/29/2009 12:59 AM, Mr. Teo En Ming (Zhang Enming) wrote:

OK I believe the 3rd patch is not incomplete but there's a white space issue when I copied the code from the mailing list into my vi.
 
See http://www.htdig.org/mail/2000/11/0167.html
 
When I used the -l flag to patch using the 3rd patch, the number of errors was reduced.
 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# patch -l -p1 < intel-gfx-passthru-patch-3.patch 
patching file tools/firmware/hvmloader/Makefile
patching file tools/firmware/hvmloader/hvmloader.c
Hunk #1 FAILED at 688.
1 out of 1 hunk FAILED -- saving rejects to file tools/firmware/hvmloader/hvmloader.c.rej
 
Now patching tools/firmware/hvmloader/Makefile is successful but patching tools/firmware/hvmloader/hvmloader.c still failed.
 
-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore




On 08/28/2009 11:55 PM, Mr. Teo En Ming (Zhang Enming) wrote:

Dear Weidong,

A big big thanks for the vga passthrough patches for xen 3.5-unstable!!! These are eagerly anticipated patches. As I did not study computer science and computer architecture, I won't be able to write those patches you guys at Intel wrote.

I applied the following patches xen-gfx-passthrough.patch and qemu-gfx-passthrough.patch to xen 3.5-unstable without issues.

Then I tried to apply the 3rd patch you provided at http://lists.xensource.com/archives/html/xen-devel/2009-08/msg01047.html

I saved the following code

<CODE>

diff -r 494be76c1ad9 tools/firmware/hvmloader/Makefile
--- a/tools/firmware/hvmloader/Makefile Thu Aug 27 16:54:33 2009 +0800
+++ b/tools/firmware/hvmloader/Makefile Thu Aug 27 17:22:01 2009 +0800
@@ -50,6 +50,7 @@ roms.h: ../rombios/BIOS-bochs-latest ../
 roms.h: ../rombios/BIOS-bochs-latest ../vgabios/VGABIOS-lgpl-latest.bin \
    ../vgabios/VGABIOS-lgpl-latest.cirrus.bin ../etherboot/eb-roms.h
    sh ./mkhex rombios ../rombios/BIOS-bochs-latest > roms.h
+   sh ./mkhex vgabios_pt ../vgabios/vgabios-pt.bin >> roms.h
    sh ./mkhex vgabios_stdvga ../vgabios/VGABIOS-lgpl-latest.bin >> roms.h
    sh ./mkhex vgabios_cirrusvga \
        ../vgabios/VGABIOS-lgpl-latest.cirrus.bin >> roms.h
diff -r 494be76c1ad9 tools/firmware/hvmloader/hvmloader.c
--- a/tools/firmware/hvmloader/hvmloader.c  Thu Aug 27 16:54:33 2009 +0800
+++ b/tools/firmware/hvmloader/hvmloader.c  Thu Aug 27 17:23:00 2009 +0800
@@ -688,9 +688,9 @@ int main(void)
         vgabios_sz = round_option_rom(sizeof(vgabios_stdvga));
         break;
     case VGA_pt:
-        printf("Loading Gfx Video BIOS from 0xC0000 ...\n");
-        vgabios_sz =
-            round_option_rom((*(uint8_t *)(VGABIOS_PHYSICAL_ADDRESS+2)) * 512);
+         printf("Loading Gfx Video BIOS from file ...\n");
+         memcpy((void *)VGABIOS_PHYSICAL_ADDRESS, vgabios_pt, 
sizeof(vgabios_pt));
+         vgabios_sz = round_option_rom(sizeof(vgabios_pt));
         break;
     default:
         printf("No emulated VGA adaptor ...\n");
  
</CODE>
 
as intel-gfx-passthru-patch-3.patch and then I tried to apply the patch to xen 3.5-unstable. I got errors. I think it's because the 3rd patch you provided is incomplete.
 
Here's my patching process:
 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# find . -name vgabios
./tools/firmware/vgabios
./.hg/store/data/tools/firmware/vgabios
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# cp ~enming/vgabios-pt.bin tools/firmware/vgabios/
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# ls tools/firmware/vgabios/
biossums.c  clext.c      Makefile  TODO                 vbe.h            vgabios.h       vgatables.h
BUGS        COPYING      Notes     vbe.c                vbetables-gen.c  vgabios-pt.bin
ChangeLog   dataseghack  README    vbe_display_api.txt  vgabios.c        vgafonts.h
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# pwd
/usr/src/xen-unstable.hg-vgapt
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# wget http://lists.xensource.com/archives/html/xen-devel/2009-08/bincPiiAf0QWg.bin
--2009-08-28 23:18:21--  http://lists.xensource.com/archives/html/xen-devel/2009-08/bincPiiAf0QWg.bin
Resolving lists.xensource.com... 70.42.241.110
Connecting to lists.xensource.com|70.42.241.110|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 12565 (12K) [application/octet-stream]
Saving to: `bincPiiAf0QWg.bin'
 
100%[======================================================================>] 12,565      30.7K/s   in 0.4s    
 
2009-08-28 23:18:22 (30.7 KB/s) - `bincPiiAf0QWg.bin' saved [12565/12565]
 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# mv bincPiiAf0QWg.bin xen-gfx-passthrough.patch
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# vi xen-gfx-passthrough.patch 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# patch < xen-gfx-passthrough.patch 
can't find file to patch at input line 4
Perhaps you should have used the -p or --strip option?
The text leading up to this was:
--------------------------
|diff -r 5d7e7a250267 tools/firmware/hvmloader/config.h
|--- a/tools/firmware/hvmloader/config.h      Wed Aug 26 18:28:44 2009 +0800
|+++ b/tools/firmware/hvmloader/config.h      Thu Aug 27 16:54:24 2009 +0800
--------------------------
File to patch: ^C
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# ex xen-gfx-passthrough.patch 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# patch -p1 < xen-gfx-passthrough.patch 
patching file tools/firmware/hvmloader/config.h
patching file tools/firmware/hvmloader/hvmloader.c
patching file tools/libxc/ia64/xc_ia64_hvm_build.c
patching file tools/libxc/xc_hvm_build.c
patching file tools/libxc/xc_linux.c
patching file tools/libxc/xenctrl.h
patching file tools/libxc/xenguest.h
patching file tools/python/xen/lowlevel/xc/xc.c
patching file tools/python/xen/xend/XendConfig.py
Hunk #1 succeeded at 174 (offset -1 lines).
patching file tools/python/xen/xend/image.py
Hunk #1 succeeded at 780 (offset -6 lines).
Hunk #3 succeeded at 895 (offset -6 lines).
patching file tools/python/xen/xm/create.py
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# wget http://lists.xensource.com/archives/html/xen-devel/2009-08/binglLqkeq4Rj.bin
--2009-08-28 23:21:35--  http://lists.xensource.com/archives/html/xen-devel/2009-08/binglLqkeq4Rj.bin
Resolving lists.xensource.com... 70.42.241.110
Connecting to lists.xensource.com|70.42.241.110|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 9841 (9.6K) [application/octet-stream]
Saving to: `binglLqkeq4Rj.bin'
 
100%[======================================================================>] 9,841       24.3K/s   in 0.4s    
 
2009-08-28 23:21:36 (24.3 KB/s) - `binglLqkeq4Rj.bin' saved [9841/9841]
 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# mv binglLqkeq4Rj.bin qemu-gfx-passthrough.patch
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# vi qemu-gfx-passthrough.patch 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# find . -name hw
./tools/ioemu-remote/hw
./.hg/store/data/tools/ioemu/hw
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# mv qemu-gfx-passthrough.patch tools/ioemu-remote/
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# cd tools/ioemu-remote/
[root@fedora11-x86-64-host ioemu-remote]# patch -p1 < qemu-
qemu-aio.h                  qemu-img.c                  qemu-sockets.c
qemu-binfmt-conf.sh         qemu-img.texi               qemu-tech.texi
qemu-char.c                 qemu-lock.h                 qemu-timer.h
qemu-char.h                 qemu-log.h                  qemu-tool.c
qemu-common.h               qemu-malloc.c               qemu-xen.h
qemu-doc.texi               qemu-nbd.c                  
qemu-gfx-passthrough.patch  qemu-nbd.texi               
[root@fedora11-x86-64-host ioemu-remote]# patch -p1 < qemu-gfx-passthrough.patch 
patching file hw/pass-through.c
patching file hw/pass-through.h
patching file hw/pc.c
patching file vl.c
[root@fedora11-x86-64-host ioemu-remote]# cd ..
[root@fedora11-x86-64-host tools]# cd ..
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# vi intel-gfx-passthru-patch-3.patch
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# patch -p1 < intel-gfx-passthru-patch-3.patch 
patching file tools/firmware/hvmloader/Makefile
Hunk #1 FAILED at 50.
1 out of 1 hunk FAILED -- saving rejects to file tools/firmware/hvmloader/Makefile.rej
patching file tools/firmware/hvmloader/hvmloader.c
patch: **** malformed patch at line 24: sizeof(vgabios_pt));
 
[root@fedora11-x86-64-host xen-unstable.hg-vgapt]# vi intel-gfx-passthru-patch-3.patch 
 
For everybody's convenience, I have attached intel-gfx-passthru-patch-3.patch and the firmware for my nVidia GeForce 8400 GS PCI Express x16 graphics card in this email.
 
Please help me complete intel-gfx-passthru-patch-3.patch as I really need it.
 
Thank you very much!!!
  
-- 
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics Engineering) BEng(Hons)(Mechanical Engineering) 
Technical Support Engineer 
Information Technology Department
Asiasoft Online Pte Ltd
Tampines Central 1 #04-01 Tampines Plaza 
Singapore 529541
Republic of Singapore
Mobile: +65-9648-9798
MSN: teoenming@xxxxxxxxxxx
Alma Maters: Singapore Polytechnic, National University of Singapore
This patch supports basic gfx passthrough on QEMU:
  - disable emulated VGA adpater if there is passthroughed gfx
  - register/unregister legacy VGA I/O ports and MMIOs for passthroughed gfx
 
Signed-off-by: Ben Lin <ben.y.lin@xxxxxxxxx>
Signed-off-by: Weidong Han <weidong.han@xxxxxxxxx>
No virus found in this incoming message.
Checked by AVG - www.avg.com 
Version: 8.5.409 / Virus Database: 270.13.69/2328 - Release Date: 08/27/09
18:02:00
 
No virus found in this outgoing message.
Checked by AVG - www.avg.com 
Version: 8.5.409 / Virus Database: 270.13.71/2330 - Release Date: 08/27/09
18:02:00
  

 
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
  




 
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
  

 




 


_______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel















_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>