/frameworks/base/core/java/android/os/ |
D | NativeHandle.java | 62 private static FileDescriptor[] createFileDescriptorArray(@NonNull int[] fds) { in createFileDescriptorArray() argument 63 FileDescriptor[] list = new FileDescriptor[fds.length]; in createFileDescriptorArray() 64 for (int i = 0; i < fds.length; i++) { in createFileDescriptorArray() 66 descriptor.setInt$(fds[i]); in createFileDescriptorArray() 78 private NativeHandle(@NonNull int[] fds, @NonNull int[] ints, boolean own) { in NativeHandle() argument 79 this(createFileDescriptorArray(fds), ints, own); in NativeHandle() 87 public NativeHandle(@NonNull FileDescriptor[] fds, @NonNull int[] ints, boolean own) { in NativeHandle() argument 88 mFds = fds.clone(); in NativeHandle() 112 FileDescriptor[] fds = new FileDescriptor[mFds.length]; in dup() local 118 fds[i] = newFd; in dup() [all …]
|
D | FileBridge.java | 71 ParcelFileDescriptor[] fds = ParcelFileDescriptor.createSocketPair(SOCK_STREAM); in FileBridge() local 72 mServer = fds[0]; in FileBridge() 73 mClient = fds[1]; in FileBridge()
|
/frameworks/base/apex/jobscheduler/service/jni/ |
D | com_android_server_alarm_AlarmManagerService.cpp | 79 AlarmImpl(const TimerFds &fds, int epollfd, const std::string &rtc_dev) in AlarmImpl() argument 80 : fds{fds}, epollfd{epollfd}, rtc_dev{rtc_dev} {} in AlarmImpl() 89 const TimerFds fds; member in android::AlarmImpl 96 for (auto fd : fds) { in ~AlarmImpl() 121 return timerfd_settime(fds[type], TFD_TIMER_ABSTIME, &spec, NULL); in set() 131 return timerfd_gettime(fds[type], spec); in getTime() 184 ssize_t err = read(fds[alarm_idx], &unused, sizeof(unused)); in waitForAlarm() 270 TimerFds fds; in android_server_alarm_AlarmManagerService_init() local 272 epollfd = epoll_create(fds.size()); in android_server_alarm_AlarmManagerService_init() 274 ALOGE("epoll_create(%zu) failed: %s", fds.size(), strerror(errno)); in android_server_alarm_AlarmManagerService_init() [all …]
|
/frameworks/base/services/core/java/com/android/server/biometrics/sensors/face/aidl/ |
D | AidlNativeHandleUtils.java | 48 final FileDescriptor[] fds = handle.getFileDescriptors(); in dup() local 50 res.fds = new ParcelFileDescriptor[fds.length]; in dup() 51 for (int i = 0; i < fds.length; ++i) { in dup() 52 res.fds[i] = ParcelFileDescriptor.dup(fds[i]); in dup() 70 for (ParcelFileDescriptor fd : handle.fds) { in close()
|
/frameworks/native/libs/gui/ |
D | IGraphicBufferProducerFlattenables.cpp | 46 void*& buffer, size_t& size, int*& fds, size_t& count) const in flatten() argument 61 status_t result = fence->flatten(buffer, size, fds, count); in flatten() 80 void const*& buffer, size_t& size, int const*& fds, size_t& count) in unflatten() argument 96 status_t result = fence->unflatten(buffer, size, fds, count); in unflatten() 129 void*& buffer, size_t& size, int*& fds, size_t& count) const in flatten() argument 143 status_t result = frameTimestamps.flatten(buffer, size, fds, count); in flatten() 152 void const*& buffer, size_t& size, int const*& fds, size_t& count) in unflatten() argument 166 status_t result = frameTimestamps.unflatten(buffer, size, fds, count); in unflatten() 189 void*& fBuffer, size_t& size, int*& fds, size_t& count) const { in flatten() argument 199 status_t status = buffer->flatten(fBuffer, size, fds, count); in flatten() [all …]
|
D | BufferItem.cpp | 126 void*& buffer, size_t& size, int*& fds, size_t& count) const { in flatten() argument 141 status_t err = mGraphicBuffer->flatten(buffer, size, fds, count); in flatten() 147 status_t err = mFence->flatten(buffer, size, fds, count); in flatten() 194 void const*& buffer, size_t& size, int const*& fds, size_t& count) { in unflatten() argument 205 status_t err = mGraphicBuffer->unflatten(buffer, size, fds, count); in unflatten() 212 status_t err = mFence->unflatten(buffer, size, fds, count); in unflatten()
|
/frameworks/base/services/core/jni/ |
D | com_android_server_UsbMidiDevice.cpp | 93 jobjectArray fds = env->NewObjectArray(subdevice_count + 1, sFileDescriptorClass, NULL); in android_server_UsbMidiDevice_open() local 94 if (!fds) { in android_server_UsbMidiDevice_open() 109 env->SetObjectArrayElement(fds, i, jifd.get()); in android_server_UsbMidiDevice_open() 126 env->SetObjectArrayElement(fds, subdevice_count, jifd.get()); in android_server_UsbMidiDevice_open() 130 return fds; in android_server_UsbMidiDevice_open() 134 ScopedLocalRef<jobject> jifd(env, env->GetObjectArrayElement(fds, i)); in android_server_UsbMidiDevice_open() 145 android_server_UsbMidiDevice_close(JNIEnv *env, jobject thiz, jobjectArray fds) in android_server_UsbMidiDevice_close() argument 153 int count = env->GetArrayLength(fds); in android_server_UsbMidiDevice_close() 155 jobject fd = env->GetObjectArrayElement(fds, i); in android_server_UsbMidiDevice_close()
|
/frameworks/native/libs/vr/libbufferhub/include/private/dvr/ |
D | native_handle_wrapper.h | 51 std::vector<FileHandleType> fds; in DuplicateHandle() local 56 fds.emplace_back(fd.Duplicate()); in DuplicateHandle() 59 return FromFdsAndInts(std::move(fds), ints_); in DuplicateHandle() 75 static native_handle_t* FromFdsAndInts(std::vector<FileHandleType> fds, in FromFdsAndInts() argument 77 native_handle_t* handle = native_handle_create(fds.size(), ints.size()); in FromFdsAndInts() 85 handle->data[i] = fds[i].Release(); in FromFdsAndInts()
|
/frameworks/wilhelm/tests/sandbox/ |
D | getch.c | 38 fd_set fds; in kbhit() local 39 FD_ZERO(&fds); // not in original posting to stackoverflow in kbhit() 40 FD_SET(0, &fds); in kbhit() 41 return select(1, &fds, NULL, NULL, &tv); in kbhit()
|
/frameworks/native/libs/gui/include/gui/bufferqueue/1.0/ |
D | Conversion.h | 316 void const*& buffer, size_t& size, int const*& fds, size_t& numFds); 329 void*& buffer, size_t& size, int*& fds, size_t& numFds); 390 void*& buffer, size_t& size, int*& fds, size_t& numFds); 409 void const*& buffer, size_t& size, int const*& fds, size_t& numFds); 448 void const*& buffer, size_t& size, int const*& fds, size_t& numFds); 465 void*& buffer, size_t& size, int*& fds, size_t numFds); 507 void const*& buffer, size_t& size, int const*& fds, size_t& numFds); 523 void*& buffer, size_t& size, int*& fds, size_t& numFds); 639 void*& buffer, size_t& size, int*& fds, size_t& numFds); 659 void const*& buffer, size_t& size, int const*& fds, size_t& numFds);
|
/frameworks/native/libs/gui/bufferqueue/1.0/ |
D | Conversion.cpp | 211 int* fds = new int[numFds]; in convertTo() local 229 std::copy(handle->data, intsStart, fds); in convertTo() 235 int const* constFds = static_cast<int const*>(fds); in convertTo() 238 delete [] fds; in convertTo() 360 void const*& buffer, size_t& size, int const*& fds, size_t& numFds) { in unflattenFence() argument 377 *nh = native_handle_create_from_fd(*fds); in unflattenFence() 382 ++fds; in unflattenFence() 403 void*& buffer, size_t& size, int*& fds, size_t& numFds) { in flattenFence() argument 414 *fds = fd; in flattenFence() 415 ++fds; in flattenFence() [all …]
|
D | H2BGraphicBufferProducer.cpp | 160 int* fds = new int[numFds]; in convertTo() local 178 std::copy(handle->data, intsStart, fds); in convertTo() 184 int const* constFds = static_cast<int const*>(fds); in convertTo() 187 delete [] fds; in convertTo() 236 void const*& buffer, size_t& size, int const*& fds, size_t& numFds) { in unflattenFence() argument 253 *nh = native_handle_create_from_fd(*fds); in unflattenFence() 258 ++fds; in unflattenFence() 279 void*& buffer, size_t& size, int*& fds, size_t& numFds) { in flattenFence() argument 290 *fds = fd; in flattenFence() 291 ++fds; in flattenFence() [all …]
|
/frameworks/native/libs/input/tests/ |
D | TestHelpers.h | 32 int fds[2]; in Pipe() local 33 ::pipe(fds); in Pipe() 35 receiveFd = fds[0]; in Pipe() 36 sendFd = fds[1]; in Pipe()
|
/frameworks/base/core/jni/ |
D | android_os_NativeHandle.cpp | 43 ScopedLocalRef<jintArray> fds(env, env->NewIntArray(numFds)); in MakeJavaNativeHandleObj() local 44 env->SetIntArrayRegion(fds.get(), 0, numFds, &(handle->data[0])); in MakeJavaNativeHandleObj() 51 gNativeHandleFields.constructID, fds.get(), ints.get(), false /*own*/); in MakeJavaNativeHandleObj() 64 ScopedLocalRef<jintArray> fds(env, (jintArray) env->CallObjectMethod( in MakeCppNativeHandle() local 70 const int numFds = (int) env->GetArrayLength(fds.get()); in MakeCppNativeHandle() 78 env->GetIntArrayRegion(fds.get(), 0, numFds, &(handle->data[0])); in MakeCppNativeHandle()
|
/frameworks/base/tools/bit/ |
D | command.cpp | 107 int fds[2]; in get_command_output() local 108 if (0 != pipe(fds)) { in get_command_output() 120 while ((dup2(fds[1], STDOUT_FILENO) == -1) && (errno == EINTR)) {} in get_command_output() 121 close(fds[1]); in get_command_output() 122 close(fds[0]); in get_command_output() 133 close(fds[1]); in get_command_output() 138 ssize_t amt = read(fds[0], buf, size); in get_command_output()
|
D | adb.cpp | 304 int fds[2]; in run_instrumentation_test() local 305 if (0 != pipe(fds)) { in run_instrumentation_test() 316 while ((dup2(fds[1], STDOUT_FILENO) == -1) && (errno == EINTR)) {} in run_instrumentation_test() 317 close(fds[1]); in run_instrumentation_test() 318 close(fds[0]); in run_instrumentation_test() 327 close(fds[1]); in run_instrumentation_test() 331 int err = read_instrumentation_results(fds[0], buf, size, callbacks); in run_instrumentation_test()
|
/frameworks/native/cmds/bugreportz/ |
D | bugreportz_test.cpp | 36 int fds[2]; in SetUp() local 37 ASSERT_EQ(0, pipe(fds)); in SetUp() 38 read_fd_ = fds[0]; in SetUp() 39 write_fd_ = fds[1]; in SetUp()
|
/frameworks/native/libs/gui/include/gui/ |
D | IGraphicBufferProducer.h | 356 status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const; 357 status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count); 393 status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const; 394 status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count); 686 status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const; 687 status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count); 724 status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const; 725 status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count); 787 status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const; 788 status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count);
|
D | BufferItem.h | 41 status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const; 42 status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count);
|
/frameworks/base/core/java/android/printservice/ |
D | PrintDocument.java | 79 ParcelFileDescriptor[] fds = ParcelFileDescriptor.createPipe(); in getData() local 80 source = fds[0]; in getData() 81 sink = fds[1]; in getData()
|
/frameworks/base/cmds/incident/ |
D | main.cpp | 375 int fds[2]; in main() local 376 pipe(fds); in main() 378 unique_fd readEnd(fds[0]); in main() 379 unique_fd writeEnd(fds[1]); in main() 393 return listener->getExitCodeOrElse(stream_output(fds[0], STDOUT_FILENO)); in main() 402 return listener->getExitCodeOrElse(stream_output(fds[0], STDOUT_FILENO)); in main()
|
/frameworks/base/services/core/java/com/android/server/notification/ |
D | PulledStats.java | 49 final ParcelFileDescriptor[] fds = ParcelFileDescriptor.createPipe(); in toParcelFileDescriptor() local 56 fds[1]); in toParcelFileDescriptor() 73 return fds[0]; in toParcelFileDescriptor()
|
/frameworks/native/libs/ui/ |
D | Fence.cpp | 160 status_t Fence::flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const { in flatten() argument 168 *fds++ = mFenceFd; in flatten() 174 status_t Fence::unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count) { in unflatten() argument 196 mFenceFd.reset(*fds++); in unflatten()
|
/frameworks/base/core/java/com/android/internal/os/ |
D | ZygoteConnection.java | 568 StructPollfd[] fds = new StructPollfd[] { in handleParentProc() local 579 fds[0].fd = pipeFd; in handleParentProc() 580 fds[0].events = (short) POLLIN; in handleParentProc() 581 fds[0].revents = 0; in handleParentProc() 582 fds[0].userData = null; in handleParentProc() 584 int res = android.system.Os.poll(fds, remainingSleepTime); in handleParentProc() 593 if ((fds[0].revents & POLLIN) != 0) { in handleParentProc()
|
/frameworks/native/cmds/dumpstate/ |
D | DumpstateInternal.cpp | 167 pollfd fds[] = { { .fd = fd, .events = POLLIN } }; in DumpFileFromFdToFd() local 168 int ret = TEMP_FAILURE_RETRY(poll(fds, arraysize(fds), 30 * 1000)); in DumpFileFromFdToFd()
|