Skip to content

Commit affe981

Browse files
author
Android Build Coastguard Worker
committed
Snap for 12695596 from 2a249a7 to 25Q1-release
Change-Id: Iee396a42648cf32c239d90245c55fdfe27400d69
2 parents 6f0d96a + 2a249a7 commit affe981

24 files changed

Lines changed: 381 additions & 88 deletions

include/android/performance_hint.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,7 @@ int ASessionCreationConfig_setPreferPowerEfficiency(
518518
pipeline is reached.
519519
*/
520520
int ASessionCreationConfig_setGraphicsPipeline(
521-
ASessionCreationConfig* _Nonnull confi, bool enabled) __INTRODUCED_IN(36);
521+
ASessionCreationConfig* _Nonnull config, bool enabled) __INTRODUCED_IN(36);
522522

523523
__END_DECLS
524524

include/ftl/flags.h

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
#include <bitset>
2323
#include <cstdint>
2424
#include <iterator>
25+
#include <initializer_list>
2526
#include <string>
2627
#include <type_traits>
2728

@@ -40,6 +41,7 @@ class Flags {
4041

4142
public:
4243
constexpr Flags(F f) : mFlags(static_cast<U>(f)) {}
44+
constexpr Flags(std::initializer_list<F> fs) : mFlags(combine(fs)) {}
4345
constexpr Flags() : mFlags(0) {}
4446
constexpr Flags(const Flags<F>& f) : mFlags(f.mFlags) {}
4547

@@ -197,6 +199,14 @@ class Flags {
197199
private:
198200
U mFlags;
199201

202+
static constexpr U combine(std::initializer_list<F> fs) {
203+
U result = 0;
204+
for (const F f : fs) {
205+
result |= static_cast<U>(f);
206+
}
207+
return result;
208+
}
209+
200210
static void appendFlag(std::string& str, const std::string_view& flag, bool& first) {
201211
if (first) {
202212
first = false;

include/input/CoordinateFilter.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class CoordinateFilter {
4444
* the previous call.
4545
* @param coords Coordinates to be overwritten by the corresponding filtered coordinates.
4646
*/
47-
void filter(std::chrono::duration<float> timestamp, PointerCoords& coords);
47+
void filter(std::chrono::nanoseconds timestamp, PointerCoords& coords);
4848

4949
private:
5050
OneEuroFilter mXFilter;

include/input/OneEuroFilter.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ class OneEuroFilter {
5656
* provided in the previous call.
5757
* @param rawPosition Position to be filtered.
5858
*/
59-
float filter(std::chrono::duration<float> timestamp, float rawPosition);
59+
float filter(std::chrono::nanoseconds timestamp, float rawPosition);
6060

6161
private:
6262
/**
@@ -67,7 +67,7 @@ class OneEuroFilter {
6767

6868
/**
6969
* Slope of the cutoff frequency criterion. This is the term scaling the absolute value of the
70-
* filtered signal's speed. The data member is dimensionless, that is, it does not have units.
70+
* filtered signal's speed. Units are 1 / position.
7171
*/
7272
const float mBeta;
7373

@@ -78,17 +78,17 @@ class OneEuroFilter {
7878
const float mSpeedCutoffFreq;
7979

8080
/**
81-
* The timestamp from the previous call. Units are seconds.
81+
* The timestamp from the previous call.
8282
*/
83-
std::optional<std::chrono::duration<float>> mPrevTimestamp;
83+
std::optional<std::chrono::nanoseconds> mPrevTimestamp;
8484

8585
/**
8686
* The raw position from the previous call.
8787
*/
8888
std::optional<float> mPrevRawPosition;
8989

9090
/**
91-
* The filtered velocity from the previous call. Units are position per second.
91+
* The filtered velocity from the previous call. Units are position per nanosecond.
9292
*/
9393
std::optional<float> mPrevFilteredVelocity;
9494

libs/binder/TEST_MAPPING

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -67,15 +67,7 @@
6767
"name": "fuzz_service_test"
6868
},
6969
{
70-
"name": "CtsOsTestCases",
71-
"options": [
72-
{
73-
"include-filter": "android.os.cts.BinderTest"
74-
},
75-
{
76-
"include-filter": "android.os.cts.ParcelTest"
77-
}
78-
]
70+
"name": "CtsOsTestCases_ParcelAndBinderTests"
7971
},
8072
{
8173
"name": "libbinder_rs-internal_test"

libs/binder/ndk/libbinder_ndk.map.txt

Lines changed: 1 addition & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -164,96 +164,53 @@ LIBBINDER_NDK34 { # introduced=UpsideDownCake
164164
LIBBINDER_NDK35 { # introduced=VanillaIceCream
165165
global:
166166
APersistableBundle_readFromParcel;
167-
APersistableBundle_readFromParcel; # llndk=202404
168167
APersistableBundle_writeToParcel;
169-
APersistableBundle_writeToParcel; # llndk=202404
170168
APersistableBundle_new;
171-
APersistableBundle_new; # llndk=202404
172169
APersistableBundle_dup;
173-
APersistableBundle_dup; # llndk=202404
174170
APersistableBundle_delete;
175-
APersistableBundle_delete; # llndk=202404
176171
APersistableBundle_isEqual;
177-
APersistableBundle_isEqual; # llndk=202404
178172
APersistableBundle_size;
179-
APersistableBundle_size; # llndk=202404
180173
APersistableBundle_erase;
181-
APersistableBundle_erase; # llndk=202404
182174
APersistableBundle_putBoolean;
183-
APersistableBundle_putBoolean; # llndk=202404
184175
APersistableBundle_putInt;
185-
APersistableBundle_putInt; # llndk=202404
186176
APersistableBundle_putLong;
187-
APersistableBundle_putLong; # llndk=202404
188177
APersistableBundle_putDouble;
189-
APersistableBundle_putDouble; # llndk=202404
190178
APersistableBundle_putString;
191-
APersistableBundle_putString; # llndk=202404
192179
APersistableBundle_putBooleanVector;
193-
APersistableBundle_putBooleanVector; # llndk=202404
194180
APersistableBundle_putIntVector;
195-
APersistableBundle_putIntVector; # llndk=202404
196181
APersistableBundle_putLongVector;
197-
APersistableBundle_putLongVector; # llndk=202404
198182
APersistableBundle_putDoubleVector;
199-
APersistableBundle_putDoubleVector; # llndk=202404
200183
APersistableBundle_putStringVector;
201-
APersistableBundle_putStringVector; # llndk=202404
202184
APersistableBundle_putPersistableBundle;
203-
APersistableBundle_putPersistableBundle; # llndk=202404
204185
APersistableBundle_getBoolean;
205-
APersistableBundle_getBoolean; # llndk=202404
206186
APersistableBundle_getInt;
207-
APersistableBundle_getInt; # llndk=202404
208187
APersistableBundle_getLong;
209-
APersistableBundle_getLong; # llndk=202404
210188
APersistableBundle_getDouble;
211-
APersistableBundle_getDouble; # llndk=202404
212189
APersistableBundle_getString;
213-
APersistableBundle_getString; # llndk=202404
214190
APersistableBundle_getBooleanVector;
215-
APersistableBundle_getBooleanVector; # llndk=202404
216191
APersistableBundle_getIntVector;
217-
APersistableBundle_getIntVector; # llndk=202404
218192
APersistableBundle_getLongVector;
219-
APersistableBundle_getLongVector; # llndk=202404
220193
APersistableBundle_getDoubleVector;
221-
APersistableBundle_getDoubleVector; # llndk=202404
222194
APersistableBundle_getStringVector;
223-
APersistableBundle_getStringVector; # llndk=202404
224195
APersistableBundle_getPersistableBundle;
225-
APersistableBundle_getPersistableBundle; # llndk=202404
226196
APersistableBundle_getBooleanKeys;
227-
APersistableBundle_getBooleanKeys; # llndk=202404
228197
APersistableBundle_getIntKeys;
229-
APersistableBundle_getIntKeys; # llndk=202404
230198
APersistableBundle_getLongKeys;
231-
APersistableBundle_getLongKeys; # llndk=202404
232199
APersistableBundle_getDoubleKeys;
233-
APersistableBundle_getDoubleKeys; # llndk=202404
234200
APersistableBundle_getStringKeys;
235-
APersistableBundle_getStringKeys; # llndk=202404
236201
APersistableBundle_getBooleanVectorKeys;
237-
APersistableBundle_getBooleanVectorKeys; # llndk=202404
238202
APersistableBundle_getIntVectorKeys;
239-
APersistableBundle_getIntVectorKeys; # llndk=202404
240203
APersistableBundle_getLongVectorKeys;
241-
APersistableBundle_getLongVectorKeys; # llndk=202404
242204
APersistableBundle_getDoubleVectorKeys;
243-
APersistableBundle_getDoubleVectorKeys; # llndk=202404
244205
APersistableBundle_getStringVectorKeys;
245-
APersistableBundle_getStringVectorKeys; # llndk=202404
246206
APersistableBundle_getPersistableBundleKeys;
247-
APersistableBundle_getPersistableBundleKeys; # llndk=202404
248-
AServiceManager_openDeclaredPassthroughHal; # systemapi llndk=202404
207+
AServiceManager_openDeclaredPassthroughHal; # systemapi llndk
249208
};
250209

251210
LIBBINDER_NDK36 { # introduced=36
252211
global:
253212
AIBinder_Class_setTransactionCodeToFunctionNameMap;
254-
AIBinder_Class_setTransactionCodeToFunctionNameMap; # llndk=202504
255213
AIBinder_Class_getFunctionName;
256-
AIBinder_Class_getFunctionName; # llndk=202504
257214
ABinderRpc_registerAccessorProvider; # systemapi
258215
ABinderRpc_unregisterAccessorProvider; # systemapi
259216
ABinderRpc_Accessor_new; # systemapi

libs/ftl/flags_test.cpp

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#include <ftl/flags.h>
1818
#include <gtest/gtest.h>
1919

20-
#include <type_traits>
20+
#include <initializer_list>
2121

2222
namespace android::test {
2323

@@ -59,6 +59,18 @@ TEST(Flags, All) {
5959
ASSERT_FALSE(flags.all(TestFlags::ONE | TestFlags::TWO | TestFlags::THREE));
6060
}
6161

62+
TEST(Flags, ImplicitConstructionAndAssignmentFromInitializerList) {
63+
Flags<TestFlags> flags = {TestFlags::ONE, TestFlags::THREE};
64+
ASSERT_TRUE(flags.test(TestFlags::ONE));
65+
ASSERT_FALSE(flags.test(TestFlags::TWO));
66+
ASSERT_TRUE(flags.test(TestFlags::THREE));
67+
68+
flags = {};
69+
ASSERT_FALSE(flags.test(TestFlags::ONE));
70+
ASSERT_FALSE(flags.test(TestFlags::TWO));
71+
ASSERT_FALSE(flags.test(TestFlags::THREE));
72+
}
73+
6274
TEST(Flags, DefaultConstructor_hasNoFlagsSet) {
6375
Flags<TestFlags> flags;
6476
ASSERT_FALSE(flags.any(TestFlags::ONE | TestFlags::TWO | TestFlags::THREE));

libs/gui/SurfaceComposerClient.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2873,6 +2873,11 @@ void SurfaceComposerClient::getDynamicDisplayInfoInternal(gui::DynamicDisplayInf
28732873
outInfo->hasArrSupport = ginfo.hasArrSupport;
28742874
outInfo->frameRateCategoryRate = ui::FrameRateCategoryRate(ginfo.frameRateCategoryRate.normal,
28752875
ginfo.frameRateCategoryRate.high);
2876+
outInfo->supportedRefreshRates.clear();
2877+
outInfo->supportedRefreshRates.reserve(ginfo.supportedRefreshRates.size());
2878+
for (const auto rate : ginfo.supportedRefreshRates) {
2879+
outInfo->supportedRefreshRates.push_back(static_cast<float>(rate));
2880+
}
28762881
}
28772882

28782883
status_t SurfaceComposerClient::getDynamicDisplayInfoFromId(int64_t displayId,

libs/gui/aidl/android/gui/DynamicDisplayInfo.aidl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,7 @@ parcelable DynamicDisplayInfo {
5050

5151
// Represents frame rate for FrameRateCategory Normal and High.
5252
FrameRateCategoryRate frameRateCategoryRate;
53+
54+
// All the refresh rates supported for the default display mode.
55+
float[] supportedRefreshRates;
5356
}

libs/gui/aidl/android/gui/LutProperties.aidl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,6 @@ parcelable LutProperties {
2727

2828
int size;
2929
@Backing(type="int")
30-
enum SamplingKey { RGB, MAX_RGB }
30+
enum SamplingKey { RGB, MAX_RGB, CIE_Y }
3131
SamplingKey[] samplingKeys;
3232
}

0 commit comments

Comments
 (0)