From: Julien Grall <julien.grall@linaro.org>
To: Vijay Kilari <vijay.kilari@gmail.com>,
Ian Campbell <Ian.Campbell@citrix.com>,
Stefano Stabellini <stefano.stabellini@citrix.com>,
Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Cc: Prasun Kapoor <Prasun.Kapoor@caviumnetworks.com>,
Vijaya Kumar K <vijaya.kumar@caviumnetworks.com>,
xen-devel@lists.xen.org
Subject: Re: MPIDR register usage in ARMv8
Date: Wed, 16 Apr 2014 10:06:53 +0100 [thread overview]
Message-ID: <534E482D.2000806@linaro.org> (raw)
In-Reply-To: <CALicx6tbV4PORGh-LOgHHMWj=5vyJqFPpr_gztH4BnSRW5JM9Q@mail.gmail.com>
On 16/04/14 06:53, Vijay Kilari wrote:
> Hi Ian,
Hi Vijaya,
>
> I understand that arm64/head.S is using MPIDR definitions
> from xen/include/asm-arm/processor.h which is valid for arm32 but
> not for ARMv8 as below
>
> /* MPIDR Multiprocessor Affinity Register */
> #define _MPIDR_UP (30)
> #define MPIDR_UP (_AC(1,U) << _MPIDR_UP)
> #define _MPIDR_SMP (31)
> #define MPIDR_SMP (_AC(1,U) << _MPIDR_SMP)
> #define MPIDR_AFF0_SHIFT (0)
> #define MPIDR_AFF0_MASK (_AC(0xff,U) << MPIDR_AFF0_SHIFT)
> #define MPIDR_HWID_MASK _AC(0xffffff,U)
> #define MPIDR_INVALID (~MPIDR_HWID_MASK)
>
> The same is used in arm64/head.S checking for bit 31 (_MPIDR_SMP) which is not
> valid in MPIDR_EL1 register definition also MPIDR_HWID_MASK should
> be updated for ARMv8
Bit 31 is RAO on ARM64. So the check is useless below.
Except the MPIDR_HWID_MASK I don't see any problem as the only
difference between ARMv8 and ARMv7 is adding a new affinity field (AFF3).
>
> arm64/head.s:
>
> mrs x0, mpidr_el1
> tbz x0, _MPIDR_SMP, 1f /* Multiprocessor extension not
> supported? */
> tbnz x0, _MPIDR_UP, 1f /* Uniprocessor system? */
>
> mov x13, #(~MPIDR_HWID_MASK)
> bic x24, x0, x13 /* Mask out flags to get CPU ID */
> 1:
>
> Do you agree that this requires change?
What are the changes? You only copied the existing code?
Regards,
--
Julien Grall
next prev parent reply other threads:[~2014-04-16 9:06 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-16 5:53 MPIDR register usage in ARMv8 Vijay Kilari
2014-04-16 9:06 ` Julien Grall [this message]
2014-04-16 9:28 ` Vijay Kilari
2014-04-16 10:07 ` Ian Campbell
2014-04-16 9:13 ` Ian Campbell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=534E482D.2000806@linaro.org \
--to=julien.grall@linaro.org \
--cc=Ian.Campbell@citrix.com \
--cc=Prasun.Kapoor@caviumnetworks.com \
--cc=stefano.stabellini@citrix.com \
--cc=stefano.stabellini@eu.citrix.com \
--cc=vijay.kilari@gmail.com \
--cc=vijaya.kumar@caviumnetworks.com \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.