linux/drivers/input/misc
Marek Szyprowski 6ae645d5fa Input: max8997-haptic - fix NULL pointer dereference
NULL pointer derefence happens when booting with DTB because the
platform data for haptic device is not set in supplied data from parent
MFD device.

The MFD device creates only platform data (from Device Tree) for itself,
not for haptic child.

Unable to handle kernel NULL pointer dereference at virtual address 0000009c
pgd = c0004000
	[0000009c] *pgd=00000000
	Internal error: Oops: 5 [#1] PREEMPT SMP ARM
	(max8997_haptic_probe) from [<c03f9cec>] (platform_drv_probe+0x4c/0xb0)
	(platform_drv_probe) from [<c03f8440>] (driver_probe_device+0x214/0x2c0)
	(driver_probe_device) from [<c03f8598>] (__driver_attach+0xac/0xb0)
	(__driver_attach) from [<c03f67ac>] (bus_for_each_dev+0x68/0x9c)
	(bus_for_each_dev) from [<c03f7a38>] (bus_add_driver+0x1a0/0x218)
	(bus_add_driver) from [<c03f8db0>] (driver_register+0x78/0xf8)
	(driver_register) from [<c0101774>] (do_one_initcall+0x90/0x1d8)
	(do_one_initcall) from [<c0a00dbc>] (kernel_init_freeable+0x15c/0x1fc)
	(kernel_init_freeable) from [<c06bb5b4>] (kernel_init+0x8/0x114)
	(kernel_init) from [<c0107938>] (ret_from_fork+0x14/0x3c)

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: <stable@vger.kernel.org>
Fixes: 104594b01c ("Input: add driver support for MAX8997-haptic")
[k.kozlowski: Write commit message, add CC-stable]
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-05-09 09:33:33 -07:00
..
88pm80x_onkey.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
88pm860x_onkey.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2014-12-17 10:06:02 -08:00
ab8500-ponkey.c Input: ab8500-ponkey - Fix module autoload for OF platform driver 2015-09-03 10:56:19 -07:00
ad714x-i2c.c Input: ad714x - convert to using managed resources 2015-09-19 11:42:39 -07:00
ad714x-spi.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2015-11-06 11:57:41 -08:00
ad714x.c Input: ad714x - convert to using managed resources 2015-09-19 11:42:39 -07:00
ad714x.h Input: ad714x - convert to using managed resources 2015-09-19 11:42:39 -07:00
adxl34x-i2c.c Input: drop owner assignment from i2c_driver 2015-07-17 16:57:00 -07:00
adxl34x-spi.c spi: Drop owner assignment from spi_drivers 2015-10-28 10:30:17 +09:00
adxl34x.c Input: delete non-required instances of include <linux/init.h> 2014-01-06 23:23:57 -08:00
adxl34x.h
apanel.c
arizona-haptics.c Input: arizona-haptic - don't assign input_dev parent 2016-04-17 05:24:52 -07:00
ati_remote2.c Input: ati_remote2 - fix crashes on detecting device with invalid descriptor 2016-03-23 17:29:29 -07:00
atlas_btns.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2014-01-24 17:17:30 -08:00
axp20x-pek.c Input: axp20x-pek - add module alias 2015-08-03 14:11:46 -07:00
bfin_rotary.c Input: bfin_rotary - introduce open and close methods 2015-02-15 16:06:29 -08:00
bma150.c Input: bma150 - constify bma150_cfg structure 2016-01-02 21:08:52 -08:00
cm109.c
cma3000_d0x_i2c.c Input: drop owner assignment from i2c_driver 2015-07-17 16:57:00 -07:00
cma3000_d0x.c Input: use dev_get_platdata() 2013-12-06 02:06:29 -08:00
cma3000_d0x.h
cobalt_btns.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
da9052_onkey.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
da9055_onkey.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
da9063_onkey.c Input: da9063 - report KEY_POWER instead of KEY_SLEEP during power key-press 2015-12-12 21:05:09 -08:00
dm355evm_keys.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
drv260x.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2015-09-04 12:02:11 -07:00
drv2665.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2015-09-04 12:02:11 -07:00
drv2667.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2015-09-04 12:02:11 -07:00
e3x0-button.c Input: add support for NI Ettus Research USRP E3x0 button 2015-01-10 14:17:10 -08:00
gp2ap002a00f.c Input: export I2C module alias information in missing drivers 2015-07-30 11:05:37 -07:00
gpio_tilt_polled.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
gpio-beeper.c Input: improve usage of gpiod API 2015-06-16 17:09:14 -07:00
hp_sdc_rtc.c Input: hp_sdc_rtc - fix y2038 problem in proc_show 2015-10-22 23:31:28 -07:00
ideapad_slidebar.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
ims-pcu.c Input: ims-pcu - sanity check against missing interfaces 2016-03-17 14:16:57 -07:00
ixp4xx-beeper.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
Kconfig Input: sirfsoc-onkey - allow modular build 2016-01-27 15:55:14 -08:00
keyspan_remote.c Input: keyspan_remote - remove unnecessary break after goto 2014-07-18 10:53:27 -07:00
kxtj9.c Input: kxtj9 - remove unneeded retval variable 2015-10-02 11:44:17 -07:00
m68kspkr.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
Makefile Input: Remove the max77843 haptic driver 2015-08-07 14:57:25 +01:00
max8925_onkey.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2014-12-17 10:06:02 -08:00
max8997_haptic.c Input: max8997-haptic - fix NULL pointer dereference 2016-05-09 09:33:33 -07:00
max77693-haptic.c Input: max77693: Add support for Maxim 77843 2015-08-07 14:57:25 +01:00
mc13783-pwrbutton.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
mma8450.c Input: mma8450 - convert to using managed resources 2015-03-24 11:35:06 -07:00
mpu3050.c Input: drop owner assignment from i2c_driver 2015-07-17 16:57:00 -07:00
palmas-pwrbutton.c Input: constify of_device_id arrays 2015-03-19 12:16:18 -07:00
pcap_keys.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
pcf8574_keypad.c Input: drop owner assignment from i2c_driver 2015-07-17 16:57:00 -07:00
pcf50633-input.c Input: delete non-required instances of include <linux/init.h> 2014-01-06 23:23:57 -08:00
pcspkr.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
pm8xxx-vibrator.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2014-12-17 10:06:02 -08:00
pm8941-pwrkey.c Input: pm8941-pwrkey - remove unneded semicolon 2015-09-19 11:39:03 -07:00
pmic8xxx-pwrkey.c Input: pmic8xxx-pwrkey - fix algorithm for converting trigger delay 2016-04-17 05:24:53 -07:00
powermate.c Input: powermate - fix oops with malicious USB descriptors 2016-03-14 09:36:49 -07:00
pwm-beeper.c Input: pwm-beeper - fix module autoload for OF platform driver 2015-09-03 10:56:20 -07:00
rb532_button.c MIPS: Remove all the uses of custom gpio.h 2015-09-03 12:08:02 +02:00
regulator-haptic.c Input: regulator-haptic - fix module autoload for OF platform driver 2015-09-03 10:56:20 -07:00
retu-pwrbutton.c Input: retu-pwrbutton - pass the IRQF_ONESHOT flag 2015-05-15 15:58:41 -07:00
rotary_encoder.c Input: rotary-encoder - support more than 2 gpios as input 2016-03-02 15:48:05 -08:00
sgi_btns.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
sirfsoc-onkey.c Input: sirfsoc-onkey - allow modular build 2016-01-27 15:55:14 -08:00
soc_button_array.c Input: soc_button_array - remove duplicated include 2015-05-13 10:30:18 -07:00
sparcspkr.c Input: sparcspkr - use platform_register/unregister_drivers() 2015-12-02 10:02:50 -08:00
tps65218-pwrbutton.c Input: constify of_device_id arrays 2015-03-19 12:16:18 -07:00
twl4030-pwrbutton.c Input: twl4030-pwrbutton - pass the IRQF_ONESHOT flag 2015-05-15 15:58:40 -07:00
twl4030-vibra.c Input: twl4030-vibra - do not reparent to grandparent 2016-04-20 14:39:46 -07:00
twl6040-vibra.c Input: twl6040-vibra - fix atomic schedule panic 2016-04-25 14:06:38 -07:00
uinput.c Input: uinput - sanity check on ff_effects_max and EV_FF 2015-12-18 17:48:52 -08:00
wistron_btns.c input: misc: drop owner assignment from platform_drivers 2014-10-20 16:20:40 +02:00
wm831x-on.c Input: wm831x-on - pass the IRQF_ONESHOT flag 2015-05-15 15:58:42 -07:00
xen-kbdfront.c Input: xen - check return value of xenbus_printf 2015-10-22 23:32:01 -07:00
yealink.c Input: delete non-required instances of include <linux/init.h> 2014-01-06 23:23:57 -08:00
yealink.h