Loading libs/graphicsenv/GraphicsEnv.cpp +12 −14 Original line number Diff line number Diff line Loading @@ -158,24 +158,23 @@ void GraphicsEnv::setDriverPath(const std::string path) { void GraphicsEnv::setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName) { int64_t driverBuildTime, const std::string& appPackageName) { ATRACE_CALL(); std::lock_guard<std::mutex> lock(mStatsLock); ALOGV("setGpuStats:\n" "\tdriverPackageName[%s]\n" "\tdriverVersionName[%s]\n" "\tdriverVersionCode[%llu]\n" "\tdriverBuildDate[%s]\n" "\tdriverVersionCode[%" PRIu64 "]\n" "\tdriverBuildTime[%" PRId64 "]\n" "\tappPackageName[%s]\n", driverPackageName.c_str(), driverVersionName.c_str(), (unsigned long long)driverVersionCode, driverBuildDate.c_str(), appPackageName.c_str()); driverPackageName.c_str(), driverVersionName.c_str(), driverVersionCode, driverBuildTime, appPackageName.c_str()); mGpuStats.driverPackageName = driverPackageName; mGpuStats.driverVersionName = driverVersionName; mGpuStats.driverVersionCode = driverVersionCode; mGpuStats.driverBuildDate = driverBuildDate; mGpuStats.driverBuildTime = driverBuildTime; mGpuStats.appPackageName = appPackageName; } Loading Loading @@ -264,21 +263,20 @@ void GraphicsEnv::sendGpuStatsLocked(GraphicsEnv::Driver driver, bool isDriverLo ALOGV("sendGpuStats:\n" "\tdriverPackageName[%s]\n" "\tdriverVersionName[%s]\n" "\tdriverVersionCode[%llu]\n" "\tdriverBuildDate[%s]\n" "\tdriverVersionCode[%" PRIu64 "]\n" "\tdriverBuildTime[%" PRId64 "]\n" "\tappPackageName[%s]\n" "\tdriver[%d]\n" "\tisDriverLoaded[%d]\n" "\tdriverLoadingTime[%lld]", "\tdriverLoadingTime[%" PRId64 "]", mGpuStats.driverPackageName.c_str(), mGpuStats.driverVersionName.c_str(), (unsigned long long)mGpuStats.driverVersionCode, mGpuStats.driverBuildDate.c_str(), mGpuStats.appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, (long long)driverLoadingTime); mGpuStats.driverVersionCode, mGpuStats.driverBuildTime, mGpuStats.appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, driverLoadingTime); const sp<IGpuService> gpuService = getGpuService(); if (gpuService) { gpuService->setGpuStats(mGpuStats.driverPackageName, mGpuStats.driverVersionName, mGpuStats.driverVersionCode, mGpuStats.driverBuildDate, mGpuStats.driverVersionCode, mGpuStats.driverBuildTime, mGpuStats.appPackageName, driver, isDriverLoaded, driverLoadingTime); } Loading libs/graphicsenv/IGpuService.cpp +5 −5 Original line number Diff line number Diff line Loading @@ -29,7 +29,7 @@ public: virtual void setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName, int64_t driverBuildTime, const std::string& appPackageName, GraphicsEnv::Driver driver, bool isDriverLoaded, int64_t driverLoadingTime) { Parcel data, reply; Loading @@ -38,7 +38,7 @@ public: data.writeUtf8AsUtf16(driverPackageName); data.writeUtf8AsUtf16(driverVersionName); data.writeUint64(driverVersionCode); data.writeUtf8AsUtf16(driverBuildDate); data.writeInt64(driverBuildTime); data.writeUtf8AsUtf16(appPackageName); data.writeInt32(static_cast<int32_t>(driver)); data.writeBool(isDriverLoaded); Loading Loading @@ -68,8 +68,8 @@ status_t BnGpuService::onTransact(uint32_t code, const Parcel& data, Parcel* rep uint64_t driverVersionCode; if ((status = data.readUint64(&driverVersionCode)) != OK) return status; std::string driverBuildDate; if ((status = data.readUtf8FromUtf16(&driverBuildDate)) != OK) return status; int64_t driverBuildTime; if ((status = data.readInt64(&driverBuildTime)) != OK) return status; std::string appPackageName; if ((status = data.readUtf8FromUtf16(&appPackageName)) != OK) return status; Loading @@ -83,7 +83,7 @@ status_t BnGpuService::onTransact(uint32_t code, const Parcel& data, Parcel* rep int64_t driverLoadingTime; if ((status = data.readInt64(&driverLoadingTime)) != OK) return status; setGpuStats(driverPackageName, driverVersionName, driverVersionCode, driverBuildDate, setGpuStats(driverPackageName, driverVersionName, driverVersionCode, driverBuildTime, appPackageName, static_cast<GraphicsEnv::Driver>(driver), isDriverLoaded, driverLoadingTime); Loading libs/graphicsenv/include/graphicsenv/GraphicsEnv.h +3 −3 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ private: std::string driverPackageName; std::string driverVersionName; uint64_t driverVersionCode; std::string driverBuildDate; int64_t driverBuildTime; std::string appPackageName; Driver glDriverToLoad; Driver glDriverFallback; Loading @@ -59,7 +59,7 @@ private: : driverPackageName(""), driverVersionName(""), driverVersionCode(0), driverBuildDate(""), driverBuildTime(0), appPackageName(""), glDriverToLoad(Driver::NONE), glDriverFallback(Driver::NONE), Loading @@ -80,7 +80,7 @@ public: void setDriverPath(const std::string path); android_namespace_t* getDriverNamespace(); void setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t versionCode, const std::string& driverBuildDate, uint64_t versionCode, int64_t driverBuildTime, const std::string& appPackageName); void setDriverToLoad(Driver driver); void setDriverLoaded(Api api, bool isDriverLoaded, int64_t driverLoadingTime); Loading libs/graphicsenv/include/graphicsenv/IGpuService.h +1 −1 Original line number Diff line number Diff line Loading @@ -35,7 +35,7 @@ public: // set GPU stats from GraphicsEnvironment. virtual void setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName, int64_t driverBuildTime, const std::string& appPackageName, GraphicsEnv::Driver driver, bool isDriverLoaded, int64_t driverLoadingTime) = 0; }; Loading services/gpuservice/GpuService.cpp +6 −7 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ GpuService::GpuService() = default; void GpuService::setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName, int64_t driverBuildTime, const std::string& appPackageName, GraphicsEnv::Driver driver, bool isDriverLoaded, int64_t driverLoadingTime) { ATRACE_CALL(); Loading @@ -48,15 +48,14 @@ void GpuService::setGpuStats(const std::string& driverPackageName, ALOGV("Received:\n" "\tdriverPackageName[%s]\n" "\tdriverVersionName[%s]\n" "\tdriverVersionCode[%llu]\n" "\tdriverBuildDate[%s]\n" "\tdriverVersionCode[%" PRIu64 "]\n" "\tdriverBuildTime[%" PRId64 "]\n" "\tappPackageName[%s]\n" "\tdriver[%d]\n" "\tisDriverLoaded[%d]\n" "\tdriverLoadingTime[%lld]", driverPackageName.c_str(), driverVersionName.c_str(), (unsigned long long)driverVersionCode, driverBuildDate.c_str(), appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, (long long)driverLoadingTime); "\tdriverLoadingTime[%" PRId64 "]", driverPackageName.c_str(), driverVersionName.c_str(), driverVersionCode, driverBuildTime, appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, driverLoadingTime); } status_t GpuService::shellCommand(int /*in*/, int out, int err, std::vector<String16>& args) { Loading Loading
libs/graphicsenv/GraphicsEnv.cpp +12 −14 Original line number Diff line number Diff line Loading @@ -158,24 +158,23 @@ void GraphicsEnv::setDriverPath(const std::string path) { void GraphicsEnv::setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName) { int64_t driverBuildTime, const std::string& appPackageName) { ATRACE_CALL(); std::lock_guard<std::mutex> lock(mStatsLock); ALOGV("setGpuStats:\n" "\tdriverPackageName[%s]\n" "\tdriverVersionName[%s]\n" "\tdriverVersionCode[%llu]\n" "\tdriverBuildDate[%s]\n" "\tdriverVersionCode[%" PRIu64 "]\n" "\tdriverBuildTime[%" PRId64 "]\n" "\tappPackageName[%s]\n", driverPackageName.c_str(), driverVersionName.c_str(), (unsigned long long)driverVersionCode, driverBuildDate.c_str(), appPackageName.c_str()); driverPackageName.c_str(), driverVersionName.c_str(), driverVersionCode, driverBuildTime, appPackageName.c_str()); mGpuStats.driverPackageName = driverPackageName; mGpuStats.driverVersionName = driverVersionName; mGpuStats.driverVersionCode = driverVersionCode; mGpuStats.driverBuildDate = driverBuildDate; mGpuStats.driverBuildTime = driverBuildTime; mGpuStats.appPackageName = appPackageName; } Loading Loading @@ -264,21 +263,20 @@ void GraphicsEnv::sendGpuStatsLocked(GraphicsEnv::Driver driver, bool isDriverLo ALOGV("sendGpuStats:\n" "\tdriverPackageName[%s]\n" "\tdriverVersionName[%s]\n" "\tdriverVersionCode[%llu]\n" "\tdriverBuildDate[%s]\n" "\tdriverVersionCode[%" PRIu64 "]\n" "\tdriverBuildTime[%" PRId64 "]\n" "\tappPackageName[%s]\n" "\tdriver[%d]\n" "\tisDriverLoaded[%d]\n" "\tdriverLoadingTime[%lld]", "\tdriverLoadingTime[%" PRId64 "]", mGpuStats.driverPackageName.c_str(), mGpuStats.driverVersionName.c_str(), (unsigned long long)mGpuStats.driverVersionCode, mGpuStats.driverBuildDate.c_str(), mGpuStats.appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, (long long)driverLoadingTime); mGpuStats.driverVersionCode, mGpuStats.driverBuildTime, mGpuStats.appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, driverLoadingTime); const sp<IGpuService> gpuService = getGpuService(); if (gpuService) { gpuService->setGpuStats(mGpuStats.driverPackageName, mGpuStats.driverVersionName, mGpuStats.driverVersionCode, mGpuStats.driverBuildDate, mGpuStats.driverVersionCode, mGpuStats.driverBuildTime, mGpuStats.appPackageName, driver, isDriverLoaded, driverLoadingTime); } Loading
libs/graphicsenv/IGpuService.cpp +5 −5 Original line number Diff line number Diff line Loading @@ -29,7 +29,7 @@ public: virtual void setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName, int64_t driverBuildTime, const std::string& appPackageName, GraphicsEnv::Driver driver, bool isDriverLoaded, int64_t driverLoadingTime) { Parcel data, reply; Loading @@ -38,7 +38,7 @@ public: data.writeUtf8AsUtf16(driverPackageName); data.writeUtf8AsUtf16(driverVersionName); data.writeUint64(driverVersionCode); data.writeUtf8AsUtf16(driverBuildDate); data.writeInt64(driverBuildTime); data.writeUtf8AsUtf16(appPackageName); data.writeInt32(static_cast<int32_t>(driver)); data.writeBool(isDriverLoaded); Loading Loading @@ -68,8 +68,8 @@ status_t BnGpuService::onTransact(uint32_t code, const Parcel& data, Parcel* rep uint64_t driverVersionCode; if ((status = data.readUint64(&driverVersionCode)) != OK) return status; std::string driverBuildDate; if ((status = data.readUtf8FromUtf16(&driverBuildDate)) != OK) return status; int64_t driverBuildTime; if ((status = data.readInt64(&driverBuildTime)) != OK) return status; std::string appPackageName; if ((status = data.readUtf8FromUtf16(&appPackageName)) != OK) return status; Loading @@ -83,7 +83,7 @@ status_t BnGpuService::onTransact(uint32_t code, const Parcel& data, Parcel* rep int64_t driverLoadingTime; if ((status = data.readInt64(&driverLoadingTime)) != OK) return status; setGpuStats(driverPackageName, driverVersionName, driverVersionCode, driverBuildDate, setGpuStats(driverPackageName, driverVersionName, driverVersionCode, driverBuildTime, appPackageName, static_cast<GraphicsEnv::Driver>(driver), isDriverLoaded, driverLoadingTime); Loading
libs/graphicsenv/include/graphicsenv/GraphicsEnv.h +3 −3 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ private: std::string driverPackageName; std::string driverVersionName; uint64_t driverVersionCode; std::string driverBuildDate; int64_t driverBuildTime; std::string appPackageName; Driver glDriverToLoad; Driver glDriverFallback; Loading @@ -59,7 +59,7 @@ private: : driverPackageName(""), driverVersionName(""), driverVersionCode(0), driverBuildDate(""), driverBuildTime(0), appPackageName(""), glDriverToLoad(Driver::NONE), glDriverFallback(Driver::NONE), Loading @@ -80,7 +80,7 @@ public: void setDriverPath(const std::string path); android_namespace_t* getDriverNamespace(); void setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t versionCode, const std::string& driverBuildDate, uint64_t versionCode, int64_t driverBuildTime, const std::string& appPackageName); void setDriverToLoad(Driver driver); void setDriverLoaded(Api api, bool isDriverLoaded, int64_t driverLoadingTime); Loading
libs/graphicsenv/include/graphicsenv/IGpuService.h +1 −1 Original line number Diff line number Diff line Loading @@ -35,7 +35,7 @@ public: // set GPU stats from GraphicsEnvironment. virtual void setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName, int64_t driverBuildTime, const std::string& appPackageName, GraphicsEnv::Driver driver, bool isDriverLoaded, int64_t driverLoadingTime) = 0; }; Loading
services/gpuservice/GpuService.cpp +6 −7 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ GpuService::GpuService() = default; void GpuService::setGpuStats(const std::string& driverPackageName, const std::string& driverVersionName, uint64_t driverVersionCode, const std::string& driverBuildDate, const std::string& appPackageName, int64_t driverBuildTime, const std::string& appPackageName, GraphicsEnv::Driver driver, bool isDriverLoaded, int64_t driverLoadingTime) { ATRACE_CALL(); Loading @@ -48,15 +48,14 @@ void GpuService::setGpuStats(const std::string& driverPackageName, ALOGV("Received:\n" "\tdriverPackageName[%s]\n" "\tdriverVersionName[%s]\n" "\tdriverVersionCode[%llu]\n" "\tdriverBuildDate[%s]\n" "\tdriverVersionCode[%" PRIu64 "]\n" "\tdriverBuildTime[%" PRId64 "]\n" "\tappPackageName[%s]\n" "\tdriver[%d]\n" "\tisDriverLoaded[%d]\n" "\tdriverLoadingTime[%lld]", driverPackageName.c_str(), driverVersionName.c_str(), (unsigned long long)driverVersionCode, driverBuildDate.c_str(), appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, (long long)driverLoadingTime); "\tdriverLoadingTime[%" PRId64 "]", driverPackageName.c_str(), driverVersionName.c_str(), driverVersionCode, driverBuildTime, appPackageName.c_str(), static_cast<int32_t>(driver), isDriverLoaded, driverLoadingTime); } status_t GpuService::shellCommand(int /*in*/, int out, int err, std::vector<String16>& args) { Loading