All of lore.kernel.org
 help / color / mirror / Atom feed
* [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
@ 2016-04-09 20:39 bugzilla-daemon
  2016-04-10 17:32 ` [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", " bugzilla-daemon
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-09 20:39 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

            Bug ID: 116101
           Summary: "Userspace still has active objects" and "trying to
                    unbind memory from uninitialized GART !" when
                    unbinding from radeon
           Product: Drivers
           Version: 2.5
    Kernel Version: 4.5.0
          Hardware: All
                OS: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: Video(DRI - non Intel)
          Assignee: drivers_video-dri@kernel-bugs.osdl.org
          Reporter: MonopolyMan720@aol.com
        Regression: No

Created attachment 212291
  --> https://bugzilla.kernel.org/attachment.cgi?id=212291&action=edit
Journalctl output

I am attempting to unbind my R9 290 from radeon and rebind it to vfio. However,
the entire system hangs when "echo "0000:01:00.0" >
/sys/bus/pci/devices/0000:01:00.0/driver/unbind" is ran as root. 

Steps to Reproduce: 
Run the following script as root

#!/bin/bash
set -x
echo "1002 67b1" > /sys/bus/pci/drivers/vfio-pci/new_id
echo "0000:01:00.0" > /sys/bus/pci/devices/0000:01:00.0/driver/unbind
echo "0000:01:00.0" > /sys/bus/pci/drivers/vfio-pci/bind
echo "1002 67b1" > /sys/bus/pci/drivers/vfio-pci/remove_id

echo "1002 aac8" > /sys/bus/pci/drivers/vfio-pci/new_id
echo "0000:01:00.1" > /sys/bus/pci/devices/0000:01:00.1/driver/unbind
echo "0000:01:00.1" > /sys/bus/pci/drivers/vfio-pci/bind
echo "1002 aac8" > /sys/bus/pci/drivers/vfio-pci/remove_id

set +x

Actual Results: 
System hangs on "echo "0000:01:00.0" >
/sys/bus/pci/devices/0000:01:00.0/driver/unbind"

Journalctl shows "Apr 09 16:10:26 joey-arch-pc kernel: radeon 0000:01:00.0:
Userspace still has active objects !" followed by numerous "Apr 09 16:10:26
joey-arch-pc kernel: trying to unbind memory from uninitialized GART !"

Expected Results: 

The GPU should be unbinding from radeon and rebinding to vfio-pci without
hanging. 

Additional information:
I experienced the same issue on 4.1.20-1. 

I know of instances where the same script results in the expected outcome with
a Cayman PRO graphics card. 

Attached is the output of journalctl for the entire boot. Go to 16:10:26 to see
relevant call traces.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
  2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
@ 2016-04-10 17:32 ` bugzilla-daemon
  2016-04-11  7:36 ` bugzilla-daemon
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-10 17:32 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

Joe P. <MonopolyMan720@aol.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|"Userspace still has active |"RIP
                   |objects" and "trying to     |radeon_gem_va_ioctl+0x35/0x
                   |unbind memory from          |650", "Userspace still has
                   |uninitialized GART !" when  |active objects", and
                   |unbinding from radeon       |"trying to unbind memory
                   |                            |from uninitialized GART !"
                   |                            |when unbinding from radeon

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
  2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
  2016-04-10 17:32 ` [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", " bugzilla-daemon
@ 2016-04-11  7:36 ` bugzilla-daemon
  2016-04-11 14:46 ` bugzilla-daemon
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-11  7:36 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

Christian König <deathsimple@vodafone.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |deathsimple@vodafone.de

--- Comment #1 from Christian König <deathsimple@vodafone.de> ---
Well as the error message already suggests "Userspace still has active objects
!" you have an application which is still using the hardware.

So unbinding and rebinding it to the isn't possible in this state.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
  2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
  2016-04-10 17:32 ` [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", " bugzilla-daemon
  2016-04-11  7:36 ` bugzilla-daemon
@ 2016-04-11 14:46 ` bugzilla-daemon
  2016-04-11 14:54 ` bugzilla-daemon
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-11 14:46 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

--- Comment #2 from Joe P. <MonopolyMan720@aol.com> ---
Right now the radeon card isn't being used for anything. I am using my Intel
iGPU as my output but using PRIME offloading to play games via the 290 (which
works fine). Sorry, I should have specified that in the original report.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
  2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
                   ` (2 preceding siblings ...)
  2016-04-11 14:46 ` bugzilla-daemon
@ 2016-04-11 14:54 ` bugzilla-daemon
  2016-04-11 18:43 ` bugzilla-daemon
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-11 14:54 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

--- Comment #3 from Joe P. <MonopolyMan720@aol.com> ---
(In reply to Christian König from comment #1)
> Well as the error message already suggests "Userspace still has active
> objects !" you have an application which is still using the hardware.
> 
> So unbinding and rebinding it to the isn't possible in this state.

Just to show that it's working 

$ glxinfo | grep "OpenGL renderer"
OpenGL renderer string: Mesa DRI Intel(R) Sandybridge Server 

$ DRI_PRIME=1 glxinfo | grep "OpenGL renderer"
OpenGL renderer string: Gallium 0.4 on AMD HAWAII (DRM 2.43.0, LLVM 3.7.1)

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
  2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
                   ` (3 preceding siblings ...)
  2016-04-11 14:54 ` bugzilla-daemon
@ 2016-04-11 18:43 ` bugzilla-daemon
  2016-04-12 23:26 ` bugzilla-daemon
  2016-04-13  0:25 ` bugzilla-daemon
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-11 18:43 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

--- Comment #4 from Christian König <deathsimple@vodafone.de> ---
It doesn't matter what OpenGL driver you currently use for the desktop. The
hardware is in use by something so unbinding can't work correctly.

Try "sudo lsof /dev/dri/card1" (or whatever number your Radeon card is) to
figure out which process it is using.

Might be that X has opened for prime support or something without your
knowledge.

Another possibility is that a framebuffer device is still bound to it.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
  2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
                   ` (4 preceding siblings ...)
  2016-04-11 18:43 ` bugzilla-daemon
@ 2016-04-12 23:26 ` bugzilla-daemon
  2016-04-13  0:25 ` bugzilla-daemon
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-12 23:26 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

Joe P. <MonopolyMan720@aol.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |INVALID

--- Comment #5 from Joe P. <MonopolyMan720@aol.com> ---
(In reply to Christian König from comment #4)
> It doesn't matter what OpenGL driver you currently use for the desktop. The
> hardware is in use by something so unbinding can't work correctly.
> 
> Try "sudo lsof /dev/dri/card1" (or whatever number your Radeon card is) to
> figure out which process it is using.
> 
> Might be that X has opened for prime support or something without your
> knowledge.
> 
> Another possibility is that a framebuffer device is still bound to it.

Wow, can't believe it was that simple. I checked and X was using the device. I 
set the ignore option of the 290 to true in the X configuration file and it
worked fine. X wasn't using the device and I am still able to use PRIME
offloading. I'm having some issues when using PRIME, but that's a separate
issue and I can now unbind the device. Thanks. Marking the bug as invalid.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", and "trying to unbind memory from uninitialized GART !" when unbinding from radeon
  2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
                   ` (5 preceding siblings ...)
  2016-04-12 23:26 ` bugzilla-daemon
@ 2016-04-13  0:25 ` bugzilla-daemon
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2016-04-13  0:25 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=116101

--- Comment #6 from Michel Dänzer <michel@daenzer.net> ---
There's still a bug though — if unbinding can't work, it should be refused
upfront, not attempted anyway, breaking things.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

end of thread, other threads:[~2016-04-13  0:25 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-09 20:39 [Bug 116101] New: "Userspace still has active objects" and "trying to unbind memory from uninitialized GART !" when unbinding from radeon bugzilla-daemon
2016-04-10 17:32 ` [Bug 116101] "RIP radeon_gem_va_ioctl+0x35/0x650", "Userspace still has active objects", " bugzilla-daemon
2016-04-11  7:36 ` bugzilla-daemon
2016-04-11 14:46 ` bugzilla-daemon
2016-04-11 14:54 ` bugzilla-daemon
2016-04-11 18:43 ` bugzilla-daemon
2016-04-12 23:26 ` bugzilla-daemon
2016-04-13  0:25 ` bugzilla-daemon

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.