public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2 0/5] Enable caches for the RPi2
Date: Wed, 16 Mar 2016 22:26:39 -0600	[thread overview]
Message-ID: <56EA31FF.6080304@wwwdotorg.org> (raw)
In-Reply-To: <1458139284-86132-1-git-send-email-agraf@suse.de>

On 03/16/2016 08:41 AM, Alexander Graf wrote:
> This patch set converts the Raspberry Pi 2 system to properly make use of
> the caches available in it.
>
> Because we're running in HYP mode, we first need to teach U-Boot how to
> make use of HYP registers and the LPAE page layout which is mandated by
> hardware when running in HYP mode.
>
> Then while we're at it, also mark the frame buffer cached to speed up
> screen updates.
>
> With this patch set, my Raspberry Pi 3 running in AArch32 mode is a *lot*
> faster than without.
>
> Please verify that the code works on a RPi2 as well and doesn't break the
> original Pi. In theory it should work, but I only have a 3 to test on
> available here.

This series mostly works OK. I found the following results, with my 
rpi_dev branch on github if you want to test the exact same commits:

RPi B+ (running rpi_1 build):
- Very minor transient corruption when running "ls mmc 0:2 /etc"

RPi 2 (running rpi_2 build):
RPi 3 (booting in 32-bit mode and running rpi_2 build):
RPi 3 (booting in 32-bit mode and running rpi_3_32b build):
- Obvious transient corruption when running "ls mmc 0:2 /etc"

RPi 3 (booting in 64-bit mode and running rpi_3 build):
- No issues

I suspect the transient corruptions that I saw were missing cache flush 
operations; during the large "memcpy" while scrolling the LCD, I would 
see corruption in the copied data. This would soon disappear; presumably 
as new data is written to the bottom lines of the frame-buffer flushes 
out old cache lines while doing a write-allocate?

Still, I'm not 100% sure this is an issue with these patches since the 
RPi B+ has a similar (although much less obvious) issue. Perhaps U-Boot 
is using the wrong VC/GPU cache alias (top 2 bits of 32-bit physical 
address) for the frame-buffer, i.e. the issue is in the GPU cache, not 
in the ARM cache?

As far as I can tell, USB worked fine in all cases (at least, the 
on-board hub/Ethernet device seemed to be enumerated without issue 
according to "usb tree" and "usb info".)

As such, I'm tempted to just ack the patches, but it'd be nice if you 
could take a look and see if something obvious is wrong.

  parent reply	other threads:[~2016-03-17  4:26 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-16 14:41 [U-Boot] [PATCH v2 0/5] Enable caches for the RPi2 Alexander Graf
2016-03-16 14:41 ` [U-Boot] [PATCH v2 1/5] arm64: Add 32bit arm compatible dcache definitions Alexander Graf
2016-03-27 22:25   ` [U-Boot] [U-Boot, v2, " Tom Rini
2016-03-16 14:41 ` [U-Boot] [PATCH v2 2/5] arm: Add support for HYP mode and LPAE page tables Alexander Graf
2016-03-27 22:25   ` [U-Boot] [U-Boot, v2, " Tom Rini
2016-03-16 14:41 ` [U-Boot] [PATCH v2 3/5] lcd: Fix compile warning in 64bit mode Alexander Graf
2016-03-27 22:25   ` [U-Boot] [U-Boot, v2, " Tom Rini
2016-03-16 14:41 ` [U-Boot] [PATCH v2 4/5] RPi: Enable caches for rpi2 Alexander Graf
2016-03-27 22:25   ` [U-Boot] [U-Boot,v2,4/5] " Tom Rini
2016-03-16 14:41 ` [U-Boot] [PATCH v2 5/5] bcm2835 video: Map fb as cached Alexander Graf
2016-03-22 15:22   ` [U-Boot] [PATCH v3 " Alexander Graf
2016-03-24  0:27   ` [U-Boot] [PATCH v4 " Alexander Graf
2016-03-24  2:05     ` Stephen Warren
2016-03-24  7:33       ` Alexander Graf
2016-03-24  9:31   ` [U-Boot] [PATCH v5 " Alexander Graf
2016-03-25  3:28     ` Stephen Warren
2016-03-27 22:30     ` [U-Boot] [U-Boot,v5,5/5] " Tom Rini
2016-03-17  4:26 ` Stephen Warren [this message]
2016-03-17  5:35   ` [U-Boot] [PATCH v2 0/5] Enable caches for the RPi2 Alexander Graf
2016-03-17  7:58   ` Alexander Graf
2016-03-19  2:12     ` Stephen Warren
2016-03-25  4:13 ` Stephen Warren
2016-08-11 13:42   ` Alexander Graf

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=56EA31FF.6080304@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=u-boot@lists.denx.de \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox