[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] Re: Video Presentation on PCI Express x16 VGA Pass Through to Xen-based Windows XP Home Edition HVM Virtual Machine


  • To: xen-devel@xxxxxxxxxxxxxxxxxxx
  • From: "Mr. Teo En Ming (Zhang Enming)" <space.time.universe@xxxxxxxxx>
  • Date: Wed, 9 Sep 2009 23:39:34 +0800
  • Delivery-date: Wed, 09 Sep 2009 08:40:11 -0700
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=IAqeifVGyDtE4ZEjpSdW0j45Tb3ugwBANaiP9ABmWm+KIRS9rU5Rl0/RJ3MLiGc0lg XXLmCcuCNaB+/y4FLE7AH1sr45o60oAG2Ni6KJ9qAfxspDK3Pi/pQ0lNYqtB1nO1b3ru f++Q0WNznH6o9w3aTCcBfyJ9H9q7qiqrrkMSU=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

Hi All,

Weidong's graphic card is:

01:00.0 VGA compatible controller: nVidia Corporation Unknown device 05ff (rev a1) (prog-if 00 [VGA controller])
        Subsystem: nVidia Corporation Unknown device 0661
        Flags: bus master, fast devsel, latency 0, IRQ 16
        Memory at c2000000 (32-bit, non-prefetchable) [size=16M]
        Memory at e0000000 (64-bit, prefetchable) [size=256M]
        Memory at c0000000 (64-bit, non-prefetchable) [size=32M]
        I/O ports at 9c00 [size=128]
        Expansion ROM at bff00000 [disabled] [size=512K]
        Capabilities: [60] Power Management version 3
        Capabilities: [68] Message Signalled Interrupts: 64bit+ Queue=0/0 Enable+
        Capabilities: [78] Express Endpoint IRQ 0


So his xen-vBAR-pBAR.patch is:

<CODE>

diff -r 96b634bf65c3 tools/firmware/hvmloader/acpi/dsdt.asl
--- a/tools/firmware/hvmloader/acpi/dsdt.asl    Mon Aug 31 13:14:47 2009 +0800
+++ b/tools/firmware/hvmloader/acpi/dsdt.asl    Mon Aug 31 16:03:27 2009 +0800
@@ -175,6 +175,34 @@ DefinitionBlock ("DSDT.aml", "DSDT", 2,
                         0x000BFFFF,
                         0x00000000,
                         0x00020000)
+
+                    /* reserve MMIO BARs of gfx for 1:1 mapping */
+                    DWordMemory(
+                        ResourceProducer, PosDecode, MinFixed, MaxFixed,
+                        Cacheable, ReadWrite,
+                        0x00000000,
+                        0xE0000000,
+                        0xEFFFFFFF,
+                        0x00000000,
+                        0x10000000)
+
+                    DWordMemory(
+                        ResourceProducer, PosDecode, MinFixed, MaxFixed,
+                        NonCacheable, ReadWrite,
+                        0x00000000,
+                        0xC0000000,
+                        0xC1FFFFFF,
+                        0x00000000,
+                        0x02000000)
+
+                    DWordMemory(
+                        ResourceProducer, PosDecode, MinFixed, MaxFixed,
+                        NonCacheable, ReadWrite,
+                        0x00000000,
+                        0xC2000000,
+                        0xC2FFFFFF,
+                        0x00000000,
+                        0x01000000)
+                        0x01000000)
 
                     DWordMemory(
                         ResourceProducer, PosDecode, MinFixed, MaxFixed,

</CODE>

My own nvidia pci express x16 geforce 8400 GS graphics card is:

01:00.0 VGA compatible controller: nVidia Corporation GeForce 8400 GS (rev a1) (prog-if 00 [VGA controller])
    Flags: bus master, fast devsel, latency 0, IRQ 16
    Memory at d2000000 (32-bit, non-prefetchable) [size=16M]
    Memory at c0000000 (64-bit, prefetchable) [size=256M]
    Memory at d0000000 (64-bit, non-prefetchable) [size=32M]
    I/O ports at d000 [size=128]
    [virtual] Expansion ROM at d3000000 [disabled] [size=128K]
    Capabilities: <access denied>
    Kernel driver in use: nvidia
    Kernel modules: nvidia



So should I modify Weidong's xen-vBAR-pBAR.patch like the following code section to reflect my own graphics card?

<CODE>

diff -r 96b634bf65c3 tools/firmware/hvmloader/acpi/dsdt.asl
--- a/tools/firmware/hvmloader/acpi/dsdt.asl    Mon Aug 31 13:14:47 2009 +0800
+++ b/tools/firmware/hvmloader/acpi/dsdt.asl    Mon Aug 31 16:03:27 2009 +0800
@@ -175,6 +175,34 @@ DefinitionBlock ("DSDT.aml", "DSDT", 2,
                         0x000BFFFF,
                         0x00000000,
                         0x00020000)
+
+                    /* reserve MMIO BARs of gfx for 1:1 mapping */
+                    DWordMemory(
+                        ResourceProducer, PosDecode, MinFixed, MaxFixed,
+                        Cacheable, ReadWrite,
+                        0x00000000,
+                        0xC0000000,
+                        0xCFFFFFFF,
+                        0x00000000,
+                        0x10000000)
+
+                    DWordMemory(
+                        ResourceProducer, PosDecode, MinFixed, MaxFixed,
+                        NonCacheable, ReadWrite,
+                        0x00000000,
+                        0xD0000000,
+                        0xD1FFFFFF,
+                        0x00000000,
+                        0x02000000)
+
+                    DWordMemory(
+                        ResourceProducer, PosDecode, MinFixed, MaxFixed,
+                        NonCacheable, ReadWrite,
+                        0x00000000,
+                        0xD2000000,
+                        0xD2FFFFFF,
+                        0x00000000,
+                        0x01000000)
+                        0x01000000)
 
                     DWordMemory(
                         ResourceProducer, PosDecode, MinFixed, MaxFixed,

</CODE>

I am doing a direct substitution using pattern recognition. Please advise and correct me on my modifications above because I am not acquainted with the memory regions of graphics card.

--
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics) BEng(Hons)(Mechanical Engineering)
Alma Maters:
(1) Singapore Polytechnic
(2) National University of Singapore
Blog URL: http://teo-en-ming-aka-zhang-enming.blogspot.com
Email: space.time.universe@xxxxxxxxx
MSN: teoenming@xxxxxxxxxxx
Mobile Phone: +65-9648-9798
Street: Bedok Reservoir Road
Republic of Singapore
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.