]> git.saurik.com Git - apple/xnu.git/blobdiff - bsd/sys/ubc_internal.h
xnu-2422.90.20.tar.gz
[apple/xnu.git] / bsd / sys / ubc_internal.h
index d7197f089707ffe87193b9d9db0221cfc5c285d3..dbc19de88b4f3fe0d9348e3b606e178b68ea12bc 100644 (file)
@@ -101,6 +101,7 @@ struct cs_blob {
        cpu_type_t      csb_cpu_type;
        unsigned int    csb_flags;
        off_t           csb_base_offset;        /* Offset of Mach-O binary in fat binary */
        cpu_type_t      csb_cpu_type;
        unsigned int    csb_flags;
        off_t           csb_base_offset;        /* Offset of Mach-O binary in fat binary */
+       off_t           csb_blob_offset;        /* offset of blob itself, from csb_base_offset */
        off_t           csb_start_offset;       /* Blob coverage area start, from csb_base_offset */
        off_t           csb_end_offset;         /* Blob coverage area end, from csb_base_offset */
        ipc_port_t      csb_mem_handle;
        off_t           csb_start_offset;       /* Blob coverage area start, from csb_base_offset */
        off_t           csb_end_offset;         /* Blob coverage area end, from csb_base_offset */
        ipc_port_t      csb_mem_handle;
@@ -108,6 +109,7 @@ struct cs_blob {
        vm_offset_t     csb_mem_offset;
        vm_address_t    csb_mem_kaddr;
        unsigned char   csb_sha1[SHA1_RESULTLEN];
        vm_offset_t     csb_mem_offset;
        vm_address_t    csb_mem_kaddr;
        unsigned char   csb_sha1[SHA1_RESULTLEN];
+       unsigned int    csb_sigpup;
 };
 
 /*
 };
 
 /*
@@ -125,6 +127,8 @@ struct ubc_info {
         struct cl_readahead   *cl_rahead;      /* cluster read ahead context */
         struct cl_writebehind *cl_wbehind;     /* cluster write behind context */
 
         struct cl_readahead   *cl_rahead;      /* cluster read ahead context */
         struct cl_writebehind *cl_wbehind;     /* cluster write behind context */
 
+       struct timespec         cs_mtime;       /* modify time of file when
+                                                  first cs_blob was loaded */
        struct  cs_blob         *cs_blobs;      /* for CODE SIGNING */
 #if CHECK_CS_VALIDATION_BITMAP
        void                    *cs_valid_bitmap;     /* right now: used only for signed files on the read-only root volume */
        struct  cs_blob         *cs_blobs;      /* for CODE SIGNING */
 #if CHECK_CS_VALIDATION_BITMAP
        void                    *cs_valid_bitmap;     /* right now: used only for signed files on the read-only root volume */
@@ -150,7 +154,7 @@ struct ubc_info {
  */
 
 __BEGIN_DECLS
  */
 
 __BEGIN_DECLS
-__private_extern__ void ubc_init(void) __attribute__((section("__TEXT, initcode")));;
+__private_extern__ void ubc_init(void);
 __private_extern__ int ubc_umount(mount_t mp);
 __private_extern__ void        ubc_unmountall(void);
 __private_extern__ memory_object_t ubc_getpager(vnode_t);
 __private_extern__ int ubc_umount(mount_t mp);
 __private_extern__ void        ubc_unmountall(void);
 __private_extern__ memory_object_t ubc_getpager(vnode_t);
@@ -159,7 +163,7 @@ __private_extern__ void     ubc_destroy_named(vnode_t);
 /* internal only */
 __private_extern__ void        cluster_release(struct ubc_info *);
 __private_extern__ uint32_t cluster_max_io_size(mount_t, int);
 /* internal only */
 __private_extern__ void        cluster_release(struct ubc_info *);
 __private_extern__ uint32_t cluster_max_io_size(mount_t, int);
-__private_extern__ uint32_t cluster_hard_throttle_limit(vnode_t, uint32_t *, uint32_t);
+__private_extern__ uint32_t cluster_throttle_io_limit(vnode_t, uint32_t *);
 
 
 /* Flags for ubc_getobject() */
 
 
 /* Flags for ubc_getobject() */
@@ -185,8 +189,10 @@ int UBCINFOEXISTS(vnode_t);
 
 /* code signing */
 struct cs_blob;
 
 /* code signing */
 struct cs_blob;
-int    ubc_cs_blob_add(vnode_t, cpu_type_t, off_t, vm_address_t, vm_size_t);
+int    ubc_cs_blob_add(vnode_t, cpu_type_t, off_t, vm_address_t, off_t, vm_size_t);
+int    ubc_cs_sigpup_add(vnode_t, vm_address_t, vm_size_t);
 struct cs_blob *ubc_get_cs_blobs(vnode_t);
 struct cs_blob *ubc_get_cs_blobs(vnode_t);
+void   ubc_get_cs_mtime(vnode_t, struct timespec *);
 int    ubc_cs_getcdhash(vnode_t, off_t, unsigned char *);
 kern_return_t ubc_cs_blob_allocate(vm_offset_t *, vm_size_t *);
 void ubc_cs_blob_deallocate(vm_offset_t, vm_size_t);
 int    ubc_cs_getcdhash(vnode_t, off_t, unsigned char *);
 kern_return_t ubc_cs_blob_allocate(vm_offset_t *, vm_size_t *);
 void ubc_cs_blob_deallocate(vm_offset_t, vm_size_t);