From mboxrd@z Thu Jan 1 00:00:00 1970
From: bugzilla-daemon@bugzilla.kernel.org
Subject: [Bug 84431] New: Kernel crash when unloading radeon module for
switcheroo card
Date: Fri, 12 Sep 2014 20:39:24 +0000
Message-ID:
Mime-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Return-path:
Received: from mail.kernel.org (mail.kernel.org [198.145.19.201])
by gabe.freedesktop.org (Postfix) with ESMTP id 004516E088
for ; Fri, 12 Sep 2014 13:39:26 -0700 (PDT)
Received: from mail.kernel.org (localhost [127.0.0.1])
by mail.kernel.org (Postfix) with ESMTP id 283402011E
for ; Fri, 12 Sep 2014 20:39:26 +0000 (UTC)
Received: from bugzilla1.web.kernel.org (bugzilla1.web.kernel.org
[172.20.200.51])
by mail.kernel.org (Postfix) with ESMTP id A8A922026D
for ; Fri, 12 Sep 2014 20:39:24 +0000 (UTC)
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: dri-devel-bounces@lists.freedesktop.org
Sender: "dri-devel"
To: dri-devel@lists.freedesktop.org
List-Id: dri-devel@lists.freedesktop.org
https://bugzilla.kernel.org/show_bug.cgi?id=84431
Bug ID: 84431
Summary: Kernel crash when unloading radeon module for
switcheroo card
Product: Drivers
Version: 2.5
Kernel Version: all
Hardware: All
OS: Linux
Tree: Mainline
Status: NEW
Severity: high
Priority: P1
Component: Video(DRI - non Intel)
Assignee: drivers_video-dri@kernel-bugs.osdl.org
Reporter: pali.rohar@gmail.com
Regression: No
Created attachment 149991
--> https://bugzilla.kernel.org/attachment.cgi?id=149991&action=edit
Fix crash after rmmod radeon on PX systems.
Calling rmmod radeon on PX system cause kernel crash. Reason is function
vga_switcheroo_init_domain_pm_ops() which setting dev->pm_domain function of
PCI device. When radeon module is unloaded pointer dev->pm_domain is set to
vga_switcheroo function which try to call radeon function (which does not
exists in memory after rmmod radeon). I bet that nouveau has same problem.
I'm attaching simple patch which set dev->pm_domain of PCI device back to NULL
when removing radeon device so vga_switcheroo will not be called.
But I think that proper way for fixing this bug - which is in vga_switcheroo -
should be to add function like "vga_switcheroo_exit_domain_pm_ops()" which will
set pm_domain back to origin value (which is in my case NULL).
With my patch on PX system I can call rmmod radeon, modprobe radeon, rmmod
radeon, ... many times without no crash.
--
You are receiving this mail because:
You are watching the assignee of the bug.