1// Copyright 2013 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef COMPONENTS_NACL_LOADER_NACL_HELPER_LINUX_H_
6#define COMPONENTS_NACL_LOADER_NACL_HELPER_LINUX_H_
7
8namespace nacl {
9
10// A mini-zygote specifically for Native Client. This file defines
11// constants used to implement communication between the nacl_helper
12// process and the Chrome zygote.
13
14#define kNaClMaxIPCMessageLength 2048
15
16// Used by Helper to tell Zygote it has started successfully.
17#define kNaClHelperStartupAck "NACLHELPER_OK"
18
19enum NaClZygoteIPCCommand {
20  kNaClForkRequest,
21  kNaClGetTerminationStatusRequest,
22};
23
24// The next set of constants define global Linux file descriptors.
25// For communications between NaCl loader and browser.
26// See also content/common/zygote_main_linux.cc and
27// http://code.google.com/p/chromium/wiki/LinuxZygote
28
29// For communications between NaCl loader and zygote.
30#define kNaClZygoteDescriptor 3
31
32} // namespace nacl
33
34#endif  // COMPONENTS_NACL_LOADER_NACL_HELPER_LINUX_H_
35