All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thorsten Blum <blum@kernel.org>
To: Thomas Bogendoerfer <tsbogend@alpha.franken.de>,
	Rosen Penev <rosenp@gmail.com>,
	Hemanth Selam <hemanth.selam@gmail.com>
Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org,
	Thorsten Blum <blum@kernel.org>
Subject: [PATCH 4/4] mips: n64: Use SZ_8M in plat_mem_setup()
Date: Thu, 29 Oct 2026 22:23:47 +0100	[thread overview]
Message-ID: <20261029212343.110095-10-blum@kernel.org> (raw)
In-Reply-To: <20261029212343.110095-6-blum@kernel.org>

Replace the hard-coded value with SZ_8M and improve the comments in
plat_mem_setup() and plat_time_init().

Signed-off-by: Thorsten Blum <blum@kernel.org>
---
 arch/mips/n64/init.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/arch/mips/n64/init.c b/arch/mips/n64/init.c
index 995556e4afd9..522b6405b644 100644
--- a/arch/mips/n64/init.c
+++ b/arch/mips/n64/init.c
@@ -11,6 +11,7 @@
 #include <linux/memblock.h>
 #include <linux/platform_device.h>
 #include <linux/platform_data/simplefb.h>
+#include <linux/sizes.h>
 #include <linux/slab.h>
 
 #include <asm/bootinfo.h>
@@ -122,11 +123,13 @@ arch_initcall(n64_platform_init);
 void __init plat_mem_setup(void)
 {
 	iomem_resource_init();
-	memblock_add(0x0, 8 * 1024 * 1024); /* Bootloader blocks the 4mb config */
+
+	/* The bootloader requires an Expansion Pak (8 MiB of RAM in total). */
+	memblock_add(0x0, SZ_8M);
 }
 
 void __init plat_time_init(void)
 {
-	/* 93.75 MHz cpu, count register runs at half rate */
+	/* The count register runs at half the 93.75 MHz CPU clock rate. */
 	mips_hpt_frequency = 93750000 / 2;
 }

      parent reply	other threads:[~2026-10-29 21:24 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-29 21:23 [PATCH 0/4] mips: n64: Clean up platform initialization Thorsten Blum
2026-10-29 21:23 ` [PATCH 1/4] mips: n64: Use DEFINE_RES_*() helpers Thorsten Blum
2026-10-29 21:23 ` [PATCH 2/4] mips: n64: Simplify framebuffer allocation Thorsten Blum
2026-10-29 21:23 ` [PATCH 3/4] mips: n64: Rename the video interface register helper Thorsten Blum
2026-10-29 21:23 ` Thorsten Blum [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=20261029212343.110095-10-blum@kernel.org \
    --to=blum@kernel.org \
    --cc=hemanth.selam@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=rosenp@gmail.com \
    --cc=tsbogend@alpha.franken.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 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.