Bug 44130 - Radeon pm segfault
Summary: Radeon pm segfault
Status: RESOLVED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Radeon (show other bugs)
Version: XOrg git
Hardware: All Linux (All)
: medium blocker
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-24 14:51 UTC by serveralex
Modified: 2012-01-04 07:02 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Patch for issue (1.22 KB, patch)
2011-12-24 14:51 UTC, serveralex
no flags Details | Splinter Review
cleaned up patch (1.40 KB, patch)
2011-12-30 09:57 UTC, Alex Deucher
no flags Details | Splinter Review

Description serveralex 2011-12-24 14:51:36 UTC
Created attachment 54798 [details] [review]
Patch for issue

Radeon driver with kms enabled may crash when the card does not have any power states registered. Card is onboard X1250. Patch is attached.

Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] RIP: 0010:[<ffffffffa00a5cf8>]  [<ffffffffa00a5cf8>] radeon_atombios_get_power_modes+0x298/0x310 [radeon]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] RSP: 0018:ffff880137eedb78  EFLAGS: 00010283
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] RAX: 0000000000000000 RBX: ffff880138576000 RCX: fffffffffffffff0
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] RDX: ffff8801369f4c00 RSI: 0000000000000082 RDI: 0000000000000202
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] RBP: ffff880137eedba8 R08: 0000000000000000 R09: 0000000000000000
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] R10: 0000000000000001 R11: 0000000000000000 R12: 0000000000000000
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] R13: 0000000001c20013 R14: 0000000000000000 R15: ffff880137118800
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] FS:  00007f617105e720(0000) GS:ffff88013fd00000(0000) knlGS:0000000000000000
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] CR2: 0000000000000020 CR3: 0000000137f56000 CR4: 00000000000006e0
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] Process modprobe (pid: 95, threadinfo ffff880137eec000, task ffff880137f3c500)
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] Stack:
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  ffff8801371189b0 0201adf838576000 ffff880137118c20 ffff880138576000
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  0000000000000002 0000000001c20013 ffff880137eedbc8 ffffffffa00f2335
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  ffff880138576000 0000000000000002 ffff880137eedbe8 ffffffffa00c14b5
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] Call Trace:
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa00f2335>] radeon_pm_init+0x115/0x2a0 [radeon]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa00c14b5>] radeon_modeset_init+0x135/0x170 [radeon]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa00a1ea0>] radeon_driver_load_kms+0x120/0x160 [radeon]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa0028e10>] drm_get_pci_dev+0x190/0x2f0 [drm]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa0105c7f>] radeon_pci_probe+0xae/0x42f [radeon]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff812c205f>] local_pci_probe+0x5f/0xd0
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff812c32c8>] pci_device_probe+0x88/0xb0
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff8134152a>] ? driver_sysfs_add+0x7a/0xb0
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff81341658>] really_probe+0x68/0x190
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff813417c5>] driver_probe_device+0x45/0x70
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff8134188b>] __driver_attach+0x9b/0xa0
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff813417f0>] ? driver_probe_device+0x70/0x70
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff81340cf8>] bus_for_each_dev+0x68/0x90
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff813414ae>] driver_attach+0x1e/0x20
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff81340580>] bus_add_driver+0x1a0/0x260
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff81341f30>] driver_register+0x80/0x150
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff812c3575>] __pci_register_driver+0x55/0xd0
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff814d758b>] ? printk+0x68/0x6d
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa0029081>] drm_pci_init+0x111/0x120 [drm]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa014d000>] ? 0xffffffffa014cfff
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffffa014d0e7>] radeon_init+0xe7/0x1000 [radeon]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff810001d3>] do_one_initcall+0x43/0x180
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff8108c8ec>] sys_init_module+0xcc/0x220
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  [<ffffffff814e1d82>] system_call_fastpath+0x16/0x1b
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] Code: 00 44 89 a3 60 11 00 00 c7 83 68 11 00 00 00 00 00 00 48 89 c1 89 83 64 11 00 00 48 c1 e0 06 48 c1 e1 04 48 29 c8 48 8b 44 10 08 <0f> b7 40 20 66 89 83 80 11 00 00 48 83 c4 18 5b 41 5c 41 5d c9 
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] RIP  [<ffffffffa00a5cf8>] radeon_atombios_get_power_modes+0x298/0x310 [radeon]
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014]  RSP <ffff880137eedb78>
Dec 24 23:11:02 serveralex-mint kernel: [    1.137014] CR2: 0000000000000020
Dec 24 23:11:02 serveralex-mint kernel: [    1.143210] ---[ end trace c6e617fdb31200a0 ]---
Comment 1 Alex Deucher 2011-12-30 09:57:11 UTC
Created attachment 54978 [details] [review]
cleaned up patch

I've sent a slightly cleaned up version of your patch to Dave.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.