]> git.karo-electronics.de Git - linux-beck.git/commitdiff
ARM: 8592/1: cache-l2x0.c: Replace magic numbers
authorAndrey Smirnov <andrew.smirnov@gmail.com>
Wed, 3 Aug 2016 19:29:38 +0000 (20:29 +0100)
committerRussell King <rmk+kernel@armlinux.org.uk>
Fri, 12 Aug 2016 15:47:03 +0000 (16:47 +0100)
Replace magic numbers used for L310 Prefetch Control Register

Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/mm/cache-l2x0.c

index cc12905ae6f89bc86a3ad6f76093714b9b2c7e73..7e624872bd6f79f81a4753933d47b58593c67e3f 100644 (file)
@@ -710,8 +710,10 @@ static void __init l2c310_fixup(void __iomem *base, u32 cache_id,
            revision < L310_CACHE_ID_RTL_R3P2) {
                u32 val = l2x0_saved_regs.prefetch_ctrl;
                /* I don't think bit23 is required here... but iMX6 does so */
-               if (val & (BIT(30) | BIT(23))) {
-                       val &= ~(BIT(30) | BIT(23));
+               if (val & (L310_PREFETCH_CTRL_DBL_LINEFILL |
+                          L310_PREFETCH_CTRL_DBL_LINEFILL_INCR)) {
+                       val &= ~(L310_PREFETCH_CTRL_DBL_LINEFILL |
+                                L310_PREFETCH_CTRL_DBL_LINEFILL_INCR);
                        l2x0_saved_regs.prefetch_ctrl = val;
                        errata[n++] = "752271";
                }