diff --git a/power/stats/aidl/aidl_api/android.hardware.power.stats/current/android/hardware/power/stats/IPowerStats.aidl b/power/stats/aidl/aidl_api/android.hardware.power.stats/current/android/hardware/power/stats/IPowerStats.aidl index 0b6387e4aa..5b11695e85 100644 --- a/power/stats/aidl/aidl_api/android.hardware.power.stats/current/android/hardware/power/stats/IPowerStats.aidl +++ b/power/stats/aidl/aidl_api/android.hardware.power.stats/current/android/hardware/power/stats/IPowerStats.aidl @@ -38,5 +38,5 @@ interface IPowerStats { android.hardware.power.stats.EnergyConsumer[] getEnergyConsumerInfo(); android.hardware.power.stats.EnergyConsumerResult[] getEnergyConsumed(in int[] energyConsumerIds); android.hardware.power.stats.Channel[] getEnergyMeterInfo(); - android.hardware.power.stats.EnergyMeasurement[] readEnergyMeters(in int[] channelIds); + android.hardware.power.stats.EnergyMeasurement[] readEnergyMeter(in int[] channelIds); } diff --git a/power/stats/aidl/android/hardware/power/stats/IPowerStats.aidl b/power/stats/aidl/android/hardware/power/stats/IPowerStats.aidl index 24a8f67ca8..7a95f744d0 100644 --- a/power/stats/aidl/android/hardware/power/stats/IPowerStats.aidl +++ b/power/stats/aidl/android/hardware/power/stats/IPowerStats.aidl @@ -107,5 +107,5 @@ interface IPowerStats { * - STATUS_BAD_VALUE if an invalid channelId is provided * - STATUS_FAILED_TRANSACTION if any EnergyMeasurement fails to be returned */ - EnergyMeasurement[] readEnergyMeters(in int[] channelIds); -} \ No newline at end of file + EnergyMeasurement[] readEnergyMeter(in int[] channelIds); +} diff --git a/power/stats/aidl/default/PowerStats.cpp b/power/stats/aidl/default/PowerStats.cpp index 6cb0a738b0..0ffbd083c6 100644 --- a/power/stats/aidl/default/PowerStats.cpp +++ b/power/stats/aidl/default/PowerStats.cpp @@ -53,8 +53,8 @@ ndk::ScopedAStatus PowerStats::getEnergyMeterInfo(std::vector* _aidl_re return ndk::ScopedAStatus::ok(); } -ndk::ScopedAStatus PowerStats::readEnergyMeters(const std::vector& in_channelIds, - std::vector* _aidl_return) { +ndk::ScopedAStatus PowerStats::readEnergyMeter(const std::vector& in_channelIds, + std::vector* _aidl_return) { (void)in_channelIds; (void)_aidl_return; return ndk::ScopedAStatus::ok(); diff --git a/power/stats/aidl/default/PowerStats.h b/power/stats/aidl/default/PowerStats.h index 04c2d547cc..cb98e553f3 100644 --- a/power/stats/aidl/default/PowerStats.h +++ b/power/stats/aidl/default/PowerStats.h @@ -35,8 +35,8 @@ class PowerStats : public BnPowerStats { ndk::ScopedAStatus getEnergyConsumed(const std::vector& in_energyConsumerIds, std::vector* _aidl_return) override; ndk::ScopedAStatus getEnergyMeterInfo(std::vector* _aidl_return) override; - ndk::ScopedAStatus readEnergyMeters(const std::vector& in_channelIds, - std::vector* _aidl_return) override; + ndk::ScopedAStatus readEnergyMeter(const std::vector& in_channelIds, + std::vector* _aidl_return) override; }; } // namespace stats diff --git a/power/stats/aidl/vts/VtsHalPowerStatsTargetTest.cpp b/power/stats/aidl/vts/VtsHalPowerStatsTargetTest.cpp index 033bf1a3a4..bed3fdf352 100644 --- a/power/stats/aidl/vts/VtsHalPowerStatsTargetTest.cpp +++ b/power/stats/aidl/vts/VtsHalPowerStatsTargetTest.cpp @@ -262,7 +262,7 @@ TEST_P(PowerStatsAidl, ValidateChannelUniqueIds) { // Reading energy meter must return a valid status TEST_P(PowerStatsAidl, TestReadEnergyMeter) { std::vector data; - ASSERT_TRUE(powerstats->readEnergyMeters({}, &data).isOk()); + ASSERT_TRUE(powerstats->readEnergyMeter({}, &data).isOk()); } // Reading energy meter must return results for all available channels @@ -271,7 +271,7 @@ TEST_P(PowerStatsAidl, TestGetAllEnergyMeasurements) { ASSERT_TRUE(powerstats->getEnergyMeterInfo(&channels).isOk()); std::vector measurements; - ASSERT_TRUE(powerstats->readEnergyMeters({}, &measurements).isOk()); + ASSERT_TRUE(powerstats->readEnergyMeter({}, &measurements).isOk()); testMatching(channels, &Channel::id, measurements, &EnergyMeasurement::id); } @@ -291,7 +291,7 @@ TEST_P(PowerStatsAidl, TestGetSelectedEnergyMeasurements) { } std::vector selectedMeasurements; - ASSERT_TRUE(powerstats->readEnergyMeters(selectedIds, &selectedMeasurements).isOk()); + ASSERT_TRUE(powerstats->readEnergyMeter(selectedIds, &selectedMeasurements).isOk()); testMatching(selectedChannels, &Channel::id, selectedMeasurements, &EnergyMeasurement::id); }