OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "mojo/edk/embedder/entrypoints.h" | 5 #include "mojo/edk/embedder/entrypoints.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include "mojo/edk/embedder/embedder_internal.h" | 9 #include "mojo/edk/embedder/embedder_internal.h" |
10 #include "mojo/edk/system/core.h" | 10 #include "mojo/edk/system/core.h" |
(...skipping 10 matching lines...) Expand all Loading... |
21 extern "C" { | 21 extern "C" { |
22 | 22 |
23 MojoTimeTicks MojoGetTimeTicksNowImpl() { | 23 MojoTimeTicks MojoGetTimeTicksNowImpl() { |
24 return g_core->GetTimeTicksNow(); | 24 return g_core->GetTimeTicksNow(); |
25 } | 25 } |
26 | 26 |
27 MojoResult MojoCloseImpl(MojoHandle handle) { | 27 MojoResult MojoCloseImpl(MojoHandle handle) { |
28 return g_core->Close(handle); | 28 return g_core->Close(handle); |
29 } | 29 } |
30 | 30 |
31 MojoResult MojoQueryHandleSignalsStateImpl( | |
32 MojoHandle handle, | |
33 MojoHandleSignalsState* signals_state) { | |
34 return g_core->QueryHandleSignalsState(handle, signals_state); | |
35 } | |
36 | |
37 MojoResult MojoWaitImpl(MojoHandle handle, | 31 MojoResult MojoWaitImpl(MojoHandle handle, |
38 MojoHandleSignals signals, | 32 MojoHandleSignals signals, |
39 MojoDeadline deadline, | 33 MojoDeadline deadline, |
40 MojoHandleSignalsState* signals_state) { | 34 MojoHandleSignalsState* signals_state) { |
41 return g_core->Wait(handle, signals, deadline, signals_state); | 35 return g_core->Wait(handle, signals, deadline, signals_state); |
42 } | 36 } |
43 | 37 |
44 MojoResult MojoWaitManyImpl(const MojoHandle* handles, | 38 MojoResult MojoWaitManyImpl(const MojoHandle* handles, |
45 const MojoHandleSignals* signals, | 39 const MojoHandleSignals* signals, |
46 uint32_t num_handles, | 40 uint32_t num_handles, |
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
280 | 274 |
281 } // extern "C" | 275 } // extern "C" |
282 | 276 |
283 namespace mojo { | 277 namespace mojo { |
284 namespace edk { | 278 namespace edk { |
285 | 279 |
286 MojoSystemThunks MakeSystemThunks() { | 280 MojoSystemThunks MakeSystemThunks() { |
287 MojoSystemThunks system_thunks = {sizeof(MojoSystemThunks), | 281 MojoSystemThunks system_thunks = {sizeof(MojoSystemThunks), |
288 MojoGetTimeTicksNowImpl, | 282 MojoGetTimeTicksNowImpl, |
289 MojoCloseImpl, | 283 MojoCloseImpl, |
290 MojoQueryHandleSignalsStateImpl, | |
291 MojoWaitImpl, | 284 MojoWaitImpl, |
292 MojoWaitManyImpl, | 285 MojoWaitManyImpl, |
293 MojoCreateMessagePipeImpl, | 286 MojoCreateMessagePipeImpl, |
294 MojoWriteMessageImpl, | 287 MojoWriteMessageImpl, |
295 MojoReadMessageImpl, | 288 MojoReadMessageImpl, |
296 MojoCreateDataPipeImpl, | 289 MojoCreateDataPipeImpl, |
297 MojoWriteDataImpl, | 290 MojoWriteDataImpl, |
298 MojoBeginWriteDataImpl, | 291 MojoBeginWriteDataImpl, |
299 MojoEndWriteDataImpl, | 292 MojoEndWriteDataImpl, |
300 MojoReadDataImpl, | 293 MojoReadDataImpl, |
(...skipping 21 matching lines...) Expand all Loading... |
322 MojoUnwrapPlatformHandleImpl, | 315 MojoUnwrapPlatformHandleImpl, |
323 MojoWrapPlatformSharedBufferHandleImpl, | 316 MojoWrapPlatformSharedBufferHandleImpl, |
324 MojoUnwrapPlatformSharedBufferHandleImpl, | 317 MojoUnwrapPlatformSharedBufferHandleImpl, |
325 MojoNotifyBadMessageImpl, | 318 MojoNotifyBadMessageImpl, |
326 MojoGetPropertyImpl}; | 319 MojoGetPropertyImpl}; |
327 return system_thunks; | 320 return system_thunks; |
328 } | 321 } |
329 | 322 |
330 } // namespace edk | 323 } // namespace edk |
331 } // namespace mojo | 324 } // namespace mojo |
OLD | NEW |