On 11/14/20 11:21 AM, Mateusz Guzik wrote:
> Author: mjg
> Date: Sat Nov 14 19:21:46 2020
> New Revision: 367694
> URL: https://svnweb.freebsd.org/changeset/base/367694
> 
> Log:
>   thread: batch resource limit free calls
> 
> Modified:
>   head/sys/kern/kern_resource.c
>   head/sys/kern/kern_thread.c
>   head/sys/sys/resourcevar.h
> 
> Modified: head/sys/kern/kern_resource.c
> ==============================================================================
> --- head/sys/kern/kern_resource.c     Sat Nov 14 19:20:58 2020        
> (r367693)
> +++ head/sys/kern/kern_resource.c     Sat Nov 14 19:21:46 2020        
> (r367694)
> @@ -1236,6 +1236,14 @@ lim_free(struct plimit *limp)
>               free((void *)limp, M_PLIMIT);
>  }
>  
> +void
> +lim_freen(struct plimit *limp, int n)
> +{
> +
> +     if (refcount_releasen(&limp->pl_refcnt, n))
> +             free((void *)limp, M_PLIMIT);

You don't need this cast.

-- 
John Baldwin
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to