/frameworks/base/services/core/java/com/android/server/am/ |
H A D | NativeCrashListener.java | 175 static int readExactly(FileDescriptor fd, byte[] buffer, int offset, int numBytes) argument 179 int n = Os.read(fd, buffer, offset + totalRead, numBytes); 193 void consumeNativeCrashData(FileDescriptor fd) { argument 200 Os.setsockoptTimeval(fd, SOL_SOCKET, SO_RCVTIMEO, timeout); 201 Os.setsockoptTimeval(fd, SOL_SOCKET, SO_SNDTIMEO, timeout); 208 int headerBytes = readExactly(fd, buf, 0, 8); 239 bytes = Os.read(fd, buf, 0, buf.length);
|
/frameworks/base/services/net/java/android/net/ip/ |
H A D | IpNeighborMonitor.java | 149 FileDescriptor fd = null; 152 fd = NetlinkSocket.forProto(OsConstants.NETLINK_ROUTE); 153 Os.bind(fd, (SocketAddress)(new NetlinkSocketAddress(0, OsConstants.RTMGRP_NEIGH))); 154 Os.connect(fd, (SocketAddress)(new NetlinkSocketAddress(0, 0))); 157 final NetlinkSocketAddress nlAddr = (NetlinkSocketAddress) Os.getsockname(fd); 165 IoUtils.closeQuietly(fd); 169 return fd;
|
/frameworks/native/cmds/cmd/ |
H A D | cmd.cpp | 97 int fd = open(fullPath.string(), flags, S_IRWXU|S_IRWXG); local 99 ALOGD("openFile: fd=%d", fd); 101 if (fd < 0) { 102 return fd; 116 close(fd); 130 close(fd); 138 return fd;
|
/frameworks/av/cmds/stagefright/ |
H A D | stream.cpp | 50 // Object assumes ownership of fd. 51 explicit MyStreamSource(int fd); 72 MyStreamSource::MyStreamSource(int fd) argument 73 : mFd(fd), 76 CHECK_GE(fd, 0); 78 mFileSize = lseek64(fd, 0, SEEK_END); 79 lseek64(fd, 0, SEEK_SET); 367 int fd = open(argv[1], O_RDONLY); local 369 if (fd < 0) { 374 source = new MyStreamSource(fd); [all...] |
H A D | audioloop.cpp | 147 int fd = open(fileOut, O_CREAT | O_LARGEFILE | O_TRUNC | O_RDWR, S_IRUSR | S_IWUSR); local 148 if (fd < 0) { 151 sp<AMRWriter> writer = new AMRWriter(fd); 152 close(fd);
|
/frameworks/base/tests/touchlag/ |
H A D | touchlag.cpp | 142 int fd; member in class:TouchEvents::EventThread 148 read(fd, &event, sizeof(event)); 170 fd = open("/dev/input/event1", O_RDONLY); 224 int fd = open("/dev/graphics/fb0", O_RDWR); local 225 ioctl(fd, FBIOGET_VSCREENINFO, &vi); 226 ioctl(fd, FBIOGET_FSCREENINFO, &fi); 227 void* bits = mmap(0, fi.smem_len, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); 260 ioctl(fd, FBIO_WAITFORVSYNC, &crt); 292 close(fd);
|
/frameworks/ml/nn/runtime/test/ |
H A D | TestMemoryInternal.cpp | 181 int fd = ASharedMemory_create(nullptr, size); local 182 ASSERT_GE(fd, 0); 184 uint8_t* buf = (uint8_t*)mmap(nullptr, size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); 195 WrapperMemory mem(size, PROT_READ | PROT_WRITE, fd, 0); 207 close(fd); 213 int fd = ASharedMemory_create(nullptr, size); local 214 ASSERT_GE(fd, 0); 215 WrapperMemory mem(size, PROT_READ | PROT_WRITE, fd, 0); 222 close(fd);
|
/frameworks/native/libs/binder/ |
H A D | ProcessState.cpp | 383 int fd = open(driver, O_RDWR | O_CLOEXEC); local 384 if (fd >= 0) { 386 status_t result = ioctl(fd, BINDER_VERSION, &vers); 389 close(fd); 390 fd = -1; 395 close(fd); 396 fd = -1; 399 result = ioctl(fd, BINDER_SET_MAX_THREADS, &maxThreads); 406 return fd;
|
/frameworks/av/media/mtp/ |
H A D | MtpServer.h | 90 MtpObjectFormat format, int fd) 91 : mHandle(handle), mPath(path), mSize(size), mFormat(format), mFD(fd) { 126 uint64_t size, MtpObjectFormat format, int fd); 89 ObjectEdit(MtpObjectHandle handle, const char* path, uint64_t size, MtpObjectFormat format, int fd) argument
|
/frameworks/base/core/java/android/os/ |
H A D | FileObserver.java | 131 private native void observe(int fd); argument 132 private native int startWatching(int fd, String path, int mask); argument 133 private native void stopWatching(int fd, int wfd); argument
|
/frameworks/base/core/jni/ |
H A D | android_backup_BackupDataInput.cpp | 37 int fd = jniGetFDFromFileDescriptor(env, fileDescriptor); local 38 if (fd == -1) { 42 return (jlong)new BackupDataReader(fd);
|
H A D | com_android_internal_content_NativeLibraryHelper.cpp | 127 int fd = TEMP_FAILURE_RETRY(open(filePath, O_RDONLY)); local 128 if (fd < 0) { 138 while ((numBytes = TEMP_FAILURE_RETRY(read(fd, crcBuffer, sizeof(crcBuffer)))) > 0) { 141 close(fd); 252 int fd = mkstemp(localTmpFileName); local 253 if (fd < 0) { 258 if (!zipFile->uncompressEntry(zipEntry, fd)) { 260 close(fd); 265 close(fd); 564 int fd local [all...] |
H A D | android_util_Process.cpp | 217 int fd; local 222 fd = open(proc_path, O_RDONLY | O_CLOEXEC); 223 if (fd >= 0) { 224 int rc = read(fd, cmdline, sizeof(cmdline)-1); 226 close(fd); 558 int fd = open(text, O_WRONLY | O_CLOEXEC); local 559 if (fd >= 0) { 561 write(fd, text, strlen(text)); 562 close(fd); 606 int fd local 719 int fd = open(file.string(), O_RDONLY | O_CLOEXEC); local 1026 int fd = open(file8, O_RDONLY | O_CLOEXEC); local 1160 int fd = open(path, O_RDONLY | O_CLOEXEC); local [all...] |
/frameworks/base/graphics/java/android/graphics/ |
H A D | BitmapRegionDecoder.java | 74 * @param fd The file descriptor containing the data to decode 86 FileDescriptor fd, boolean isShareable) throws IOException { 87 return nativeNewInstance(fd, isShareable); 273 FileDescriptor fd, boolean isShareable); 85 newInstance( FileDescriptor fd, boolean isShareable) argument 272 nativeNewInstance( FileDescriptor fd, boolean isShareable) argument
|
/frameworks/base/libs/androidfw/include/androidfw/ |
H A D | BackupHelpers.h | 70 BackupDataWriter(int fd); 71 // does not close fd 107 BackupDataReader(int fd); 108 // does not close fd 150 status_t WriteSnapshot(int fd);
|
/frameworks/base/libs/hwui/hwui/ |
H A D | Bitmap.cpp | 106 int fd = ashmem_create_region("bitmap", size); local 107 if (fd < 0) { 111 void* addr = mmap(NULL, size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); 113 close(fd); 117 if (ashmem_set_prot_region(fd, PROT_READ) < 0) { 119 close(fd); 122 return sk_sp<Bitmap>(new Bitmap(addr, fd, size, info, rowBytes)); 191 Bitmap::Bitmap(void* address, int fd, size_t mappedSize, const SkImageInfo& info, size_t rowBytes) argument 196 mPixelStorage.ashmem.fd = fd; [all...] |
/frameworks/native/cmds/installd/tests/ |
H A D | test_utils.h | 84 int fd = open(file.c_str(), O_WRONLY | O_CREAT, S_IRUSR | S_IWUSR); local 86 if (fd < 0) { 93 ssize_t cur = write(fd, bytes.get() + wrote, length - wrote);
|
/frameworks/av/services/audiopolicy/common/managerdefinitions/src/ |
H A D | AudioOutputDescriptor.cpp | 187 status_t AudioOutputDescriptor::dump(int fd) argument 210 write(fd, result.string(), result.size()); 235 status_t SwAudioOutputDescriptor::dump(int fd) argument 245 write(fd, result.string(), result.size()); 247 AudioOutputDescriptor::dump(fd); 544 status_t HwAudioOutputDescriptor::dump(int fd) argument 550 AudioOutputDescriptor::dump(fd); 554 write(fd, result.string(), result.size()); 555 mSource->dump(fd); 718 status_t SwAudioOutputCollection::dump(int fd) cons [all...] |
/frameworks/native/services/inputflinger/ |
H A D | EventHub.cpp | 144 EventHub::Device::Device(int fd, int32_t id, const String8& path, argument 147 fd(fd), id(id), path(path), identifier(identifier), 151 isVirtual(fd < 0) { 168 if (fd >= 0) { 169 ::close(fd); 170 fd = -1; 175 fd = open(path, O_RDWR | O_CLOEXEC | O_NONBLOCK); 176 if(fd < 0) { 308 if(ioctl(device->fd, EVIOCGAB 1115 int fd = open(devicePath, O_RDWR | O_CLOEXEC | O_NONBLOCK); local [all...] |
/frameworks/av/include/media/ |
H A D | IMediaExtractorService.h | 35 virtual sp<IDataSource> makeIDataSource(int fd, int64_t offset, int64_t length) = 0;
|
/frameworks/av/include/media/stagefright/ |
H A D | AMRWriter.h | 29 AMRWriter(int fd);
|
/frameworks/av/media/libaaudio/src/binding/ |
H A D | AudioEndpointParcelable.h | 51 int32_t addFileDescriptor(const android::base::unique_fd& fd, int32_t sizeInBytes);
|
/frameworks/av/media/libmedia/include/media/ |
H A D | IMediaExtractorService.h | 35 virtual sp<IDataSource> makeIDataSource(int fd, int64_t offset, int64_t length) = 0;
|
/frameworks/av/media/libstagefright/include/media/stagefright/ |
H A D | AMRWriter.h | 29 AMRWriter(int fd);
|
/frameworks/av/media/libstagefright/omx/ |
H A D | OMXMaster.cpp | 38 int fd = open(filename, O_RDONLY); local 39 if (fd < 0) { 43 ssize_t len = read(fd, mProcessName, sizeof(mProcessName)); 51 close(fd);
|