lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 25 Jan 2011 12:24:13 +0000
From:	Dave Martin <dave.martin@...aro.org>
To:	Santosh Shilimkar <santosh.shilimkar@...com>
Cc:	Russell King - ARM Linux <linux@....linux.org.uk>,
	sen wang <wangchendu@...il.com>,
	David Brown <davidb@...eaurora.org>,
	linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org
Subject: Re: questions about arm trustzone

On Tue, Jan 25, 2011 at 11:46 AM, Santosh Shilimkar
<santosh.shilimkar@...com> wrote:
>> -----Original Message-----
>> From: linux-arm-kernel-bounces@...ts.infradead.org [mailto:linux-
>> arm-kernel-bounces@...ts.infradead.org] On Behalf Of Russell King -
>> ARM Linux
>> Sent: Tuesday, January 25, 2011 3:57 PM
>> To: sen wang
>> Cc: David Brown; linux-kernel@...r.kernel.org; linux-arm-
>> kernel@...ts.infradead.org
>> Subject: Re: questions about arm trustzone
>>
>> On Tue, Jan 25, 2011 at 05:19:16PM +0800, sen wang wrote:
>> > It seems linux run in the normal world, and the "scm.c"  is the
>> path
>> > to the monitor mode.
>> > where can I find the example code for monitor and secure world?
>>
>> OMAP also uses smc: arch/arm/mach-omap2/omap44xx-smc.S
>>
>> There's no interface defined for smc because it's highly vendor and
>> implementation specific.  It's just like a SWI (or svc) where it
>> causes entry via a vector into a priviledged mode, which can be
>> thought of being similar to a branch to a vector with a mode switch.
>>
> The code above won't give major details of how the monitor mode is
> implemented.  But as Russell said, it's pretty much vendor specific.
>
> On OMAP, We have standard API interfaces to enter into monitor
> world. One of the parameter denotes the kind of service, is
> requested.

I'm going off on a bit of a tangent here, but do you know whether the
Secure World code on OMAP can cope with being called from Thumb?  In
particular, if the Secure World tries to read the comment field from
the SMC instruction (which I notice is non-zero in some cases for
OMAP), it would need to be specifically coded to cope with the Thumb
case for this to work.

Avoiding this complexity is one of the motivations for using r7 for
the syscall number with CONFIG_EABI (instead of using the SVC comment
field).

Currently in my efforts to get the OMAP kernel working in Thumb-2, I
have assumed for simplicity that the Secure World will choke on SMCs
from Thumb code, but it would be nice to minimise the amount of code
which we need to build as ARM in the CONFIG_THUMB2_KERNEL case.  In
principle, everything could be Thumb code, now that the SWP
instruction usage is gone.

Cheers
---Dave
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ