Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-08 Thread Greg Bellows
Unfortunately, the arm_is_secure*() functions cannot be moved either as they are used within cpu.h. Greg On 6 October 2014 16:07, Peter Maydell wrote: > On 6 October 2014 21:47, Greg Bellows wrote: > > > > > > On 6 October 2014 15:07, Peter Maydell wrote: > >> You should use is_a64() rather t

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-06 Thread Peter Maydell
On 6 October 2014 21:47, Greg Bellows wrote: > > > On 6 October 2014 15:07, Peter Maydell wrote: >> You should use is_a64() rather than directly looking at >> env->aarch64, incidentally. > > > Since I am touching arm_current_el(), should I go ahead and fix it to use > is_a64() as well? Optional.

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-06 Thread Greg Bellows
On 6 October 2014 15:07, Peter Maydell wrote: > On 6 October 2014 20:45, Greg Bellows wrote: > > On 6 October 2014 09:56, Peter Maydell wrote: > >> I checked your git tree and we don't actually use > >> arm_is_secure_below_el3() anywhere except in > >> arm_is_secure(), do we? That suggests to m

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-06 Thread Peter Maydell
On 6 October 2014 20:45, Greg Bellows wrote: > On 6 October 2014 09:56, Peter Maydell wrote: >> I checked your git tree and we don't actually use >> arm_is_secure_below_el3() anywhere except in >> arm_is_secure(), do we? That suggests to me we should >> just fold the two functions together. > > >

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-06 Thread Greg Bellows
On 6 October 2014 09:56, Peter Maydell wrote: > On 30 September 2014 22:49, Greg Bellows wrote: > > From: Fabian Aggeler > > > > arm_is_secure() function allows to determine CPU security state > > if the CPU implements Security Extensions/EL3. > > arm_is_secure_below_el3() returns true if CPU i

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-06 Thread Peter Maydell
On 6 October 2014 18:57, Sergey Fedorov wrote: > On 06.10.2014 07:56, Peter Maydell wrote: >> Can these functions live in internals.h rather than cpu.h? >> (The difference is that internals.h is restricted to only >> target-arm/ code whereas cpu.h is auto-included for a much >> wider set of files.

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-06 Thread Sergey Fedorov
On 06.10.2014 07:56, Peter Maydell wrote: > On 30 September 2014 22:49, Greg Bellows wrote: >> From: Fabian Aggeler >> >> arm_is_secure() function allows to determine CPU security state >> if the CPU implements Security Extensions/EL3. >> arm_is_secure_below_el3() returns true if CPU is in secure

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-06 Thread Peter Maydell
On 30 September 2014 22:49, Greg Bellows wrote: > From: Fabian Aggeler > > arm_is_secure() function allows to determine CPU security state > if the CPU implements Security Extensions/EL3. > arm_is_secure_below_el3() returns true if CPU is in secure state > below EL3. > > Signed-off-by: Sergey Fed

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-10-01 Thread Greg Bellows
Yeah, that would be cleaner, I'll fix it in the next version. On 30 September 2014 17:50, Edgar E. Iglesias wrote: > On Tue, Sep 30, 2014 at 04:49:14PM -0500, Greg Bellows wrote: > > From: Fabian Aggeler > > > > arm_is_secure() function allows to determine CPU security state > > if the CPU impl

Re: [Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-09-30 Thread Edgar E. Iglesias
On Tue, Sep 30, 2014 at 04:49:14PM -0500, Greg Bellows wrote: > From: Fabian Aggeler > > arm_is_secure() function allows to determine CPU security state > if the CPU implements Security Extensions/EL3. > arm_is_secure_below_el3() returns true if CPU is in secure state > below EL3. Hi Greg, > >

[Qemu-devel] [PATCH v5 02/33] target-arm: add arm_is_secure() function

2014-09-30 Thread Greg Bellows
From: Fabian Aggeler arm_is_secure() function allows to determine CPU security state if the CPU implements Security Extensions/EL3. arm_is_secure_below_el3() returns true if CPU is in secure state below EL3. Signed-off-by: Sergey Fedorov Signed-off-by: Fabian Aggeler Signed-off-by: Greg Bellow