1 : /*
2 : * Copyright (c) 2012 The Native Client Authors. All rights reserved.
3 : * Use of this source code is governed by a BSD-style license that can be
4 : * found in the LICENSE file.
5 : */
6 :
7 : /*
8 : * Gather ye all module initializations and finalizations here.
9 : */
10 : #include "native_client/src/shared/srpc/nacl_srpc.h"
11 : #include "native_client/src/trusted/debug_stub/debug_stub.h"
12 : #include "native_client/src/trusted/desc/nrd_all_modules.h"
13 : #include "native_client/src/trusted/fault_injection/fault_injection.h"
14 : #include "native_client/src/trusted/service_runtime/nacl_globals.h"
15 : #include "native_client/src/trusted/service_runtime/nacl_syscall_handlers.h"
16 : #include "native_client/src/trusted/service_runtime/nacl_thread_nice.h"
17 : #include "native_client/src/trusted/service_runtime/nacl_tls.h"
18 : #include "native_client/src/trusted/service_runtime/nacl_stack_safety.h"
19 :
20 293 : void NaClAllModulesInit(void) {
21 293 : NaClNrdAllModulesInit();
22 293 : NaClFaultInjectionModuleInit();
23 293 : NaClGlobalModuleInit(); /* various global variables */
24 293 : NaClSrpcModuleInit();
25 293 : NaClTlsInit();
26 293 : NaClSyscallTableInit();
27 293 : NaClThreadNiceInit();
28 293 : }
29 :
30 :
31 11 : void NaClAllModulesFini(void) {
32 11 : NaClTlsFini();
33 11 : NaClSrpcModuleFini();
34 11 : NaClGlobalModuleFini();
35 11 : NaClNrdAllModulesFini();
36 11 : }
|