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/include/os/linux/spl/sys/zone.h

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 /*
    2  *  Copyright (C) 2007-2010 Lawrence Livermore National Security, LLC.
    3  *  Copyright (C) 2007 The Regents of the University of California.
    4  *  Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER).
    5  *  Written by Brian Behlendorf <behlendorf1@llnl.gov>.
    6  *  UCRL-CODE-235197
    7  *
    8  *  This file is part of the SPL, Solaris Porting Layer.
    9  *
   10  *  The SPL is free software; you can redistribute it and/or modify it
   11  *  under the terms of the GNU General Public License as published by the
   12  *  Free Software Foundation; either version 2 of the License, or (at your
   13  *  option) any later version.
   14  *
   15  *  The SPL is distributed in the hope that it will be useful, but WITHOUT
   16  *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
   17  *  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
   18  *  for more details.
   19  *
   20  *  You should have received a copy of the GNU General Public License along
   21  *  with the SPL.  If not, see <http://www.gnu.org/licenses/>.
   22  */
   23 
   24 #ifndef _SPL_ZONE_H
   25 #define _SPL_ZONE_H
   26 
   27 #include <sys/byteorder.h>
   28 #include <sys/cred.h>
   29 
   30 #include <linux/cred.h>
   31 #include <linux/user_namespace.h>
   32 
   33 /*
   34  * Attach the given dataset to the given user namespace.
   35  */
   36 extern int zone_dataset_attach(cred_t *, const char *, int);
   37 
   38 /*
   39  * Detach the given dataset from the given user namespace.
   40  */
   41 extern int zone_dataset_detach(cred_t *, const char *, int);
   42 
   43 /*
   44  * Returns true if the named pool/dataset is visible in the current zone.
   45  */
   46 extern int zone_dataset_visible(const char *dataset, int *write);
   47 
   48 int spl_zone_init(void);
   49 void spl_zone_fini(void);
   50 
   51 extern unsigned int crgetzoneid(const cred_t *);
   52 extern unsigned int global_zoneid(void);
   53 extern boolean_t inglobalzone(proc_t *);
   54 
   55 #define INGLOBALZONE(x) inglobalzone(x)
   56 #define GLOBAL_ZONEID   global_zoneid()
   57 
   58 #endif /* SPL_ZONE_H */

Cache object: af6f7e6e381ebb1cbd2d1fb61751e6ba


[ 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.