From 2489007e7d740ccbc3e0a202914e243ad5178787 Mon Sep 17 00:00:00 2001 From: codeworkx Date: Sat, 22 Sep 2012 09:48:20 +0200 Subject: merge opensource jb u5 Change-Id: I1aaec157aa196f3448eff8636134fce89a814cf2 --- arch/arm/mach-exynos/sec_log.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'arch/arm/mach-exynos/sec_log.c') diff --git a/arch/arm/mach-exynos/sec_log.c b/arch/arm/mach-exynos/sec_log.c index b55e7da..61e73af 100644 --- a/arch/arm/mach-exynos/sec_log.c +++ b/arch/arm/mach-exynos/sec_log.c @@ -105,6 +105,31 @@ out: __setup("sec_log=", sec_log_setup); +#ifdef CONFIG_CORESIGHT_ETM +static int __init sec_etb_setup(char *str) +{ + unsigned size = memparse(str, &str); + unsigned long base = 0; + + /* If we encounter any problem parsing str ... */ + if (!size || size != roundup_pow_of_two(size) || *str != '@' + || kstrtoul(str + 1, 0, &base)) + goto out; + + if (reserve_bootmem(base, size, BOOTMEM_EXCLUSIVE)) { + pr_err("%s: failed reserving size %d " + "at base 0x%lx\n", __func__, size, base); + goto out; + } + + return 1; +out: + return 0; +} + +__setup("sec_etb=", sec_etb_setup); +#endif + #ifdef CONFIG_SEC_LOG_LAST_KMSG static void __init sec_log_save_old(void) { -- cgit v1.1