summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usb/CommonUtils.cpp6
-rw-r--r--usb/include/pixelusb/CommonUtils.h9
2 files changed, 7 insertions, 8 deletions
diff --git a/usb/CommonUtils.cpp b/usb/CommonUtils.cpp
index 6e0f08c9..91688b98 100644
--- a/usb/CommonUtils.cpp
+++ b/usb/CommonUtils.cpp
@@ -200,10 +200,10 @@ static VendorUsbDataSessionEvent_UsbDeviceState stringToUsbDeviceStateProto(
}
}
-void BuildVendorUsbDataSessionEvent(bool is_host, boot_clock::time_point currentTime,
- boot_clock::time_point startTime,
+void BuildVendorUsbDataSessionEvent(bool is_host, steady_clock::time_point currentTime,
+ steady_clock::time_point startTime,
std::vector<std::string> *states,
- std::vector<boot_clock::time_point> *timestamps,
+ std::vector<steady_clock::time_point> *timestamps,
VendorUsbDataSessionEvent *event) {
if (is_host) {
event->set_usb_role(VendorUsbDataSessionEvent_UsbDataRole_USB_ROLE_HOST);
diff --git a/usb/include/pixelusb/CommonUtils.h b/usb/include/pixelusb/CommonUtils.h
index dbd59c63..93855be3 100644
--- a/usb/include/pixelusb/CommonUtils.h
+++ b/usb/include/pixelusb/CommonUtils.h
@@ -17,7 +17,6 @@
#ifndef HARDWARE_GOOGLE_PIXEL_USB_UTILSCOMMON_H_
#define HARDWARE_GOOGLE_PIXEL_USB_UTILSCOMMON_H_
-#include <android-base/chrono_utils.h>
#include <android-base/unique_fd.h>
#include <hardware/google/pixel/pixelstats/pixelatoms.pb.h>
@@ -59,8 +58,8 @@ constexpr char kUvcEnabled[] = "ro.usb.uvc.enabled";
#define FUNCTION_PATH CONFIG_PATH FUNCTION_NAME
#define RNDIS_PATH FUNCTIONS_PATH "gsi.rndis"
-using ::android::base::boot_clock;
using android::hardware::google::pixel::PixelAtoms::VendorUsbDataSessionEvent;
+using ::std::chrono::steady_clock;
// Adds the given fd to the epollfd(epfd).
int addEpollFd(const ::android::base::unique_fd &epfd, const ::android::base::unique_fd &fd);
@@ -74,10 +73,10 @@ int linkFunction(const char *function, int index);
bool setVidPidCommon(const char *vid, const char *pid);
// Pulls down USB gadget. Returns true on success, false on failure
bool resetGadgetCommon();
-void BuildVendorUsbDataSessionEvent(bool is_host, boot_clock::time_point currentTime,
- boot_clock::time_point startTime,
+void BuildVendorUsbDataSessionEvent(bool is_host, steady_clock::time_point currentTime,
+ steady_clock::time_point startTime,
std::vector<std::string> *states,
- std::vector<boot_clock::time_point> *timestamps,
+ std::vector<steady_clock::time_point> *timestamps,
VendorUsbDataSessionEvent *event);
} // namespace usb