git: c2cd285bfe41 - stable/13 - sys: Add a deprecation warning for 32-bit kernels.
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 06 Sep 2023 21:56:49 UTC
The branch stable/13 has been updated by jhb:
URL: https://cgit.FreeBSD.org/src/commit/?id=c2cd285bfe41574490e5f2c11b113e5fb8536a55
commit c2cd285bfe41574490e5f2c11b113e5fb8536a55
Author: John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2023-08-16 16:48:51 +0000
Commit: John Baldwin <jhb@FreeBSD.org>
CommitDate: 2023-09-06 21:56:10 +0000
sys: Add a deprecation warning for 32-bit kernels.
Per recent discussions on arch@ and at the BSDCan developer summit, we
are considering removing support for 32-bit platforms (in some form)
for 15.0 (at the earliest). A final decision on what will ship in
15.0 will be made closer to the release of 15.0. However, we should
communicate the potential deprecation in 14.0 to provide notice to
users.
This commit adds a warning during boot on 32-bit kernels that they are
deprecated and may be removed in 15.0. More details will be included
in a followup commit to RELNOTES.
Reviewed by: brooks, imp, emaste
Differential Revision: https://reviews.freebsd.org/D41163
(cherry picked from commit 41582f28ddf7b42b713b270d41e8da80160b69a3)
---
sys/kern/init_main.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c
index 4a8dc8ac45f1..73d78ad16df3 100644
--- a/sys/kern/init_main.c
+++ b/sys/kern/init_main.c
@@ -386,6 +386,15 @@ SYSINIT(diagwarn2, SI_SUB_LAST, SI_ORDER_FIFTH,
print_caddr_t, diag_warn);
#endif
+#if __SIZEOF_LONG__ == 4
+static char ilp32_warn[] =
+ "WARNING: 32-bit kernels are deprecated and may be removed in FreeBSD 15.0.\n";
+SYSINIT(ilp32warn, SI_SUB_COPYRIGHT, SI_ORDER_FIFTH,
+ print_caddr_t, ilp32_warn);
+SYSINIT(ilp32warn2, SI_SUB_LAST, SI_ORDER_FIFTH,
+ print_caddr_t, ilp32_warn);
+#endif
+
static int
null_fetch_syscall_args(struct thread *td __unused)
{