Home | History | Annotate | Download | only in usb

Lines Matching full:portname

96 std::string appendRoleNodeHelper(const std::string &portName,
98 std::string node("/sys/class/typec/" + portName);
140 void switchToDrp(const std::string &portName) {
142 appendRoleNodeHelper(std::string(portName.c_str()), PortRoleType::MODE);
160 bool switchMode(const hidl_string &portName,
163 appendRoleNodeHelper(std::string(portName.c_str()), newRole.type);
210 switchToDrp(std::string(portName.c_str()));
240 Return<void> Usb::switchRole(const hidl_string &portName,
243 appendRoleNodeHelper(std::string(portName.c_str()), newRole.type);
259 roleSwitch = switchMode(portName, newRole, this);
284 mCallback_1_0->notifyRoleSwitchStatus(portName, newRole,
297 Status getAccessoryConnected(const std::string &portName, std::string *accessory) {
299 "/sys/class/typec/" + portName + "-partner/accessory_mode";
310 Status getCurrentRoleHelper(const std::string &portName, bool connected,
319 filename = "/sys/class/typec/" + portName + "/power_role";
322 filename = "/sys/class/typec/" + portName + "/data_role";
325 filename = "/sys/class/typec/" + portName + "/data_role";
334 if (getAccessoryConnected(portName, &accessory) != Status::SUCCESS) {
388 std::unordered_map<std::string, bool>::const_iterator portName =
390 if (portName == names->end()) {
406 bool canSwitchRoleHelper(const std::string &portName, PortRoleType /*type*/) {
408 "/sys/class/typec/" + portName + "-partner/supports_usb_power_delivery";
436 (*currentPortStatus_1_1)[i].status.portName = port.first;
597 + std::string(currentPortStatus_1_1[i].status.portName.c_str())
601 switchToDrp(currentPortStatus_1_1[i].status.portName);