Hi All I have a problem with xen and pci passthrough... I have centos 6 with xen here. Xen Pkgs from http://www.crc.id.au/ Kernel Pkgs from http://elrepo.org/tiki/kernel-ml (3.3.0-1.el6.elrepo.x86_64) in dom0/U. I hide the PCI ID''s with kernel parameter: ''xen-pciback.hide=(08:02.0)(08:02.1)'' and load after boot the backend module with: ''modprobe xen-pciback'' ''ll /sys/module/xen_pciback/drivers/pci\:pciback/'' shows: lrwxrwxrwx 1 root root 0 Mar 24 10:20 0000:08:02.0 -> ../../../../devices/pci0000:00/0000:00:1e.0/0000:08:02.0 lrwxrwxrwx 1 root root 0 Mar 24 10:20 0000:08:02.1 -> ../../../../devices/pci0000:00/0000:00:1e.0/0000:08:02.1 --w------- 1 root root 4096 Mar 24 10:20 bind -r-------- 1 root root 4096 Mar 24 10:20 irq_handlers --w------- 1 root root 4096 Mar 24 10:20 irq_handler_state lrwxrwxrwx 1 root root 0 Mar 24 10:20 module -> ../../../../module/xen_pciback --w------- 1 root root 4096 Mar 24 10:20 new_id --w------- 1 root root 4096 Mar 24 10:20 new_slot -rw------- 1 root root 4096 Mar 24 10:20 permissive -rw------- 1 root root 4096 Mar 24 10:20 quirks --w------- 1 root root 4096 Mar 24 10:20 remove_id --w------- 1 root root 4096 Mar 24 10:20 remove_slot -r-------- 1 root root 4096 Mar 24 10:20 slots --w------- 1 root root 4096 Mar 24 10:20 uevent --w------- 1 root root 4096 Mar 24 10:20 unbind but with ''xm pci-list-assignable-devices'' I see no output :/ I have configured the domU with: ''pci = [ ''08:02.0'', ''08:02.1'' ]'' and I see this if I create the domU: Using config file "/etc/xen/furfur.cfg". Started domain furfur (id=8) Xen Minimal OS! start_info: 0xaa0000(VA) nr_pages: 0x20000 shared_inf: 0xbcf60000(MA) pt_base: 0xaa3000(VA) nr_pt_frames: 0x9 mfn_list: 0x9a0000(VA) mod_start: 0x0(VA) mod_len: 0 flags: 0x0 cmd_line: (hd0)/boot/grub/grub.conf stack: 0x95f980-0x97f980 MM: Init _text: 0x0(VA) _etext: 0x6f9a4(VA) _erodata: 0x89000(VA) _edata: 0x91c60(VA) stack start: 0x95f980(VA) _end: 0x99ff80(VA) start_pfn: aaf max_pfn: 20000 Mapping memory range 0xc00000 - 0x20000000 setting 0x0-0x89000 readonly skipped 0x1000 MM: Initialise page allocator for ba9000(ba9000)-20000000(20000000) MM: done Demand map pfns at 20001000-2020001000. Heap resides at 2020002000-4020002000. Initialising timer interface Initialising console ... done. gnttab_table mapped at 0x20001000. Initialising scheduler Thread "Idle": pointer: 0x2020002050, stack: 0xcc0000 Initialising xenbus Thread "xenstore": pointer: 0x2020002800, stack: 0xcd0000 Dummy main: start_info=0x97fa80 Thread "main": pointer: 0x2020002fb0, stack: 0xce0000 Thread "pcifront": pointer: 0x2020003760, stack: 0xcf0000 "main" "(hd0)/boot/grub/grub.conf" pcifront_watches: waiting for backend path to appear device/pci/0/backend vbd 51712 is hd0 ******************* BLKFRONT for device/vbd/51712 ********** pcifront_watches: waiting for backend to get into the right state /local/domain/0/backend/pci/8/0 ******************* PCIFRONT for device/pci/0 ********** backend at /local/domain/0/backend/vbd/8/51712 backend at /local/domain/0/backend/pci/8/0 10485760 sectors of 512 bytes ************************** vbd 51728 is hd1 ******************* BLKFRONT for device/vbd/51728 ********** ************************** pcifront_watches: waiting for backend events /local/domain/0/backend/pci/8/0/state backend at /local/domain/0/backend/vbd/8/51728 2097152 sectors of 512 bytes ************************** Thread "kbdfront": pointer: 0x2020131010, stack: 0xd00000 ******************* FBFRONT for device/vfb/0 ********** ******************* KBDFRONT for device/vkbd/0 ********** Failed to read device/vfb/0/backend-id. Failed to read device/vkbd/0/backend-id. error writing initialized: ENOENT but after start it has no PCI support :( the xen-pcifront is compiled in: grep -i xen /boot/config-3.3.0-1.el6.elrepo.x86_64 CONFIG_XEN=y CONFIG_XEN_DOM0=y CONFIG_XEN_PRIVILEGED_GUEST=y CONFIG_XEN_PVHVM=y CONFIG_XEN_MAX_DOMAIN_MEMORY=500 CONFIG_XEN_SAVE_RESTORE=y # CONFIG_XEN_DEBUG_FS is not set CONFIG_PCI_XEN=y CONFIG_XEN_PCIDEV_FRONTEND=y CONFIG_XEN_BLKDEV_FRONTEND=m CONFIG_XEN_BLKDEV_BACKEND=m CONFIG_NETXEN_NIC=m CONFIG_XEN_NETDEV_FRONTEND=m CONFIG_XEN_NETDEV_BACKEND=m CONFIG_INPUT_XEN_KBDDEV_FRONTEND=y CONFIG_HVC_XEN=y CONFIG_XEN_WDT=m CONFIG_XEN_FBDEV_FRONTEND=y # Xen driver support CONFIG_XEN_BALLOON=y CONFIG_XEN_SELFBALLOONING=y CONFIG_XEN_SCRUB_PAGES=y CONFIG_XEN_DEV_EVTCHN=m CONFIG_XEN_BACKEND=y CONFIG_XENFS=m CONFIG_XEN_COMPAT_XENFS=y CONFIG_XEN_SYS_HYPERVISOR=y CONFIG_XEN_XENBUS_FRONTEND=y CONFIG_XEN_GNTDEV=m CONFIG_XEN_GRANT_DEV_ALLOC=m CONFIG_SWIOTLB_XEN=y CONFIG_XEN_TMEM=y CONFIG_XEN_PCIDEV_BACKEND=m CONFIG_XEN_PRIVCMD=m PCI output of domU dmesg: dmesg | grep PCI Allocating PCI resources starting at 20800000 (gap: 20800000:df800000) PCI: setting up Xen PCI frontend stub PCI: pci_cache_line_size set to 64 bytes PCI: System does not support PCI PCI: System does not support PCI PCI: max bus depth: 0 pci_try_num: 1 PCI: CLS 0 bytes, default 64 what can be the problem? what can I do? can someone help? TiA -- Greetz
Hello, It''s possible that you need to load a handful of xen modules at startup inorder to create guests. From what you posted below, I can''t tell what''s happening on dom0 boot. Take a look at find /lib/modules -name "xen*.ko" | grep 3.3 the results of the above find command need to setup here cat>>/etc/rc.modules<<EOL modprobe xenfs modprobe xen-gntdev (and so on) EOL chmod +x /etc/rc.modules ----- Original Message ----- From: Christoph Kaminski <mangel@gmx.de> To: xen-users@lists.xensource.com Cc: Sent: Saturday, March 24, 2012 2:28 AM Subject: [Xen-users] Problems centos6/xen/pci passthrough Hi All I have a problem with xen and pci passthrough... I have centos 6 with xen here. Xen Pkgs from http://www.crc.id.au/ Kernel Pkgs from http://elrepo.org/tiki/kernel-ml (3.3.0-1.el6.elrepo.x86_64) in dom0/U. -- Mark
have loaded all found xen modules... still the same problem with pci passthrough On Sat, 24 Mar 2012 12:44:40 -0700 (PDT), Mark Pryor wrote:> Hello, > > It's possible that you need to load a handful of xen modules at > startup inorder to create guests. > > From what you posted below, I can't tell what's happening on dom0 > boot. > > Take a look at > > find /lib/modules -name "xen*.ko" | grep 3.3 > > the results of the above find command need to setup here > > cat>>/etc/rc.modules<<EOL > modprobe xenfs > modprobe xen-gntdev > (and so on) > EOL > chmod +x /etc/rc.modules > > > > ----- Original Message ----- > From: Christoph Kaminski <mangel@gmx.de> > To: xen-users@lists.xensource.com > Cc: > Sent: Saturday, March 24, 2012 2:28 AM > Subject: [Xen-users] Problems centos6/xen/pci passthrough > > Hi All > > I have a problem with xen and pci passthrough... > I have centos 6 with xen here. Xen Pkgs from http://www.crc.id.au/ > Kernel Pkgs from http://elrepo.org/tiki/kernel-ml > (3.3.0-1.el6.elrepo.x86_64) in dom0/U.-- Greetz _______________________________________________ Xen-users mailing list Xen-users@lists.xen.org http://lists.xen.org/xen-users
no one a hint for me? does someone use other pkgs for centos 6 where pci passthrough is working? On Sun, 25 Mar 2012 08:33:27 +0100, Christoph Kaminski wrote:> have loaded all found xen modules... still the same problem with pci > passthrough > > On Sat, 24 Mar 2012 12:44:40 -0700 (PDT), Mark Pryor wrote: >> Hello, >> >> It's possible that you need to load a handful of xen modules at >> startup inorder to create guests. >> >> From what you posted below, I can't tell what's happening on dom0 >> boot. >> >> Take a look at >> >> find /lib/modules -name "xen*.ko" | grep 3.3 >> >> the results of the above find command need to setup here >> >> cat>>/etc/rc.modules<<EOL >> modprobe xenfs >> modprobe xen-gntdev >> (and so on) >> EOL >> chmod +x /etc/rc.modules >> >> >> >> ----- Original Message ----- >> From: Christoph Kaminski <mangel@gmx.de> >> To: xen-users@lists.xensource.com >> Cc: >> Sent: Saturday, March 24, 2012 2:28 AM >> Subject: [Xen-users] Problems centos6/xen/pci passthrough >> >> Hi All >> >> I have a problem with xen and pci passthrough... >> I have centos 6 with xen here. Xen Pkgs from http://www.crc.id.au/ >> Kernel Pkgs from http://elrepo.org/tiki/kernel-ml >> (3.3.0-1.el6.elrepo.x86_64) in dom0/U.-- Greetz _______________________________________________ Xen-users mailing list Xen-users@lists.xen.org http://lists.xen.org/xen-users
Have you tried xen-pciback.hide=(0000:08:02.0)(0000:**08:02.1) ? I do not know why the prefixing ''0000:'' is missing on any Xen Wiki page; but most people say it is required. On Tuesday, March 27, 2012, Christoph Kaminski wrote:> no one a hint for me? > > does someone use other pkgs for centos 6 where pci passthrough is working? > > On Sun, 25 Mar 2012 08:33:27 +0100, Christoph Kaminski wrote: > >> have loaded all found xen modules... still the same problem with pci >> passthrough >> >> On Sat, 24 Mar 2012 12:44:40 -0700 (PDT), Mark Pryor wrote: >> >>> Hello, >>> >>> It''s possible that you need to load a handful of xen modules at >>> startup inorder to create guests. >>> >>> From what you posted below, I can''t tell what''s happening on dom0 boot. >>> >>> Take a look at >>> >>> find /lib/modules -name "xen*.ko" | grep 3.3 >>> >>> the results of the above find command need to setup here >>> >>> cat>>/etc/rc.modules<<EOL >>> modprobe xenfs >>> modprobe xen-gntdev >>> (and so on) >>> EOL >>> chmod +x /etc/rc.modules >>> >>> >>> >>> ----- Original Message ----- >>> From: Christoph Kaminski <mangel@gmx.de> >>> To: xen-users@lists.xensource.com >>> Cc: >>> Sent: Saturday, March 24, 2012 2:28 AM >>> Subject: [Xen-users] Problems centos6/xen/pci passthrough >>> >>> Hi All >>> >>> I have a problem with xen and pci passthrough... >>> I have centos 6 with xen here. Xen Pkgs from http://www.crc.id.au/ >>> Kernel Pkgs from http://elrepo.org/tiki/kernel-**ml<http://elrepo.org/tiki/kernel-ml> >>> (3.3.0-1.el6.elrepo.x86_64) in dom0/U. >>> >> > -- > Greetz > > ______________________________**_________________ > Xen-users mailing list > Xen-users@lists.xen.org > http://lists.xen.org/xen-users-- Regards, David Shen http://about.me/davidshen https://twitter.com/#!/davidshen84 _______________________________________________ Xen-users mailing list Xen-users@lists.xen.org http://lists.xen.org/xen-users
Coming from Debian so I don''t know if my experiences are a 1 to 1 map, but it looks like you are loading pciback after the system boots, which is too late since the device drivers have already loaded. The purpose of pciback is to load with the system before the devices are initialized and the system loads the drivers. From the reading I''ve found you supposedly have to rebuild your initrd with pciback for it to load at boot time: http://itknowledgeexchange.techtarget.com/linux-lotus-domino/centos-5-and-pciback-aka-hiding-pci-card-from-xen-dom0/ For that reason my solution has been to just compile a kernel with pciback "built-in", since I have had no luck with the module approach. Most of the guides I have read mention pci stub scripts, which I believe is a different utility from pciback. Also, on Debian the domain is not required for hiding or passing pci devices (in reference to the lspci format "domain:bus:slot.function" not the Xen domain). I hope that helps, ~Casey On Thu, Apr 12, 2012 at 12:14 AM, Xi Shen <davidshen84@gmail.com> wrote:> Have you tried xen-pciback.hide=(0000:08:02.0)(0000:**08:02.1) ? I do > not know why the prefixing ''0000:'' is missing on any Xen Wiki page; but > most people say it is required. > > > On Tuesday, March 27, 2012, Christoph Kaminski wrote: > >> no one a hint for me? >> >> does someone use other pkgs for centos 6 where pci passthrough is working? >> >> On Sun, 25 Mar 2012 08:33:27 +0100, Christoph Kaminski wrote: >> >>> have loaded all found xen modules... still the same problem with pci >>> passthrough >>> >>> On Sat, 24 Mar 2012 12:44:40 -0700 (PDT), Mark Pryor wrote: >>> >>>> Hello, >>>> >>>> It''s possible that you need to load a handful of xen modules at >>>> startup inorder to create guests. >>>> >>>> From what you posted below, I can''t tell what''s happening on dom0 boot. >>>> >>>> Take a look at >>>> >>>> find /lib/modules -name "xen*.ko" | grep 3.3 >>>> >>>> the results of the above find command need to setup here >>>> >>>> cat>>/etc/rc.modules<<EOL >>>> modprobe xenfs >>>> modprobe xen-gntdev >>>> (and so on) >>>> EOL >>>> chmod +x /etc/rc.modules >>>> >>>> >>>> >>>> ----- Original Message ----- >>>> From: Christoph Kaminski <mangel@gmx.de> >>>> To: xen-users@lists.xensource.com >>>> Cc: >>>> Sent: Saturday, March 24, 2012 2:28 AM >>>> Subject: [Xen-users] Problems centos6/xen/pci passthrough >>>> >>>> Hi All >>>> >>>> I have a problem with xen and pci passthrough... >>>> I have centos 6 with xen here. Xen Pkgs from http://www.crc.id.au/ >>>> Kernel Pkgs from http://elrepo.org/tiki/kernel-**ml<http://elrepo.org/tiki/kernel-ml> >>>> (3.3.0-1.el6.elrepo.x86_64) in dom0/U. >>>> >>> >> -- >> Greetz >> >> ______________________________**_________________ >> Xen-users mailing list >> Xen-users@lists.xen.org >> http://lists.xen.org/xen-users > > > > -- > Regards, > David Shen > > http://about.me/davidshen > https://twitter.com/#!/davidshen84 > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xen.org > http://lists.xen.org/xen-users >_______________________________________________ Xen-users mailing list Xen-users@lists.xen.org http://lists.xen.org/xen-users
it seems to be a problem with pv-grub. If I start it without pv-grub, directly with set kernel/ramdisk/extra options then it works... any solutions for it? On Sat, 24 Mar 2012 10:28:49 +0100, Christoph Kaminski wrote:> Hi All > > I have a problem with xen and pci passthrough... > I have centos 6 with xen here. Xen Pkgs from http://www.crc.id.au/ > Kernel Pkgs from http://elrepo.org/tiki/kernel-ml > (3.3.0-1.el6.elrepo.x86_64) in dom0/U. > > I hide the PCI ID''s with kernel parameter: > ''xen-pciback.hide=(08:02.0)(08:02.1)'' and load after boot the backend > module with: ''modprobe xen-pciback'' > > ''ll /sys/module/xen_pciback/drivers/pci\:pciback/'' shows: > > lrwxrwxrwx 1 root root 0 Mar 24 10:20 0000:08:02.0 -> > ../../../../devices/pci0000:00/0000:00:1e.0/0000:08:02.0 > lrwxrwxrwx 1 root root 0 Mar 24 10:20 0000:08:02.1 -> > ../../../../devices/pci0000:00/0000:00:1e.0/0000:08:02.1 > --w------- 1 root root 4096 Mar 24 10:20 bind > -r-------- 1 root root 4096 Mar 24 10:20 irq_handlers > --w------- 1 root root 4096 Mar 24 10:20 irq_handler_state > lrwxrwxrwx 1 root root 0 Mar 24 10:20 module -> > ../../../../module/xen_pciback > --w------- 1 root root 4096 Mar 24 10:20 new_id > --w------- 1 root root 4096 Mar 24 10:20 new_slot > -rw------- 1 root root 4096 Mar 24 10:20 permissive > -rw------- 1 root root 4096 Mar 24 10:20 quirks > --w------- 1 root root 4096 Mar 24 10:20 remove_id > --w------- 1 root root 4096 Mar 24 10:20 remove_slot > -r-------- 1 root root 4096 Mar 24 10:20 slots > --w------- 1 root root 4096 Mar 24 10:20 uevent > --w------- 1 root root 4096 Mar 24 10:20 unbind > > but with ''xm pci-list-assignable-devices'' I see no output :/ > > I have configured the domU with: ''pci = [ ''08:02.0'', ''08:02.1'' ]'' and > I see this if I create the domU: > > Using config file "/etc/xen/furfur.cfg". > Started domain furfur (id=8) > Xen Minimal OS! > start_info: 0xaa0000(VA) > nr_pages: 0x20000 > shared_inf: 0xbcf60000(MA) > pt_base: 0xaa3000(VA) > nr_pt_frames: 0x9 > mfn_list: 0x9a0000(VA) > mod_start: 0x0(VA) > mod_len: 0 > flags: 0x0 > cmd_line: (hd0)/boot/grub/grub.conf > stack: 0x95f980-0x97f980 > MM: Init > _text: 0x0(VA) > _etext: 0x6f9a4(VA) > _erodata: 0x89000(VA) > _edata: 0x91c60(VA) > stack start: 0x95f980(VA) > _end: 0x99ff80(VA) > start_pfn: aaf > max_pfn: 20000 > Mapping memory range 0xc00000 - 0x20000000 > setting 0x0-0x89000 readonly > skipped 0x1000 > MM: Initialise page allocator for ba9000(ba9000)-20000000(20000000) > MM: done > Demand map pfns at 20001000-2020001000. > Heap resides at 2020002000-4020002000. > Initialising timer interface > Initialising console ... done. > gnttab_table mapped at 0x20001000. > Initialising scheduler > Thread "Idle": pointer: 0x2020002050, stack: 0xcc0000 > Initialising xenbus > Thread "xenstore": pointer: 0x2020002800, stack: 0xcd0000 > Dummy main: start_info=0x97fa80 > Thread "main": pointer: 0x2020002fb0, stack: 0xce0000 > Thread "pcifront": pointer: 0x2020003760, stack: 0xcf0000 > "main" "(hd0)/boot/grub/grub.conf" > pcifront_watches: waiting for backend path to appear > device/pci/0/backend > vbd 51712 is hd0 > ******************* BLKFRONT for device/vbd/51712 ********** > > > pcifront_watches: waiting for backend to get into the right state > /local/domain/0/backend/pci/8/0 > ******************* PCIFRONT for device/pci/0 ********** > > > backend at /local/domain/0/backend/vbd/8/51712 > backend at /local/domain/0/backend/pci/8/0 > 10485760 sectors of 512 bytes > ************************** > vbd 51728 is hd1 > ******************* BLKFRONT for device/vbd/51728 ********** > > > ************************** > pcifront_watches: waiting for backend events > /local/domain/0/backend/pci/8/0/state > backend at /local/domain/0/backend/vbd/8/51728 > 2097152 sectors of 512 bytes > ************************** > Thread "kbdfront": pointer: 0x2020131010, stack: 0xd00000 > ******************* FBFRONT for device/vfb/0 ********** > > > ******************* KBDFRONT for device/vkbd/0 ********** > > > Failed to read device/vfb/0/backend-id. > Failed to read device/vkbd/0/backend-id. > error writing initialized: ENOENT > > but after start it has no PCI support :( the xen-pcifront is compiled > in: > > grep -i xen /boot/config-3.3.0-1.el6.elrepo.x86_64 > CONFIG_XEN=y > CONFIG_XEN_DOM0=y > CONFIG_XEN_PRIVILEGED_GUEST=y > CONFIG_XEN_PVHVM=y > CONFIG_XEN_MAX_DOMAIN_MEMORY=500 > CONFIG_XEN_SAVE_RESTORE=y > # CONFIG_XEN_DEBUG_FS is not set > CONFIG_PCI_XEN=y > CONFIG_XEN_PCIDEV_FRONTEND=y > CONFIG_XEN_BLKDEV_FRONTEND=m > CONFIG_XEN_BLKDEV_BACKEND=m > CONFIG_NETXEN_NIC=m > CONFIG_XEN_NETDEV_FRONTEND=m > CONFIG_XEN_NETDEV_BACKEND=m > CONFIG_INPUT_XEN_KBDDEV_FRONTEND=y > CONFIG_HVC_XEN=y > CONFIG_XEN_WDT=m > CONFIG_XEN_FBDEV_FRONTEND=y > # Xen driver support > CONFIG_XEN_BALLOON=y > CONFIG_XEN_SELFBALLOONING=y > CONFIG_XEN_SCRUB_PAGES=y > CONFIG_XEN_DEV_EVTCHN=m > CONFIG_XEN_BACKEND=y > CONFIG_XENFS=m > CONFIG_XEN_COMPAT_XENFS=y > CONFIG_XEN_SYS_HYPERVISOR=y > CONFIG_XEN_XENBUS_FRONTEND=y > CONFIG_XEN_GNTDEV=m > CONFIG_XEN_GRANT_DEV_ALLOC=m > CONFIG_SWIOTLB_XEN=y > CONFIG_XEN_TMEM=y > CONFIG_XEN_PCIDEV_BACKEND=m > CONFIG_XEN_PRIVCMD=m > > PCI output of domU dmesg: > > dmesg | grep PCI > Allocating PCI resources starting at 20800000 (gap: > 20800000:df800000) > PCI: setting up Xen PCI frontend stub > PCI: pci_cache_line_size set to 64 bytes > PCI: System does not support PCI > PCI: System does not support PCI > PCI: max bus depth: 0 pci_try_num: 1 > PCI: CLS 0 bytes, default 64 > > what can be the problem? what can I do? > > can someone help? > > TiA-- Greetz
can someone confirm that it is a bug? On Fri, 13 Apr 2012 18:17:59 +0200, Christoph Kaminski wrote:> it seems to be a problem with pv-grub. If I start it without pv-grub, > directly with set kernel/ramdisk/extra options then it works... > > any solutions for it? >-- Greetz