Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(542)

Side by Side Diff: src/trusted/service_runtime/sel_ldr.h

Issue 7108031: this patch adds the manifest proxy server to sel_ldr and the manifest (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client/
Patch Set: '' Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2011 The Native Client Authors. All rights reserved. 2 * Copyright (c) 2011 The Native Client Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be 3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file. 4 * found in the LICENSE file.
5 */ 5 */
6 6
7 /* 7 /*
8 * NaCl Simple/secure ELF loader (NaCl SEL). 8 * NaCl Simple/secure ELF loader (NaCl SEL).
9 * 9 *
10 * This loader can only process NaCl object files as produced using 10 * This loader can only process NaCl object files as produced using
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 } \ 67 } \
68 } while (0) 68 } while (0)
69 #else 69 #else
70 #define WINDOWS_EXCEPTION_TRY do { 70 #define WINDOWS_EXCEPTION_TRY do {
71 #define WINDOWS_EXCEPTION_CATCH } while (0) 71 #define WINDOWS_EXCEPTION_CATCH } while (0)
72 #endif 72 #endif
73 73
74 struct NaClAppThread; 74 struct NaClAppThread;
75 struct NaClDesc; /* see native_client/src/trusted/desc/nacl_desc_base.h */ 75 struct NaClDesc; /* see native_client/src/trusted/desc/nacl_desc_base.h */
76 struct NaClDynamicRegion; 76 struct NaClDynamicRegion;
77 struct NaClManifestProxy;
77 struct NaClSecureService; 78 struct NaClSecureService;
78 struct NaClSecureReverseService; 79 struct NaClSecureReverseService;
80 struct NaClThreadInterface; /* see sel_ldr_thread_interface.h */
79 81
80 struct NaClDebugCallbacks { 82 struct NaClDebugCallbacks {
81 void (*thread_create_hook)(struct NaClAppThread *natp); 83 void (*thread_create_hook)(struct NaClAppThread *natp);
82 void (*thread_exit_hook)(struct NaClAppThread *natp); 84 void (*thread_exit_hook)(struct NaClAppThread *natp);
83 void (*process_exit_hook)(int exit_status); 85 void (*process_exit_hook)(int exit_status);
84 }; 86 };
85 87
86 struct NaClApp { 88 struct NaClApp {
87 /* 89 /*
88 * public, user settable prior to app start. 90 * public, user settable prior to app start.
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 int threads_launching; 209 int threads_launching;
208 210
209 /* 211 /*
210 * Name service must launch after mu, cv, vm_hole_may_exit, 212 * Name service must launch after mu, cv, vm_hole_may_exit,
211 * threads_launching are initialized. 213 * threads_launching are initialized.
212 */ 214 */
213 struct NaClNameService *name_service; /* default name server */ 215 struct NaClNameService *name_service; /* default name server */
214 struct NaClDesc *name_service_conn_cap; 216 struct NaClDesc *name_service_conn_cap;
215 217
216 struct NaClSecureService *secure_service; 218 struct NaClSecureService *secure_service;
219 struct NaClThread reverse_setup_thread;
220 /* used only during setup, thread dtors before exiting */
221 struct NaClManifestProxy *manifest_proxy;
217 struct NaClSecureReverseClient *reverse_client; 222 struct NaClSecureReverseClient *reverse_client;
218 int reverse_channel_initialized; 223 int reverse_channel_initialized;
219 NaClSrpcChannel reverse_channel; 224 NaClSrpcChannel reverse_channel;
220 225
221 NaClErrorCode module_load_status; 226 NaClErrorCode module_load_status;
222 int module_may_start; 227 int module_may_start;
223 228
224 /* 229 /*
225 * runtime info below, thread state, etc; initialized only when app 230 * runtime info below, thread state, etc; initialized only when app
226 * is run. Mutex mu protects access to mem_map and other member 231 * is run. Mutex mu protects access to mem_map and other member
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after
526 uintptr_t NaClAppVmmapFindMapSpace(struct NaClApp *nap, 531 uintptr_t NaClAppVmmapFindMapSpace(struct NaClApp *nap,
527 int num_pages); 532 int num_pages);
528 533
529 void NaClCreateServiceSocket(struct NaClApp *nap); 534 void NaClCreateServiceSocket(struct NaClApp *nap);
530 535
531 void NaClSendServiceAddressTo(struct NaClApp *nap, 536 void NaClSendServiceAddressTo(struct NaClApp *nap,
532 int desc); 537 int desc);
533 538
534 void NaClSecureCommandChannel(struct NaClApp *nap); 539 void NaClSecureCommandChannel(struct NaClApp *nap);
535 540
541 int NaClSecureReverseClientInsertHandler(
542 struct NaClSecureReverseClient *self,
543 void (*handler)(
544 void *handler_state,
noelallen_use_chromium 2011/06/14 02:25:45 nit: Should these param names be intented to align
bsy 2011/06/14 20:30:03 sure, that would make it more readable and less li
545 struct NaClThreadInterface *thread_if,
546 struct NaClDesc *new_conn),
547 void *handler_state);
548
536 NaClErrorCode NaClWaitForLoadModuleStatus(struct NaClApp *nap) NACL_WUR; 549 NaClErrorCode NaClWaitForLoadModuleStatus(struct NaClApp *nap) NACL_WUR;
537 550
538 NaClErrorCode NaClWaitForStartModuleCommand(struct NaClApp *nap) NACL_WUR; 551 NaClErrorCode NaClWaitForStartModuleCommand(struct NaClApp *nap) NACL_WUR;
539 552
540 void NaClFillMemoryRegionWithHalt(void *start, size_t size); 553 void NaClFillMemoryRegionWithHalt(void *start, size_t size);
541 554
542 void NaClFillTrampolineRegion(struct NaClApp *nap); 555 void NaClFillTrampolineRegion(struct NaClApp *nap);
543 556
544 void NaClFillEndOfTextRegion(struct NaClApp *nap); 557 void NaClFillEndOfTextRegion(struct NaClApp *nap);
545 558
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
601 614
602 void NaClVmHoleWaitToStartThread(struct NaClApp *nap); 615 void NaClVmHoleWaitToStartThread(struct NaClApp *nap);
603 616
604 void NaClVmHoleThreadStackIsSafe(struct NaClApp *nap); 617 void NaClVmHoleThreadStackIsSafe(struct NaClApp *nap);
605 618
606 void NaClGdbHook(struct NaClApp const *nap); 619 void NaClGdbHook(struct NaClApp const *nap);
607 620
608 EXTERN_C_END 621 EXTERN_C_END
609 622
610 #endif /* NATIVE_CLIENT_SRC_TRUSTED_SERVICE_RUNTIME_SEL_LDR_H_ */ 623 #endif /* NATIVE_CLIENT_SRC_TRUSTED_SERVICE_RUNTIME_SEL_LDR_H_ */
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698