All of lore.kernel.org
 help / color / mirror / Atom feed
From: Francesco Lavra <francescolavra.fl@gmail.com>
To: The development of GNU GRUB <grub-devel@gnu.org>
Cc: phcoder@gmail.com, Leif Lindholm <leif.lindholm@linaro.org>
Subject: Re: ARM branch
Date: Sat, 04 May 2013 19:50:02 +0200	[thread overview]
Message-ID: <51854A4A.2030401@gmail.com> (raw)
In-Reply-To: <20130501183258.GB28516@rocoto.smurfnet.nu>

Hi,

On 05/01/2013 08:32 PM, Leif Lindholm wrote:
> On Fri, Apr 12, 2013 at 07:33:21PM +0200, Vladimir 'φ-coder/phcoder' Serbinenko wrote:
>> Hello, all. I've uploaded Leif's and my ARM code to
>> http://bzr.savannah.gnu.org/lh/grub/branches/arm/changes. Francesco's
>> code will be added as well once his papers are done. The only dirty part
>> for Raspberry pi that I didn't upload is:
> 
> I have attached a patch (against this branch) that contains build
> system fixes and changes to the assembly files in order to permit the 
> same target-platform combination to build correctly on both ARMv6 and
> ARMv7, with no special options required.
[...]
> === modified file 'grub-core/kern/arm/cache.S'
> --- grub-core/kern/arm/cache.S	2013-04-07 00:41:07 +0000
> +++ grub-core/kern/arm/cache.S	2013-04-28 12:48:56 +0000
[...]
> @@ -149,21 +137,26 @@
>  clean_invalidate_dcache:
>  	push	{r4-r12, lr}
>  	mrc 	p15, 1, r0, c0, c0, 1	@ Read CLIDR
> -	ubfx	r1, r0, #24, #3		@ Extract LoC
> -	
> +	lsr	r1, r0, #24		@ Extract LoC
> +	and	r1, r1, #0x7
> +
>  	mov	r2, #0			@ First level, L1
>  2:	and	r8, r0, #7		@ cache type at current level
>  	cmp	r8, #2
>  	blt	5f			@ instruction only, or none, skip level
>  
> -	@ set current cache level/type (for CSSIDR read)
> +	@ set current cache level/type (for CCSIDR read)
>  	lsl	r8, r2, #1
>  	mcr	p15, 2, r8, c0, c0, 0	@ Write CSSELR (level, type: data/uni)
>  
>  	@ read current cache information
> -	mrc	p15, 1, r8, c0, c0, 0	@ Read CSSIDR
> -	ubfx	r3, r8, #13, #14	@ Number of sets -1
> -	ubfx	r4, r8, #3, #9		@ Number of ways -1
> +	mrc	p15, 1, r8, c0, c0, 0	@ Read CCSIDR

Unfortunately, in ARMv6 there are no such things as CLIDR, CSSELR and
CCSIDR.

--
Francesco


  parent reply	other threads:[~2013-05-04 17:49 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-12 17:33 ARM branch Vladimir 'φ-coder/phcoder' Serbinenko
2013-05-01 18:32 ` Leif Lindholm
2013-05-03 12:34   ` Vladimir 'φ-coder/phcoder' Serbinenko
2013-05-07 10:08     ` Leif Lindholm
2013-05-04 17:50   ` Francesco Lavra [this message]
2013-05-07 12:18     ` Leif Lindholm

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=51854A4A.2030401@gmail.com \
    --to=francescolavra.fl@gmail.com \
    --cc=grub-devel@gnu.org \
    --cc=leif.lindholm@linaro.org \
    --cc=phcoder@gmail.com \
    /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.