From: Igor Belousov <igor.b@beldev.am>
To: linux-kernel@vger.kernel.org, linux-mm@kvack.org
Cc: akpm@linux-foundation.org, hannes@cmpxchg.org,
minchan@kernel.org, nphamcs@gmail.com, senozhatsky@chromium.org,
shakeel.butt@linux.dev, yosry.ahmed@linux.dev,
Igor Belousov <igor.b@beldev.am>
Subject: [PATCH mm-new] mm/zblock: avoid failing the build
Date: Mon, 28 Apr 2025 08:57:27 +0200 [thread overview]
Message-ID: <20250428065727.57990-1-igor.b@beldev.am> (raw)
Don't break the build for a PAGE_SIZE that is not fully supported,
just print out a warning in that case.
Signed-off-by: Igor Belousov <igor.b@beldev.am>
---
mm/zblock.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/mm/zblock.h b/mm/zblock.h
index fd72961c077a..8610196b651e 100644
--- a/mm/zblock.h
+++ b/mm/zblock.h
@@ -21,7 +21,8 @@
/* max 256 slots per block, max table size 64 */
#define SLOT_BITS 8
#else
-#error Unsupported PAGE_SIZE
+#warn This PAGE_SIZE is not quite supported yet
+#define SLOT_BITS 8
#endif
#define MAX_SLOTS (1 << SLOT_BITS)
@@ -101,7 +102,7 @@ static const struct block_desc block_desc[] = {
{ SLOT_SIZE(10, 3), 10, 3 },
{ SLOT_SIZE(9, 3), 9, 3 },
{ SLOT_SIZE(4, 2), 4, 2 },
-#elif PAGE_SIZE == 0x4000
+#else
{ SLOT_SIZE(255, 0), 255, 0 },
{ SLOT_SIZE(185, 0), 185, 0 },
{ SLOT_SIZE(145, 0), 145, 0 },
--
2.49.0
next reply other threads:[~2025-04-28 6:58 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-28 6:57 Igor Belousov [this message]
2025-04-28 8:46 ` [PATCH mm-new] mm/zblock: avoid failing the build kernel test robot
2025-04-28 9:27 ` Andrew Morton
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=20250428065727.57990-1-igor.b@beldev.am \
--to=igor.b@beldev.am \
--cc=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=minchan@kernel.org \
--cc=nphamcs@gmail.com \
--cc=senozhatsky@chromium.org \
--cc=shakeel.butt@linux.dev \
--cc=yosry.ahmed@linux.dev \
/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