]> git.saurik.com Git - apple/xnu.git/blame - osfmk/kern/sync_lock.c
xnu-7195.50.7.100.1.tar.gz
[apple/xnu.git] / osfmk / kern / sync_lock.c
CommitLineData
1c79356b 1/*
6d2010ae 2 * Copyright (c) 2000-2009 Apple Inc. All rights reserved.
1c79356b 3 *
2d21ac55 4 * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
0a7de745 5 *
2d21ac55
A
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. The rights granted to you under the License
10 * may not be used to create, or enable the creation or redistribution of,
11 * unlawful or unlicensed copies of an Apple operating system, or to
12 * circumvent, violate, or enable the circumvention or violation of, any
13 * terms of an Apple operating system software license agreement.
0a7de745 14 *
2d21ac55
A
15 * Please obtain a copy of the License at
16 * http://www.opensource.apple.com/apsl/ and read it before using this file.
0a7de745 17 *
2d21ac55
A
18 * The Original Code and all software distributed under the License are
19 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
8f6c56a5
A
20 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
21 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
2d21ac55
A
22 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
23 * Please see the License for the specific language governing rights and
24 * limitations under the License.
0a7de745 25 *
2d21ac55 26 * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
1c79356b
A
27 */
28/*
29 * @OSF_COPYRIGHT@
0a7de745 30 *
1c79356b
A
31 */
32/*
33 * File: kern/sync_lock.c
34 * Author: Joseph CaraDonna
35 *
36 * Contains RT distributed lock synchronization services.
37 */
38
91447636
A
39#include <mach/mach_types.h>
40#include <mach/lock_set_server.h>
41#include <mach/task_server.h>
42
1c79356b
A
43#include <kern/misc_protos.h>
44#include <kern/sync_lock.h>
45#include <kern/sched_prim.h>
46#include <kern/ipc_kobject.h>
47#include <kern/ipc_sync.h>
1c79356b
A
48#include <kern/thread.h>
49#include <kern/task.h>
50
51#include <ipc/ipc_port.h>
52#include <ipc/ipc_space.h>
316670eb 53#include <libkern/OSAtomic.h>
1c79356b 54
b0d623f7
A
55
56
1c79356b 57/*
39236c6e 58 * OBSOLETE: lock set routines are obsolete
0a7de745 59 */
1c79356b 60kern_return_t
0a7de745
A
61lock_set_create(
62 __unused task_t task,
63 __unused lock_set_t *new_lock_set,
64 __unused int n_ulocks,
65 __unused int policy)
1c79356b 66{
39236c6e 67 return KERN_FAILURE;
1c79356b
A
68}
69
70kern_return_t
0a7de745 71lock_set_destroy(
39236c6e
A
72 __unused task_t task,
73 __unused lock_set_t lock_set)
1c79356b 74{
39236c6e 75 return KERN_FAILURE;
1c79356b
A
76}
77
78kern_return_t
0a7de745 79lock_acquire(
39236c6e
A
80 __unused lock_set_t lock_set,
81 __unused int lock_id)
1c79356b 82{
39236c6e 83 return KERN_FAILURE;
1c79356b
A
84}
85
86kern_return_t
0a7de745 87lock_release(
39236c6e
A
88 __unused lock_set_t lock_set,
89 __unused int lock_id)
1c79356b 90{
39236c6e 91 return KERN_FAILURE;
1c79356b
A
92}
93
1c79356b 94kern_return_t
0a7de745 95lock_try(
39236c6e
A
96 __unused lock_set_t lock_set,
97 __unused int lock_id)
1c79356b 98{
0a7de745 99 return KERN_FAILURE;
1c79356b
A
100}
101
1c79356b 102kern_return_t
0a7de745 103lock_make_stable(
39236c6e
A
104 __unused lock_set_t lock_set,
105 __unused int lock_id)
1c79356b 106{
0a7de745 107 return KERN_FAILURE;
1c79356b
A
108}
109
110kern_return_t
0a7de745 111lock_handoff(
39236c6e
A
112 __unused lock_set_t lock_set,
113 __unused int lock_id)
1c79356b 114{
91447636 115 return KERN_FAILURE;
1c79356b
A
116}
117
118kern_return_t
0a7de745 119lock_handoff_accept(
39236c6e
A
120 __unused lock_set_t lock_set,
121 __unused int lock_id)
1c79356b 122{
91447636 123 return KERN_FAILURE;
1c79356b
A
124}
125
1c79356b 126void
39236c6e
A
127lock_set_reference(
128 __unused lock_set_t lock_set)
1c79356b 129{
39236c6e 130 return;
1c79356b
A
131}
132
1c79356b 133void
39236c6e
A
134lock_set_dereference(
135 __unused lock_set_t lock_set)
1c79356b 136{
39236c6e 137 return;
91447636 138}