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

Side by Side Diff: mojo/nacl/generator/libmojo.cc.tmpl

Issue 846443006: Include Mojo SDK/EDK via fully-qualified paths in Chromium code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix include to satisfy checkdeps Created 5 years, 11 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
« no previous file with comments | « mojo/environment/environment.cc ('k') | mojo/nacl/generator/mojo_syscall.cc.tmpl » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 {{generator_warning}} 5 {{generator_warning}}
6 6
7 #include "mojo/public/c/system/core.h"
8 #include "native_client/src/public/chrome_main.h" 7 #include "native_client/src/public/chrome_main.h"
9 #include "native_client/src/public/imc_syscalls.h" 8 #include "native_client/src/public/imc_syscalls.h"
10 #include "native_client/src/public/imc_types.h" 9 #include "native_client/src/public/imc_types.h"
10 #include "third_party/mojo/src/mojo/public/c/system/core.h"
11 11
12 // The value for this FD must not conflict with uses inside Chromium. However, 12 // The value for this FD must not conflict with uses inside Chromium. However,
13 // mojo/nacl doesn't depend on any Chromium headers, so we can't use a #define 13 // mojo/nacl doesn't depend on any Chromium headers, so we can't use a #define
14 // from there. 14 // from there.
15 #define NACL_MOJO_DESC (NACL_CHROME_DESC_BASE + 3) 15 #define NACL_MOJO_DESC (NACL_CHROME_DESC_BASE + 3)
16 16
17 static void DoMojoCall(uint32_t params[], nacl_abi_size_t num_params) { 17 static void DoMojoCall(uint32_t params[], nacl_abi_size_t num_params) {
18 NaClAbiNaClImcMsgIoVec iov[1] = { 18 NaClAbiNaClImcMsgIoVec iov[1] = {
19 {params, num_params} 19 {params, num_params}
20 }; 20 };
21 NaClAbiNaClImcMsgHdr msgh = {iov, 1, NULL, 0}; 21 NaClAbiNaClImcMsgHdr msgh = {iov, 1, NULL, 0};
22 // Note: return value unchecked. We're relying on the result parameter being 22 // Note: return value unchecked. We're relying on the result parameter being
23 // unmodified - if the syscall fails, the Mojo function will return whatever 23 // unmodified - if the syscall fails, the Mojo function will return whatever
24 // the result parameter was initialized to before this function was called. 24 // the result parameter was initialized to before this function was called.
25 imc_sendmsg(NACL_MOJO_DESC, &msgh, 0); 25 imc_sendmsg(NACL_MOJO_DESC, &msgh, 0);
26 } 26 }
27 27
28 {{body}} 28 {{body}}
OLDNEW
« no previous file with comments | « mojo/environment/environment.cc ('k') | mojo/nacl/generator/mojo_syscall.cc.tmpl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698