All of lore.kernel.org
 help / color / mirror / Atom feed
* DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64)
@ 2007-06-25 17:08 Stefan Neuwirth
  2007-06-25 17:32 ` Ian Pratt
  2007-06-25 17:57 ` Keir Fraser
  0 siblings, 2 replies; 5+ messages in thread
From: Stefan Neuwirth @ 2007-06-25 17:08 UTC (permalink / raw)
  To: xen-devel

Hi there,

I'm running xen-3.1.0 using gentoo amd64 for dom0. When starting a PV
guest domain everything is fine, up to the moment I try to configure
the ethernet device. The device is a real ethernet card that shown to
the guest by using pci passthrough.

~ # ifconfig eth4
eth4      Link encap:Ethernet  HWaddr 00:00:D1:ED:14:02  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Interrupt:22 

~ # ifconfig eth4 192.168.0.131 netmask 255.255.255.0 up
----------- [cut here ] --------- [please bite here ] ---------
Kernel BUG at ...arch/x86_64/kernel/../../i386/kernel/pci-dma-xen.c:331
invalid opcode: 0000 [1] SMP 
CPU 0 
Modules linked in: usbcore starfire mii
Pid: 2978, comm: ifconfig Not tainted 2.6.18-xen #8
RIP: e030:[<ffffffff80210bdd>]  [<ffffffff80210bdd>] dma_map_single+0x19a/0x1b2
RSP: e02b:ffff88001f517d48  EFLAGS: 00010292
RAX: 000000000000002f RBX: ffff88000019a810 RCX: ffff88001f516000
RDX: ffffffffff578000 RSI: 0000000000000001 RDI: ffffffff80561340
RBP: 00000004397da810 R08: 00000000a83abafa R09: 0000000000000000
R10: 0000000000000000 R11: 00000000000000c8 R12: 0000000000000600
R13: ffff88000007f070 R14: 0000000000000070 R15: ffff88001f7e0000
FS:  00002b009bbc36d0(0000) GS:ffffffff805e5000(0000) knlGS:0000000000000000
CS:  e033 DS: 0000 ES: 0000
Process ifconfig (pid: 2978, threadinfo ffff88001f516000, task ffff8800001eb8c0)
Stack:  ffff88001f7e05e0 ffff88001f6d37c0 ffff88001f7e05e0 ffff88001f7e0500
 000000000000000f ffffffff880047e4 0000000000000000 ffffc20000280000
 000000001fad8340 ffffc200002d0070 ffffc200002d0040 ffff88001f7e0000
Call Trace:
 [<ffffffff880047e4>] :starfire:netdev_open+0x264/0x690
 [<ffffffff80452ee0>] dev_open+0x2d/0x70
 [<ffffffff80450ccb>] dev_change_flags+0x5c/0x11e
 [<ffffffff8049394d>] devinet_ioctl+0x2a4/0x6a7
 [<ffffffff80217749>] do_page_fault+0xdf8/0x1198
 [<ffffffff80446c55>] sock_ioctl+0x214/0x239
 [<ffffffff80287f71>] do_ioctl+0x21/0x79
 [<ffffffff8028823d>] vfs_ioctl+0x274/0x28d
 [<ffffffff802740e5>] fd_install+0x25/0x5f
 [<ffffffff802882b1>] sys_ioctl+0x5b/0x7e
 [<ffffffff80209f8a>] system_call+0x86/0x8b
 [<ffffffff80209f04>] system_call+0x0/0x8b


Code: 0f 0b 68 78 15 4f 80 c2 4b 01 48 89 e8 48 83 c4 08 5b 5d 41 
RIP  [<ffffffff80210bdd>] dma_map_single+0x19a/0x1b2
 RSP <ffff88001f517d48>
 Segmentation fault

The same happens when using a tulip based ethernet card instead of the
adaptec starfire card. 

Any hints?

  Stefan

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64)
  2007-06-25 17:08 DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64) Stefan Neuwirth
@ 2007-06-25 17:32 ` Ian Pratt
  2007-06-25 18:05   ` Stefan Neuwirth
  2007-06-25 17:57 ` Keir Fraser
  1 sibling, 1 reply; 5+ messages in thread
From: Ian Pratt @ 2007-06-25 17:32 UTC (permalink / raw)
  To: Stefan Neuwirth, xen-devel

> I'm running xen-3.1.0 using gentoo amd64 for dom0. When starting a PV
> guest domain everything is fine, up to the moment I try to configure
> the ethernet device. The device is a real ethernet card that shown to
> the guest by using pci passthrough.

Can you repro using the linux kernel that's part of the Xen 3.1.0
distribution?

Ian

 
> ~ # ifconfig eth4
> eth4      Link encap:Ethernet  HWaddr 00:00:D1:ED:14:02
>           BROADCAST MULTICAST  MTU:1500  Metric:1
>           RX packets:0 errors:0 dropped:0 overruns:0 frame:0
>           TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
>           collisions:0 txqueuelen:1000
>           RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
>           Interrupt:22
> 
> ~ # ifconfig eth4 192.168.0.131 netmask 255.255.255.0 up
> ----------- [cut here ] --------- [please bite here ] ---------
> Kernel BUG at
...arch/x86_64/kernel/../../i386/kernel/pci-dma-xen.c:331
> invalid opcode: 0000 [1] SMP
> CPU 0
> Modules linked in: usbcore starfire mii
> Pid: 2978, comm: ifconfig Not tainted 2.6.18-xen #8
> RIP: e030:[<ffffffff80210bdd>]  [<ffffffff80210bdd>]
> dma_map_single+0x19a/0x1b2
> RSP: e02b:ffff88001f517d48  EFLAGS: 00010292
> RAX: 000000000000002f RBX: ffff88000019a810 RCX: ffff88001f516000
> RDX: ffffffffff578000 RSI: 0000000000000001 RDI: ffffffff80561340
> RBP: 00000004397da810 R08: 00000000a83abafa R09: 0000000000000000
> R10: 0000000000000000 R11: 00000000000000c8 R12: 0000000000000600
> R13: ffff88000007f070 R14: 0000000000000070 R15: ffff88001f7e0000
> FS:  00002b009bbc36d0(0000) GS:ffffffff805e5000(0000)
> knlGS:0000000000000000
> CS:  e033 DS: 0000 ES: 0000
> Process ifconfig (pid: 2978, threadinfo ffff88001f516000, task
> ffff8800001eb8c0)
> Stack:  ffff88001f7e05e0 ffff88001f6d37c0 ffff88001f7e05e0
> ffff88001f7e0500
>  000000000000000f ffffffff880047e4 0000000000000000 ffffc20000280000
>  000000001fad8340 ffffc200002d0070 ffffc200002d0040 ffff88001f7e0000
> Call Trace:
>  [<ffffffff880047e4>] :starfire:netdev_open+0x264/0x690
>  [<ffffffff80452ee0>] dev_open+0x2d/0x70
>  [<ffffffff80450ccb>] dev_change_flags+0x5c/0x11e
>  [<ffffffff8049394d>] devinet_ioctl+0x2a4/0x6a7
>  [<ffffffff80217749>] do_page_fault+0xdf8/0x1198
>  [<ffffffff80446c55>] sock_ioctl+0x214/0x239
>  [<ffffffff80287f71>] do_ioctl+0x21/0x79
>  [<ffffffff8028823d>] vfs_ioctl+0x274/0x28d
>  [<ffffffff802740e5>] fd_install+0x25/0x5f
>  [<ffffffff802882b1>] sys_ioctl+0x5b/0x7e
>  [<ffffffff80209f8a>] system_call+0x86/0x8b
>  [<ffffffff80209f04>] system_call+0x0/0x8b
> 
> 
> Code: 0f 0b 68 78 15 4f 80 c2 4b 01 48 89 e8 48 83 c4 08 5b 5d 41
> RIP  [<ffffffff80210bdd>] dma_map_single+0x19a/0x1b2
>  RSP <ffff88001f517d48>
>  Segmentation fault
> 
> The same happens when using a tulip based ethernet card instead of the
> adaptec starfire card.
> 
> Any hints?
> 
>   Stefan
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64)
  2007-06-25 17:08 DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64) Stefan Neuwirth
  2007-06-25 17:32 ` Ian Pratt
@ 2007-06-25 17:57 ` Keir Fraser
  2007-06-25 18:49   ` Stefan Neuwirth
  1 sibling, 1 reply; 5+ messages in thread
From: Keir Fraser @ 2007-06-25 17:57 UTC (permalink / raw)
  To: Stefan Neuwirth, xen-devel

You might need to explicitly request a swiotlb ('swiotlb=force').

 K.

On 25/6/07 18:08, "Stefan Neuwirth"
<neuwirt-xen-devel@trillian.hd.shuttle.de> wrote:

> Hi there,
> 
> I'm running xen-3.1.0 using gentoo amd64 for dom0. When starting a PV
> guest domain everything is fine, up to the moment I try to configure
> the ethernet device. The device is a real ethernet card that shown to
> the guest by using pci passthrough.
> 
> ~ # ifconfig eth4
> eth4      Link encap:Ethernet  HWaddr 00:00:D1:ED:14:02
>           BROADCAST MULTICAST  MTU:1500  Metric:1
>           RX packets:0 errors:0 dropped:0 overruns:0 frame:0
>           TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
>           collisions:0 txqueuelen:1000
>           RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
>           Interrupt:22
> 
> ~ # ifconfig eth4 192.168.0.131 netmask 255.255.255.0 up
> ----------- [cut here ] --------- [please bite here ] ---------
> Kernel BUG at ...arch/x86_64/kernel/../../i386/kernel/pci-dma-xen.c:331
> invalid opcode: 0000 [1] SMP
> CPU 0 
> Modules linked in: usbcore starfire mii
> Pid: 2978, comm: ifconfig Not tainted 2.6.18-xen #8
> RIP: e030:[<ffffffff80210bdd>]  [<ffffffff80210bdd>]
> dma_map_single+0x19a/0x1b2
> RSP: e02b:ffff88001f517d48  EFLAGS: 00010292
> RAX: 000000000000002f RBX: ffff88000019a810 RCX: ffff88001f516000
> RDX: ffffffffff578000 RSI: 0000000000000001 RDI: ffffffff80561340
> RBP: 00000004397da810 R08: 00000000a83abafa R09: 0000000000000000
> R10: 0000000000000000 R11: 00000000000000c8 R12: 0000000000000600
> R13: ffff88000007f070 R14: 0000000000000070 R15: ffff88001f7e0000
> FS:  00002b009bbc36d0(0000) GS:ffffffff805e5000(0000) knlGS:0000000000000000
> CS:  e033 DS: 0000 ES: 0000
> Process ifconfig (pid: 2978, threadinfo ffff88001f516000, task
> ffff8800001eb8c0)
> Stack:  ffff88001f7e05e0 ffff88001f6d37c0 ffff88001f7e05e0 ffff88001f7e0500
>  000000000000000f ffffffff880047e4 0000000000000000 ffffc20000280000
>  000000001fad8340 ffffc200002d0070 ffffc200002d0040 ffff88001f7e0000
> Call Trace:
>  [<ffffffff880047e4>] :starfire:netdev_open+0x264/0x690
>  [<ffffffff80452ee0>] dev_open+0x2d/0x70
>  [<ffffffff80450ccb>] dev_change_flags+0x5c/0x11e
>  [<ffffffff8049394d>] devinet_ioctl+0x2a4/0x6a7
>  [<ffffffff80217749>] do_page_fault+0xdf8/0x1198
>  [<ffffffff80446c55>] sock_ioctl+0x214/0x239
>  [<ffffffff80287f71>] do_ioctl+0x21/0x79
>  [<ffffffff8028823d>] vfs_ioctl+0x274/0x28d
>  [<ffffffff802740e5>] fd_install+0x25/0x5f
>  [<ffffffff802882b1>] sys_ioctl+0x5b/0x7e
>  [<ffffffff80209f8a>] system_call+0x86/0x8b
>  [<ffffffff80209f04>] system_call+0x0/0x8b
> 
> 
> Code: 0f 0b 68 78 15 4f 80 c2 4b 01 48 89 e8 48 83 c4 08 5b 5d 41
> RIP  [<ffffffff80210bdd>] dma_map_single+0x19a/0x1b2
>  RSP <ffff88001f517d48>
>  Segmentation fault
> 
> The same happens when using a tulip based ethernet card instead of the
> adaptec starfire card.
> 
> Any hints?
> 
>   Stefan
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64)
  2007-06-25 17:32 ` Ian Pratt
@ 2007-06-25 18:05   ` Stefan Neuwirth
  0 siblings, 0 replies; 5+ messages in thread
From: Stefan Neuwirth @ 2007-06-25 18:05 UTC (permalink / raw)
  To: Ian Pratt; +Cc: xen-devel

"Ian Pratt" <Ian.Pratt@cl.cam.ac.uk> writes:

>> I'm running xen-3.1.0 using gentoo amd64 for dom0. When starting a PV
>> guest domain everything is fine, up to the moment I try to configure
>> the ethernet device. The device is a real ethernet card that shown to
>> the guest by using pci passthrough.
>
> Can you repro using the linux kernel that's part of the Xen 3.1.0
> distribution?

It's a source build of xen-3.1.0 and the kernel is linux-2.6.18-xen
(same for dom0 and domU), I just changed some config items to get
things running on the machine.

  Stefan

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64)
  2007-06-25 17:57 ` Keir Fraser
@ 2007-06-25 18:49   ` Stefan Neuwirth
  0 siblings, 0 replies; 5+ messages in thread
From: Stefan Neuwirth @ 2007-06-25 18:49 UTC (permalink / raw)
  To: Keir Fraser; +Cc: xen-devel

Keir Fraser <keir@xensource.com> writes:

> You might need to explicitly request a swiotlb ('swiotlb=force').

Solved the problem, thank you.

  Stefan

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-06-25 18:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-25 17:08 DMA-Bug using PCI-Passthrough (xen-3.1.0, gentoo amd64) Stefan Neuwirth
2007-06-25 17:32 ` Ian Pratt
2007-06-25 18:05   ` Stefan Neuwirth
2007-06-25 17:57 ` Keir Fraser
2007-06-25 18:49   ` Stefan Neuwirth

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.