svn commit: r368124 - in head/sys: cam cam/ata cam/ctl cam/mmc cam/nvme cam/scsi compat/linprocfs compat/linux conf contrib/openzfs/module/os/freebsd/zfs dev/ahci dev/ata dev/firewire dev/flash dev...
Konstantin Belousov
kostikbel at gmail.com
Sun Nov 29 17:36:35 UTC 2020
On Sun, Nov 29, 2020 at 02:03:57PM +0100, Michal Meloun wrote:
> On 28.11.2020 13:12, Konstantin Belousov wrote:
> > Author: kib
> > Date: Sat Nov 28 12:12:51 2020
> > New Revision: 368124
> > URL: https://svnweb.freebsd.org/changeset/base/368124
> >
> > Log:
> > Make MAXPHYS tunable. Bump MAXPHYS to 1M.
> >
> Unfortunately, bumping MAXPHYS broke arm kernel. The kernel runs out of KVA
> while running 'pbuf' keg init function. This causes that keg_alloc_slab()
> always returns NULL and for cycle in uma_prealloc() newer ends (whish should
> be considered as another bug).
> Do you think that MAXPHYS constant can depends on given arch?
> 128k (or 256k) sounds reasonable for arm32 systems...
I think it is reasonable to return to 128KB for 32bit systems.
diff --git a/sys/sys/param.h b/sys/sys/param.h
index 00fb0c860e7..076b1fcde05 100644
--- a/sys/sys/param.h
+++ b/sys/sys/param.h
@@ -159,8 +159,12 @@
#ifndef DFLTPHYS
#define DFLTPHYS (64 * 1024) /* default max raw I/O transfer size */
#endif
-#ifndef MAXPHYS
-#define MAXPHYS (1024 * 1024) /* max raw I/O transfer size */
+#ifndef MAXPHYS /* max raw I/O transfer size */
+#ifdef __ILP32__
+#define MAXPHYS (128 * 1024)
+#else
+#define MAXPHYS (1024 * 1024)
+#endif
#endif
#ifndef MAXDUMPPGS
#define MAXDUMPPGS (DFLTPHYS/PAGE_SIZE)
More information about the svn-src-head
mailing list