From 1de67b38984892e529ea435824d8f179ccd1cca3 Mon Sep 17 00:00:00 2001 From: zbb Date: Tue, 18 Apr 2017 10:20:42 +0000 Subject: [PATCH] Reduce kmem_arena maximum size for Armada38x VM_KMEM_SIZE_MAX allows to limit kmem arena size. In our case this was necessary, as decreasing size of kmem_arena leaves more space for kernel_arena. kernel_arena is pool used for contigmalloc (in effect, DMA) allocations, which failed on Armada38x. This resulted in 'no memory errors' (e.g. USB_ERR_NOMEM errors) and failure of whole system. The need for greater size of kernel_arena probably comes from more peripherals making use of busdma. Value used as upper limit is half of the default value (0x1399a000). Submitted by: Wojciech Macek Obtained from: Semihalf Sponsored by: Stormshield Differential revision: https://reviews.freebsd.org/D10216 --- sys/arm/conf/ARMADA38X | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/arm/conf/ARMADA38X b/sys/arm/conf/ARMADA38X index bb3b557c11b..711fd85ba92 100644 --- a/sys/arm/conf/ARMADA38X +++ b/sys/arm/conf/ARMADA38X @@ -21,6 +21,8 @@ options ROOTDEVNAME=\"/dev/da0s1a\" options SCHED_ULE # ULE scheduler options SMP +options VM_KMEM_SIZE_MAX=0x9CCD000 + # Pseudo devices device random device pty -- 2.45.0