[RFC PATCH] ARM: Make a compile trustzone conditionally

Kyungmin Park kmpark at infradead.org
Mon Jun 18 00:37:48 EDT 2012


Hi Olof,

On 6/18/12, Olof Johansson <olof at lixom.net> wrote:
> On Sun, Jun 10, 2012 at 10:15 PM, Kyungmin Park <kmpark at infradead.org>
> wrote:
>> From: Kyungmin Park <kyungmin.park at samsung.com>
>>
>> Some boards can use the trustzone but others can't use trustzone.
>> However we need to build it simultaneously. To address this issue,
>> introduce arm trustzone support and use it at each board files.
>>
>> e.g., In boot_secondary at mach-exynos/platsmp.c
>>
>>        __raw_writel(virt_to_phys(exynos4_secondary_startup),
>>                CPU1_BOOT_REG);
>>
>>        if (trustzone_enabled()) {
>>                /* Call Exynos specific smc call */
>>                /* exynos_smc(SMC_CMD_CPU1BOOT, cpu, 0, 0); */
>>        }
>>
>>        gic_raise_softirq(cpumask_of(cpu), 1);
>>
>>        if (pen_release == -1)
>
> I would prefer to see this handled by using the smp_ops patchset that
> Marc Zyngier has been posting instead, replacing the boot_secondary
> function pointer during early boot depending on whether trustzone is
> enabled or not.
I understand your request, but it's not only boot_secondary but also
exynos pm common code and so on.even more it's used at devfreq to
adjust the RAM bus timings.

Now these files are covered.

arch/arm/mach-exynos/cpu-exynos4.c
arch/arm/mach-exynos/cpu-exynos5.c
arch/arm/mach-exynos/cpuidle-exynos4.c
arch/arm/mach-exynos/cpuidle-exynos5.c
arch/arm/mach-exynos/idle-exynos4.S
arch/arm/mach-exynos/idle-exynos5.S
arch/arm/mach-exynos/include/mach/entry-macro.S
arch/arm/mach-exynos/platsmp.c
arch/arm/mach-exynos/pm-exynos4.c
arch/arm/mach-exynos/pm-exynos5.c
arch/arm/mach-exynos/sleep-exynos4.S
arch/arm/mach-exynos/sleep-exynos5.S
arch/arm/mach-exynos/tmu.c

How do you think?

Thank you,
Kyungmin Park



More information about the linux-arm-kernel mailing list