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

Side by Side Diff: native_client_sdk/src/libraries/nacl_io/kernel_object.h

Issue 304013002: [NaCl SDK] Create Filesystem nodes in /dev/fs/... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef LIBRARIES_NACL_IO_KERNEL_OBJECT_H_ 5 #ifndef LIBRARIES_NACL_IO_KERNEL_OBJECT_H_
6 #define LIBRARIES_NACL_IO_KERNEL_OBJECT_H_ 6 #define LIBRARIES_NACL_IO_KERNEL_OBJECT_H_
7 7
8 #include <pthread.h> 8 #include <pthread.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 typedef std::vector<Descriptor_t> HandleMap_t; 42 typedef std::vector<Descriptor_t> HandleMap_t;
43 typedef std::map<std::string, ScopedFilesystem> FsMap_t; 43 typedef std::map<std::string, ScopedFilesystem> FsMap_t;
44 44
45 KernelObject(); 45 KernelObject();
46 virtual ~KernelObject(); 46 virtual ~KernelObject();
47 47
48 // Attach the given Filesystem object at the specified path. 48 // Attach the given Filesystem object at the specified path.
49 Error AttachFsAtPath(const ScopedFilesystem& fs, const std::string& path); 49 Error AttachFsAtPath(const ScopedFilesystem& fs, const std::string& path);
50 50
51 // Unmap the Filesystem object from the specified path and release it. 51 // Unmap the Filesystem object from the specified path and release it.
52 Error DetachFsAtPath(const std::string& path); 52 Error DetachFsAtPath(const std::string& path, ScopedFilesystem* out_fs);
53 53
54 // Find the filesystem for the given path, and acquires it and return a 54 // Find the filesystem for the given path, and acquires it and return a
55 // path relative to the filesystem. 55 // path relative to the filesystem.
56 // Assumes |out_fs| and |rel_path| are non-NULL. 56 // Assumes |out_fs| and |rel_path| are non-NULL.
57 Error AcquireFsAndRelPath(const std::string& path, 57 Error AcquireFsAndRelPath(const std::string& path,
58 ScopedFilesystem* out_fs, 58 ScopedFilesystem* out_fs,
59 Path* rel_path); 59 Path* rel_path);
60 60
61 // Find the filesystem and node for the given path, acquiring/creating it as 61 // Find the filesystem and node for the given path, acquiring/creating it as
62 // specified by the |oflags|. 62 // specified by the |oflags|.
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 109
110 // Lock to protect cwd_. 110 // Lock to protect cwd_.
111 sdk_util::SimpleLock cwd_lock_; 111 sdk_util::SimpleLock cwd_lock_;
112 112
113 DISALLOW_COPY_AND_ASSIGN(KernelObject); 113 DISALLOW_COPY_AND_ASSIGN(KernelObject);
114 }; 114 };
115 115
116 } // namespace nacl_io 116 } // namespace nacl_io
117 117
118 #endif // LIBRARIES_NACL_IO_KERNEL_OBJECT_H_ 118 #endif // LIBRARIES_NACL_IO_KERNEL_OBJECT_H_
OLDNEW
« no previous file with comments | « native_client_sdk/src/libraries/nacl_io/filesystem.cc ('k') | native_client_sdk/src/libraries/nacl_io/kernel_object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698