Date: Sun, 3 Feb 2019 05:26:10 +0000 (UTC) From: Cy Schubert <cy@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r343705 - head/sys/contrib/ipfilter/netinet Message-ID: <201902030526.x135QApN017887@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: cy Date: Sun Feb 3 05:26:10 2019 New Revision: 343705 URL: https://svnweb.freebsd.org/changeset/base/343705 Log: new_kmem_alloc(9) is a Solaris/illumos malloc(9). FreeBSD and NetBSD never get here, however a test for SOLARIS, as redundant as this test is, serves to document that this is the illumos definition. This should help those who come after me to follow the code more easily. MFC after: 1 month Modified: head/sys/contrib/ipfilter/netinet/ip_compat.h Modified: head/sys/contrib/ipfilter/netinet/ip_compat.h ============================================================================== --- head/sys/contrib/ipfilter/netinet/ip_compat.h Sun Feb 3 05:26:07 2019 (r343704) +++ head/sys/contrib/ipfilter/netinet/ip_compat.h Sun Feb 3 05:26:10 2019 (r343705) @@ -590,7 +590,7 @@ MALLOC_DECLARE(M_IPFILTER); # define COPYOUT(a,b,c) (bcopy((caddr_t)(a), (caddr_t)(b), (c)), 0) # endif -# ifndef KMALLOC +# if SOLARIS && !defined(KMALLOC) # define KMALLOC(a,b) (a) = (b)new_kmem_alloc(sizeof(*(a)), \ KMEM_NOSLEEP) # define KMALLOCS(a,b,c) (a) = (b)new_kmem_alloc((c), KMEM_NOSLEEP)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201902030526.x135QApN017887>