Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
xen, qemu-xen-traditionnal, quemu upstream [SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
CaptainBlood
Veteran
Veteran


Joined: 24 Jan 2010
Posts: 1103

PostPosted: Sun Jan 18, 2015 9:33 am    Post subject: xen, qemu-xen-traditionnal, quemu upstream [SOLVED] Reply with quote

Hi,

Since my former laptop died, I had to renew the device.
Unfortunately new Mediatek MT7630e WIFI chipset remains unknown to the linux kernel.

Consequently I had to fall back to an usb wifi adapter.

Formerly I used to pci passthrough WIFI to a domU PV.

I now have to translate my pci passthrough to usb passthrough.

According to http://wiki.xen.org/wiki/XL_vs_Xend_Feature_Comparison, there are many way how to achieve this.

To sum up I can :
- Fallback to xend since xl isn't PVUSB ready yet. (regressive, to be avoided as much as possible IMHO)
- use qemu whether xen-traditionnal or upstream.

My current choice is qemu, and I'm about to start working on it.

My guess would favor qemu upstream, at leat as a second step to achieve once feature has been activated with qemu-xen-traditionnal

However stable qemu package requires setting KVM kernel flag on, which I don't understand since I'm doing Xen not KVM

Anyone to explain what I should do to succeed qemu upstream install?

Thks 4 ur attention.


Last edited by CaptainBlood on Sun Jan 18, 2015 2:47 pm; edited 2 times in total
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 2616

PostPosted: Sun Jan 18, 2015 10:10 am    Post subject: Re: xen, qemu-xen-traditionnal, quemu upstream Reply with quote

CaptainBlood wrote:
Unfortunately new Mediatek MT7630e WIFI chipset remains unknown to the linux kernel.
But you could get it from the manufacturer's site: http://www.mediatek.com/en/downloads/mt7630-pcie/
Back to top
View user's profile Send private message
szatox
Veteran
Veteran


Joined: 27 Aug 2013
Posts: 1747

PostPosted: Sun Jan 18, 2015 11:17 am    Post subject: Reply with quote

Quote:
However stable qemu package requires setting KVM kernel flag on, which I don't understand since I'm doing Xen not KVM
Quite funny, my qemu doesn't seem to even have kvm flag, even though I definitely have kvm active when I run some vms. Obviously you can't have both hypervisors active at the same time as they will always conflict. Show us your errors


Quote:
USE="xen" emerge -pvDN qemu

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild N ] sys-power/iasl-20130117-r1 USE="{-test}" 1240 KiB
[ebuild N ] dev-python/pypam-0.5.0-r2 PYTHON_TARGETS="python2_7" 103 KiB
[ebuild N ] dev-python/markdown-2.5.1 USE="-doc -pygments {-test}" PYTHON_TARGETS="python2_7 python3_3 (-pypy) (-pypy3) -python3_4" 283 KiB
[ebuild N ] dev-python/lxml-3.3.5 USE="threads -beautifulsoup3 -doc -examples" PYTHON_TARGETS="python2_7 python3_3 -python3_4" 3387 KiB
[ebuild N ] app-emulation/xen-tools-4.3.3-r1 USE="pam -api -custom-cflags -debug -doc -flask -hvm (-ocaml) -pygrub -python -qemu -screen -static-libs -system-seabios" PYTHON_TARGETS="python2_7" 16551 KiB
[ebuild R ] app-emulation/qemu-2.1.2-r2 USE="aio alsa bluetooth caps curl fdt filecaps gtk jpeg ncurses nls opengl pin-upstream-blobs png sdl seccomp threads usb uuid vhost-net vnc xen* -accessibility -debug (-glusterfs) -infiniband -iscsi -lzo -nfs -numa -pulseaudio -python -rbd -sasl (-selinux) -smartcard -snappy -spice -ssh -static -static-softmmu -static-user -systemtap -tci {-test} -tls -usbredir -vde -virtfs -xattr -xfs" PYTHON_TARGETS="python2_7" QEMU_SOFTMMU_TARGETS="x86_64 -aarch64 -alpha -arm -cris -i386 -lm32 -m68k -microblaze -microblazeel -mips -mips64 -mips64el -mipsel -moxie -or32 -ppc -ppc64 -ppcemb -s390x -sh4 -sh4eb -sparc -sparc64 -unicore32 -xtensa -xtensaeb" QEMU_USER_TARGETS="arm -aarch64 -alpha -armeb -cris -i386 -m68k -microblaze -microblazeel -mips -mips64 -mips64el -mipsel -mipsn32 -mipsn32el -or32 -ppc -ppc64 -ppc64abi32 -s390x -sh4 -sh4eb -sparc -sparc32plus -sparc64 -unicore32 -x86_64" 0 KiB

Total: 6 packages (5 new, 1 reinstall), Size of downloads: 21561 KiB
Back to top
View user's profile Send private message
CaptainBlood
Veteran
Veteran


Joined: 24 Jan 2010
Posts: 1103

PostPosted: Sun Jan 18, 2015 12:05 pm    Post subject: Re: xen, qemu-xen-traditionnal, quemu upstream Reply with quote

charles17 wrote:
CaptainBlood wrote:
Unfortunately new Mediatek MT7630e WIFI chipset remains unknown to the linux kernel.
But you could get it from the manufacturer's site: http://www.mediatek.com/en/downloads/mt7630-pcie/


Indeed , but WIFI doesn't compile out of the box on my laptop.(BT does).
ASAIR I succeeded once somehow but I can't remember the trick :(

I've already started a thread in this respect, coz I''m probably not the only one facing this issue.
https://forums.gentoo.org/viewtopic-t-1005188-highlight-.html
No reply as of today :(

Thks 4 ur attention, interest & support


Last edited by CaptainBlood on Sun Jan 18, 2015 2:49 pm; edited 1 time in total
Back to top
View user's profile Send private message
CaptainBlood
Veteran
Veteran


Joined: 24 Jan 2010
Posts: 1103

PostPosted: Sun Jan 18, 2015 2:40 pm    Post subject: Reply with quote

szatox wrote:
Quote:
However stable qemu package requires setting KVM kernel flag on, which I don't understand since I'm doing Xen not KVM
Quite funny, my qemu doesn't seem to even have kvm flag, even though I definitely have kvm active when I run some vms. Obviously you can't have both hypervisors active at the same time as they will always conflict. Show us your errors


Quote:
USE="xen" emerge -pvDN qemu

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild N ] sys-power/iasl-20130117-r1 USE="{-test}" 1240 KiB
[ebuild N ] dev-python/pypam-0.5.0-r2 PYTHON_TARGETS="python2_7" 103 KiB
[ebuild N ] dev-python/markdown-2.5.1 USE="-doc -pygments {-test}" PYTHON_TARGETS="python2_7 python3_3 (-pypy) (-pypy3) -python3_4" 283 KiB
[ebuild N ] dev-python/lxml-3.3.5 USE="threads -beautifulsoup3 -doc -examples" PYTHON_TARGETS="python2_7 python3_3 -python3_4" 3387 KiB
[ebuild N ] app-emulation/xen-tools-4.3.3-r1 USE="pam -api -custom-cflags -debug -doc -flask -hvm (-ocaml) -pygrub -python -qemu -screen -static-libs -system-seabios" PYTHON_TARGETS="python2_7" 16551 KiB
[ebuild R ] app-emulation/qemu-2.1.2-r2 USE="aio alsa bluetooth caps curl fdt filecaps gtk jpeg ncurses nls opengl pin-upstream-blobs png sdl seccomp threads usb uuid vhost-net vnc xen* -accessibility -debug (-glusterfs) -infiniband -iscsi -lzo -nfs -numa -pulseaudio -python -rbd -sasl (-selinux) -smartcard -snappy -spice -ssh -static -static-softmmu -static-user -systemtap -tci {-test} -tls -usbredir -vde -virtfs -xattr -xfs" PYTHON_TARGETS="python2_7" QEMU_SOFTMMU_TARGETS="x86_64 -aarch64 -alpha -arm -cris -i386 -lm32 -m68k -microblaze -microblazeel -mips -mips64 -mips64el -mipsel -moxie -or32 -ppc -ppc64 -ppcemb -s390x -sh4 -sh4eb -sparc -sparc64 -unicore32 -xtensa -xtensaeb" QEMU_USER_TARGETS="arm -aarch64 -alpha -armeb -cris -i386 -m68k -microblaze -microblazeel -mips -mips64 -mips64el -mipsel -mipsn32 -mipsn32el -or32 -ppc -ppc64 -ppc64abi32 -s390x -sh4 -sh4eb -sparc -sparc32plus -sparc64 -unicore32 -x86_64" 0 KiB

Total: 6 packages (5 new, 1 reinstall), Size of downloads: 21561 KiB
Here's the message i was referring to.
Quote:
~ # emerge -1 qemu

* IMPORTANT: 1 news items need reading for repository 'gentoo-zh'.
* Use eselect news to read news items.

Calculating dependencies... done!

>>> Verifying ebuild manifests
>>> Running pre-merge checks for app-emulation/qemu-2.1.2-r2
* Determining the location of the kernel source code
* Found kernel source directory:
* /usr/src/linux
* Found kernel object directory:
* /lib/modules/3.14.27-gentoo-VGA0-KMS/build
* Found sources for kernel version:
* 3.14.27-gentoo-VGA0-KMS
* Checking for suitable kernel configuration options...
* You must enable KVM in your kernel to continue
* You will need the Universal TUN/TAP driver compiled into your kernel or loaded as a module to use the virtual network device if using -net tap.
* You will also need support for 802.1d Ethernet Bridging for some network configurations.
* If you have an AMD CPU, you must enable KVM_AMD in your kernel configuration.
* If you have an Intel CPU, you must enable KVM_INTEL in your kernel configuration.
* Please check to make sure these options are set correctly.
* Failure to do so may cause unexpected problems.
Nevertheless is seems it was missleading to identify the origin of install failure.

My system is configured for LTO, which generally requires libraries to be compiled with -ffat-lto-objects.
And qemu pulled 2 libs:
Quote:
sys-libs/libseccomp
dev-libs/libaio
But in the case of qemu, -ffat-lto-objects was not enough for libaio.
I finally succeeded to install qemu by reconfiguring sys-libs/libaio compilation flag to -fno-lto

Although I probably remain very far from solving my passthrough issue, at least this step seems solved.

For the record I would not be surprised to fail using qemu upstream for my purpose, but this is another story.

Thks 4 ur attention, interest & support


Last edited by CaptainBlood on Sun Jan 18, 2015 2:56 pm; edited 1 time in total
Back to top
View user's profile Send private message
szatox
Veteran
Veteran


Joined: 27 Aug 2013
Posts: 1747

PostPosted: Sun Jan 18, 2015 2:55 pm    Post subject: Reply with quote

Quote:
* If you have an AMD CPU, you must enable KVM_AMD in your kernel configuration.
* If you have an Intel CPU, you must enable KVM_INTEL in your kernel configuration.
I see those every time I compile qemu. This message is purely informational. It doesn't check kernel config. It's just qemu is typicaly used with kvm, so they remind the kernel module is necessary.

Launch that qemu/xen you installed and see what would happen.
From qemu manual:

-machine [type=]name[,prop=value[,...]]
Select the emulated machine by name. Use "-machine help" to list available machines. Supported machine properties are:

accel=accels1[:accels2[:...]]
This is used to enable an accelerator. Depending on the target architecture, kvm, xen, or tcg can be available. By default,
tcg is used. If there is more than one accelerator specified, the next one is used if the previous one fails to initialize.

So, -machine accel=xen and go. I suppose you will know if it's using xen when you see it running
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum