Home
last modified time | relevance | path

Searched refs:numFds (Results 1 – 25 of 43) sorted by relevance

12

/frameworks/base/core/jni/
Dandroid_os_NativeHandle.cpp42 const int numFds = handle->numFds; in MakeJavaNativeHandleObj() local
43 ScopedLocalRef<jintArray> fds(env, env->NewIntArray(numFds)); in MakeJavaNativeHandleObj()
44 env->SetIntArrayRegion(fds.get(), 0, numFds, &(handle->data[0])); in MakeJavaNativeHandleObj()
48 env->SetIntArrayRegion(ints.get(), 0, numInts, &(handle->data[numFds])); in MakeJavaNativeHandleObj()
70 const int numFds = (int) env->GetArrayLength(fds.get()); in MakeCppNativeHandle() local
74 ? native_handle_create(numFds, numInts) in MakeCppNativeHandle()
75 : storage->allocTemporaryNativeHandle(numFds, numInts); in MakeCppNativeHandle()
78 env->GetIntArrayRegion(fds.get(), 0, numFds, &(handle->data[0])); in MakeCppNativeHandle()
79 env->GetIntArrayRegion(ints.get(), 0, numInts, &(handle->data[numFds])); in MakeCppNativeHandle()
/frameworks/native/libs/gui/bufferqueue/1.0/
DConversion.cpp63 return ((nh == nullptr) || (nh->numFds == 0) || in native_handle_read_fd()
64 (nh->numFds <= index) || (index < 0)) ? in native_handle_read_fd()
210 size_t numFds = static_cast<size_t>(handle ? handle->numFds : 0); in convertTo() local
211 int* fds = new int[numFds]; in convertTo()
226 ints[10] = static_cast<int32_t>(handle->numFds); in convertTo()
228 int* intsStart = handle->data + handle->numFds; in convertTo()
236 status_t status = l->unflatten(constBuffer, size, constFds, numFds); in convertTo()
360 void const*& buffer, size_t& size, int const*& fds, size_t& numFds) { in unflattenFence() argument
372 if (numFds < numFdsInHandle) { in unflattenFence()
383 --numFds; in unflattenFence()
[all …]
DH2BGraphicBufferProducer.cpp81 return ((nh == nullptr) || (nh->numFds == 0) || in native_handle_read_fd()
82 (nh->numFds <= index) || (index < 0)) ? in native_handle_read_fd()
159 size_t numFds = static_cast<size_t>(handle ? handle->numFds : 0); in convertTo() local
160 int* fds = new int[numFds]; in convertTo()
175 ints[10] = static_cast<int32_t>(handle->numFds); in convertTo()
177 int* intsStart = handle->data + handle->numFds; in convertTo()
185 status_t status = l->unflatten(constBuffer, size, constFds, numFds); in convertTo()
236 void const*& buffer, size_t& size, int const*& fds, size_t& numFds) { in unflattenFence() argument
248 if (numFds < numFdsInHandle) { in unflattenFence()
259 --numFds; in unflattenFence()
[all …]
/frameworks/native/libs/gui/include/gui/bufferqueue/1.0/
DConversion.h316 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/av/services/camera/libcameraservice/device3/
DBufferUtils.h43 result = 31 * result + buf->numFds; in operator()
44 for (int i = 0; i < buf->numFds; i++) { in operator()
53 if (buf1->numFds == buf2->numFds) { in operator()
54 for (int i = 0; i < buf1->numFds; i++) { in operator()
/frameworks/native/libs/ui/
DFence.cpp184 uint32_t numFds; in unflatten() local
185 FlattenableUtils::read(buffer, size, numFds); in unflatten()
187 if (numFds > 1) { in unflatten()
191 if (count < numFds) { in unflatten()
195 if (numFds) { in unflatten()
DGraphicBuffer.cpp390 memcpy(buf + 13, handle->data + handle->numFds, in flatten()
430 const size_t numFds = static_cast<size_t>(buf[10]); in unflatten() local
438 if (numFds >= maxNumber || numInts >= (maxNumber - flattenWordCount)) { in unflatten()
443 ALOGE("unflatten: numFds or numInts is too large: %zd, %zd", numFds, numInts); in unflatten()
450 size_t fdCountNeeded = numFds; in unflatten()
458 if (numFds || numInts) { in unflatten()
471 native_handle_create(static_cast<int>(numFds), static_cast<int>(numInts)); in unflatten()
480 memcpy(h->data, fds, numFds * sizeof(int)); in unflatten()
481 memcpy(h->data + numFds, buf + flattenWordCount, numInts * sizeof(int)); in unflatten()
518 fds += numFds; in unflatten()
[all …]
DGralloc2.cpp204 *outNumFds = uint32_t(bufferHandle->numFds); in getTransportSize()
335 if (fenceHandle && fenceHandle->numFds == 1) { in unlock()
DGralloc3.cpp169 *outNumFds = uint32_t(bufferHandle->numFds); in getTransportSize()
291 if (fenceHandle && fenceHandle->numFds == 1) { in unlock()
/frameworks/native/libs/vr/libbufferhub/include/private/dvr/
Dnative_handle_wrapper.h27 const int fd_count = handle->numFds; in NativeHandleWrapper()
84 for (int i = 0; i < handle->numFds; i++) { in FromFdsAndInts()
87 memcpy(&handle->data[handle->numFds], ints.data(), in FromFdsAndInts()
/frameworks/av/camera/ndk/ndk_vendor/impl/
Dutils.cpp133 if (nh1->numFds !=0 || nh2->numFds !=0) { in isWindowNativeHandleEqual()
137 if (nh1->version != nh2->version || nh1->numFds != nh2->numFds || in isWindowNativeHandleEqual()
/frameworks/base/core/java/android/os/
DNativeHandle.java187 int numFds = mFds.length; in getFdsAsIntArray() local
188 int[] fds = new int[numFds]; in getFdsAsIntArray()
190 for (int i = 0; i < numFds; i++) { in getFdsAsIntArray()
/frameworks/av/media/libmedia/include/media/omx/1.0/
DConversion.h137 return ((nh == nullptr) || (nh->numFds == 0) ||
138 (nh->numFds <= index) || (index < 0)) ?
633 t.nativeHandle->numFds, in convertTo()
634 (t.nativeHandle->numFds > 0) ? t.nativeHandle->data[0] : -1, in convertTo()
635 (t.nativeHandle->numFds > 1) ? t.nativeHandle->data[1] : -1); in convertTo()
643 size_t numFds = static_cast<size_t>(handle ? handle->numFds : 0); in convertTo() local
644 int* fds = new int[numFds]; in convertTo()
659 ints[10] = static_cast<int32_t>(handle->numFds); in convertTo()
661 int* intsStart = handle->data + handle->numFds; in convertTo()
669 status_t status = l->unflatten(constBuffer, size, constFds, numFds); in convertTo()
/frameworks/av/services/camera/libcameraservice/device1/
DCameraHardwareInterface.h448 result = 31 * result + buf->numFds; in operator()
450 int length = buf->numFds + buf->numInts; in operator()
460 if (buf1->numFds == buf2->numFds && buf1->numInts == buf2->numInts) { in operator()
461 int length = buf1->numFds + buf1->numInts; in operator()
/frameworks/av/media/codec2/vndk/
DC2AllocatorGralloc.cpp78 handle->numFds < 0 || in native_handle_is_invalid()
81 handle->numFds > int((INT_MAX - handle->version) / sizeof(int)) - handle->numInts); in native_handle_is_invalid()
113 &handle->data[handle->numFds + handle->numInts - NUM_INTS]); in getExtraData()
144 … handle->numInts > int((INT_MAX - handle->version) / sizeof(int)) - NUM_INTS - handle->numFds) { in WrapAndMoveNativeHandle()
152 native_handle_t *res = native_handle_create(handle->numFds, handle->numInts + NUM_INTS); in WrapAndMoveNativeHandle()
154 memcpy(&res->data, &handle->data, sizeof(int) * (handle->numFds + handle->numInts)); in WrapAndMoveNativeHandle()
202 native_handle_t *res = native_handle_create(handle->numFds, handle->numInts - NUM_INTS); in UnwrapNativeHandle()
204 memcpy(&res->data, &handle->data, sizeof(int) * (res->numFds + res->numInts)); in UnwrapNativeHandle()
Dtypes.cpp156 if (!from || from->numFds == 0) { in h2b()
160 if (from->numFds != 1 || from->numInts != 0) { in h2b()
/frameworks/av/media/utils/
DAImageReaderUtils.cpp44 if (handle->numFds != 0 || in AImageReader_getHGBPFromHandle()
/frameworks/base/core/jni/hwbinder/
DEphemeralStorage.cpp75 int numFds, int numInts) { in allocTemporaryNativeHandle() argument
79 item.mPtr = native_handle_create(numFds, numInts); in allocTemporaryNativeHandle()
DEphemeralStorage.h46 native_handle_t *allocTemporaryNativeHandle(int numFds, int numInts);
/frameworks/av/media/codec2/vndk/internal/
DC2HandleIonInternal.h53 numFds = sizeof(mFds) / sizeof(int), enumerator
/frameworks/av/media/bufferpool/1.0/vts/
Dallocator.cpp61 numFds = sizeof(mFds) / sizeof(int), enumerator
70 HandleAshmem::numFds,
/frameworks/av/media/bufferpool/2.0/tests/
Dallocator.cpp61 numFds = sizeof(mFds) / sizeof(int), enumerator
70 HandleAshmem::numFds,
/frameworks/native/libs/gui/bufferqueue/2.0/
Dtypes.cpp149 if (!from || from->numFds == 0) { in h2b()
153 if (from->numFds != 1 || from->numInts != 0) { in h2b()
/frameworks/av/drm/mediadrm/plugins/clearkey/hidl/
DDrmFactory.cpp95 if (fd.getNativeHandle() == nullptr || fd->numFds < 1) { in debug()
/frameworks/hardware/interfaces/bufferhub/1.0/vts/functional/
DVtsHalBufferHubV1_0TargetTest.cpp226 EXPECT_EQ(token->numFds, 0); in TEST_F()
321 EXPECT_EQ(token->numFds, 0); in TEST_F()

12