linux/drivers
Dave Airlie 87fdee8a92 drm/radeon: fix hotplug race at startup
commit 7f98ca454a upstream.

We apparantly get a hotplug irq before we've initialised
modesetting,

[drm] Loading R100 Microcode
BUG: unable to handle kernel NULL pointer dereference at   (null)
IP: [<c125f56f>] __mutex_lock_slowpath+0x23/0x91
*pde = 00000000
Oops: 0002 [#1]
Modules linked in: radeon(+) drm_kms_helper ttm drm i2c_algo_bit backlight pcspkr psmouse evdev sr_mod input_leds led_class cdrom sg parport_pc parport floppy intel_agp intel_gtt lpc_ich acpi_cpufreq processor button mfd_core agpgart uhci_hcd ehci_hcd rng_core snd_intel8x0 snd_ac97_codec ac97_bus snd_pcm usbcore usb_common i2c_i801 i2c_core snd_timer snd soundcore thermal_sys
CPU: 0 PID: 15 Comm: kworker/0:1 Not tainted 4.2.0-rc7-00015-gbf67402 #111
Hardware name: MicroLink                               /D850MV                         , BIOS MV85010A.86A.0067.P24.0304081124 04/08/2003
Workqueue: events radeon_hotplug_work_func [radeon]
task: f6ca5900 ti: f6d3e000 task.ti: f6d3e000
EIP: 0060:[<c125f56f>] EFLAGS: 00010282 CPU: 0
EIP is at __mutex_lock_slowpath+0x23/0x91
EAX: 00000000 EBX: f5e900fc ECX: 00000000 EDX: fffffffe
ESI: f6ca5900 EDI: f5e90100 EBP: f5e90000 ESP: f6d3ff0c
 DS: 007b ES: 007b FS: 0000 GS: 0000 SS: 0068
CR0: 8005003b CR2: 00000000 CR3: 36f61000 CR4: 000006d0
Stack:
 f5e90100 00000000 c103c4c1 f6d2a5a0 f5e900fc f6df394c c125f162 f8b0faca
 f6d2a5a0 c138ca00 f6df394c f7395600 c1034741 00d40000 00000000 f6d2a5a0
 c138ca00 f6d2a5b8 c138ca10 c1034b58 00000001 f6d40000 f6ca5900 f6d0c940
Call Trace:
 [<c103c4c1>] ? dequeue_task_fair+0xa4/0xb7
 [<c125f162>] ? mutex_lock+0x9/0xa
 [<f8b0faca>] ? radeon_hotplug_work_func+0x17/0x57 [radeon]
 [<c1034741>] ? process_one_work+0xfc/0x194
 [<c1034b58>] ? worker_thread+0x18d/0x218
 [<c10349cb>] ? rescuer_thread+0x1d5/0x1d5
 [<c103742a>] ? kthread+0x7b/0x80
 [<c12601c0>] ? ret_from_kernel_thread+0x20/0x30
 [<c10373af>] ? init_completion+0x18/0x18
Code: 42 08 e8 8e a6 dd ff c3 57 56 53 83 ec 0c 8b 35 48 f7 37 c1 8b 10 4a 74 1a 89 c3 8d 78 04 8b 40 08 89 63

Reported-and-Tested-by: Meelis Roos <mroos@linux.ee>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Cc: Jan Beulich <JBeulich@suse.com>
Cc: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
History 2015-08-27 12:19:50 +01:00
..
accessibility printk: move braille console support into separate braille.[ch] files 2013-07-31 14:41:03 -07:00
acpi ACPI / PNP: Reserve ACPI resources at the fs_initcall_sync stage 2015-07-15 10:01:34 +01:00
amba ARM: SoC: driver changes 2014-04-05 15:37:40 -07:00
ata libata: Do not blacklist M510DC 2015-08-11 09:57:34 +01:00
atm atm: fore200e.c: Cleaning up uninitialized variables 2014-06-02 17:11:03 -07:00
auxdisplay framebuffer: Use fb_<level> 2013-10-29 12:53:07 +02:00
base regmap: Fix possible shift overflow in regmap_field_init() 2015-07-15 10:00:37 +01:00
bcma bcma: gpio: register 32 GPIOs on BCM5357 2014-03-27 14:20:04 -04:00
block rbd: fix copyup completion race 2015-08-27 12:08:07 +01:00
bluetooth Bluetooth: ath3k: Add a new ID 0cf3:e006 to ath3k list 2015-07-20 13:17:08 +01:00
bus bus: omap_l3_noc: Correct returning IRQ_HANDLED unconditionally in the irq handler 2015-02-04 10:57:52 +00:00
cdrom Merge branch 'for-linus' of git://git.kernel.dk/linux-block 2014-06-11 08:41:17 -07:00
char agp/intel: Fix typo in needs_ilk_vtd_wa() 2015-07-15 10:00:58 +01:00
clk clk: ti: dra7-atl-clock: Fix possible ERR_PTR dereference 2015-07-15 10:01:15 +01:00
clocksource clocksource: exynos_mct: Avoid blocking calls in the cpu hotplug notifier 2015-07-15 10:00:56 +01:00
connector Char / misc driver patches for 3.16-rc1 2014-06-03 08:06:56 -07:00
cpufreq intel_pstate: set BYT MSR with wrmsrl_on_cpu() 2015-07-09 14:36:00 +01:00
cpuidle cpuidle: remove state_count field from struct cpuidle_device 2015-04-27 16:16:34 +01:00
crypto crypto: ixp4xx - Remove bogus BUG_ON on scattered dst buffer 2015-08-27 12:08:06 +01:00
dca dca: convert to idr_alloc() 2013-02-27 19:10:15 -08:00
devfreq PM / devfreq: remove checks for CONFIG_EXYNOS_ASV 2014-05-24 22:33:51 +09:00
dio m68k: don't export static inline functions 2009-12-06 11:18:28 +01:00
dma dmaengine: mv_xor: bug fix for racing condition in descriptors cleanup 2015-07-15 10:00:31 +01:00
edac sb_edac: avoid INTERNAL ERROR message in EDAC with unspecified channel 2015-04-21 11:54:45 +01:00
eisa Revert "EISA: Initialize device before its resources" 2014-01-17 14:57:29 -07:00
extcon extcon: palmas: Use devm_extcon_dev_allocate for extcon_dev 2014-04-29 09:52:12 +09:00
firewire firewire: cdev: prevent kernel stack leaking into ioctl arguments 2014-11-27 11:21:52 +00:00
firmware sysfs: Create mountpoints with sysfs_create_mount_point 2015-08-20 18:24:03 +01:00
fmc Merge 3.14-rc5 into char-misc-next 2014-03-02 19:53:09 -08:00
gpio gpio: gpio-kempld: Fix get_direction return value 2015-06-03 13:27:19 +01:00
gpu drm/radeon: fix hotplug race at startup 2015-08-27 12:19:50 +01:00
hid HID: cp2112: fix to force single data-report reply 2015-08-11 09:57:30 +01:00
hsi hsi: omap_ssi_port: use normal module refcounting 2014-06-05 00:59:05 +02:00
hv Drivers: hv: vmbus: Don't wait after requesting offers 2015-05-05 11:09:38 +01:00
hwmon hwmon: (mcp3021) Fix broken output scaling 2015-07-15 10:01:09 +01:00
hwspinlock A single patch from Vincent extending OMAP's hwspinlock support to OMAP5. 2013-05-07 14:01:27 -07:00
i2c i2c: at91: fix a race condition when using the DMA controller 2015-07-15 10:00:30 +01:00
ide Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/ide 2014-07-21 22:44:24 -07:00
idle intel_idle: fix IVT idle state table setting 2014-04-21 23:36:07 +02:00
iio iio: adc: vf610: fix the adc register read fail issue 2015-08-11 09:57:35 +01:00
infiniband IB/mlx4: Convert slave port before building address-handle 2015-07-15 10:01:20 +01:00
input Input: usbtouchscreen - avoid unresponsive TSC-30 touch screen 2015-08-11 09:57:44 +01:00
iommu iommu/amd: Handle large pages correctly in free_pagetable 2015-07-15 10:00:45 +01:00
ipack ipack: convert bus code to use dev_groups 2013-10-16 18:40:57 -07:00
irqchip irqchip: sunxi-nmi: Fix off-by-one error in irq iterator 2015-06-30 17:15:21 +01:00
isdn isdn/gigaset: reset tty->receive_room when attaching ser_gigaset 2015-08-12 09:48:29 +01:00
leds leds / PM: fix hibernation on arm when gpio-led used with CPU led trigger 2015-07-09 14:36:01 +01:00
lguest lguest: fix out-by-one error in address checking. 2015-06-03 14:30:03 +01:00
macintosh powerpc/macintosh/smu.c: Fix closing brace followed by if 2014-06-24 12:43:15 +10:00
mailbox drivers/mailbox/omap: make mbox->irq signed for error handling 2014-01-23 16:36:53 -08:00
mcb mcb: Add support for shared PCI IRQs 2014-05-27 17:38:11 -07:00
md md/raid1: extend spinlock to protect raid1_end_read_request against inconsistencies 2015-08-27 12:08:08 +01:00
media [media] cx24117: fix a buffer overflow when checking userspace params 2015-07-09 14:35:58 +01:00
memory memory: mvebu-devbus: add a devbus, keep-config property 2014-04-29 13:17:10 +00:00
memstick memstick: mspro_block: add missing curly braces 2015-05-06 11:33:10 +01:00
message mptfusion: enable no_write_same for vmware scsi disks 2014-10-30 09:40:12 -07:00
mfd mfd: kempld-core: Fix callback return value check 2015-04-10 10:03:55 +01:00
misc mei: make device disabled on stop unconditionally 2015-03-18 15:06:06 +00:00
mmc mmc: sdhci: Fix FSL ESDHC reset handling quirk 2015-08-12 09:48:35 +01:00
mtd mtd: dc21285: use raw spinlock functions for nw_gpio_lock 2015-07-15 10:01:21 +01:00
net niu: don't count tx error twice in case of headroom realloc fails 2015-08-25 10:13:51 +01:00
nfc NFC: microread: Potential overflows in microread_target_discovered() 2014-10-05 13:41:05 -07:00
ntb ntb: Use pci_enable_msix_range() instead of pci_enable_msix() 2014-04-07 10:59:20 -07:00
nubus kernel/printk: use symbolic defines for console loglevels 2014-06-04 16:54:17 -07:00
of of: return NUMA_NO_NODE from fallback of_node_to_nid() 2015-07-15 10:01:25 +01:00
oprofile oprofile, nmi-timer: Fix CPU hotplug callback registration 2014-03-20 13:43:46 +01:00
parisc PCI changes for the v3.12 merge window: 2013-09-03 16:24:35 -07:00
parport parport: fix menu breakage 2014-07-25 18:00:23 -07:00
pci PCI: cpcihp: Add missing curly braces in cpci_configure_slot() 2015-04-27 16:16:33 +01:00
pcmcia Disable write buffering on Toshiba ToPIC95 2015-07-15 10:00:33 +01:00
phy phy: twl4030-usb: remove incorrect pm_runtime_get_sync() in probe function. 2015-07-15 10:01:23 +01:00
pinctrl pinctrl: mvebu: armada-38x: fix incorrect total number of GPIOs 2015-07-15 10:00:30 +01:00
platform dell-laptop: Fix allocating & freeing SMI buffer page 2015-07-15 10:00:54 +01:00
pnp ACPI / PNP: Reserve ACPI resources at the fs_initcall_sync stage 2015-07-15 10:01:34 +01:00
power power_supply: lp8788-charger: Fix leaked power supply on probe fail 2015-05-04 16:06:35 +01:00
powercap powercap / RAPL: add support for CPU model 0x3f 2015-01-15 10:44:49 +00:00
pps drivers/pps/clients/pps-gpio.c: remove redundant of_match_ptr 2013-11-13 12:09:35 +09:00
ps3 ps3-vuart: don't use PREPARE_WORK 2014-03-07 10:24:48 -05:00
ptp ptp: ptp_pch depends on x86_32 2014-06-17 15:43:48 -07:00
pwm pwm: Fix period and polarity in pwm_get() for non-perfect matches 2014-10-05 13:40:52 -07:00
rapidio rapidio/tsi721_dma: fix failure to obtain transaction descriptor 2014-07-30 17:16:13 -07:00
regulator regulator: core: fix constraints output buffer 2015-07-15 10:00:25 +01:00
remoteproc remoteproc: da8xx: don't select CMA on no-MMU 2014-06-17 17:09:36 +02:00
reset reset: sunxi: fix spinlock initialization 2015-01-22 16:33:34 +00:00
rpmsg A small pull request consisting of: 2013-05-07 14:02:00 -07:00
rtc drivers/rtc/rtc-s5m.c: terminate s5m_rtc_id array with empty element 2015-02-04 10:58:19 +00:00
s390 KVM: s390: virtio-ccw: don't overwrite config space values 2015-07-15 10:01:12 +01:00
sbus bbc-i2c: Fix BBC I2C envctrl on SunBlade 2000 2014-08-14 10:09:44 +08:00
scsi ipr: Fix invalid array indexing for HRRQ 2015-08-25 10:13:45 +01:00
sfi SFI / ACPI: Fix warnings reported during builds with W=1 2013-12-07 01:24:33 +01:00
sh SH Driver Update for v3.16 2014-06-06 11:44:09 -07:00
sn Drivers: misc: remove __dev* attributes. 2013-01-03 15:57:16 -08:00
soc soc: qcom: fix of_device_id table 2014-05-26 21:27:09 +02:00
spi spi: fix race freeing dummy_tx/rx before it is unmapped 2015-07-09 14:35:59 +01:00
spmi spmi: pm: drop bus-level PM suspend/resume routines 2014-03-08 22:15:52 -08:00
ssb Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus 2014-01-30 17:20:32 -08:00
staging staging: vt6655: device_rx_srv check sk_buff is NULL 2015-07-15 10:00:15 +01:00
target iscsi-target: Fix iser explicit logout TX kthread leak 2015-08-20 19:58:05 +01:00
tc TC: Handle device_register() errors. 2014-06-26 10:48:23 +01:00
thermal thermal: exynos: Disable the regulator on probe failure 2015-08-27 12:08:09 +01:00
tty tty: remove platform_sysrq_reset_seq 2015-07-15 10:01:19 +01:00
uio Revert "uio: fix vma io range check in mmap" 2014-06-17 16:07:08 -07:00
usb drivers/usb: Delete XHCI command timer if necessary 2015-08-27 12:08:13 +01:00
uwb uwb: init beacon cache entry before registering uwb device 2014-10-05 13:40:58 -07:00
vfio vfio-pci: Fix the check on pci device type in vfio_pci_probe() 2015-01-16 14:34:28 +00:00
vhost vhost: actually track log eventfd file 2015-08-25 10:13:39 +01:00
video video/fbdev: fix defio's fsync 2015-01-16 14:34:19 +00:00
virt drivers: clean-up prom.h implicit includes 2013-10-09 20:04:04 -05:00
virtio virtio_pci: Clear stale cpumask when setting irq affinity 2015-06-30 17:15:20 +01:00
vlynq drivers/vlynq/vlynq.c: fix another resource size off by 1 error 2014-01-23 16:36:55 -08:00
vme vme_tsi148: Utilize to_pci_dev() macro 2014-04-16 14:08:37 -07:00
w1 w1_therm reference count family data 2015-07-09 14:36:07 +01:00
watchdog watchdog: omap: assert the counter being stopped before reprogramming 2015-07-15 10:01:29 +01:00
xen xen/events: don't bind non-percpu VIRQs with percpu chip 2015-06-02 12:08:17 +01:00
zorro zorro/UAPI: Use proper types (endianness/size) in <linux/zorro.h> 2013-11-26 11:09:09 +01:00
Kconfig soc: Introduce drivers/soc place-holder for SOC specific drivers 2014-05-23 11:37:46 -05:00
Makefile Char / misc driver patches for 3.16-rc1 2014-06-03 08:06:56 -07:00