The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/contrib/openzfs/config/kernel-kmem-cache.m4

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 dnl #
    2 dnl # grsecurity API change,
    3 dnl # kmem_cache_create() with SLAB_USERCOPY flag replaced by
    4 dnl # kmem_cache_create_usercopy().
    5 dnl #
    6 AC_DEFUN([ZFS_AC_KERNEL_SRC_KMEM_CACHE_CREATE_USERCOPY], [
    7         ZFS_LINUX_TEST_SRC([kmem_cache_create_usercopy], [
    8                 #include <linux/slab.h>
    9                 static void ctor(void *foo) { /* fake ctor */ }
   10         ],[
   11                 struct kmem_cache *skc_linux_cache;
   12                 const char *name = "test";
   13                 size_t size = 4096;
   14                 size_t align = 8;
   15                 unsigned long flags = 0;
   16                 size_t useroffset = 0;
   17                 size_t usersize = size - useroffset;
   18 
   19                 skc_linux_cache = kmem_cache_create_usercopy(
   20                     name, size, align, flags, useroffset, usersize, ctor);
   21         ])
   22 ])
   23 
   24 AC_DEFUN([ZFS_AC_KERNEL_KMEM_CACHE_CREATE_USERCOPY], [
   25         AC_MSG_CHECKING([whether kmem_cache_create_usercopy() exists])
   26         ZFS_LINUX_TEST_RESULT([kmem_cache_create_usercopy], [
   27                 AC_MSG_RESULT(yes)
   28                 AC_DEFINE(HAVE_KMEM_CACHE_CREATE_USERCOPY, 1,
   29                     [kmem_cache_create_usercopy() exists])
   30         ],[
   31                 AC_MSG_RESULT(no)
   32         ])
   33 ])
   34 
   35 AC_DEFUN([ZFS_AC_KERNEL_SRC_KMEM_CACHE], [
   36         ZFS_AC_KERNEL_SRC_KMEM_CACHE_CREATE_USERCOPY
   37 ])
   38 
   39 AC_DEFUN([ZFS_AC_KERNEL_KMEM_CACHE], [
   40         ZFS_AC_KERNEL_KMEM_CACHE_CREATE_USERCOPY
   41 ])

Cache object: 913c3acaa351ea0f14c224b4a52921a4


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.