| /developtools/hdc/src/test/ |
| D | ut_mod.cpp | 24 uint8_t *bufPtr = nullptr; in TestBaseCommand() local 30 reinterpret_cast<void **>(&bufPtr), 0)) < 0) { in TestBaseCommand() 33 if (!strcmp("0", reinterpret_cast<char *>(bufPtr))) { in TestBaseCommand() 34 delete[] bufPtr; in TestBaseCommand() 35 bufPtr = nullptr; in TestBaseCommand() 38 delete[] bufPtr; in TestBaseCommand() 39 bufPtr = nullptr; in TestBaseCommand() 44 reinterpret_cast<void **>(&bufPtr), 0)) < expert) { in TestBaseCommand() 47 if (strcmp(MESSAGE_SUCCESS.c_str(), reinterpret_cast<char *>(bufPtr))) { in TestBaseCommand() 50 delete[] bufPtr; in TestBaseCommand() [all …]
|
| /developtools/hdc/src/common/ |
| D | task.cpp | 55 bool HdcTaskBase::SendToAnother(const uint16_t command, uint8_t *bufPtr, const int size) in SendToAnother() argument 64 channelBase->SendWithCmd(taskInfo->channelId, command, bufPtr, size); in SendToAnother() 68 … return sessionBase->Send(taskInfo->sessionId, taskInfo->channelId, command, bufPtr, size) > 0; in SendToAnother() 100 bool HdcTaskBase::ServerCommand(const uint16_t command, uint8_t *bufPtr, const int size) in ServerCommand() argument 103 return hSession->ServerCommand(taskInfo->sessionId, taskInfo->channelId, command, bufPtr, size); in ServerCommand() 107 int HdcTaskBase::ThreadCtrlCommunicate(const uint8_t *bufPtr, const int size) in ThreadCtrlCommunicate() argument 116 return Base::SendToPollFd(fd, bufPtr, size); in ThreadCtrlCommunicate()
|
| D | channel.h | 32 …void SendWithCmd(const uint32_t channelId, const uint16_t commandFlag, uint8_t *bufPtr, const int … 44 virtual int ReadChannel(HChannel hChannel, uint8_t *bufPtr, const int bytesIO) in ReadChannel() argument 49 void Send(const uint32_t channelId, uint8_t *bufPtr, const int size); 50 void SendChannel(HChannel hChannel, uint8_t *bufPtr, const int size); 51 …void SendChannelWithCmd(HChannel hChannel, const uint16_t commandFlag, uint8_t *bufPtr, const int … 52 void EchoToClient(HChannel hChannel, uint8_t *bufPtr, const int size);
|
| D | task.h | 39 …bool SendToAnother(const uint16_t command, uint8_t *bufPtr, const int size); // D / S corresponds… 41 …bool ServerCommand(const uint16_t command, uint8_t *bufPtr, const int size); // D / s command is … 42 …int ThreadCtrlCommunicate(const uint8_t *bufPtr, const int size); // main thread and s…
|
| D | channel.cpp | 272 …:SendChannelWithCmd(HChannel hChannel, const uint16_t commandFlag, uint8_t *bufPtr, const int size) in SendChannelWithCmd() argument 285 if (size > 0 && memcpy_s(data + sizeof(commandFlag), size, bufPtr, size)) { in SendChannelWithCmd() 294 …:SendWithCmd(const uint32_t channelId, const uint16_t commandFlag, uint8_t *bufPtr, const int size) in SendWithCmd() argument 307 SendChannelWithCmd(hChannel, commandFlag, bufPtr, size); in SendWithCmd() 312 void HdcChannelBase::SendChannel(HChannel hChannel, uint8_t *bufPtr, const int size) in SendChannel() argument 322 if (memcpy_s(data + DWORD_SERIALIZE_SIZE, sizeNewBuf - DWORD_SERIALIZE_SIZE, bufPtr, size)) { in SendChannel() 340 void HdcChannelBase::Send(const uint32_t channelId, uint8_t *bufPtr, const int size) in Send() argument 353 SendChannel(hChannel, bufPtr, size); in Send() 543 void HdcChannelBase::EchoToClient(HChannel hChannel, uint8_t *bufPtr, const int size) in EchoToClient() argument 553 if (memcpy_s(data + DWORD_SERIALIZE_SIZE, sizeNewBuf - DWORD_SERIALIZE_SIZE, bufPtr, size)) { in EchoToClient()
|
| D | session.cpp | 772 int HdcSessionBase::SendByProtocol(HSession hSession, uint8_t *bufPtr, const int bufLen, bool echo ) in SendByProtocol() argument 776 delete[] bufPtr; in SendByProtocol() 785 ret = pTCP->WriteUvTcpFd(&hSession->hChildWorkTCP, bufPtr, bufLen); in SendByProtocol() 788 ret = pTCP->WriteUvTcpFd(&hSession->hWorkTCP, bufPtr, bufLen); in SendByProtocol() 790 ret = pTCP->WriteUvTcpFd(&hSession->hChildWorkTCP, bufPtr, bufLen); in SendByProtocol() 797 ret = pUSB->SendUSBBlock(hSession, bufPtr, bufLen); in SendByProtocol() 798 delete[] bufPtr; in SendByProtocol() 804 ret = pUART->SendUARTData(hSession, bufPtr, bufLen); in SendByProtocol() 805 delete[] bufPtr; in SendByProtocol() 899 int HdcSessionBase::OnRead(HSession hSession, uint8_t *bufPtr, const int bufLen) in OnRead() argument [all …]
|
| D | forward.h | 85 bool SendToTask(const uint32_t cid, const uint16_t command, uint8_t *bufPtr, const int bufSize); 89 int SendForwardBuf(HCtxForward ctx, uint8_t *bufPtr, const int size);
|
| D | session.h | 91 int OnRead(HSession hSession, uint8_t *bufPtr, const int bufLen); 94 int SendByProtocol(HSession hSession, uint8_t *bufPtr, const int bufLen, bool echo = false); 113 uint8_t *bufPtr, const int size) in ServerCommand() argument
|
| D | forward.cpp | 216 bool HdcForwardBase::SendToTask(const uint32_t cid, const uint16_t command, uint8_t *bufPtr, const … in SendToTask() argument 230 if (bufSize > 0 && bufPtr != nullptr && memcpy_s(newBuf + 4, bufSize, bufPtr, bufSize) != EOK) { in SendToTask() 727 int HdcForwardBase::SendForwardBuf(HCtxForward ctx, uint8_t *bufPtr, const int size) in SendForwardBuf() argument 742 (void)memcpy_s(pDynBuf, size, bufPtr, size); in SendForwardBuf()
|
| /developtools/hdc/src/host/ |
| D | server_for_client.h | 37 int ReadChannel(HChannel hChannel, uint8_t *bufPtr, const int bytesIO) override; 43 …bool SendToDaemon(HChannel hChannel, const uint16_t commandFlag, uint8_t *bufPtr, const int bufSiz… 44 int BindChannelToSession(HChannel hChannel, uint8_t *bufPtr, const int bytesIO); 56 int ChannelHandShake(HChannel hChannel, uint8_t *bufPtr, const int bytesIO);
|
| D | server_for_client.cpp | 201 …nt::SendToDaemon(HChannel hChannel, const uint16_t commandFlag, uint8_t *bufPtr, const int bufSize) in SendToDaemon() argument 220 …if (ptrServer->Send(hdi->hSession->sessionId, hChannel->channelId, commandFlag, bufPtr, bufSize) <… in SendToDaemon() 712 int HdcServerForClient::BindChannelToSession(HChannel hChannel, uint8_t *bufPtr, const int bytesIO) in BindChannelToSession() argument 767 int HdcServerForClient::ChannelHandShake(HChannel hChannel, uint8_t *bufPtr, const int bytesIO) in ChannelHandShake() argument 770 rebuildHandshake.insert(rebuildHandshake.end(), bufPtr, bufPtr + bytesIO); in ChannelHandShake() 809 int HdcServerForClient::ReadChannel(HChannel hChannel, uint8_t *bufPtr, const int bytesIO) in ReadChannel() argument 813 return ChannelHandShake(hChannel, bufPtr, bytesIO); in ReadChannel() 816 uint16_t command = *reinterpret_cast<uint16_t *>(bufPtr); in ReadChannel() 819 … if (!SendToDaemon(hChannel, command, bufPtr + sizeof(uint16_t), bytesIO - sizeof(uint16_t))) { in ReadChannel() 826 … string retEcho = String2FormatCommand(reinterpret_cast<char *>(bufPtr), bytesIO, &formatCommand); in ReadChannel() [all …]
|
| D | server.h | 52 …ommand(const uint32_t sessionId, const uint32_t channelId, const uint16_t command, uint8_t *bufPtr,
|
| D | server.cpp | 906 uint8_t *bufPtr, const int size) in ServerCommand() argument 914 return FetchCommand(hSession, channelId, command, bufPtr, size); in ServerCommand()
|
| /developtools/hdc/test/unittest/common/ |
| D | uart_test.cpp | 531 uint8_t *bufPtr = reinterpret_cast<uint8_t *>(&testHead); variable 539 buffer.assign(bufPtr, bufPtr + sizeof(UartHead)); 548 buffer.assign(bufPtr, bufPtr + sizeof(UartHead)); 555 buffer.assign(bufPtr, bufPtr + sizeof(UartHead)); 564 buffer.assign(bufPtr, bufPtr + sizeof(UartHead)); 572 buffer.assign(bufPtr, bufPtr + sizeof(UartHead)); 580 buffer.assign(bufPtr, bufPtr + sizeof(UartHead)); 591 buffer.assign(bufPtr, bufPtr + sizeof(UartHead)); 602 buffer.assign(bufPtr, bufPtr + sizeof(UartHead));
|
| /developtools/hdc/test/unittest/common/include/ |
| D | HdcJdwpTest.h | 37 uint8_t *bufPtr, const int size) in ServerCommand() argument
|
| /developtools/hdc/src/daemon/ |
| D | daemon_usb.cpp | 519 uint8_t *bufPtr = ctxIo->buf; in OnUSBRead() local 549 if (thisClass->JumpAntiquePacket(*bufPtr, bytesIOBytes)) { in OnUSBRead() 555 …if ((childRet = thisClass->AvailablePacket((uint8_t *)bufPtr, bytesIOBytes, &sessionId)) != RET_SU… in OnUSBRead() 557 … WRITE_LOG(LOG_WARN, "AvailablePacket check failed, ret:%d buf:%-50s", bytesIOBytes, bufPtr); in OnUSBRead() 564 … if ((childRet = thisClass->DispatchToWorkThread(sessionId, bufPtr, bytesIOBytes)) < 0) { in OnUSBRead()
|
| D | daemon.h | 35 …ommand(const uint32_t sessionId, const uint32_t channelId, const uint16_t command, uint8_t *bufPtr,
|
| D | daemon.cpp | 460 uint8_t *bufPtr, const int size) in ServerCommand() argument 462 return Send(sessionId, channelId, command, reinterpret_cast<uint8_t *>(bufPtr), size) > 0; in ServerCommand()
|