On 9/29/26 14:08, Mark Johnston wrote:
> The branch main has been updated by markj:
> 
> URL: 
> https://cgit.FreeBSD.org/src/commit/?id=767cd9bb420008a3ebeef65fe1d31eab60d61028
> 
> commit 767cd9bb420008a3ebeef65fe1d31eab60d61028
> Author:     Mark Johnston <[email protected]>
> AuthorDate: 2026-09-29 21:08:17 +0000
> Commit:     Mark Johnston <[email protected]>
> CommitDate: 2026-09-29 21:08:17 +0000
> 
>     vm_swapout: Fix the build without options RACCT
>     
>     Reported by:    Jenkins
>     Fixes:          da0764f23554 ("vm_swapout: Restore handling of 
> RLIMIT_RSS")
> ---
>  sys/amd64/conf/GENERIC | 6 +++---
>  sys/vm/vm_swapout.c    | 7 ++++++-
>  2 files changed, 9 insertions(+), 4 deletions(-)
> 
> diff --git a/sys/amd64/conf/GENERIC b/sys/amd64/conf/GENERIC
> index 61533394a3d0..ed0b854d1766 100644
> --- a/sys/amd64/conf/GENERIC
> +++ b/sys/amd64/conf/GENERIC
> @@ -89,9 +89,9 @@ options     KDTRACE_FRAME           # Ensure frames are 
> compiled in
>  options      KDTRACE_HOOKS           # Kernel DTrace hooks
>  options      DDB_CTF                 # Kernel ELF linker loads CTF data
>  options      INCLUDE_CONFIG_FILE     # Include this file in kernel
> -options      RACCT                   # Resource accounting framework
> -options      RACCT_DEFAULT_TO_DISABLED # Set kern.racct.enable=0 by default
> -options      RCTL                    # Resource limits
> +#options     RACCT                   # Resource accounting framework
> +#ptions      RACCT_DEFAULT_TO_DISABLED # Set kern.racct.enable=0 by default

Missing leading o before ptions (but in a comment).

> +#options     RCTL                    # Resource limits
>  
>  # Debugging support.  Always need this:
>  options      KDB                     # Enable kernel debugger support.
> diff --git a/sys/vm/vm_swapout.c b/sys/vm/vm_swapout.c
> index a0c61c33fa5a..6f6b7de2fce9 100644
> --- a/sys/vm/vm_swapout.c
> +++ b/sys/vm/vm_swapout.c
> @@ -295,10 +295,11 @@ vm_daemon(void)
>       struct thread *td;
>       struct vmspace *vm;
>       int breakout, tryagain, attempts;
> -     uint64_t rsize, ravailable;
>  
> +#ifdef RACCT
>       if (racct_enable && vm_daemon_timeout == 0)
>               vm_daemon_timeout = hz;
> +#endif
>  
>       while (true) {
>               mtx_lock(&vm_daemon_mtx);
> @@ -370,7 +371,10 @@ again:
>                                   &vm->vm_map, limit);
>                               size = vmspace_resident_count(vm);
>                       }
> +#ifdef RACCT
>                       if (racct_enable) {
> +                             uint64_t ravailable, rsize;
> +
>                               rsize = IDX_TO_OFF(size);
>                               PROC_LOCK(p);
>                               if (p->p_state == PRS_NORMAL)
> @@ -407,6 +411,7 @@ again:
>                                               tryagain = 1;
>                               }
>                       }
> +#endif
>                       vmspace_free(vm);
>                       sx_slock(&allproc_lock);
>                       PRELE(p);
> 
> 


-- 
===
Mark Millard
marklmi at yahoo.com

Reply via email to