public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Nishanth Menon <nm@ti.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v4 03/10] Exynos542x: Add workaround for ARM errata 798870
Date: Tue, 24 Feb 2015 17:13:37 -0600	[thread overview]
Message-ID: <20150224231337.GA31136@kahuna> (raw)
In-Reply-To: <1424419040-28768-4-git-send-email-akshay.s@samsung.com>

On 13:27-20150220, Akshay Saraswat wrote:
> This patch adds workaround for ARM errata 798870 which says
> "If back-to-back speculative cache line fills (fill A and fill B) are
> issued from the L1 data cache of a CPU to the L2 cache, the second
> request (fill B) is then cancelled, and the second request would have
> detected a hazard against a recent write or eviction (write B) to the
> same cache line as fill B then the L2 logic might deadlock."
> 
> Signed-off-by: Kimoon Kim <kimoon.kim@samsung.com>
> Signed-off-by: Akshay Saraswat <akshay.s@samsung.com>
> Reviewed-by: Simon Glass <sjg@chromium.org>
> Tested-by: Simon Glass <sjg@chromium.org>
> ---
> Changes since v3:
> 	- Added errata number in comment.
> 	- Moved changes to arm generic armv7.h
> 
> Changes since v2:
> 	- No change.
> 
> Changes since v1:
> 	- Added Reviewed-by & Tested-by.
> 	- Added space before */ on line # 40.
> 
>  arch/arm/include/asm/armv7.h | 16 ++++++++++++++++
>  1 file changed, 16 insertions(+)
> 
> diff --git a/arch/arm/include/asm/armv7.h b/arch/arm/include/asm/armv7.h
> index a13da23..a2040b7 100644
> --- a/arch/arm/include/asm/armv7.h
> +++ b/arch/arm/include/asm/armv7.h
> @@ -69,6 +69,22 @@
>  #define CP15DSB	asm volatile ("mcr     p15, 0, %0, c7, c10, 4" : : "r" (0))
>  #define CP15DMB	asm volatile ("mcr     p15, 0, %0, c7, c10, 5" : : "r" (0))
>  
> +/*
> + * Workaround for ARM errata # 798870
> + * Set L2ACTLR[7] to reissue any memory transaction in the L2 that has been
> + * stalled for 1024 cycles to verify that its hazard condition still exists.
> + */
> +static inline void v7_enable_l2_hazard_detect(void)
> +{
> +	uint32_t val;
> +
> +	/* L2ACTLR[7]: Enable hazard detect timeout */
> +	asm volatile ("mrc     p15, 1, %0, c15, c0, 0\n\t" : "=r"(val));
> +	val |= (1 << 7);
> +	asm volatile ("mcr     p15, 1, %0, c15, c0, 0\n\t" : : "r"(val));

This wont work for us in DRA7/OMAP5 L2ACTLR cannot be modified by
u-boot. has to go to secure world using smc call.

> +}
> +
> +void v7_en_l2_hazard_detect(void);
>  void v7_outer_cache_enable(void);
>  void v7_outer_cache_disable(void);
>  void v7_outer_cache_flush_all(void);

How about this - using the series:
https://patchwork.ozlabs.org/patch/443261/                
https://patchwork.ozlabs.org/patch/443264/                
https://patchwork.ozlabs.org/patch/443268/                
https://patchwork.ozlabs.org/patch/443265/                
https://patchwork.ozlabs.org/patch/443263/                
https://patchwork.ozlabs.org/patch/443262/                
https://patchwork.ozlabs.org/patch/443267/                
https://patchwork.ozlabs.org/patch/443266/                
https://patchwork.ozlabs.org/patch/443260/                
-- 
Regards,
Nishanth Menon

  reply	other threads:[~2015-02-24 23:13 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-20  7:57 [U-Boot] [PATCH v4 00/11] Add support for booting multiple cores Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 01/10] Exynos542x: Config: Add various configs Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 02/10] Exynos542x: CPU: Power down all secondary cores Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 03/10] Exynos542x: Add workaround for ARM errata 798870 Akshay Saraswat
2015-02-24 23:13   ` Nishanth Menon [this message]
2015-02-24 23:59     ` Nishanth Menon
2015-02-25 19:55     ` Kevin Hilman
2015-02-25 20:58       ` Nishanth Menon
2015-02-20  7:57 ` [U-Boot] [PATCH v4 04/10] Exynos542x: Add workaround for ARM errata 799270 Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 05/10] Exynos542x: Add workaround for exynos iROM errata Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 06/10] Exynos542x: cache: Disable clean/evict push to external Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 07/10] Exynos542x: add L2 control register configuration Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 08/10] Exynos542x: Fix secondary core booting for thumb Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 09/10] Exynos542x: Make A7s boot with thumb-mode U-Boot on warm reset Akshay Saraswat
2015-02-20  7:57 ` [U-Boot] [PATCH v4 10/10] Exynos: Fix L2 cache timings on Exynos5420 and Exynos5800 Akshay Saraswat
2015-02-28  9:48 ` [U-Boot] [PATCH v4 00/11] Add support for booting multiple cores Minkyu Kang
  -- strict thread matches above, loose matches on Subject: below --
2015-02-25  8:11 [U-Boot] [PATCH v4 03/10] Exynos542x: Add workaround for ARM errata 798870 Akshay Saraswat
2015-02-25  8:27 Akshay Saraswat
2015-02-25 14:27 ` Nishanth Menon
2015-02-25 19:58 ` Kevin Hilman
2015-02-26  4:28 Akshay Saraswat

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=20150224231337.GA31136@kahuna \
    --to=nm@ti.com \
    --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