Kernel KVM virtualization development
 help / color / mirror / Atom feed
* PCI assignement with nvidia K1: RmInitAdapter failed
@ 2013-07-09  9:18 Guillaume Thouvenin
  2013-07-09 10:15 ` Guillaume Thouvenin
  0 siblings, 1 reply; 7+ messages in thread
From: Guillaume Thouvenin @ 2013-07-09  9:18 UTC (permalink / raw)
  To: kvm

Hello,

I'd like to test a nvidia K1 with pci assignement by using the pci-stub 
module or the vfio module. I'm running an ubuntu raring as the host and 
a version 1.4.0 of qemu-system-x86 1.4.0. The nvidia K1 has a grid 
architecture and I see four K1 on one card.

I have unbind the device from the old driver and bind it to the 
vfio-pci. Then started the VM with the following command:

  $ sudo sh -c "qemu-system-x86_64 -M q35 -m 4096 --enable-kvm \
        -net nic,model=virtio,macaddr=52:54:00:82:69:75 -net tap,ifname=tap0 \
        -drive file=/home/thouveng/ubu13.04_amd64_base.qcow2,if=virtio \
        -device vfio-pci,host=87:00.0"

Then I logged into the VM and I can see the nvidia device:

  $ lspci | grep -i nvi
  00:03.0 VGA compatible controller: NVIDIA Corporation GK107GL [GRID 
K1] (rev a1)

I installed the nvidia driver that I downloaded from their website. 
Every things seems ok. Now to validate that everyhting is working I 
tried to run the command "nvidia-smi -q" and I got the following error:

  $ nvidia-smi -q
  NVIDIA: could not open the device file /dev/nvidia0 (Input/output error).
  Unable to determine the device handle for GPU 0000:00:03.0: Unknown Error

  and in the syslog of the guest I can see:
   [ 1502.459123] NVRM: RmInitAdapter failed! (0x26:0x38:1170)
  [ 1502.459150] NVRM: rm_init_adapter(0) failed

  I checked the BAR registers in the guest but as far as I understand 
them, memory regions seem correct:

  $ lspci -v
  00:03.0 VGA compatible controller: NVIDIA Corporation GK107GL [GRID 
K1] (rev a1) (prog-if 00 [VGA controller])
    Subsystem: NVIDIA Corporation Device 099d
    Flags: bus master, fast devsel, latency 0, IRQ 23
    Memory at fd000000 (32-bit, non-prefetchable) [size=16M]
    Memory at f0000000 (64-bit, prefetchable) [size=128M]
    Memory at fa000000 (64-bit, prefetchable) [size=32M]
    I/O ports at c000 [size=128]
    Expansion ROM at fe000000 [disabled] [size=512K]
    Capabilities: <access denied>
    Kernel driver in use: nvidia


   I also tried to do the assignement with pci-stub but I have the same 
problem.
The onlu clue that I could find on the web was on the page 
http://us.download.nvidia.com/XFree86/Linux-x86/304.60/README/commonproblems.html where they said that the same problem occured when the "VBIOS fail to load on my Optimus system". They said about this error "Such problems are typically beyond the control of the NVIDIA driver, which relies on proper cooperation of ACPI and the System BIOS to retrieve important information about the GPU, including the Video 
BIOS."

  I don't really understand the problem. I will really appreciate any help to
troubleshoot the problem and any links that can help are more than welcome :).

  I will also appreciate any comment about a succesfull story with PCI 
assignement with a K1. I don't have all of them but I maybe will have 
the opportunity to test them so any comments are welcome :).


Best regards,
Guillaume


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

end of thread, other threads:[~2013-07-11 10:05 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-09  9:18 PCI assignement with nvidia K1: RmInitAdapter failed Guillaume Thouvenin
2013-07-09 10:15 ` Guillaume Thouvenin
2013-07-09 17:52   ` Alex Williamson
2013-07-10 12:54     ` Guillaume Thouvenin
2013-07-10 15:25       ` Alex Williamson
2013-07-11 10:05         ` Guillaume Thouvenin
2013-07-10 15:30   ` Guillaume Thouvenin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox