Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: samsung: Limit SAMSUNG_PM_DEBUG config option to non-Exynos platforms

"Samsung PM Suspend debug" feature (controlled by SAMSUNG_PM_DEBUG
config option) is not working properly (debug messages are not
displayed after resume) on Exynos platforms because GPIOs restore
code is not implemented.

Add PLAT_S3C24XX, ARCH_S3C64XX and ARCH_S5PV210 dependencies to
SAMSUNG_PM_DEBUG config option to hide it on Exynos platforms.
Then convert Exynos code to not require <plat/pm-common.h>
header (use pr_debug() directly instead of S3C_PMDBG() macro and
remove redundant s3c_pm_*() calls).

Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>

authored by

Bartlomiej Zolnierkiewicz and committed by
Krzysztof Kozlowski
b1658855 7b981b18

+5 -10
+4 -10
arch/arm/mach-exynos/suspend.c
··· 30 30 #include <asm/smp_scu.h> 31 31 #include <asm/suspend.h> 32 32 33 - #include <plat/pm-common.h> 34 - 35 33 #include "common.h" 36 34 37 35 #define REG_TABLE_END (-1U) ··· 496 498 u32 eint_wakeup_mask = exynos_read_eint_wakeup_mask(); 497 499 int ret; 498 500 499 - s3c_pm_debug_init(); 501 + pr_debug("%s: suspending the system...\n", __func__); 500 502 501 - S3C_PMDBG("%s: suspending the system...\n", __func__); 502 - 503 - S3C_PMDBG("%s: wakeup masks: %08x,%08x\n", __func__, 503 + pr_debug("%s: wakeup masks: %08x,%08x\n", __func__, 504 504 exynos_irqwake_intmask, eint_wakeup_mask); 505 505 506 506 if (exynos_irqwake_intmask == -1U ··· 508 512 return -EINVAL; 509 513 } 510 514 511 - s3c_pm_save_uarts(); 512 515 if (pm_data->pm_prepare) 513 516 pm_data->pm_prepare(); 514 517 flush_cache_all(); ··· 520 525 521 526 if (pm_data->pm_resume_prepare) 522 527 pm_data->pm_resume_prepare(); 523 - s3c_pm_restore_uarts(); 524 528 525 - S3C_PMDBG("%s: wakeup stat: %08x\n", __func__, 529 + pr_debug("%s: wakeup stat: %08x\n", __func__, 526 530 pmu_raw_readl(S5P_WAKEUP_STAT)); 527 531 528 - S3C_PMDBG("%s: resuming the system...\n", __func__); 532 + pr_debug("%s: resuming the system...\n", __func__); 529 533 530 534 return 0; 531 535 }
+1
arch/arm/plat-samsung/Kconfig
··· 239 239 config SAMSUNG_PM_DEBUG 240 240 bool "Samsung PM Suspend debug" 241 241 depends on PM && DEBUG_KERNEL 242 + depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210 242 243 depends on DEBUG_EXYNOS_UART || DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART 243 244 help 244 245 Say Y here if you want verbose debugging from the PM Suspend and