From: "Mr. Teo En Ming (Zhang Enming)" Subject: Re: Re: Fire-wire passthrough with Linux pv-ops (2.6.31.1) Date: Tue, 3 Nov 2009 20:27:00 +0800 Message-ID: References: <20091009071135.GJ1434@reaktio.net> <20091013142253.GB19950@phenom.dumpdata.com> <20091013170431.GB21615@phenom.dumpdata.com> <20091023175700.GA1383@phenom.dumpdata.com> <715D42877B251141A38726ABF5CABF2C0550A64C5A@pdsmsx503.ccr.corp.intel.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1082082339==" Return-path: In-Reply-To: <715D42877B251141A38726ABF5CABF2C0550A64C5A@pdsmsx503.ccr.corp.intel.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "Han, Weidong" Cc: Jeremy Fitzhardinge , "xen-devel@lists.xensource.com" , space.time.universe@gmail.com, "xen-users@lists.xensource.com" , Konrad Rzeszutek Wilk List-Id: xen-devel@lists.xenproject.org --===============1082082339== Content-Type: multipart/alternative; boundary=0016364ed9d465e03f0477769c05 --0016364ed9d465e03f0477769c05 Content-Type: text/plain; charset=GB2312 Content-Transfer-Encoding: quoted-printable Hi Weidong, I have applied the patch to pv-ops dom0 kernel 2.6.31.5. Please refer to the following link: http://enmingteo.files.wordpress.com/2009/11/screenshot-01.png It does however cause my console terminal in dom0 to be very sluggish/unresponsive after I have started Slackware64 13.0 HVM. Here is my qemu-dm-slackware64.log output: domid: 1 qemu: the number of cpus is 2 config qemu network with xen bridge for tap1.0 eth0 Watching /local/domain/0/device-model/1/logdirty/next-active Watching /local/domain/0/device-model/1/command qemu_map_cache_init nr_buckets =3D 10000 size 4194304 shared page at pfn feffd buffered io page at pfn feffb Guest uuid =3D 4d2942cf-1ba2-0ff1-4252-184d1ab31369 Time offset set 0 cirrus_vga_enabled populating video RAM at ff000000 mapping video RAM from ff000000 Register xen platform. Done register platform. xs_read(/vm/4d2942cf-1ba2-0ff1-4252-184d1ab31369/log-throttling): read erro= r platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state. xs_read(/local/domain/0/device-model/1/xen_extended_power_mgmt): read error xs_read(): vncpasswd get error. /vm/4d2942cf-1ba2-0ff1-4252-184d1ab31369/vncpasswd. medium change watch on `hdc' (index: 1): /media/hitachi/slackware64-13.0-install-dvd.iso I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0 I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0 dm-command: hot insert pass-through pci dev register_real_device: Assigning real physical device 02:01.0 ... pt_iomul_init: Error: pt_iomul_init can't open file /dev/xen/pci_iomul: No such file or directory: 0x2:0x1.0x0 pt_register_regions: IO region registered (size=3D0x00001000 base_addr=3D0xd3801000) pt_register_regions: IO region registered (size=3D0x00000100 base_addr=3D0xd3800000) register_real_device: Real physical device 02:01.0 registered successfuly! IRQ type =3D INTx cirrus vga map change while on lfb mode pt_iomem_map: e_phys=3De3001000 maddr=3Dd3801000 type=3D0 len=3D4096 index= =3D0 first_map=3D1 pt_iomem_map: e_phys=3De3002000 maddr=3Dd3800000 type=3D0 len=3D4096 index= =3D1 first_map=3D1 mapping vram to e0000000 - e0400000 platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state. platform_fixed_ioport: changed ro/rw state of ROM memory area. now is ro state. pt_pci_write_config: Warning: Guest attempt to set address to unused Base Address Register. [00:05.0][Offset:30h][Length:4] Here is my domU lspci -vvv output: 00:05.0 FireWire (IEEE 1394): Agere Systems FW322/323 (rev 70) (prog-if 10 [OHCI]) Subsystem: Intel Corporation Device 1003 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx- Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=3Dmedium >TAbort- SERR- > Hi En Ming, > > I found the line "register_real_device: Error: Binding of interrupt > failed! rc=3D-1". So I guess the Fire-wire device doesn't support MSI, a= nd > shares IRQ with other devices. This is the issue I and Jeremy are > discussing. You can search mail subject "pv-ops: fix shared irq device > passthrough" in mailing list for more details. Pls apply the attached pat= ch > to pv-ops dom0 see if it fixes your problem. > > > Regards, > Weidong > > ------------------------------ > *From:* Mr. Teo En Ming (Zhang Enming) [mailto: > space.time.universe@gmail.com] > *Sent:* 2009=C4=EA11=D4=C21=C8=D5 22:08 > *To:* Konrad Rzeszutek Wilk > *Cc:* Jeremy Fitzhardinge; xen-devel@lists.xensource.com; Han, Weidong; > space.time.universe@gmail.com; xen-users@lists.xensource.com > *Subject:* Re: [Xen-devel] Re: Fire-wire passthrough with Linux pv-ops > (2.6.31.1) > > Hi All, > > I have just installed Slackware64 13.0 64-bit Linux as HVM domU. Please > refer to > http://enmingteo.wordpress.com/2009/11/01/picture-tutorial-how-to-setup-s= lackware64-13-0-hvm-domu-with-xen-3-5-unstable-pv-ops-dom0-kernel-2-6-31-4-= in-fedora-11-x86-64-dom0/for more details and screenshots. > > I have tried to passthrough the firewire controller on Intel DQ45CB > motherboard to Slackware64 13.0 HVM domU but I can't load the kernel modu= les > for it. > > Please have a look at the following output within Slackware64 13.0 HVM > domU. > > 00:05.0 FireWire (IEEE 1394): Agere Systems FW322/323 (rev 70) (prog-if 1= 0 > [OHCI]) > Subsystem: Intel Corporation Device 1003 > Flags: bus master, medium devsel, latency 128, IRQ 36 > Memory at e3001000 (32-bit, non-prefetchable) [size=3D4K] > Memory at e3002000 (32-bit, non-prefetchable) [size=3D4K] > Capabilities: [44] Power Management version 2 > Kernel driver in use: ohci1394 > Kernel modules: ohci1394 > > root@slackware64-13:~# lsmod | egrep "(ohci|1394)" > root@slackware64-13:~# cd /lib/modules/2.6.29.6/kernel/drivers/ieee1394/ > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394# ls > dv1394.ko eth1394.ko ieee1394.ko ohci1394.ko pcilynx.ko raw1394.ko > sbp2.ko video1394.ko > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394# modinf= o > ohci1394.ko > filename: ohci1394.ko > license: GPL > description: Driver for PCI OHCI IEEE-1394 controllers > author: Sebastien Rougeaux > alias: pci:v*d*sv*sd*bc0Csc00i10* > depends: ieee1394 > vermagic: 2.6.29.6 SMP mod_unload > parm: phys_dma:Enable physical DMA (default =3D 1). (int) > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394# modinf= o > ieee1394.ko > filename: ieee1394.ko > license: GPL > depends: > vermagic: 2.6.29.6 SMP mod_unload > parm: ignore_drivers:Disable automatic probing for drivers. (in= t) > parm: fcp:Map FCP registers (default =3D 1, disable =3D 0). (in= t) > parm: disable_nodemgr:Disable nodemgr functionality. (int) > parm: disable_irm:Disable Isochronous Resource Manager > functionality. (bool) > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394#modprob= e ieee1394 > FATAL: Error inserting ieee1394 (/lib/modules/ > 2.6.29.6/kernel/drivers/ieee1394/ieee1394.ko): Invalid argument > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394#modprob= e ohci1394 > FATAL: Error inserting ohci1394 (/lib/modules/ > 2.6.29.6/kernel/drivers/ieee1394/ohci1394.ko): Invalid argument > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394# dmesg = | > grep -i firewire > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394# dmesg = | > grep -i ieee > ieee1394: module is already loaded > ieee1394: module is already loaded > ieee1394: module is already loaded > ieee1394: module is already loaded > ieee1394: module is already loaded > ieee1394: module is already loaded > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394# lsmod = | > grep ieee1394 > root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394# dmesg = | > grep 1394 > ohci1394 0000:00:05.0: PCI INT A -> GSI 36 (level, low) -> IRQ 36 > ohci1394: fw-host0: OHCI-1394 1.0 (PCI): IRQ=3D[36] > MMIO=3D[e3001000-e30017ff] Max Packet=3D[2048] IR/IT contexts=3D[8/8] > ieee1394: module is already loaded > ohci1394: module is already loaded > ieee1394: module is already loaded > ohci1394: module is already loaded > ieee1394: module is already loaded > ieee1394: module is already loaded > ieee1394: module is already loaded > ieee1394: module is already loaded > ohci1394: module is already loaded > > Debug messages in Dom0: > > domid: 3 > qemu: the number of cpus is 2 > config qemu network with xen bridge for tap3.0 eth0 > Watching /local/domain/0/device-model/3/logdirty/next-active > Watching /local/domain/0/device-model/3/command > qemu_map_cache_init nr_buckets =3D 10000 size 4194304 > shared page at pfn feffd > buffered io page at pfn feffb > Guest uuid =3D 9a35fdea-fa74-6fec-e0f2-a852836d9a22 > Time offset set 0 > cirrus_vga_enabled > populating video RAM at ff000000 > mapping video RAM from ff000000 > Register xen platform. > Done register platform. > xs_read(/vm/9a35fdea-fa74-6fec-e0f2-a852836d9a22/log-throttling): read > error > platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw > state. > xs_read(/local/domain/0/device-model/3/xen_extended_power_mgmt): read err= or > xs_read(): vncpasswd get error. > /vm/9a35fdea-fa74-6fec-e0f2-a852836d9a22/vncpasswd. > medium change watch on `hdc' (index: 1): > /media/hitachi/slackware64-13.0-install-dvd.iso > I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0 > I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0 > dm-command: hot insert pass-through pci dev > register_real_device: Assigning real physical device 02:01.0 ... > pt_iomul_init: Error: pt_iomul_init can't open file /dev/xen/pci_iomul: N= o > such file or directory: 0x2:0x1.0x0 > pt_register_regions: IO region registered (size=3D0x00001000 > base_addr=3D0xd3801000) > pt_register_regions: IO region registered (size=3D0x00000100 > base_addr=3D0xd3800000) > register_real_device: Error: Binding of interrupt failed! rc=3D-1 > register_real_device: Real physical device 02:01.0 registered successfuly= ! > IRQ type =3D INTx > cirrus vga map change while on lfb mode > pt_iomem_map: e_phys=3De3001000 maddr=3Dd3801000 type=3D0 len=3D4096 inde= x=3D0 > first_map=3D1 > pt_iomem_map: e_phys=3De3002000 maddr=3Dd3800000 type=3D0 len=3D4096 inde= x=3D1 > first_map=3D1 > mapping vram to e0000000 - e0400000 > platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw > state. > platform_fixed_ioport: changed ro/rw state of ROM memory area. now is ro > state. > *pt_pci_write_config: Warning: Guest attempt to set address to unused Bas= e > Address Register. [00:05.0][Offset:30h][Length:4]* > > The line immediately above looks very suspicious. > > -- > Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics) BEng(Hons)(Mechanical > Engineering) > Alma Maters: > (1) Singapore Polytechnic > (2) National University of Singapore > My Primary Blog: http://teo-en-ming-aka-zhang-enming.blogspot.com > My Secondary Blog: http://enmingteo.wordpress.com > My Youtube videos: http://www.youtube.com/user/enmingteo > Email: space.time.universe@gmail.com > MSN: teoenming@hotmail.com > Mobile Phone (SingTel): +65-9648-9798 > Mobile Phone (Starhub Prepaid): +65-8369-2618 > Age: 31 (as at 30 Oct 2009) > Height: 1.78 meters > Race: Chinese > Dialect: Hokkien > Street: Bedok Reservoir Road > Country: Singapore > > On Sat, Oct 24, 2009 at 2:19 AM, Mr. Teo En Ming (Zhang Enming) < > space.time.universe@gmail.com> wrote: > >> From the screenshots of the device manager in the Win XP Home domU, >> the OHCI IEEE 1394 firewire controller appears to be working properly. >> The Windows drivers for the firewire controller reports that the >> firewire controller is working fine. >> >> However, when you connect a firewire-based digital video camera to the >> firewire port, it is not detected in the Windows virtual machine. >> >> I will probably have to find time to install a Linux HVM domU and try >> to pass through the 1394 controller to it. >> >> -- >> 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@gmail.com >> MSN: teoenming@hotmail.com >> Mobile Phone: +65-9648-9798 >> Street: Bedok Reservoir Road >> Republic of Singapore >> >> >> On Sat, Oct 24, 2009 at 1:57 AM, Konrad Rzeszutek Wilk >> wrote: >> > On Sat, Oct 24, 2009 at 01:47:31AM +0800, Mr. Teo En Ming (Zhang >> Enming) wrote: >> >> Hi, >> >> >> >> Could you help me look at here >> >> >> http://lists.xensource.com/archives/html/xen-devel/2009-10/msg01149.html >> >> and also here >> http://lists.xensource.com/archives/html/xen-devel/2009-10/msg01134.html >> > >> > Its looks to be working from the Dom0 side just fine. I am curious as >> what is happening >> > on the Windows driver side. I don't know enough about where Windows >> drivers put >> > debug information so I can't suggest where to look there. One suggesti= on >> is that >> > you install Fedora Core 11 as a HVM guest and passthrough your firewir= e >> controller to it. >> > And then include the logs from the Fedora domU - that should give more >> insight on why >> > it is not working properly. >> > >> > > > > > --0016364ed9d465e03f0477769c05 Content-Type: text/html; charset=GB2312 Content-Transfer-Encoding: quoted-printable Hi Weidong,

I have applied the patch to pv-ops dom0 kernel 2.6.31.5.=

Please refer to the following link:

http://enmingteo.files.w= ordpress.com/2009/11/screenshot-01.png

It does however cause my console terminal in dom0 to be very sluggish/u= nresponsive after I have started Slackware64 13.0 HVM.

Here is my qe= mu-dm-slackware64.log output:

domid: 1
qemu: the number of cpus i= s 2
config qemu network with xen bridge for  tap1.0 eth0
Watching /loca= l/domain/0/device-model/1/logdirty/next-active
Watching /local/domain/0/= device-model/1/command
qemu_map_cache_init nr_buckets =3D 10000 size 419= 4304
shared page at pfn feffd
buffered io page at pfn feffb
Guest uuid =3D= 4d2942cf-1ba2-0ff1-4252-184d1ab31369
Time offset set 0
cirrus_vga_en= abled
populating video RAM at ff000000
mapping video RAM from ff00000= 0
Register xen platform.
Done register platform.
xs_read(/vm/4d2942cf-1= ba2-0ff1-4252-184d1ab31369/log-throttling): read error
platform_fixed_io= port: changed ro/rw state of ROM memory area. now is rw state.
xs_read(/= local/domain/0/device-model/1/xen_extended_power_mgmt): read error
xs_read(): vncpasswd get error. /vm/4d2942cf-1ba2-0ff1-4252-184d1ab31369/vn= cpasswd.
medium change watch on `hdc' (index: 1): /media/hitachi/sla= ckware64-13.0-install-dvd.iso
I/O request not ready: 0, ptr: 0, port: 0,= data: 0, count: 0, size: 0
I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0
dm= -command: hot insert pass-through pci dev
register_real_device: Assigni= ng real physical device 02:01.0 ...
pt_iomul_init: Error: pt_iomul_init = can't open file /dev/xen/pci_iomul: No such file or directory: 0x2:0x1.= 0x0
pt_register_regions: IO region registered (size=3D0x00001000 base_addr=3D0x= d3801000)
pt_register_regions: IO region registered (size=3D0x00000100 b= ase_addr=3D0xd3800000)
register_real_device: Real physical device 02:01.= 0 registered successfuly!
IRQ type =3D INTx
cirrus vga map change while on lfb mode
pt_iomem_ma= p: e_phys=3De3001000 maddr=3Dd3801000 type=3D0 len=3D4096 index=3D0 first_m= ap=3D1
pt_iomem_map: e_phys=3De3002000 maddr=3Dd3800000 type=3D0 len=3D4= 096 index=3D1 first_map=3D1
mapping vram to e0000000 - e0400000
platform_fixed_ioport: changed ro/rw= state of ROM memory area. now is rw state.
platform_fixed_ioport: chang= ed ro/rw state of ROM memory area. now is ro state.
pt_pci_write_config:= Warning: Guest attempt to set address to unused Base Address Register. [00= :05.0][Offset:30h][Length:4]

Here is my domU lspci -vvv output:

00:05.0 FireWire (IEEE 1394):= Agere Systems FW322/323 (rev 70) (prog-if 10 [OHCI])
   = Subsystem: Intel Corporation Device 1003
    Control: I/= O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- Fa= stB2B- DisINTx-
    Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=3Dmediu= m >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
 &n= bsp;  Latency: 128 (3000ns min, 6000ns max)
    Inte= rrupt: pin A routed to IRQ 36
    Region 0: Memory at e30= 01000 (32-bit, non-prefetchable) [size=3D4K]
    Region 1: Memory at e3002000 (32-bit, non-prefetchable) = [size=3D4K]
    Capabilities: [44] Power Management versi= on 2
        Flags: PMEClk- DSI- D1+ D2+ A= uxCurrent=3D0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
     = ;   Status: D0 NoSoftRst+ PME-Enable- DSel=3D0 DScale=3D0 PME-     Kernel driver in use: ohci1394
    Ker= nel modules: ohci1394

Here is my domU /proc/interrupts output:
           CPU0 &n= bsp;     CPU1      
&= nbsp; 0:        132   &nb= sp;      0   IO-APIC-edge  &nb= sp;   timer
  1:       = ; 176        181   IO-APIC-edg= e      i8042
  4:          0 &nbs= p;        1   IO-APIC-edge&nbs= p;  
  6:        = ;  1          2 &nbs= p; IO-APIC-edge      floppy
  7: &nbs= p;        0     = ;     0   IO-APIC-edge    = ;  parport0
  8:       &nbs= p;  1          0 &nb= sp; IO-APIC-edge      rtc0
  9:  = ;        0     =      0   IO-APIC-fasteoi   acpi
 12:        518   &n= bsp;    632   IO-APIC-edge    =   i8042
 14:       2600 &nb= sp;     2591   IO-APIC-edge   =    ide0
 15:       2023&nbs= p;      2073   IO-APIC-edge  &= nbsp;   ide1
 32:      &nbs= p; 174        167   IO-APIC-fa= steoi   eth0
 36:        842   &n= bsp;    815   IO-APIC-fasteoi   ohci1394=
NMI:          0  = ;        0   Non-maskable inte= rrupts
LOC:    1362927    1362831 &nb= sp; Local timer interrupts
RES:       2164=        2467   Rescheduling interrup= ts
CAL:         10   &n= bsp;     38   Function call interrupts
TLB= :        323    &nbs= p;   324   TLB shootdowns
TRM:   &nbs= p;      0       = ;   0   Thermal event interrupts
THR:  &nb= sp;       0     &nbs= p;    0   Threshold APIC interrupts
SPU: &= nbsp;        0    &n= bsp;     0   Spurious interrupts
ERR:          0
MIS: &= nbsp;        0

I still cannot loa= d the kernel modules for the firewire controller in domU.

root@slack= ware64-13:~# modprobe ieee1394
FATAL: Error inserting ieee1394 (/lib/mod= ules/2.6.29= .6/kernel/drivers/ieee1394/ieee1394.ko): Invalid argument
root@slackware64-13:~# modprobe ohci1394
FATAL: Error inserting ohci1394= (/lib/modules/2.6.29.6/kernel/drivers/ieee1394/ohci1394.ko): Invalid argument

Here is my /proc/interrupts output in dom0 AFTER I have started Slackwa= re64 domU:

         &nb= sp; CPU0       CPU1    &n= bsp; 
  1:        &nb= sp; 2          0  xen-pir= q-ioapic-edge  i8042
  4:      &= nbsp;   3          0=   xen-pirq-ioapic-edge
  8:          1 &nbs= p;        0  xen-pirq-ioapic-edge&n= bsp; rtc0
  9:         = ; 0          0  xen-pirq-= ioapic-level  acpi
 12:      &nb= sp;   4          0&n= bsp; xen-pirq-ioapic-edge  i8042
 16:    &= nbsp;     0       &n= bsp;  0  xen-pirq-ioapic-level  uhci_hcd:usb3
 17:          1 &nbs= p;        0  xen-pirq-ioapic-level<= br> 18:         59  =         0  xen-pirq-ioapic-level&nb= sp; ehci_hcd:usb1, uhci_hcd:usb5, uhci_hcd:usb8
 19:  &nb= sp;   60581         = 0  xen-pirq-ioapic-level  ata_piix, ata_piix, uhci_hcd:usb7
 21:          0 &nbs= p;        0  xen-pirq-ioapic-level&= nbsp; uhci_hcd:usb4
 22:       2500&n= bsp;         0  xen-pirq-ioapi= c-level  HDA Intel
 23:      35508&nb= sp;         0  xen-pirq-ioapic= -level  ehci_hcd:usb2, uhci_hcd:usb6
 24:   &nb= sp; 121214          0 &nb= sp; xen-dyn-virq      timer0
 25:     290373      = ;    0   xen-dyn-ipi     =   resched0
 26:        = ;  0          0 &nbs= p; xen-dyn-ipi       callfunc0
 27:&n= bsp;         0   &nb= sp;      0   xen-dyn-virq  &nb= sp;   debug0
 28:      &nbs= p; 213          0   = xen-dyn-ipi       callfuncsingle0
 29:          0 &nbs= p;  3091038   xen-dyn-virq      tim= er1
 30:          0&nb= sp;     76203   xen-dyn-ipi   =     resched1
 31:      = ;    0         = 0   xen-dyn-ipi       callfunc1 32:          0 &nb= sp;        0   xen-dyn-virq&nb= sp;     debug1
 33:          0 &nbs= p;      644   xen-dyn-ipi  &nb= sp;    callfuncsingle1
 34:    &= nbsp;    87       1002 &n= bsp; xen-dyn-event     xenbus
 36:  &= nbsp;       0     &n= bsp;    0   xen-dyn-virq    &n= bsp; mce
 38:       8967  &= nbsp;    5621  xen-pirq-msi    &nbs= p;  peth0
 39:         61  &nb= sp;     563   xen-dyn-event   =   evtchn:xenstored
 40:      &nb= sp;   0          0&n= bsp;  xen-dyn-event     evtchn:xenstored
 = 42:          1  &nbs= p;       0   xen-dyn-event &nb= sp;   evtchn:xenstored
 43:     =   4098     462204   xen-dyn-event &= nbsp;   evtchn:qemu-dm
 44:       8156     = 115233   xen-dyn-event     evtchn:qemu-dm
= NMI:          0  &nb= sp;       0   Non-maskable interrup= ts
LOC:          0 &nb= sp;        0   Local timer int= errupts
SPU:          0&nbs= p;         0   Spurious i= nterrupts
CNT:          0  &nb= sp;       0   Performance counter i= nterrupts
PND:          0&n= bsp;         0   Performa= nce pending work
RES:     290373   &n= bsp;  76203   Rescheduling interrupts
CAL:  &nb= sp;     213        6= 44   Function call interrupts
TLB:          0  &nb= sp;       0   TLB shootdowns
TRM= :          0   =        0   Thermal event interrupts=
THR:          0  = ;        0   Threshold APIC in= terrupts
MCE:          0&nb= sp;         0   Machine c= heck exceptions
MCP:        &nbs= p; 6          6   Ma= chine check polls
ERR:          0
MIS: &= nbsp;        0


--
Mr. Teo= En Ming (Zhang Enming) Dip(Mechatronics) BEng(Hons)(Mechanical Engineering= )
Alma Maters:
(1) Singapore Polytechnic
(2) National University o= f Singapore
My Primary Blog: http://teo-en-ming-aka-zhang-enming.blogspot.com
My Secondary Blo= g: http://enmingteo.wordpress.co= m
My Youtube videos: http:/= /www.youtube.com/user/enmingteo
Email: space.time.universe@gmail.com
Mobile Phone (Star= hub Prepaid): +65-8369-2618
Street: Bedok Reservoir Road
Country: Singapore

2009/11/3 Han, Weidong <weidong.han@intel.com>
Hi En Ming,
 
I found the line "register_real_device: Error: Binding of interru= pt failed!=20 rc=3D-1".  So I guess the Fire-wire devic= e doesn't=20 support MSI, and shares IRQ with other devices. This is the issue I and Jer= emy=20 are discussing. You can search mail subject "pv-ops: fix shared irq de= vice=20 passthrough" in mailing list for more details. Pls apply the atta= ched patch=20 to pv-ops dom0 see if it fixes your problem.
 
 
Regards,
Weidong


From: Mr. Teo En Ming (Zhang Enming= )=20 [mailto:= space.time.universe@gmail.com]
Sent: 2009=C4=EA11=D4=C21=C8= =D5=20 22:08
To: Konrad Rzeszutek Wilk
Cc: Jeremy Fitzhardinge= ;=20 xen-deve= l@lists.xensource.com; Han, Weidong; space.time.universe@gmail.com;=20 xen-user= s@lists.xensource.com
Subject: Re: [Xen-devel] Re: Fire-wire= =20 passthrough with Linux pv-ops (2.6.31.1)

Hi All,

I have just installed Slackware64 13.0 64-bit Lin= ux as=20 HVM domU. Please refer to http://enmingteo.wordpress.com/2009/11/01/picture-tutorial-how-to-setu= p-slackware64-13-0-hvm-domu-with-xen-3-5-unstable-pv-ops-dom0-kernel-2-6-31= -4-in-fedora-11-x86-64-dom0/=20 for more details and screenshots.

I have tried to passthrough the=20 firewire controller on Intel DQ45CB motherboard to Slackware64 13.0 HVM dom= U but=20 I can't load the kernel modules for it.

Please have a look at th= e=20 following output within Slackware64 13.0 HVM domU.

00:05.0 FireWire = (IEEE=20 1394): Agere Systems FW322/323 (rev 70) (prog-if 10=20 [OHCI])
    Subsystem: Intel Corporation Device=20 1003
    Flags: bus master, medium devsel, latency 128, I= RQ=20 36
    Memory at e3001000 (32-bit, non-prefetchable)=20 [size=3D4K]
    Memory at e3002000 (32-bit, non-prefetcha= ble)=20 [size=3D4K]
    Capabilities: [44] Power Management versi= on=20 2
    Kernel driver in use: ohci1394
   = ;=20 Kernel modules: ohci1394

root@slackware64-13:~# lsmod | egrep=20 "(ohci|1394)"
root@slackware64-13:~# cd /lib/modules/2.6.29.6/ke= rnel/drivers/ieee1394/
root@slackware64-13:/lib/modules/2.6.29.6/kernel/= drivers/ieee1394#=20 ls
dv1394.ko  eth1394.ko  ieee1394.ko  ohci1394.ko = =20 pcilynx.ko  raw1394.ko  sbp2.ko =20 video1394.ko
root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee13= 94#=20 modinfo ohci1394.ko
filename:      =20 ohci1394.ko
license:       =20 GPL
description:    Driver for PCI OHCI IEEE-1394=20 controllers
author:         Seba= stien=20 Rougeaux <sebastien.rougeaux@anu.edu.au>
alias:    = ;     =20 pci:v*d*sv*sd*bc0Csc00i10*
depends:      &= nbsp;=20 ieee1394
vermagic:       2.6.29.6 SMP=20 mod_unload
parm:         &= nbsp;=20 phys_dma:Enable physical DMA (default =3D 1).=20 (int)
root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394#= =20 modinfo ieee1394.ko
filename:      =20 ieee1394.ko
license:       =20 GPL
depends:       =20
vermagic:       2.6.29.6 SMP mod_unload= =20
parm:          =20 ignore_drivers:Disable automatic probing for drivers.=20 (int)
parm:          = =20 fcp:Map FCP registers (default =3D 1, disable =3D 0).=20 (int)
parm:          = =20 disable_nodemgr:Disable nodemgr functionality.=20 (int)
parm:          = =20 disable_irm:Disable Isochronous Resource Manager functionality.=20 (bool)
root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee1394#=20 modprobe ieee1394   
FATAL: Error inserting ieee1394=20 (/lib/modules/
2.6.29.6/kernel/drivers/ieee1394/ieee1394.ko):=20 Invalid argument
root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ie= ee1394#=20 modprobe ohci1394   
FATAL: Error inserting ohci1394=20 (/lib/modules/2.6.29.6/kernel/drivers/ieee1394/ohci1394.ko):=20 Invalid argument
root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ie= ee1394#=20 dmesg | grep -i firewire
root@slackware64-13:/lib/modules/2.6.29.6/kernel/dr= ivers/ieee1394#=20 dmesg | grep -i ieee
ieee1394: module is already loaded
ieee1394: mod= ule=20 is already loaded
ieee1394: module is already loaded
ieee1394: module= is=20 already loaded
ieee1394: module is already loaded
ieee1394: module is= =20 already loaded
root@slackware64-13:/lib/modules/2.6.29.6/kernel/drivers/ieee= 1394#=20 lsmod | grep ieee1394
root@slackware64-13:/lib/modules/2.6.29.6/kernel/drive= rs/ieee1394#=20 dmesg | grep 1394
ohci1394 0000:00:05.0: PCI INT A -> GSI 36 (level, = low)=20 -> IRQ 36
ohci1394: fw-host0: OHCI-1394 1.0 (PCI): IRQ=3D[36] = =20 MMIO=3D[e3001000-e30017ff]  Max Packet=3D[2048]  IR/IT=20 contexts=3D[8/8]
ieee1394: module is already loaded
ohci1394: module = is=20 already loaded
ieee1394: module is already loaded
ohci1394: module is= =20 already loaded
ieee1394: module is already loaded
ieee1394: module is= =20 already loaded
ieee1394: module is already loaded
ieee1394: module is= =20 already loaded
ohci1394: module is already loaded

Debug messages = in=20 Dom0:

domid: 3
qemu: the number of cpus is 2
config qemu netwo= rk=20 with xen bridge for  tap3.0 eth0
Watching=20 /local/domain/0/device-model/3/logdirty/next-active
Watching=20 /local/domain/0/device-model/3/command
qemu_map_cache_init nr_buckets = =3D 10000=20 size 4194304
shared page at pfn feffd
buffered io page at pfn=20 feffb
Guest uuid =3D 9a35fdea-fa74-6fec-e0f2-a852836d9a22
Time offset= set=20 0
cirrus_vga_enabled
populating video RAM at ff000000
mapping vide= o RAM=20 from ff000000
Register xen platform.
Done register=20 platform.
xs_read(/vm/9a35fdea-fa74-6fec-e0f2-a852836d9a22/log-throttlin= g):=20 read error
platform_fixed_ioport: changed ro/rw state of ROM memory area= . now=20 is rw state.
xs_read(/local/domain/0/device-model/3/xen_extended_power_m= gmt):=20 read error
xs_read(): vncpasswd get error.=20 /vm/9a35fdea-fa74-6fec-e0f2-a852836d9a22/vncpasswd.
medium change watch = on=20 `hdc' (index: 1): /media/hitachi/slackware64-13.0-install-dvd.iso
I/= O request=20 not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0
I/O request no= t=20 ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0
dm-command: hot in= sert=20 pass-through pci dev
register_real_device: Assigning real physical devi= ce=20 02:01.0 ...
pt_iomul_init: Error: pt_iomul_init can't open file=20 /dev/xen/pci_iomul: No such file or directory:=20 0x2:0x1.0x0
pt_register_regions: IO region registered (size=3D0x00001000= =20 base_addr=3D0xd3801000)
pt_register_regions: IO region registered=20 (size=3D0x00000100 base_addr=3D0xd3800000)
register_real_device: Error: = Binding=20 of interrupt failed! rc=3D-1
register_real_device: Real physical device = 02:01.0=20 registered successfuly!
IRQ type =3D INTx
cirrus vga map change while= on lfb=20 mode
pt_iomem_map: e_phys=3De3001000 maddr=3Dd3801000 type=3D0 len=3D409= 6 index=3D0=20 first_map=3D1
pt_iomem_map: e_phys=3De3002000 maddr=3Dd3800000 type=3D0 = len=3D4096=20 index=3D1 first_map=3D1
mapping vram to e0000000 -=20 e0400000
platform_fixed_ioport: changed ro/rw state of ROM memory area. = now=20 is rw state.
platform_fixed_ioport: changed ro/rw state of ROM memory ar= ea.=20 now is ro state.
pt_pci_write_= config:=20 Warning: Guest attempt to set address to unused Base Address Register.=20 [00:05.0][Offset:30h][Length:4]

The line immediately abo= ve=20 looks very suspicious.

--
Mr. Teo En Ming (Zhang Enming)=20 Dip(Mechatronics) BEng(Hons)(Mechanical Engineering)
Alma Maters:
(1)= =20 Singapore Polytechnic
(2) National University of Singapore
My Primary= =20 Blog: http://teo-en-ming-aka-zhang-enming.blogspot.com
My=20 Secondary Blog: http://enmingteo.wordpress.com
My=20 Youtube videos: http://www.youtube.com/user/enmingteo
Email:=20 space.ti= me.universe@gmail.com
MSN:=20 teoenming@hotmai= l.com
Mobile Phone=20 (SingTel): +65-9648-9798
Mobile Phone (Starhub Prepaid):=20 +65-8369-2618
Age: 31 (as at 30 Oct 2009)
Height: 1.78 meters
Race= :=20 Chinese
Dialect: Hokkien
Street: Bedok Reservoir Road
Country:=20 Singapore

On Sat, Oct 24, 2009 at 2:19 AM, Mr. Teo En Ming= (Zhang=20 Enming) <space.time.universe@gmail.com>=20 wrote:
From=20 the screenshots of the device manager in the Win XP Home domU,
the OHC= I=20 IEEE 1394 firewire controller appears to be working properly.
The Wind= ows=20 drivers for the firewire controller reports that the
firewire controll= er is=20 working fine.

However, when you connect a firewire-based digital v= ideo=20 camera to the
firewire port, it is not detected in the Windows virtual= =20 machine.

I will probably have to find time to install a Linux HVM = domU=20 and try
to pass through the 1394 controller to it.

--
Mr. Teo En Ming (Zhang Enming) Dip(Mechatronics)=20 BEng(Hons)(Mechanical
Engineering)
Alma Maters:
(1) Singapore=20 Polytechnic
(2) National University of Singapore
Blog URL: htt= p://teo-en-ming-aka-zhang-enming.blogspot.com
Email:=20 space.= time.universe@gmail.com
MSN:=20 teoenming@hotm= ail.com
Mobile=20 Phone: +65-9648-9798
Street: Bedok Reservoir Road
Republic of=20 Singapore


On Sat, Oct 24, 2009 at 1:57 AM, Konrad Rzeszu= tek=20 Wilk
> On Sat, Oct 24, 2009 at 01:47:31AM +0800, Mr. Teo En Ming=20 (Zhang Enming) wrote:
>> Hi,
>>
>> Could you h= elp=20 me look at here
>> http://lists.xens= ource.com/archives/html/xen-devel/2009-10/msg01149.html
>>=20 and also here http://lists.xensource.com/arch= ives/html/xen-devel/2009-10/msg01134.html
>
>=20 Its looks to be working from the Dom0 side just fine. I am curious as wha= t is=20 happening
> on the Windows driver side. I don't know enough abo= ut where=20 Windows drivers put
> debug information so I can't suggest wher= e to look=20 there. One suggestion is that
> you install Fedora Core 11 as a HVM= =20 guest and passthrough your firewire controller to it.
> And then in= clude=20 the logs from the Fedora domU - that should give more insight on why
&= gt;=20 it is not working properly.
>







--0016364ed9d465e03f0477769c05-- --===============1082082339== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --===============1082082339==--