diff options
author | Sachin Kamat <sachin.kamat@linaro.org> | 2012-12-18 11:55:17 -0500 |
---|---|---|
committer | Kukjin Kim <kgene.kim@samsung.com> | 2012-12-19 12:25:18 -0500 |
commit | bdd1853212609ef1b1826ffc8b43439b0c54b2eb (patch) | |
tree | c119e6d98fc86a101e4cd8a858503e292651fccd | |
parent | 479dda22188220acb000310759ed0470b58573e4 (diff) |
ARM: EXYNOS: Fix NULL pointer dereference bug in SMDK4X12
When DRM support for Samsung SoC and Samsung S3C framebuffer support
are selected, the kernel crashes as it does not get the required
platform data. Change the compile macro to CONFIG_DRM_EXYNOS_FIMD
to fix this.
Fixes the following boot time crash:
Unable to handle kernel NULL pointer dereference at virtual address 00000000
PC is at 0x0
LR is at s3c_fb_probe+0x198/0x788
[<c0152270>] (s3c_fb_probe+0x198/0x788) from [<c019e52c>] (platform_drv_probe+0x18/0x1c)
[<c019e52c>] (platform_drv_probe+0x18/0x1c) from [<c019d2e4>] (driver_probe_device+0x70/0x1f0)
[<c019d2e4>] (driver_probe_device+0x70/0x1f0) from [<c019d4f0>] (__driver_attach+0x8c/0x90)
[<c019d4f0>] (__driver_attach+0x8c/0x90) from [<c019bc3c>] (bus_for_each_dev+0x50/0x7c)
[<c019bc3c>] (bus_for_each_dev+0x50/0x7c) from [<c019cb4c>] (bus_add_driver+0x170/0x23c)
[<c019cb4c>] (bus_add_driver+0x170/0x23c) from [<c019d9a4>] (driver_register+0x78/0x144)
[<c019d9a4>] (driver_register+0x78/0x144) from [<c000862c>] (do_one_initcall+0x34/0x174)
[<c000862c>] (do_one_initcall+0x34/0x174) from [<c020ed7c>] (kernel_init+0x100/0x2a0)
[<c020ed7c>] (kernel_init+0x100/0x2a0) from [<c000e118>] (ret_from_fork+0x14/0x3c)
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
-rw-r--r-- | arch/arm/mach-exynos/mach-smdk4x12.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mach-exynos/mach-smdk4x12.c b/arch/arm/mach-exynos/mach-smdk4x12.c index a1555a73c7af..ae6da40c2aa9 100644 --- a/arch/arm/mach-exynos/mach-smdk4x12.c +++ b/arch/arm/mach-exynos/mach-smdk4x12.c | |||
@@ -246,7 +246,7 @@ static struct samsung_keypad_platdata smdk4x12_keypad_data __initdata = { | |||
246 | .cols = 8, | 246 | .cols = 8, |
247 | }; | 247 | }; |
248 | 248 | ||
249 | #ifdef CONFIG_DRM_EXYNOS | 249 | #ifdef CONFIG_DRM_EXYNOS_FIMD |
250 | static struct exynos_drm_fimd_pdata drm_fimd_pdata = { | 250 | static struct exynos_drm_fimd_pdata drm_fimd_pdata = { |
251 | .panel = { | 251 | .panel = { |
252 | .timing = { | 252 | .timing = { |
@@ -360,7 +360,7 @@ static void __init smdk4x12_machine_init(void) | |||
360 | 360 | ||
361 | s3c_hsotg_set_platdata(&smdk4x12_hsotg_pdata); | 361 | s3c_hsotg_set_platdata(&smdk4x12_hsotg_pdata); |
362 | 362 | ||
363 | #ifdef CONFIG_DRM_EXYNOS | 363 | #ifdef CONFIG_DRM_EXYNOS_FIMD |
364 | s5p_device_fimd0.dev.platform_data = &drm_fimd_pdata; | 364 | s5p_device_fimd0.dev.platform_data = &drm_fimd_pdata; |
365 | exynos4_fimd0_gpio_setup_24bpp(); | 365 | exynos4_fimd0_gpio_setup_24bpp(); |
366 | #else | 366 | #else |