Home
last modified time | relevance | path

Searched refs:g_usbInterface (Results 1 – 20 of 20) sorted by relevance

/test/xts/hats/hdf/usb/functionTest_additional/common/
Dusbd_function_test.cpp35 sptr<IUsbInterface> g_usbInterface = nullptr; variable
44 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
45 if (g_usbInterface == nullptr) { in SetUpTestCase()
49 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SINK, DATA_ROLE_DEVICE); in SetUpTestCase()
74 auto ret = g_usbInterface->SetCurrentFunctions(funcs);
87 auto ret = g_usbInterface->SetCurrentFunctions(funcs);
100 auto ret = g_usbInterface->SetCurrentFunctions(funcs);
113 auto ret = g_usbInterface->SetCurrentFunctions(funcs);
126 auto ret = g_usbInterface->SetCurrentFunctions(funcs);
139 auto ret = g_usbInterface->SetCurrentFunctions(funcs);
[all …]
/test/xts/hats/hdf/usb/requestTest_additional/common/
Dusbd_request_test_additional.cpp40 sptr<IUsbInterface> g_usbInterface = nullptr; variable
49 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
50 if (g_usbInterface == nullptr) { in SetUpTestCase()
54 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
64 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
75 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
82 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
84 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
104 auto ret = g_usbInterface->ClaimInterface(dev, interfaceId, 1);
109 ret = g_usbInterface->RequestQueue(dev, pipe, clientData, bufferData);
[all …]
Dusbd_request_test.cpp45 sptr<IUsbInterface> g_usbInterface = nullptr; variable
54 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
55 if (g_usbInterface == nullptr) { in SetUpTestCase()
59 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
69 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
80 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
87 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
89 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
108 auto ret = g_usbInterface->ClaimInterface(dev, interfaceId, 0);
122 auto ret = g_usbInterface->ClaimInterface(dev, interfaceId, 255);
[all …]
Dusbd_interface_test.cpp49 sptr<IUsbInterface> g_usbInterface = nullptr; variable
58 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
59 if (g_usbInterface == nullptr) { in SetUpTestCase()
63 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
73 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
84 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
87 ret = g_usbInterface->ClaimInterface(dev_, 1, 1); in SetUpTestCase()
93 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
95 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
115 auto ret = g_usbInterface->SetInterface(dev, interfaceId, altIndex);
[all …]
/test/xts/hats/hdf/usb/deviceTest_additional/common/
Dusbd_device_test.cpp33 sptr<IUsbInterface> g_usbInterface = nullptr; variable
44 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
45 if (g_usbInterface == nullptr) { in SetUpTestCase()
49 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
59 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
71 void UsbdDeviceTestAdditional::TearDownTestCase(void) { g_usbInterface->UnbindUsbdSubscriber(subscr… in TearDownTestCase()
85 auto ret = g_usbInterface->OpenDevice(dev);
97 auto ret = g_usbInterface->OpenDevice(dev);
109 auto ret = g_usbInterface->OpenDevice(dev);
121 auto ret = g_usbInterface->OpenDevice(dev);
[all …]
/test/xts/hats/hdf/usb/deviceTest/common/
Dusbd_device_test.cpp35 sptr<IUsbInterface> g_usbInterface = nullptr; variable
46 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
47 if (g_usbInterface == nullptr) { in SetUpTestCase()
51 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
61 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
75 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
92 auto ret = g_usbInterface->OpenDevice(dev);
107 auto ret = g_usbInterface->OpenDevice(dev);
122 auto ret = g_usbInterface->OpenDevice(dev);
137 auto ret = g_usbInterface->OpenDevice(dev);
[all …]
/test/xts/hats/hdf/usb/functionTest/common/
Dusbd_function_test.cpp38 sptr<IUsbInterface> g_usbInterface = nullptr; variable
47 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
48 if (g_usbInterface == nullptr) { in SetUpTestCase()
52 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SINK, DATA_ROLE_DEVICE); in SetUpTestCase()
78 auto ret = g_usbInterface->GetCurrentFunctions(funcs);
92 auto ret = g_usbInterface->SetCurrentFunctions(USB_FUNCTION_ACM);
97 ret = g_usbInterface->GetCurrentFunctions(funcs);
113 auto ret = g_usbInterface->SetCurrentFunctions(USB_FUNCTION_ACM);
128 auto ret = g_usbInterface->SetCurrentFunctions(USB_FUNCTION_INVALID);
142 auto ret = g_usbInterface->SetCurrentFunctions(USB_FUNCTION_ECM);
[all …]
/test/xts/hats/hdf/usb/transferTest_additional/common/
Dusbd_transfer_test_additional.cpp46 sptr<IUsbInterface> g_usbInterface = nullptr; variable
84 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
85 if (g_usbInterface == nullptr) { in SetUpTestCase()
91 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, DEFAULT_ROLE_HOST, DEFAULT_ROLE_HOST); in SetUpTestCase()
105 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
116 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
123 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
125 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
145 auto ret = g_usbInterface->ClaimInterface(dev, interfaceId, 1);
149 ret = g_usbInterface->BulkTransferWrite(dev, pipe, TRANSFER_TIME_OUT, bufferData);
[all …]
Dusbd_transfer_test.cpp42 sptr<IUsbInterface> g_usbInterface = nullptr; variable
51 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
52 if (g_usbInterface == nullptr) { in SetUpTestCase()
58 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, DEFAULT_ROLE_HOST, DEFAULT_ROLE_HOST); in SetUpTestCase()
72 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
83 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
90 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
92 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
115 auto ret = g_usbInterface->ControlTransferWrite(dev, ctrlparmas, bufferData);
134 auto ret = g_usbInterface->ControlTransferWrite(dev, ctrlparmas, bufferData);
[all …]
/test/xts/hats/hdf/usb/usbdBenchmarkTest/common/
DHdfUsbdBenchmarkRequestTest.cpp45 sptr<IUsbInterface> g_usbInterface = nullptr; variable
54 g_usbInterface = IUsbInterface::Get(); in SetUp()
55 ASSERT_TRUE(g_usbInterface != nullptr); in SetUp()
56 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SOURCE, DATA_ROLE_HOST); in SetUp()
66 auto ret = g_usbInterface->BindUsbdSubscriber(subscriber); in InitPara()
69 ret = g_usbInterface->OpenDevice(dev_); in InitPara()
75 ASSERT_TRUE(g_usbInterface != nullptr); in ReleasePara()
76 auto ret = g_usbInterface->UnbindUsbdSubscriber(subscriber); in ReleasePara()
78 ret = g_usbInterface->CloseDevice(dev_); in ReleasePara()
92 ASSERT_TRUE(g_usbInterface != nullptr); in BENCHMARK_F()
[all …]
DHdfUsbdBenchmarkDeviceTest.cpp34 sptr<IUsbInterface> g_usbInterface = nullptr; variable
45 g_usbInterface = IUsbInterface::Get(); in SetUp()
46 ASSERT_NE(g_usbInterface, nullptr); in SetUp()
47 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SOURCE, DATA_ROLE_HOST); in SetUp()
57 auto ret = g_usbInterface->BindUsbdSubscriber(subscriber); in InitPara()
60 ret = g_usbInterface->OpenDevice(dev_); in InitPara()
66 ASSERT_TRUE(g_usbInterface != nullptr); in ReleasePara()
67 auto ret = g_usbInterface->UnbindUsbdSubscriber(subscriber); in ReleasePara()
69 ret = g_usbInterface->CloseDevice(dev_); in ReleasePara()
83 ASSERT_NE(g_usbInterface, nullptr); in BENCHMARK_F()
[all …]
DHdfUsbdBenchmarkTransferTest.cpp46 sptr<IUsbInterface> g_usbInterface = nullptr; variable
82 g_usbInterface = IUsbInterface::Get(); in SetUp()
83 ASSERT_NE(g_usbInterface, nullptr); in SetUp()
84 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SOURCE, DATA_ROLE_HOST); in SetUp()
94 auto ret = g_usbInterface->BindUsbdSubscriber(subscriber); in InitPara()
97 ret = g_usbInterface->OpenDevice(dev_); in InitPara()
103 ASSERT_TRUE(g_usbInterface != nullptr); in ReleasePara()
104 auto ret = g_usbInterface->UnbindUsbdSubscriber(subscriber); in ReleasePara()
106 ret = g_usbInterface->CloseDevice(dev_); in ReleasePara()
121 ASSERT_TRUE(g_usbInterface != nullptr); in BENCHMARK_F()
[all …]
DHdfUsbdBenchmarkFunctionTest.cpp36 sptr<IUsbInterface> g_usbInterface = nullptr; variable
45 g_usbInterface = IUsbInterface::Get(); in SetUp()
46 if (g_usbInterface == nullptr) { in SetUp()
49 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SINK, DATA_ROLE_DEVICE); in SetUp()
73 ret = g_usbInterface->GetCurrentFunctions(funcs); in BENCHMARK_F()
96 ret = g_usbInterface->SetCurrentFunctions(funcs); in BENCHMARK_F()
118 ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SOURCE, DATA_ROLE_HOST); in BENCHMARK_F()
145 ret = g_usbInterface->QueryPort(portId, powerRole, dataRole, mode); in BENCHMARK_F()
/test/xts/hats/hdf/usb/requestTest/common/
Dusbd_request_test.cpp53 sptr<IUsbInterface> g_usbInterface = nullptr; variable
62 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
63 if (g_usbInterface == nullptr) { in SetUpTestCase()
67 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
77 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
87 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
94 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
96 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
116 auto ret = g_usbInterface->SetConfig(dev, configIndex);
132 auto ret = g_usbInterface->SetConfig(dev, configIndex);
[all …]
Dusbd_interface_test.cpp55 sptr<IUsbInterface> g_usbInterface = nullptr; variable
64 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
65 if (g_usbInterface == nullptr) { in SetUpTestCase()
69 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
79 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
89 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
92 ret = g_usbInterface->ClaimInterface(dev_, 1, 1); in SetUpTestCase()
98 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
100 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
121 auto ret = g_usbInterface->SetInterface(dev, interfaceId, altIndex);
[all …]
/test/xts/hats/hdf/usb/manageInterfaceTest/common/
Dusbd_manage_interface_test.cpp42 sptr<IUsbInterface> g_usbInterface = nullptr; variable
51 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
52 if (g_usbInterface == nullptr) { in SetUpTestCase()
56 auto ret = g_usbInterface->SetPortRole(1, 1, 1); in SetUpTestCase()
66 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
76 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
83 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
85 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
107 ret = g_usbInterface->ManageInterface(dev, interfaceId, true);
129 auto ret = g_usbInterface->ManageInterface(dev, interfaceId, true);
[all …]
/test/xts/hats/hdf/usb/transferTest/common/
Dusbd_transfer_test.cpp51 sptr<IUsbInterface> g_usbInterface = nullptr; variable
89 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
90 if (g_usbInterface == nullptr) { in SetUpTestCase()
96 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, DEFAULT_ROLE_HOST, DEFAULT_ROLE_HOST); in SetUpTestCase()
110 if (g_usbInterface->BindUsbdSubscriber(subscriber_) != HDF_SUCCESS) { in SetUpTestCase()
120 ret = g_usbInterface->OpenDevice(dev_); in SetUpTestCase()
127 g_usbInterface->UnbindUsbdSubscriber(subscriber_); in TearDownTestCase()
129 auto ret = g_usbInterface->CloseDevice(dev_); in TearDownTestCase()
150 auto ret = g_usbInterface->ControlTransferRead(dev, ctrlparmas, bufferData);
167 auto ret = g_usbInterface->ControlTransferRead(dev, ctrlparmas, bufferData);
[all …]
/test/xts/hats/hdf/usb/autoFunctionTest/common/
Dusbd_auto_function_test.cpp30 sptr<IUsbInterface> g_usbInterface = nullptr; variable
34 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
35 if (g_usbInterface == nullptr) { in SetUpTestCase()
56 auto ret = g_usbInterface->GetCurrentFunctions(funcs);
74 auto ret = g_usbInterface->QueryPort(portId, powerRole, dataRole, mode);
/test/xts/hats/hdf/usb/mtpTest/common/
Dusbfn_mtp_test.cpp69 sptr<IUsbInterface> g_usbInterface = nullptr; variable
182 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
183 ASSERT_TRUE(g_usbInterface != nullptr); in SetUpTestCase()
184 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SINK, DATA_ROLE_DEVICE); in SetUpTestCase()
188 ret = g_usbInterface->GetCurrentFunctions(g_currentFunc); in SetUpTestCase()
191 ret = g_usbInterface->SetCurrentFunctions(USB_FUNCTION_MTP); in SetUpTestCase()
206 ASSERT_TRUE(g_usbInterface != nullptr); in TearDownTestCase()
207 ret = g_usbInterface->SetCurrentFunctions(g_currentFunc); in TearDownTestCase()
/test/xts/hats/hdf/usb/mtpTest_additional/common/
Dusbfn_mtp_test.cpp61 sptr<IUsbInterface> g_usbInterface = nullptr; variable
176 g_usbInterface = IUsbInterface::Get(); in SetUpTestCase()
177 ASSERT_TRUE(g_usbInterface != nullptr); in SetUpTestCase()
178 auto ret = g_usbInterface->SetPortRole(DEFAULT_PORT_ID, POWER_ROLE_SINK, DATA_ROLE_DEVICE); in SetUpTestCase()
182 ret = g_usbInterface->GetCurrentFunctions(g_currentFunc); in SetUpTestCase()
185 ret = g_usbInterface->SetCurrentFunctions(USB_FUNCTION_MTP); in SetUpTestCase()
200 ASSERT_TRUE(g_usbInterface != nullptr); in TearDownTestCase()
201 ret = g_usbInterface->SetCurrentFunctions(g_currentFunc); in TearDownTestCase()