public inbox for linux-mips@vger.kernel.org
 help / color / mirror / Atom feed
From: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
To: "Maciej W. Rozycki" <macro@orcam.me.uk>
Cc: David Hildenbrand <david@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Arnd Bergmann <arnd@arndb.de>,
	linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] MIPS: SiByte: Bring back cache initialisation
Date: Wed, 1 Apr 2026 22:29:16 +0200	[thread overview]
Message-ID: <ac2AHAFoI8FaqU0J@alpha.franken.de> (raw)
In-Reply-To: <alpine.DEB.2.21.2603271117500.60268@angie.orcam.me.uk>

On Fri, Mar 27, 2026 at 11:38:06AM +0000, Maciej W. Rozycki wrote:
> Bring back cache initialisation for Broadcom SiByte SB1 cores, which has 
> been removed causing the kernel to hang at bootstrap right after:
> 
> Dentry cache hash table entries: 524288 (order: 8, 4194304 bytes, linear)
> Inode-cache hash table entries: 262144 (order: 7, 2097152 bytes, linear)
> 
> The cause of the problem is R4k cache handlers are also used by Broadcom 
> SiByte SB1 cores, however with a different cache error exception handler 
> and therefore not using CPU_R4K_CACHE_TLB:
> 
> obj-$(CONFIG_CPU_R4K_CACHE_TLB) += c-r4k.o cex-gen.o tlb-r4k.o
> obj-$(CONFIG_CPU_SB1)           += c-r4k.o cerr-sb1.o cex-sb1.o tlb-r4k.o
> 
> (from arch/mips/mm/Makefile).
> 
> Fixes: bbe4f634f48c ("mips: fix r3k_cache_init build regression")
> Signed-off-by: Maciej W. Rozycki <macro@orcam.me.uk>
> Cc: stable@vger.kernel.org # v6.8+
> ---
>  arch/mips/mm/cache.c |    3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> linux-mips-sibyte-r4k-cache-init.diff
> Index: linux-swarm64/arch/mips/mm/cache.c
> ===================================================================
> --- linux-swarm64.orig/arch/mips/mm/cache.c
> +++ linux-swarm64/arch/mips/mm/cache.c
> @@ -207,7 +207,8 @@ void cpu_cache_init(void)
>  {
>  	if (IS_ENABLED(CONFIG_CPU_R3000) && cpu_has_3k_cache)
>  		r3k_cache_init();
> -	if (IS_ENABLED(CONFIG_CPU_R4K_CACHE_TLB) && cpu_has_4k_cache)
> +	if ((IS_ENABLED(CONFIG_CPU_R4K_CACHE_TLB) ||
> +	     IS_ENABLED(CONFIG_CPU_SB1)) && cpu_has_4k_cache)
>  		r4k_cache_init();
>  
>  	if (IS_ENABLED(CONFIG_CPU_CAVIUM_OCTEON) && cpu_has_octeon_cache)

applied to mips-fixes

Thomas.

-- 
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]

      reply	other threads:[~2026-04-01 20:30 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-27 11:38 [PATCH] MIPS: SiByte: Bring back cache initialisation Maciej W. Rozycki
2026-04-01 20:29 ` Thomas Bogendoerfer [this message]

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=ac2AHAFoI8FaqU0J@alpha.franken.de \
    --to=tsbogend@alpha.franken.de \
    --cc=akpm@linux-foundation.org \
    --cc=arnd@arndb.de \
    --cc=david@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=macro@orcam.me.uk \
    /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