/system/core/adb/ |
D | sysdeps_test.cpp | 73 int fds[2]; in TEST() local 74 ASSERT_EQ(0, adb_socketpair(fds)) << strerror(errno); in TEST() 75 ASSERT_TRUE(WriteFdExactly(fds[0], "foo", 4)); in TEST() 76 ASSERT_TRUE(WriteFdExactly(fds[1], "bar", 4)); in TEST() 79 ASSERT_TRUE(ReadFdExactly(fds[1], buf, 4)); in TEST() 81 ASSERT_TRUE(ReadFdExactly(fds[0], buf, 4)); in TEST() 83 ASSERT_EQ(0, adb_close(fds[0])); in TEST() 84 ASSERT_EQ(0, adb_close(fds[1])); in TEST() 88 std::vector<int> fds; in TEST() local 92 fds.push_back(socketpair[0]); in TEST() [all …]
|
D | framebuffer_service.cpp | 64 int fds[2]; in framebuffer_service() local 67 if (pipe2(fds, O_CLOEXEC) < 0) goto pipefail; in framebuffer_service() 73 dup2(fds[1], STDOUT_FILENO); in framebuffer_service() 74 adb_close(fds[0]); in framebuffer_service() 75 adb_close(fds[1]); in framebuffer_service() 82 adb_close(fds[1]); in framebuffer_service() 83 fd_screencap = fds[0]; in framebuffer_service() 180 adb_close(fds[0]); in framebuffer_service()
|
D | shell_service_protocol_test.cpp | 43 int fds[2]; in SetUp() local 44 ASSERT_EQ(0, adb_socketpair(fds)); in SetUp() 45 read_fd_ = fds[0]; in SetUp() 46 write_fd_ = fds[1]; in SetUp()
|
D | fdevent_test.cpp | 92 int fds[2]; in FdEventThreadFunc() local 93 ASSERT_EQ(0, adb_socketpair(fds)); in FdEventThreadFunc() 94 read_fds.push_back(fds[0]); in FdEventThreadFunc() 95 write_fds.push_back(fds[1]); in FdEventThreadFunc()
|
D | jdwp_service.cpp | 416 int fds[2]; in create_jdwp_connection_fd() local 424 if (adb_socketpair(fds) < 0) { in create_jdwp_connection_fd() 429 D("socketpair: (%d,%d)", fds[0], fds[1]); in create_jdwp_connection_fd() 431 proc->out_fds[ proc->out_count ] = fds[1]; in create_jdwp_connection_fd() 435 return fds[0]; in create_jdwp_connection_fd()
|
D | sysdeps.h | 303 extern int adb_poll(adb_pollfd* fds, size_t nfds, int timeout); 805 static __inline__ int adb_poll(adb_pollfd* fds, size_t nfds, int timeout) { in adb_poll() argument 806 return TEMP_FAILURE_RETRY(poll(fds, nfds, timeout)); in adb_poll()
|
D | sysdeps_win32.cpp | 664 extern int adb_poll(adb_pollfd* fds, size_t nfds, int timeout) { in adb_poll() argument 670 FH fh = _fh_from_int(fds[i].fd, __func__); in adb_poll() 672 D("adb_poll received bad FD %d", fds[i].fd); in adb_poll() 673 fds[i].revents = POLLNVAL; in adb_poll() 678 .events = static_cast<short>(fds[i].events) in adb_poll() 681 original.push_back(&fds[i]); in adb_poll() 705 if (fds[i].revents != 0) { in adb_poll()
|
/system/extras/tests/pagingtest/ |
D | thrashing_test.c | 14 int fds[4] = {-1, -1, -1, -1}; in thrashing_test() local 33 filesize = num_pages * pagesize / (ARRAY_SIZE(fds) - 1); in thrashing_test() 35 for (size_t i = 0; i < ARRAY_SIZE(fds); i++) { in thrashing_test() 36 fds[i] = create_tmp_file(tmpnames[i], filesize); in thrashing_test() 37 if (fds[i] < 0) { in thrashing_test() 42 for (size_t i = 0; i < ARRAY_SIZE(fds); i++) { in thrashing_test() 43 bufs[i] = mmap(NULL, filesize, PROT_READ, MAP_PRIVATE, fds[i], 0); in thrashing_test() 51 for (size_t j = 0; j < ARRAY_SIZE(fds); j++) { in thrashing_test() 65 printf("thrashing: %llu MB/s\n", (filesize * ARRAY_SIZE(fds) * test_runs * USEC_PER_SEC) / in thrashing_test() 75 for (size_t i = 0; i < ARRAY_SIZE(fds) && fds[i] >= 0; i++) { in thrashing_test() [all …]
|
/system/extras/tests/storage/ |
D | opentest.c | 30 int *fds; in main() local 64 fds = malloc(nfiles * sizeof(int)); in main() 65 if (fds == 0) { in main() 84 fds[i] = open(name, O_WRONLY | O_CREAT, 0666); in main() 85 if (fds[i] < 0) { in main()
|
/system/core/libutils/tests/ |
D | TestHelpers.h | 30 int fds[2]; in Pipe() local 31 ::pipe(fds); in Pipe() 33 receiveFd = fds[0]; in Pipe() 34 sendFd = fds[1]; in Pipe()
|
/system/webservd/webservd/ |
D | permission_broker_firewall.cc | 27 int fds[2]; in PermissionBrokerFirewall() local 28 PCHECK(pipe(fds) == 0) << "Failed to create firewall lifeline pipe"; in PermissionBrokerFirewall() 29 lifeline_read_fd_ = fds[0]; in PermissionBrokerFirewall() 30 lifeline_write_fd_ = fds[1]; in PermissionBrokerFirewall()
|
/system/connectivity/shill/dbus/ |
D | chromeos_permission_broker_proxy.cc | 51 int fds[2]; in RequestVpnSetup() local 52 if (pipe(fds) != 0) { in RequestVpnSetup() 56 lifeline_read_fd_ = fds[0]; in RequestVpnSetup() 57 lifeline_write_fd_ = fds[1]; in RequestVpnSetup()
|
/system/core/include/utils/ |
D | Flattenable.h | 96 inline status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const; 105 inline status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count); 118 void*& buffer, size_t& size, int*& fds, size_t& count) const { in flatten() argument 119 return static_cast<T const*>(this)->T::flatten(buffer, size, fds, count); in flatten() 123 void const*& buffer, size_t& size, int const*& fds, size_t& count) { in unflatten() argument 124 return static_cast<T*>(this)->T::unflatten(buffer, size, fds, count); in unflatten()
|
/system/connectivity/apmanager/dbus/ |
D | permission_broker_dbus_proxy.cc | 51 int fds[2]; in PermissionBrokerDBusProxy() local 52 CHECK(pipe(fds) == 0) << "Failed to create lifeline pipe"; in PermissionBrokerDBusProxy() 53 lifeline_read_fd_ = fds[0]; in PermissionBrokerDBusProxy() 54 lifeline_write_fd_ = fds[1]; in PermissionBrokerDBusProxy()
|
/system/tools/aidl/tests/ |
D | aidl_test_client_file_descriptors.cpp | 91 int fds[2]; in DoPipe() local 94 if (pipe(fds)) { in DoPipe() 99 read_side->reset(fds[0]); in DoPipe() 100 write_side->reset(fds[1]); in DoPipe()
|
/system/extras/verity/fec/ |
D | image.cpp | 132 static void mmap_image_load(const std::vector<int>& fds, image *ctx, in mmap_image_load() argument 135 if (fds.size() != 1) { in mmap_image_load() 139 int fd = fds.front(); in mmap_image_load() 204 static void file_image_load(const std::vector<int>& fds, image *ctx) in file_image_load() argument 211 for (auto fd : fds) { in file_image_load() 257 for (auto fd : fds) { in file_image_load() 273 for (auto fd : fds) { in file_image_load() 291 std::vector<int> fds; in image_load() local 300 fds.push_back(fd); in image_load() 304 mmap_image_load(fds, ctx, output_needed); in image_load() [all …]
|
/system/core/adf/libadfhwc/ |
D | adfhwc.cpp | 211 pollfd *fds = new pollfd[dev->intf_fds.size()]; in adf_event_thread() local 213 fds[i].fd = dev->intf_fds[i]; in adf_event_thread() 214 fds[i].events = POLLIN | POLLPRI; in adf_event_thread() 218 int err = poll(fds, dev->intf_fds.size(), -1); in adf_event_thread() 222 if (fds[i].revents & (POLLIN | POLLPRI)) in adf_event_thread() 232 delete [] fds; in adf_event_thread()
|
/system/bt/vendor_libs/linux/ |
D | bt_vendor_linux.c | 151 struct pollfd fds[1]; in bt_vendor_wait_hcidev() local 175 fds[0].fd = fd; in bt_vendor_wait_hcidev() 176 fds[0].events = POLLIN; in bt_vendor_wait_hcidev() 193 OSI_NO_INTR(n = poll(fds, 1, MGMT_EV_POLL_TIMEOUT)); in bt_vendor_wait_hcidev() 204 if (fds[0].revents & POLLIN) { in bt_vendor_wait_hcidev()
|
/system/core/libion/tests/ |
D | allocate_test.cpp | 97 int fds[16]; in TEST_F() local 111 fds[i] = map_fd; in TEST_F() 115 ASSERT_EQ(0, close(fds[i])); in TEST_F()
|
/system/core/libsync/tests/ |
D | sync_test.cpp | 391 struct pollfd fds; in TEST() local 392 fds.fd = fenceKill.getFd(); in TEST() 393 fds.events = POLLIN | POLLERR; in TEST() 394 ASSERT_EQ(poll(&fds, 1, -1), 1); in TEST() 395 ASSERT_TRUE(fds.revents & POLLERR); in TEST()
|
/system/bt/btif/src/ |
D | btif_sock_rfc.c | 197 int fds[2] = { INVALID_FD, INVALID_FD }; in alloc_rfc_slot() local 198 if (socketpair(AF_LOCAL, SOCK_STREAM, 0, fds) == -1) { in alloc_rfc_slot() 207 slot->fd = fds[0]; in alloc_rfc_slot() 208 slot->app_fd = fds[1]; in alloc_rfc_slot()
|
D | btif_sock_l2cap.c | 301 int fds[2]; in btsock_l2cap_alloc_l() local 313 if (socketpair(AF_LOCAL, SOCK_SEQPACKET, 0, fds)) { in btsock_l2cap_alloc_l() 318 sock->our_fd = fds[0]; in btsock_l2cap_alloc_l() 319 sock->app_fd = fds[1]; in btsock_l2cap_alloc_l()
|
/system/extras/simpleperf/ |
D | cmd_record.cpp | 518 const std::vector<std::unique_ptr<EventFd>>* fds = in CreateRecordFile() local 520 CHECK(fds != nullptr); in CreateRecordFile() 521 for (auto& fd : *fds) { in CreateRecordFile()
|
/system/sepolicy/ |
D | adbd.te | 12 # Do not sanitize the environment or open fds of the shell. Allow signaling
|