diff options
127 files changed, 2476 insertions, 1534 deletions
diff --git a/Android.bp b/Android.bp index f8a9e0f0f393..ecf6deeeb432 100644 --- a/Android.bp +++ b/Android.bp @@ -69,7 +69,7 @@ filegroup { // Java/AIDL sources under frameworks/base ":framework-annotations", ":framework-blobstore-sources", - ":framework-connectivity-nsd-sources", + ":framework-connectivity-tiramisu-sources", ":framework-core-sources", ":framework-drm-sources", ":framework-graphics-nonupdatable-sources", diff --git a/core/api/current.txt b/core/api/current.txt index 8c313a25ccec..d9753ab5e4a0 100644 --- a/core/api/current.txt +++ b/core/api/current.txt @@ -8649,10 +8649,10 @@ package android.bluetooth { method public android.bluetooth.BluetoothDevice getRemoteDevice(byte[]); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_SCAN) public int getScanMode(); method public int getState(); - method public int isCisCentralSupported(); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_SCAN) public boolean isDiscovering(); method public boolean isEnabled(); method public boolean isLe2MPhySupported(); + method public int isLeAudioSupported(); method public boolean isLeCodedPhySupported(); method public boolean isLeExtendedAdvertisingSupported(); method public boolean isLePeriodicAdvertisingSupported(); @@ -9520,6 +9520,20 @@ package android.bluetooth { field @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public static final String ACTION_LE_AUDIO_CONNECTION_STATE_CHANGED = "android.bluetooth.action.LE_AUDIO_CONNECTION_STATE_CHANGED"; } + public final class BluetoothLeAudioCodecConfig { + method @NonNull public String getCodecName(); + method public int getCodecType(); + method public static int getMaxCodecType(); + field public static final int SOURCE_CODEC_TYPE_INVALID = 1000000; // 0xf4240 + field public static final int SOURCE_CODEC_TYPE_LC3 = 0; // 0x0 + } + + public static final class BluetoothLeAudioCodecConfig.Builder { + ctor public BluetoothLeAudioCodecConfig.Builder(); + method @NonNull public android.bluetooth.BluetoothLeAudioCodecConfig build(); + method @NonNull public android.bluetooth.BluetoothLeAudioCodecConfig.Builder setCodecType(int); + } + public final class BluetoothManager { method public android.bluetooth.BluetoothAdapter getAdapter(); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public java.util.List<android.bluetooth.BluetoothDevice> getConnectedDevices(int); @@ -31576,8 +31590,8 @@ package android.os { method @Deprecated public void readMap(@NonNull java.util.Map, @Nullable ClassLoader); method public <K, V> void readMap(@NonNull java.util.Map<? super K,? super V>, @Nullable ClassLoader, @NonNull Class<K>, @NonNull Class<V>); method @Deprecated @Nullable public <T extends android.os.Parcelable> T readParcelable(@Nullable ClassLoader); - method @Nullable public <T extends android.os.Parcelable> T readParcelable(@Nullable ClassLoader, @NonNull Class<T>); - method @Nullable public android.os.Parcelable[] readParcelableArray(@Nullable ClassLoader); + method @Nullable public <T> T readParcelable(@Nullable ClassLoader, @NonNull Class<T>); + method @Deprecated @Nullable public android.os.Parcelable[] readParcelableArray(@Nullable ClassLoader); method @Nullable public <T> T[] readParcelableArray(@Nullable ClassLoader, @NonNull Class<T>); method @Deprecated @Nullable public android.os.Parcelable.Creator<?> readParcelableCreator(@Nullable ClassLoader); method @Nullable public <T> android.os.Parcelable.Creator<T> readParcelableCreator(@Nullable ClassLoader, @NonNull Class<T>); @@ -31586,7 +31600,7 @@ package android.os { method @Nullable public android.os.PersistableBundle readPersistableBundle(); method @Nullable public android.os.PersistableBundle readPersistableBundle(@Nullable ClassLoader); method @Deprecated @Nullable public java.io.Serializable readSerializable(); - method @Nullable public <T extends java.io.Serializable> T readSerializable(@Nullable ClassLoader, @NonNull Class<T>); + method @Nullable public <T> T readSerializable(@Nullable ClassLoader, @NonNull Class<T>); method @NonNull public android.util.Size readSize(); method @NonNull public android.util.SizeF readSizeF(); method @Deprecated @Nullable public <T> android.util.SparseArray<T> readSparseArray(@Nullable ClassLoader); @@ -40055,6 +40069,7 @@ package android.telecom { field public static final String EXTRA_CHILD_ADDRESS = "android.telecom.extra.CHILD_ADDRESS"; field public static final String EXTRA_IS_RTT_AUDIO_PRESENT = "android.telecom.extra.IS_RTT_AUDIO_PRESENT"; field public static final String EXTRA_LAST_FORWARDED_NUMBER = "android.telecom.extra.LAST_FORWARDED_NUMBER"; + field public static final String EXTRA_LAST_KNOWN_CELL_IDENTITY = "android.telecom.extra.LAST_KNOWN_CELL_IDENTITY"; field public static final String EXTRA_SIP_INVITE = "android.telecom.extra.SIP_INVITE"; field public static final int PROPERTY_ASSISTED_DIALING = 512; // 0x200 field public static final int PROPERTY_CROSS_SIM = 8192; // 0x2000 diff --git a/core/api/module-lib-current.txt b/core/api/module-lib-current.txt index 3a35f249d177..81b4ee80a1d2 100644 --- a/core/api/module-lib-current.txt +++ b/core/api/module-lib-current.txt @@ -190,6 +190,10 @@ package android.media.session { package android.net { + public final class ConnectivityFrameworkInitializerTiramisu { + method public static void registerServiceWrappers(); + } + public final class EthernetNetworkSpecifier extends android.net.NetworkSpecifier implements android.os.Parcelable { ctor public EthernetNetworkSpecifier(@NonNull String); method public int describeContents(); diff --git a/core/api/system-current.txt b/core/api/system-current.txt index 91b8786cc615..ca3c51152514 100644 --- a/core/api/system-current.txt +++ b/core/api/system-current.txt @@ -66,6 +66,7 @@ package android { field public static final String BIND_TRANSLATION_SERVICE = "android.permission.BIND_TRANSLATION_SERVICE"; field public static final String BIND_TRUST_AGENT = "android.permission.BIND_TRUST_AGENT"; field public static final String BIND_TV_REMOTE_SERVICE = "android.permission.BIND_TV_REMOTE_SERVICE"; + field public static final String BLUETOOTH_MAP = "android.permission.BLUETOOTH_MAP"; field public static final String BRICK = "android.permission.BRICK"; field public static final String BRIGHTNESS_SLIDER_USAGE = "android.permission.BRIGHTNESS_SLIDER_USAGE"; field public static final String BROADCAST_CLOSE_SYSTEM_DIALOGS = "android.permission.BROADCAST_CLOSE_SYSTEM_DIALOGS"; @@ -12884,6 +12885,7 @@ package android.telephony.ims { method @NonNull public java.util.Set<android.telephony.ims.FeatureTagState> getDeregisteredFeatureTags(); method @NonNull public java.util.Set<android.telephony.ims.FeatureTagState> getDeregisteringFeatureTags(); method @NonNull public java.util.Set<java.lang.String> getRegisteredFeatureTags(); + method @NonNull public java.util.Set<java.lang.String> getRegisteringFeatureTags(); method public void writeToParcel(@NonNull android.os.Parcel, int); field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.DelegateRegistrationState> CREATOR; field public static final int DEREGISTERED_REASON_NOT_PROVISIONED = 1; // 0x1 @@ -12891,8 +12893,10 @@ package android.telephony.ims { field public static final int DEREGISTERED_REASON_UNKNOWN = 0; // 0x0 field public static final int DEREGISTERING_REASON_DESTROY_PENDING = 6; // 0x6 field public static final int DEREGISTERING_REASON_FEATURE_TAGS_CHANGING = 5; // 0x5 + field public static final int DEREGISTERING_REASON_LOSING_PDN = 7; // 0x7 field public static final int DEREGISTERING_REASON_PDN_CHANGE = 3; // 0x3 field public static final int DEREGISTERING_REASON_PROVISIONING_CHANGE = 4; // 0x4 + field public static final int DEREGISTERING_REASON_UNSPECIFIED = 8; // 0x8 } public static final class DelegateRegistrationState.Builder { @@ -12901,6 +12905,7 @@ package android.telephony.ims { method @NonNull public android.telephony.ims.DelegateRegistrationState.Builder addDeregisteringFeatureTag(@NonNull String, int); method @NonNull public android.telephony.ims.DelegateRegistrationState.Builder addRegisteredFeatureTag(@NonNull String); method @NonNull public android.telephony.ims.DelegateRegistrationState.Builder addRegisteredFeatureTags(@NonNull java.util.Set<java.lang.String>); + method @NonNull public android.telephony.ims.DelegateRegistrationState.Builder addRegisteringFeatureTags(@NonNull java.util.Set<java.lang.String>); method @NonNull public android.telephony.ims.DelegateRegistrationState build(); } diff --git a/core/java/Android.bp b/core/java/Android.bp index ca9a46847dea..343830a468dc 100644 --- a/core/java/Android.bp +++ b/core/java/Android.bp @@ -399,6 +399,21 @@ filegroup { ], } +aidl_interface { + name: "android.os.statsbootstrap_aidl", + unstable: true, + srcs: [ + "android/os/IStatsBootstrapAtomService.aidl", + "android/os/StatsBootstrapAtom.aidl", + "android/os/StatsBootstrapAtomValue.aidl", + ], + backend: { + cpp: { + enabled: true, + }, + }, +} + // utility classes statically linked into wifi-service filegroup { name: "framework-wifi-service-shared-srcs", diff --git a/core/java/android/app/SystemServiceRegistry.java b/core/java/android/app/SystemServiceRegistry.java index e2fd35940b52..0171f0a5a327 100644 --- a/core/java/android/app/SystemServiceRegistry.java +++ b/core/java/android/app/SystemServiceRegistry.java @@ -125,6 +125,7 @@ import android.media.tv.TvInputManager; import android.media.tv.tunerresourcemanager.ITunerResourceManager; import android.media.tv.tunerresourcemanager.TunerResourceManager; import android.net.ConnectivityFrameworkInitializer; +import android.net.ConnectivityFrameworkInitializerTiramisu; import android.net.EthernetManager; import android.net.IEthernetManager; import android.net.IIpSecService; @@ -140,8 +141,6 @@ import android.net.TetheringManager; import android.net.VpnManager; import android.net.lowpan.ILowpanManager; import android.net.lowpan.LowpanManager; -import android.net.nsd.INsdManager; -import android.net.nsd.NsdManager; import android.net.vcn.IVcnManagementService; import android.net.vcn.VcnManager; import android.net.wifi.WifiFrameworkInitializer; @@ -566,15 +565,6 @@ public final class SystemServiceRegistry { ctx.mMainThread.getHandler()); }}); - registerService(Context.NSD_SERVICE, NsdManager.class, - new CachedServiceFetcher<NsdManager>() { - @Override - public NsdManager createService(ContextImpl ctx) throws ServiceNotFoundException { - IBinder b = ServiceManager.getServiceOrThrow(Context.NSD_SERVICE); - INsdManager service = INsdManager.Stub.asInterface(b); - return new NsdManager(ctx.getOuterContext(), service); - }}); - registerService(Context.PEOPLE_SERVICE, PeopleManager.class, new CachedServiceFetcher<PeopleManager>() { @Override @@ -1486,6 +1476,7 @@ public final class SystemServiceRegistry { MediaFrameworkInitializer.registerServiceWrappers(); RoleFrameworkInitializer.registerServiceWrappers(); SchedulingFrameworkInitializer.registerServiceWrappers(); + ConnectivityFrameworkInitializerTiramisu.registerServiceWrappers(); } finally { // If any of the above code throws, we're in a pretty bad shape and the process // will likely crash, but we'll reset it just in case there's an exception handler... diff --git a/core/java/android/bluetooth/BluetoothAdapter.java b/core/java/android/bluetooth/BluetoothAdapter.java index 2c875fee101b..14be9215c769 100644 --- a/core/java/android/bluetooth/BluetoothAdapter.java +++ b/core/java/android/bluetooth/BluetoothAdapter.java @@ -2283,21 +2283,21 @@ public final class BluetoothAdapter { public @interface LeFeatureReturnValues {} /** - * Returns {@link BluetoothStatusCodes#SUCCESS} if LE Connected Isochronous Stream Central - * feature is supported, returns {@link BluetoothStatusCodes#ERROR_FEATURE_NOT_SUPPORTED} if + * Returns {@link BluetoothStatusCodes#SUCCESS} if the LE audio feature is + * supported, returns {@link BluetoothStatusCodes#ERROR_FEATURE_NOT_SUPPORTED} if * the feature is not supported or an error code. * - * @return whether the chipset supports the LE Connected Isochronous Stream Central feature + * @return whether the LE audio is supported */ @RequiresNoPermission - public @LeFeatureReturnValues int isCisCentralSupported() { + public @LeFeatureReturnValues int isLeAudioSupported() { if (!getLeAccess()) { return BluetoothStatusCodes.ERROR_BLUETOOTH_NOT_ENABLED; } try { mServiceLock.readLock().lock(); if (mService != null) { - return mService.isCisCentralSupported(); + return mService.isLeAudioSupported(); } } catch (RemoteException e) { e.rethrowFromSystemServer(); diff --git a/core/java/android/bluetooth/BluetoothLeAudioCodecConfig.java b/core/java/android/bluetooth/BluetoothLeAudioCodecConfig.java new file mode 100644 index 000000000000..dcaf4b682f44 --- /dev/null +++ b/core/java/android/bluetooth/BluetoothLeAudioCodecConfig.java @@ -0,0 +1,129 @@ +/* + * Copyright (C) 2021 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package android.bluetooth; + +import android.annotation.IntDef; +import android.annotation.NonNull; + +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; + +/** + * Represents the codec configuration for a Bluetooth LE Audio source device. + * <p>Contains the source codec type. + * <p>The source codec type values are the same as those supported by the + * device hardware. + * + * {@see BluetoothLeAudioCodecConfig} + */ +public final class BluetoothLeAudioCodecConfig { + // Add an entry for each source codec here. + + /** @hide */ + @IntDef(prefix = "SOURCE_CODEC_TYPE_", value = { + SOURCE_CODEC_TYPE_LC3, + SOURCE_CODEC_TYPE_INVALID + }) + @Retention(RetentionPolicy.SOURCE) + public @interface SourceCodecType {}; + + public static final int SOURCE_CODEC_TYPE_LC3 = 0; + public static final int SOURCE_CODEC_TYPE_INVALID = 1000 * 1000; + + /** + * Represents the count of valid source codec types. Can be accessed via + * {@link #getMaxCodecType}. + */ + private static final int SOURCE_CODEC_TYPE_MAX = 1; + + private final @SourceCodecType int mCodecType; + + /** + * Creates a new BluetoothLeAudioCodecConfig. + * + * @param codecType the source codec type + */ + private BluetoothLeAudioCodecConfig(@SourceCodecType int codecType) { + mCodecType = codecType; + } + + @Override + public String toString() { + return "{codecName:" + getCodecName() + "}"; + } + + /** + * Gets the codec type. + * + * @return the codec type + */ + public @SourceCodecType int getCodecType() { + return mCodecType; + } + + /** + * Returns the valid codec types count. + */ + public static int getMaxCodecType() { + return SOURCE_CODEC_TYPE_MAX; + } + + /** + * Gets the codec name. + * + * @return the codec name + */ + public @NonNull String getCodecName() { + switch (mCodecType) { + case SOURCE_CODEC_TYPE_LC3: + return "LC3"; + case SOURCE_CODEC_TYPE_INVALID: + return "INVALID CODEC"; + default: + break; + } + return "UNKNOWN CODEC(" + mCodecType + ")"; + } + + /** + * Builder for {@link BluetoothLeAudioCodecConfig}. + * <p> By default, the codec type will be set to + * {@link BluetoothLeAudioCodecConfig#SOURCE_CODEC_TYPE_INVALID} + */ + public static final class Builder { + private int mCodecType = BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_INVALID; + + /** + * Set codec type for Bluetooth codec config. + * + * @param codecType of this codec + * @return the same Builder instance + */ + public @NonNull Builder setCodecType(@SourceCodecType int codecType) { + mCodecType = codecType; + return this; + } + + /** + * Build {@link BluetoothLeAudioCodecConfig}. + * @return new BluetoothLeAudioCodecConfig built + */ + public @NonNull BluetoothLeAudioCodecConfig build() { + return new BluetoothLeAudioCodecConfig(mCodecType); + } + } +} diff --git a/core/java/android/bluetooth/BluetoothPbap.java b/core/java/android/bluetooth/BluetoothPbap.java index c000e56e7b04..8ee38d3e1260 100644 --- a/core/java/android/bluetooth/BluetoothPbap.java +++ b/core/java/android/bluetooth/BluetoothPbap.java @@ -23,7 +23,6 @@ import android.annotation.SdkConstant; import android.annotation.SuppressLint; import android.annotation.SystemApi; import android.bluetooth.annotations.RequiresBluetoothConnectPermission; -import android.bluetooth.annotations.RequiresLegacyBluetoothPermission; import android.compat.annotation.UnsupportedAppUsage; import android.content.Attributable; import android.content.AttributionSource; @@ -170,7 +169,7 @@ public class BluetoothPbap implements BluetoothProfile { mContext.getPackageManager(), 0); intent.setComponent(comp); if (comp == null || !mContext.bindServiceAsUser(intent, mConnection, 0, - UserHandle.CURRENT_OR_SELF)) { + UserHandle.CURRENT)) { Log.e(TAG, "Could not bind to Bluetooth Pbap Service with " + intent); return false; } diff --git a/core/java/android/bluetooth/BluetoothProfileConnector.java b/core/java/android/bluetooth/BluetoothProfileConnector.java index a254291f57db..ecd5e4077de9 100644 --- a/core/java/android/bluetooth/BluetoothProfileConnector.java +++ b/core/java/android/bluetooth/BluetoothProfileConnector.java @@ -103,7 +103,7 @@ public abstract class BluetoothProfileConnector<T> { mContext.getPackageManager(), 0); intent.setComponent(comp); if (comp == null || !mContext.bindServiceAsUser(intent, mConnection, 0, - UserHandle.CURRENT_OR_SELF)) { + UserHandle.CURRENT)) { logError("Could not bind to Bluetooth Service with " + intent); return false; } diff --git a/core/java/android/bluetooth/le/TransportBlock.java b/core/java/android/bluetooth/le/TransportBlock.java index b388beda6b3b..18bad9c3c259 100644 --- a/core/java/android/bluetooth/le/TransportBlock.java +++ b/core/java/android/bluetooth/le/TransportBlock.java @@ -24,6 +24,7 @@ import android.util.Log; import java.nio.BufferOverflowException; import java.nio.ByteBuffer; +import java.util.Arrays; /** * Wrapper for Transport Discovery Data Transport Blocks. @@ -59,8 +60,12 @@ public final class TransportBlock implements Parcelable { mOrgId = in.readInt(); mTdsFlags = in.readInt(); mTransportDataLength = in.readInt(); - mTransportData = new byte[mTransportDataLength]; - in.readByteArray(mTransportData); + if (mTransportDataLength > 0) { + mTransportData = new byte[mTransportDataLength]; + in.readByteArray(mTransportData); + } else { + mTransportData = null; + } } @Override @@ -68,7 +73,9 @@ public final class TransportBlock implements Parcelable { dest.writeInt(mOrgId); dest.writeInt(mTdsFlags); dest.writeInt(mTransportDataLength); - dest.writeByteArray(mTransportData); + if (mTransportData != null) { + dest.writeByteArray(mTransportData); + } } /** @@ -79,6 +86,21 @@ public final class TransportBlock implements Parcelable { return 0; } + /** + * @hide + */ + @Override + public boolean equals(@Nullable Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + TransportBlock other = (TransportBlock) obj; + return Arrays.equals(toByteArray(), other.toByteArray()); + } + public static final @NonNull Creator<TransportBlock> CREATOR = new Creator<TransportBlock>() { @Override public TransportBlock createFromParcel(Parcel in) { diff --git a/core/java/android/bluetooth/le/TransportDiscoveryData.java b/core/java/android/bluetooth/le/TransportDiscoveryData.java index c8e97f9a823a..2b52f19798ad 100644 --- a/core/java/android/bluetooth/le/TransportDiscoveryData.java +++ b/core/java/android/bluetooth/le/TransportDiscoveryData.java @@ -26,6 +26,7 @@ import java.nio.BufferOverflowException; import java.nio.BufferUnderflowException; import java.nio.ByteBuffer; import java.util.ArrayList; +import java.util.Arrays; import java.util.Collections; import java.util.List; @@ -96,6 +97,21 @@ public final class TransportDiscoveryData implements Parcelable { return 0; } + /** + * @hide + */ + @Override + public boolean equals(@Nullable Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + TransportDiscoveryData other = (TransportDiscoveryData) obj; + return Arrays.equals(toByteArray(), other.toByteArray()); + } + @Override public void writeToParcel(@NonNull Parcel dest, int flags) { dest.writeInt(mTransportDataType); diff --git a/core/java/android/content/AttributionSource.aidl b/core/java/android/content/AttributionSource.aidl index 10d5c274ae91..7554cb24b41f 100644 --- a/core/java/android/content/AttributionSource.aidl +++ b/core/java/android/content/AttributionSource.aidl @@ -16,4 +16,5 @@ package android.content; +@JavaOnlyStableParcelable parcelable AttributionSource; diff --git a/core/java/android/net/NetworkPolicy.java b/core/java/android/net/NetworkPolicy.java index 8a0211c2ec2f..70fe5d677b4f 100644 --- a/core/java/android/net/NetworkPolicy.java +++ b/core/java/android/net/NetworkPolicy.java @@ -16,11 +16,19 @@ package android.net; +import static android.net.NetworkStats.METERED_ALL; +import static android.net.NetworkStats.METERED_YES; +import static android.net.NetworkTemplate.MATCH_CARRIER; +import static android.net.NetworkTemplate.MATCH_MOBILE; +import static android.net.NetworkTemplate.SUBSCRIBER_ID_MATCH_RULE_EXACT; + +import android.annotation.NonNull; import android.annotation.Nullable; import android.compat.annotation.UnsupportedAppUsage; import android.os.Parcel; import android.os.Parcelable; import android.util.BackupUtils; +import android.util.Log; import android.util.Range; import android.util.RecurrenceRule; @@ -42,10 +50,25 @@ import java.util.Objects; * @hide */ public class NetworkPolicy implements Parcelable, Comparable<NetworkPolicy> { + private static final String TAG = NetworkPolicy.class.getSimpleName(); private static final int VERSION_INIT = 1; private static final int VERSION_RULE = 2; private static final int VERSION_RAPID = 3; + /** + * Initial Version of the NetworkTemplate backup serializer. + */ + private static final int TEMPLATE_BACKUP_VERSION_1_INIT = 1; + /** + * Version of the NetworkTemplate backup serializer that added carrier template support. + */ + private static final int TEMPLATE_BACKUP_VERSION_2_SUPPORT_CARRIER_TEMPLATE = 2; + /** + * Latest Version of the NetworkTemplate Backup Serializer. + */ + private static final int TEMPLATE_BACKUP_VERSION_LATEST = + TEMPLATE_BACKUP_VERSION_2_SUPPORT_CARRIER_TEMPLATE; + public static final int CYCLE_NONE = -1; public static final long WARNING_DISABLED = -1; public static final long LIMIT_DISABLED = -1; @@ -255,7 +278,7 @@ public class NetworkPolicy implements Parcelable, Comparable<NetworkPolicy> { DataOutputStream out = new DataOutputStream(baos); out.writeInt(VERSION_RAPID); - out.write(template.getBytesForBackup()); + out.write(getNetworkTemplateBytesForBackup()); cycleRule.writeToStream(out); out.writeLong(warningBytes); out.writeLong(limitBytes); @@ -274,7 +297,7 @@ public class NetworkPolicy implements Parcelable, Comparable<NetworkPolicy> { throw new BackupUtils.BadVersionException("Unknown backup version: " + version); } - final NetworkTemplate template = NetworkTemplate.getNetworkTemplateFromBackup(in); + final NetworkTemplate template = getNetworkTemplateFromBackup(in); final RecurrenceRule cycleRule; if (version >= VERSION_RULE) { cycleRule = new RecurrenceRule(in); @@ -298,4 +321,61 @@ public class NetworkPolicy implements Parcelable, Comparable<NetworkPolicy> { return new NetworkPolicy(template, cycleRule, warningBytes, limitBytes, lastWarningSnooze, lastLimitSnooze, lastRapidSnooze, metered, inferred); } + + @NonNull + private byte[] getNetworkTemplateBytesForBackup() throws IOException { + if (!template.isPersistable()) { + Log.wtf(TAG, "Trying to backup non-persistable template: " + this); + } + + final ByteArrayOutputStream baos = new ByteArrayOutputStream(); + final DataOutputStream out = new DataOutputStream(baos); + + out.writeInt(TEMPLATE_BACKUP_VERSION_LATEST); + + out.writeInt(template.getMatchRule()); + BackupUtils.writeString(out, template.getSubscriberId()); + BackupUtils.writeString(out, template.getNetworkId()); + out.writeInt(template.getMeteredness()); + out.writeInt(template.getSubscriberIdMatchRule()); + + return baos.toByteArray(); + } + + @NonNull + private static NetworkTemplate getNetworkTemplateFromBackup(DataInputStream in) + throws IOException, BackupUtils.BadVersionException { + int version = in.readInt(); + if (version < TEMPLATE_BACKUP_VERSION_1_INIT || version > TEMPLATE_BACKUP_VERSION_LATEST) { + throw new BackupUtils.BadVersionException("Unknown Backup Serialization Version"); + } + + int matchRule = in.readInt(); + final String subscriberId = BackupUtils.readString(in); + final String networkId = BackupUtils.readString(in); + + final int metered; + final int subscriberIdMatchRule; + if (version >= TEMPLATE_BACKUP_VERSION_2_SUPPORT_CARRIER_TEMPLATE) { + metered = in.readInt(); + subscriberIdMatchRule = in.readInt(); + } else { + // For backward compatibility, fill the missing filters from match rules. + metered = (matchRule == MATCH_MOBILE + || matchRule == NetworkTemplate.MATCH_MOBILE_WILDCARD + || matchRule == MATCH_CARRIER) ? METERED_YES : METERED_ALL; + subscriberIdMatchRule = SUBSCRIBER_ID_MATCH_RULE_EXACT; + } + + try { + return new NetworkTemplate(matchRule, + subscriberId, new String[]{subscriberId}, + networkId, metered, NetworkStats.ROAMING_ALL, + NetworkStats.DEFAULT_NETWORK_ALL, NetworkTemplate.NETWORK_TYPE_ALL, + NetworkTemplate.OEM_MANAGED_ALL, subscriberIdMatchRule); + } catch (IllegalArgumentException e) { + throw new BackupUtils.BadVersionException( + "Restored network template contains unknown match rule " + matchRule, e); + } + } } diff --git a/core/java/android/net/OWNERS b/core/java/android/net/OWNERS index f55bcd31feb7..b989488f9015 100644 --- a/core/java/android/net/OWNERS +++ b/core/java/android/net/OWNERS @@ -2,5 +2,6 @@ set noparent include platform/frameworks/base:/services/core/java/com/android/server/net/OWNERS +per-file **IpSec* = file:/services/core/java/com/android/server/vcn/OWNERS per-file SSL*,Uri*,Url* = prb@google.com,oth@google.com,narayan@google.com,ngeoffray@google.com per-file SntpClient* = file:/services/core/java/com/android/server/timedetector/OWNERS diff --git a/core/java/android/net/vcn/VcnCellUnderlyingNetworkPriority.java b/core/java/android/net/vcn/VcnCellUnderlyingNetworkPriority.java index 50a6bfc065d7..b3f734524078 100644 --- a/core/java/android/net/vcn/VcnCellUnderlyingNetworkPriority.java +++ b/core/java/android/net/vcn/VcnCellUnderlyingNetworkPriority.java @@ -151,7 +151,7 @@ public final class VcnCellUnderlyingNetworkPriority extends VcnUnderlyingNetwork /** Retrieve the allowed PLMN IDs, or an empty set if any PLMN ID is acceptable. */ @NonNull - public Set<String> getAllowedPlmnIds() { + public Set<String> getAllowedOperatorPlmnIds() { return Collections.unmodifiableSet(mAllowedNetworkPlmnIds); } @@ -211,7 +211,7 @@ public final class VcnCellUnderlyingNetworkPriority extends VcnUnderlyingNetwork } /** This class is used to incrementally build WifiNetworkPriority objects. */ - public static class Builder extends VcnUnderlyingNetworkPriority.Builder<Builder> { + public static final class Builder extends VcnUnderlyingNetworkPriority.Builder<Builder> { @NonNull private final Set<String> mAllowedNetworkPlmnIds = new ArraySet<>(); @NonNull private final Set<Integer> mAllowedSpecificCarrierIds = new ArraySet<>(); @@ -233,7 +233,7 @@ public final class VcnCellUnderlyingNetworkPriority extends VcnUnderlyingNetwork * and {@link SubscriptionInfo#getMncString()}. */ @NonNull - public Builder setAllowedPlmnIds(@NonNull Set<String> allowedNetworkPlmnIds) { + public Builder setAllowedOperatorPlmnIds(@NonNull Set<String> allowedNetworkPlmnIds) { validatePlmnIds(allowedNetworkPlmnIds); mAllowedNetworkPlmnIds.clear(); diff --git a/core/java/android/net/vcn/VcnGatewayConnectionConfig.java b/core/java/android/net/vcn/VcnGatewayConnectionConfig.java index 31e38c0b7574..55d3ecd2c92f 100644 --- a/core/java/android/net/vcn/VcnGatewayConnectionConfig.java +++ b/core/java/android/net/vcn/VcnGatewayConnectionConfig.java @@ -198,7 +198,10 @@ public final class VcnGatewayConnectionConfig { private static final String EXPOSED_CAPABILITIES_KEY = "mExposedCapabilities"; @NonNull private final SortedSet<Integer> mExposedCapabilities; - private static final String UNDERLYING_NETWORK_PRIORITIES_KEY = "mUnderlyingNetworkPriorities"; + /** @hide */ + @VisibleForTesting(visibility = Visibility.PRIVATE) + public static final String UNDERLYING_NETWORK_PRIORITIES_KEY = "mUnderlyingNetworkPriorities"; + @NonNull private final LinkedHashSet<VcnUnderlyingNetworkPriority> mUnderlyingNetworkPriorities; private static final String MAX_MTU_KEY = "mMaxMtu"; @@ -229,6 +232,8 @@ public final class VcnGatewayConnectionConfig { validate(); } + // Null check MUST be done for all new fields added to VcnGatewayConnectionConfig, to avoid + // crashes when parsing PersistableBundle built on old platforms. /** @hide */ @VisibleForTesting(visibility = Visibility.PRIVATE) public VcnGatewayConnectionConfig(@NonNull PersistableBundle in) { @@ -239,19 +244,30 @@ public final class VcnGatewayConnectionConfig { final PersistableBundle exposedCapsBundle = in.getPersistableBundle(EXPOSED_CAPABILITIES_KEY); - final PersistableBundle networkPrioritiesBundle = - in.getPersistableBundle(UNDERLYING_NETWORK_PRIORITIES_KEY); - mGatewayConnectionName = in.getString(GATEWAY_CONNECTION_NAME_KEY); mTunnelConnectionParams = TunnelConnectionParamsUtils.fromPersistableBundle(tunnelConnectionParamsBundle); mExposedCapabilities = new TreeSet<>(PersistableBundleUtils.toList( exposedCapsBundle, PersistableBundleUtils.INTEGER_DESERIALIZER)); - mUnderlyingNetworkPriorities = - new LinkedHashSet<>( - PersistableBundleUtils.toList( - networkPrioritiesBundle, - VcnUnderlyingNetworkPriority::fromPersistableBundle)); + + final PersistableBundle networkPrioritiesBundle = + in.getPersistableBundle(UNDERLYING_NETWORK_PRIORITIES_KEY); + + if (networkPrioritiesBundle == null) { + // UNDERLYING_NETWORK_PRIORITIES_KEY was added in Android T. Thus + // VcnGatewayConnectionConfig created on old platforms will not have this data and will + // be assigned with the default value + mUnderlyingNetworkPriorities = + new LinkedHashSet<>(DEFAULT_UNDERLYING_NETWORK_PRIORITIES); + + } else { + mUnderlyingNetworkPriorities = + new LinkedHashSet<>( + PersistableBundleUtils.toList( + networkPrioritiesBundle, + VcnUnderlyingNetworkPriority::fromPersistableBundle)); + } + mRetryIntervalsMs = in.getLongArray(RETRY_INTERVAL_MS_KEY); mMaxMtu = in.getInt(MAX_MTU_KEY); @@ -420,6 +436,7 @@ public final class VcnGatewayConnectionConfig { mGatewayConnectionName, mTunnelConnectionParams, mExposedCapabilities, + mUnderlyingNetworkPriorities, Arrays.hashCode(mRetryIntervalsMs), mMaxMtu); } @@ -434,6 +451,7 @@ public final class VcnGatewayConnectionConfig { return mGatewayConnectionName.equals(rhs.mGatewayConnectionName) && mTunnelConnectionParams.equals(rhs.mTunnelConnectionParams) && mExposedCapabilities.equals(rhs.mExposedCapabilities) + && mUnderlyingNetworkPriorities.equals(rhs.mUnderlyingNetworkPriorities) && Arrays.equals(mRetryIntervalsMs, rhs.mRetryIntervalsMs) && mMaxMtu == rhs.mMaxMtu; } diff --git a/core/java/android/net/vcn/VcnWifiUnderlyingNetworkPriority.java b/core/java/android/net/vcn/VcnWifiUnderlyingNetworkPriority.java index 2ba916927705..85eb100779a2 100644 --- a/core/java/android/net/vcn/VcnWifiUnderlyingNetworkPriority.java +++ b/core/java/android/net/vcn/VcnWifiUnderlyingNetworkPriority.java @@ -79,7 +79,7 @@ public final class VcnWifiUnderlyingNetworkPriority extends VcnUnderlyingNetwork } final VcnWifiUnderlyingNetworkPriority rhs = (VcnWifiUnderlyingNetworkPriority) other; - return mSsid == rhs.mSsid; + return mSsid.equals(rhs.mSsid); } /** @hide */ diff --git a/core/java/android/os/AppZygote.java b/core/java/android/os/AppZygote.java index 74b814ea4159..c8b4226ecae0 100644 --- a/core/java/android/os/AppZygote.java +++ b/core/java/android/os/AppZygote.java @@ -45,6 +45,8 @@ public class AppZygote { // Last UID/GID of the range the AppZygote can setuid()/setgid() to private final int mZygoteUidGidMax; + private final int mZygoteRuntimeFlags; + private final Object mLock = new Object(); /** @@ -56,11 +58,13 @@ public class AppZygote { private final ApplicationInfo mAppInfo; - public AppZygote(ApplicationInfo appInfo, int zygoteUid, int uidGidMin, int uidGidMax) { + public AppZygote(ApplicationInfo appInfo, int zygoteUid, int uidGidMin, int uidGidMax, + int runtimeFlags) { mAppInfo = appInfo; mZygoteUid = zygoteUid; mZygoteUidGidMin = uidGidMin; mZygoteUidGidMax = uidGidMax; + mZygoteRuntimeFlags = runtimeFlags; } /** @@ -110,7 +114,7 @@ public class AppZygote { mZygoteUid, mZygoteUid, null, // gids - 0, // runtimeFlags + mZygoteRuntimeFlags, // runtimeFlags "app_zygote", // seInfo abi, // abi abi, // acceptedAbiList diff --git a/core/java/android/os/GraphicsEnvironment.java b/core/java/android/os/GraphicsEnvironment.java index be21fea1d0df..2ea63297aff2 100644 --- a/core/java/android/os/GraphicsEnvironment.java +++ b/core/java/android/os/GraphicsEnvironment.java @@ -71,6 +71,9 @@ public class GraphicsEnvironment { private static final String SYSTEM_DRIVER_NAME = "system"; private static final String SYSTEM_DRIVER_VERSION_NAME = ""; private static final long SYSTEM_DRIVER_VERSION_CODE = 0; + private static final String ANGLE_DRIVER_NAME = "angle"; + private static final String ANGLE_DRIVER_VERSION_NAME = ""; + private static final long ANGLE_DRIVER_VERSION_CODE = 0; // System properties related to updatable graphics drivers. private static final String PROPERTY_GFX_DRIVER_PRODUCTION = "ro.gfx.driver.0"; @@ -138,14 +141,24 @@ public class GraphicsEnvironment { Trace.traceEnd(Trace.TRACE_TAG_GRAPHICS); Trace.traceBegin(Trace.TRACE_TAG_GRAPHICS, "setupAngle"); - setupAngle(context, coreSettings, pm, packageName); + boolean useAngle = false; + if (setupAngle(context, coreSettings, pm, packageName)) { + if (shouldUseAngle(context, coreSettings, packageName)) { + useAngle = true; + setGpuStats(ANGLE_DRIVER_NAME, ANGLE_DRIVER_VERSION_NAME, ANGLE_DRIVER_VERSION_CODE, + 0, packageName, getVulkanVersion(pm)); + } + } Trace.traceEnd(Trace.TRACE_TAG_GRAPHICS); Trace.traceBegin(Trace.TRACE_TAG_GRAPHICS, "chooseDriver"); if (!chooseDriver(context, coreSettings, pm, packageName, appInfoWithMetaData)) { - setGpuStats(SYSTEM_DRIVER_NAME, SYSTEM_DRIVER_VERSION_NAME, SYSTEM_DRIVER_VERSION_CODE, - SystemProperties.getLong(PROPERTY_GFX_DRIVER_BUILD_TIME, 0), packageName, - getVulkanVersion(pm)); + if (!useAngle) { + setGpuStats(SYSTEM_DRIVER_NAME, SYSTEM_DRIVER_VERSION_NAME, + SYSTEM_DRIVER_VERSION_CODE, + SystemProperties.getLong(PROPERTY_GFX_DRIVER_BUILD_TIME, 0), + packageName, getVulkanVersion(pm)); + } } Trace.traceEnd(Trace.TRACE_TAG_GRAPHICS); } diff --git a/core/java/android/os/Parcel.java b/core/java/android/os/Parcel.java index 8894c85fa7b4..09eac79c991e 100644 --- a/core/java/android/os/Parcel.java +++ b/core/java/android/os/Parcel.java @@ -4210,8 +4210,7 @@ public final class Parcel { * trying to instantiate an element. */ @Nullable - public <T extends Parcelable> T readParcelable(@Nullable ClassLoader loader, - @NonNull Class<T> clazz) { + public <T> T readParcelable(@Nullable ClassLoader loader, @NonNull Class<T> clazz) { Objects.requireNonNull(clazz); return readParcelableInternal(loader, clazz); } @@ -4222,10 +4221,6 @@ public final class Parcel { @SuppressWarnings("unchecked") @Nullable private <T> T readParcelableInternal(@Nullable ClassLoader loader, @Nullable Class<T> clazz) { - if (clazz != null && !Parcelable.class.isAssignableFrom(clazz)) { - throw new BadParcelableException("About to unparcel a parcelable object " - + " but class required " + clazz.getName() + " is not Parcelable"); - } Parcelable.Creator<?> creator = readParcelableCreatorInternal(loader, clazz); if (creator == null) { return null; @@ -4388,9 +4383,16 @@ public final class Parcel { * The given class loader will be used to load any enclosed * Parcelables. * @return the Parcelable array, or null if the array is null + * + * @deprecated Use the type-safer version {@link #readParcelableArray(ClassLoader, Class)} + * starting from Android {@link Build.VERSION_CODES#TIRAMISU}. Also consider changing the + * format to use {@link #createTypedArray(Parcelable.Creator)} if possible (eg. if the + * items' class is final) since this is also more performant. Note that changing to the + * latter also requires changing the writes. */ + @Deprecated @Nullable - public final Parcelable[] readParcelableArray(@Nullable ClassLoader loader) { + public Parcelable[] readParcelableArray(@Nullable ClassLoader loader) { int N = readInt(); if (N < 0) { return null; @@ -4454,8 +4456,7 @@ public final class Parcel { * deserializing the object. */ @Nullable - public <T extends Serializable> T readSerializable(@Nullable ClassLoader loader, - @NonNull Class<T> clazz) { + public <T> T readSerializable(@Nullable ClassLoader loader, @NonNull Class<T> clazz) { Objects.requireNonNull(clazz); return readSerializableInternal( loader == null ? getClass().getClassLoader() : loader, clazz); @@ -4467,11 +4468,6 @@ public final class Parcel { @Nullable private <T> T readSerializableInternal(@Nullable final ClassLoader loader, @Nullable Class<T> clazz) { - if (clazz != null && !Serializable.class.isAssignableFrom(clazz)) { - throw new BadParcelableException("About to unparcel a serializable object " - + " but class required " + clazz.getName() + " is not Serializable"); - } - String name = readString(); if (name == null) { // For some reason we were unable to read the name of the Serializable (either there diff --git a/core/java/com/android/internal/os/SystemServerClassLoaderFactory.java b/core/java/com/android/internal/os/SystemServerClassLoaderFactory.java new file mode 100644 index 000000000000..615e4b793752 --- /dev/null +++ b/core/java/com/android/internal/os/SystemServerClassLoaderFactory.java @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2021 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.android.internal.os; + +import android.os.Build; +import android.util.ArrayMap; + +import dalvik.system.PathClassLoader; + +/** @hide */ +public final class SystemServerClassLoaderFactory { + /** + * Map of paths to PathClassLoader for standalone system server jars. + */ + private static final ArrayMap<String, PathClassLoader> sLoadedPaths = new ArrayMap<>(); + + /** + * Creates and caches a ClassLoader for the jar at the given path, or returns a cached + * ClassLoader if it exists. + * + * The parent class loader should always be the system server class loader. Changing it has + * implications that require discussion with the mainline team. + * + * @hide for internal use only + */ + public static PathClassLoader getOrCreateClassLoader(String path, ClassLoader parent) { + PathClassLoader pathClassLoader = sLoadedPaths.get(path); + if (pathClassLoader == null) { + pathClassLoader = (PathClassLoader) ClassLoaderFactory.createClassLoader( + path, /*librarySearchPath=*/null, /*libraryPermittedPath=*/null, parent, + Build.VERSION.SDK_INT, /*isNamespaceShared=*/true , /*classLoaderName=*/null); + sLoadedPaths.put(path, pathClassLoader); + } + return pathClassLoader; + } +} diff --git a/core/java/com/android/internal/os/ZygoteInit.java b/core/java/com/android/internal/os/ZygoteInit.java index 6b2d35bf6128..611f644ffc7d 100644 --- a/core/java/com/android/internal/os/ZygoteInit.java +++ b/core/java/com/android/internal/os/ZygoteInit.java @@ -46,6 +46,7 @@ import android.system.OsConstants; import android.system.StructCapUserData; import android.system.StructCapUserHeader; import android.text.Hyphenator; +import android.text.TextUtils; import android.util.EventLog; import android.util.Log; import android.util.Slog; @@ -560,9 +561,8 @@ public class ZygoteInit { /** * Create the classloader for the system server and store it in - * {@link sCachedSystemServerClassLoader}. This function may be called through JNI in - * system server startup, when the runtime is in a critically low state. Do not do - * extended computation etc here. + * {@link sCachedSystemServerClassLoader}. This function is called through JNI in the forked + * system server process in the zygote SELinux domain. */ private static ClassLoader getOrCreateSystemServerClassLoader() { if (sCachedSystemServerClassLoader == null) { @@ -576,6 +576,29 @@ public class ZygoteInit { } /** + * Creates class loaders for standalone system server jars. This function is called through JNI + * in the forked system server process in the zygote SELinux domain. + */ + private static void prefetchStandaloneSystemServerJars() { + String envStr = Os.getenv("STANDALONE_SYSTEMSERVER_JARS"); + if (TextUtils.isEmpty(envStr)) { + return; + } + for (String jar : envStr.split(":")) { + try { + SystemServerClassLoaderFactory.getOrCreateClassLoader( + jar, getOrCreateSystemServerClassLoader()); + } catch (Error e) { + // We don't want the process to crash for this error because prefetching is just an + // optimization. + Log.e(TAG, + String.format("Failed to prefetch standalone system server jar \"%s\": %s", + jar, e.toString())); + } + } + } + + /** * Note that preparing the profiles for system server does not require special selinux * permissions. From the installer perspective the system server is a regular package which can * capture profile information. diff --git a/core/jni/android_media_AudioAttributes.cpp b/core/jni/android_media_AudioAttributes.cpp index f1ae268f4c16..423ef7cd980b 100644 --- a/core/jni/android_media_AudioAttributes.cpp +++ b/core/jni/android_media_AudioAttributes.cpp @@ -58,7 +58,7 @@ static struct { jmethodID setSystemUsage; jmethodID setInternalCapturePreset; jmethodID setContentType; - jmethodID setFlags; + jmethodID replaceFlags; jmethodID addTag; } gAudioAttributesBuilderMethods; @@ -130,7 +130,7 @@ static jint nativeAudioAttributesToJavaAudioAttributes( gAudioAttributesBuilderMethods.setContentType, attributes.content_type); env->CallObjectMethod(jAttributeBuilder.get(), - gAudioAttributesBuilderMethods.setFlags, + gAudioAttributesBuilderMethods.replaceFlags, attributes.flags); env->CallObjectMethod(jAttributeBuilder.get(), gAudioAttributesBuilderMethods.addTag, @@ -205,8 +205,8 @@ int register_android_media_AudioAttributes(JNIEnv *env) gAudioAttributesBuilderMethods.setContentType = GetMethodIDOrDie( env, audioAttributesBuilderClass, "setContentType", "(I)Landroid/media/AudioAttributes$Builder;"); - gAudioAttributesBuilderMethods.setFlags = GetMethodIDOrDie( - env, audioAttributesBuilderClass, "setFlags", + gAudioAttributesBuilderMethods.replaceFlags = GetMethodIDOrDie( + env, audioAttributesBuilderClass, "replaceFlags", "(I)Landroid/media/AudioAttributes$Builder;"); gAudioAttributesBuilderMethods.addTag = GetMethodIDOrDie( env, audioAttributesBuilderClass, "addTag", diff --git a/core/jni/android_media_AudioSystem.cpp b/core/jni/android_media_AudioSystem.cpp index 4b93363b5b90..c847e4d7654f 100644 --- a/core/jni/android_media_AudioSystem.cpp +++ b/core/jni/android_media_AudioSystem.cpp @@ -2273,10 +2273,8 @@ android_media_AudioSystem_getMicrophones(JNIEnv *env, jobject thiz, jobject jMic return jStatus; } -static jint -android_media_AudioSystem_getHwOffloadEncodingFormatsSupportedForA2DP( - JNIEnv *env, jobject thiz, jobject jEncodingFormatList) -{ +static jint android_media_AudioSystem_getHwOffloadFormatsSupportedForBluetoothMedia( + JNIEnv *env, jobject thiz, jint deviceType, jobject jEncodingFormatList) { ALOGV("%s", __FUNCTION__); jint jStatus = AUDIO_JAVA_SUCCESS; if (!env->IsInstanceOf(jEncodingFormatList, gArrayListClass)) { @@ -2284,8 +2282,10 @@ android_media_AudioSystem_getHwOffloadEncodingFormatsSupportedForA2DP( return (jint)AUDIO_JAVA_BAD_VALUE; } std::vector<audio_format_t> encodingFormats; - status_t status = AudioSystem::getHwOffloadEncodingFormatsSupportedForA2DP( - &encodingFormats); + status_t status = + AudioSystem::getHwOffloadFormatsSupportedForBluetoothMedia(static_cast<audio_devices_t>( + deviceType), + &encodingFormats); if (status != NO_ERROR) { ALOGE("%s: error %d", __FUNCTION__, status); jStatus = nativeToJavaStatus(status); @@ -2810,8 +2810,8 @@ static const JNINativeMethod gMethods[] = {"setA11yServicesUids", "([I)I", (void *)android_media_AudioSystem_setA11yServicesUids}, {"isHapticPlaybackSupported", "()Z", (void *)android_media_AudioSystem_isHapticPlaybackSupported}, - {"getHwOffloadEncodingFormatsSupportedForA2DP", "(Ljava/util/ArrayList;)I", - (void *)android_media_AudioSystem_getHwOffloadEncodingFormatsSupportedForA2DP}, + {"getHwOffloadFormatsSupportedForBluetoothMedia", "(ILjava/util/ArrayList;)I", + (void *)android_media_AudioSystem_getHwOffloadFormatsSupportedForBluetoothMedia}, {"setSupportedSystemUsages", "([I)I", (void *)android_media_AudioSystem_setSupportedSystemUsages}, {"setAllowedCapturePolicy", "(II)I", diff --git a/core/jni/com_android_internal_os_Zygote.cpp b/core/jni/com_android_internal_os_Zygote.cpp index 1b3f78c8f3d8..aacf700b1168 100644 --- a/core/jni/com_android_internal_os_Zygote.cpp +++ b/core/jni/com_android_internal_os_Zygote.cpp @@ -124,6 +124,7 @@ static jmethodID gCallPostForkChildHooks; static constexpr const char* kZygoteInitClassName = "com/android/internal/os/ZygoteInit"; static jclass gZygoteInitClass; static jmethodID gGetOrCreateSystemServerClassLoader; +static jmethodID gPrefetchStandaloneSystemServerJars; static bool gIsSecurityEnforced = true; @@ -1617,6 +1618,12 @@ static void SpecializeCommon(JNIEnv* env, uid_t uid, gid_t gid, jintArray gids, // at a later point (but may not have rights to use AoT artifacts). env->ExceptionClear(); } + // Also prefetch standalone system server jars. The reason for doing this here is the same + // as above. + env->CallStaticObjectMethod(gZygoteInitClass, gPrefetchStandaloneSystemServerJars); + if (env->ExceptionCheck()) { + env->ExceptionClear(); + } } if (setresgid(gid, gid, gid) == -1) { @@ -2678,6 +2685,9 @@ int register_com_android_internal_os_Zygote(JNIEnv* env) { gGetOrCreateSystemServerClassLoader = GetStaticMethodIDOrDie(env, gZygoteInitClass, "getOrCreateSystemServerClassLoader", "()Ljava/lang/ClassLoader;"); + gPrefetchStandaloneSystemServerJars = + GetStaticMethodIDOrDie(env, gZygoteInitClass, "prefetchStandaloneSystemServerJars", + "()V"); RegisterMethodsOrDie(env, "com/android/internal/os/Zygote", gMethods, NELEM(gMethods)); diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml index 1a38ea10a97d..fcf830e3dc27 100644 --- a/core/res/AndroidManifest.xml +++ b/core/res/AndroidManifest.xml @@ -2018,7 +2018,7 @@ <permission android:name="android.permission.BLUETOOTH_PRIVILEGED" android:protectionLevel="signature|privileged" /> - <!-- Control access to email providers exclusively for Bluetooth + <!-- @SystemApi Control access to email providers exclusively for Bluetooth @hide --> <permission android:name="android.permission.BLUETOOTH_MAP" diff --git a/core/tests/bluetoothtests/src/android/bluetooth/BluetoothLeAudioCodecConfigTest.java b/core/tests/bluetoothtests/src/android/bluetooth/BluetoothLeAudioCodecConfigTest.java new file mode 100644 index 000000000000..c3d707cd7596 --- /dev/null +++ b/core/tests/bluetoothtests/src/android/bluetooth/BluetoothLeAudioCodecConfigTest.java @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2021 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package android.bluetooth; + +import android.test.suitebuilder.annotation.SmallTest; + +import junit.framework.TestCase; + +/** + * Unit test cases for {@link BluetoothLeAudioCodecConfig}. + */ +public class BluetoothLeAudioCodecConfigTest extends TestCase { + private int[] mCodecTypeArray = new int[] { + BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_LC3, + BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_INVALID, + }; + + @SmallTest + public void testBluetoothLeAudioCodecConfig_valid_get_methods() { + + for (int codecIdx = 0; codecIdx < mCodecTypeArray.length; codecIdx++) { + int codecType = mCodecTypeArray[codecIdx]; + + BluetoothLeAudioCodecConfig leAudioCodecConfig = + buildBluetoothLeAudioCodecConfig(codecType); + + if (codecType == BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_LC3) { + assertEquals("LC3", leAudioCodecConfig.getCodecName()); + } + if (codecType == BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_INVALID) { + assertEquals("INVALID CODEC", leAudioCodecConfig.getCodecName()); + } + + assertEquals(codecType, leAudioCodecConfig.getCodecType()); + } + } + + private BluetoothLeAudioCodecConfig buildBluetoothLeAudioCodecConfig(int sourceCodecType) { + return new BluetoothLeAudioCodecConfig.Builder() + .setCodecType(sourceCodecType) + .build(); + + } +} diff --git a/core/tests/coretests/Android.bp b/core/tests/coretests/Android.bp index 93e4a294a2cb..05ec00fe84f0 100644 --- a/core/tests/coretests/Android.bp +++ b/core/tests/coretests/Android.bp @@ -46,6 +46,7 @@ android_test { "androidx.test.ext.junit", "androidx.test.runner", "androidx.test.rules", + "kotlin-test", "mockito-target-minus-junit4", "ub-uiautomator", "platform-test-annotations", diff --git a/core/tests/coretests/src/android/net/NetworkPolicyTest.kt b/core/tests/coretests/src/android/net/NetworkPolicyTest.kt new file mode 100644 index 000000000000..d936cad15689 --- /dev/null +++ b/core/tests/coretests/src/android/net/NetworkPolicyTest.kt @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2021 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package android.net + +import android.text.format.Time.TIMEZONE_UTC +import androidx.test.runner.AndroidJUnit4 +import org.junit.Test +import org.junit.runner.RunWith +import java.io.ByteArrayInputStream +import java.io.DataInputStream +import java.time.ZoneId +import kotlin.test.assertEquals + +private const val TEST_IMSI1 = "TESTIMSI1" +private const val TEST_SSID1 = "TESTISSID1" + +@RunWith(AndroidJUnit4::class) +class NetworkPolicyTest { + @Test + fun testTemplateBackupRestore() { + assertPolicyBackupRestore(createTestPolicyForTemplate( + NetworkTemplate.buildTemplateWifi(TEST_SSID1))) + assertPolicyBackupRestore(createTestPolicyForTemplate( + NetworkTemplate.buildTemplateMobileAll(TEST_IMSI1))) + assertPolicyBackupRestore(createTestPolicyForTemplate( + NetworkTemplate.buildTemplateCarrierMetered(TEST_IMSI1))) + } + + private fun createTestPolicyForTemplate(template: NetworkTemplate): NetworkPolicy { + return NetworkPolicy(template, NetworkPolicy.buildRule(5, ZoneId.of(TIMEZONE_UTC)), + NetworkPolicy.WARNING_DISABLED, NetworkPolicy.LIMIT_DISABLED, + NetworkPolicy.SNOOZE_NEVER, NetworkPolicy.SNOOZE_NEVER, NetworkPolicy.SNOOZE_NEVER, + /*metered*/ false, /*inferred*/ true) + } + + private fun assertPolicyBackupRestore(policy: NetworkPolicy) { + val bytes = policy.bytesForBackup + val stream = DataInputStream(ByteArrayInputStream(bytes)) + val restored = NetworkPolicy.getNetworkPolicyFromBackup(stream) + assertEquals(policy, restored) + } +}
\ No newline at end of file diff --git a/core/tests/coretests/src/android/text/format/DateIntervalFormatTest.java b/core/tests/coretests/src/android/text/format/DateIntervalFormatTest.java index 6be9306bbd2d..bd4d80de9b13 100644 --- a/core/tests/coretests/src/android/text/format/DateIntervalFormatTest.java +++ b/core/tests/coretests/src/android/text/format/DateIntervalFormatTest.java @@ -169,13 +169,13 @@ public class DateIntervalFormatTest { assertEquals("19/1/2009", formatDateRange(es_ES, tz, fixedTime, fixedTime + HOUR, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); - assertEquals("19/1/2009–22/1/2009", + assertEquals("19/1/2009 – 22/1/2009", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * DAY, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); - assertEquals("19/1/2009–22/4/2009", + assertEquals("19/1/2009 – 22/4/2009", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * MONTH, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); - assertEquals("19/1/2009–9/2/2012", + assertEquals("19/1/2009 – 9/2/2012", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); @@ -251,35 +251,35 @@ public class DateIntervalFormatTest { assertEquals("19–22 de enero de 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * DAY, 0)); - assertEquals("19–22 de ene. de 2009", + assertEquals("19–22 de ene de 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * DAY, FORMAT_SHOW_DATE | FORMAT_ABBREV_ALL)); - assertEquals("lun, 19 de ene. – jue, 22 de ene. de 2009", + assertEquals("lun, 19 de ene – jue, 22 de ene de 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * DAY, FORMAT_SHOW_WEEKDAY | FORMAT_ABBREV_ALL)); - assertEquals("lunes, 19 de enero–jueves, 22 de enero de 2009", + assertEquals("lunes, 19 de enero – jueves, 22 de enero de 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * DAY, FORMAT_SHOW_WEEKDAY)); - assertEquals("19 de enero–22 de abril de 2009", + assertEquals("19 de enero – 22 de abril de 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * MONTH, 0)); - assertEquals("19 de ene. – 22 de abr. 2009", + assertEquals("19 de ene – 22 de abr 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * MONTH, FORMAT_SHOW_DATE | FORMAT_ABBREV_ALL)); - assertEquals("lun, 19 de ene. – mié, 22 de abr. de 2009", + assertEquals("lun, 19 de ene – mié, 22 de abr de 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * MONTH, FORMAT_SHOW_WEEKDAY | FORMAT_ABBREV_ALL)); assertEquals("enero–abril de 2009", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * MONTH, FORMAT_NO_MONTH_DAY)); - assertEquals("19 de ene. de 2009 – 9 de feb. de 2012", + assertEquals("19 de ene de 2009 – 9 de feb de 2012", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_DATE | FORMAT_ABBREV_ALL)); - assertEquals("ene. de 2009 – feb. de 2012", + assertEquals("ene de 2009 – feb de 2012", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_NO_MONTH_DAY | FORMAT_ABBREV_ALL)); - assertEquals("19 de enero de 2009–9 de febrero de 2012", + assertEquals("19 de enero de 2009 – 9 de febrero de 2012", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * YEAR, 0)); - assertEquals("lunes, 19 de enero de 2009–jueves, 9 de febrero de 2012", + assertEquals("lunes, 19 de enero de 2009 – jueves, 9 de febrero de 2012", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_WEEKDAY)); // The same tests but for es_ES. @@ -291,10 +291,10 @@ public class DateIntervalFormatTest { assertEquals("lun, 19 ene – jue, 22 ene 2009", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * DAY, FORMAT_SHOW_WEEKDAY | FORMAT_ABBREV_ALL)); - assertEquals("lunes, 19 de enero–jueves, 22 de enero de 2009", + assertEquals("lunes, 19 de enero – jueves, 22 de enero de 2009", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * DAY, FORMAT_SHOW_WEEKDAY)); - assertEquals("19 de enero–22 de abril de 2009", + assertEquals("19 de enero – 22 de abril de 2009", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * MONTH, 0)); assertEquals("19 ene – 22 abr 2009", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * MONTH, @@ -311,9 +311,9 @@ public class DateIntervalFormatTest { assertEquals("ene 2009 – feb 2012", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_NO_MONTH_DAY | FORMAT_ABBREV_ALL)); - assertEquals("19 de enero de 2009–9 de febrero de 2012", + assertEquals("19 de enero de 2009 – 9 de febrero de 2012", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * YEAR, 0)); - assertEquals("lunes, 19 de enero de 2009–jueves, 9 de febrero de 2012", + assertEquals("lunes, 19 de enero de 2009 – jueves, 9 de febrero de 2012", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_WEEKDAY)); } diff --git a/data/etc/privapp-permissions-platform.xml b/data/etc/privapp-permissions-platform.xml index 1c7659ec0bec..fefcebeaef20 100644 --- a/data/etc/privapp-permissions-platform.xml +++ b/data/etc/privapp-permissions-platform.xml @@ -393,6 +393,8 @@ applications that come with the platform <!-- Permissions required for Incremental CTS tests --> <permission name="com.android.permission.USE_INSTALLER_V2"/> <permission name="android.permission.LOADER_USAGE_STATS"/> + <!-- Permissions required for Package Verifier tests --> + <permission name="android.permission.PACKAGE_VERIFICATION_AGENT" /> <!-- Permission required to test system only camera devices. --> <permission name="android.permission.SYSTEM_CAMERA" /> <!-- Permission required to test ExplicitHealthCheckServiceImpl. --> diff --git a/errorprone/java/com/google/errorprone/bugpatterns/android/RequiresPermissionChecker.java b/errorprone/java/com/google/errorprone/bugpatterns/android/RequiresPermissionChecker.java index d1e4309c365e..2f61a2883037 100644 --- a/errorprone/java/com/google/errorprone/bugpatterns/android/RequiresPermissionChecker.java +++ b/errorprone/java/com/google/errorprone/bugpatterns/android/RequiresPermissionChecker.java @@ -187,7 +187,10 @@ public final class RequiresPermissionChecker extends BugChecker if (!actualPerm.containsAll(expectedPerm)) { return buildDescription(tree) .setMessage("Method " + method.name.toString() + "() annotated " + expectedPerm - + " but too wide; only invokes methods requiring " + actualPerm) + + " but too wide; only invokes methods requiring " + actualPerm + + "\n If calling an AIDL interface, it can be annotated by adding:" + + "\n @JavaPassthrough(annotation=\"" + + "@android.annotation.RequiresPermission(...)\")") .build(); } diff --git a/libs/androidfw/LocaleDataTables.cpp b/libs/androidfw/LocaleDataTables.cpp index 2c3567a63292..2c005fd81de5 100644 --- a/libs/androidfw/LocaleDataTables.cpp +++ b/libs/androidfw/LocaleDataTables.cpp @@ -34,206 +34,209 @@ const char SCRIPT_CODES[][4] = { /* 30 */ {'H', 'a', 'n', 't'}, /* 31 */ {'H', 'e', 'b', 'r'}, /* 32 */ {'H', 'l', 'u', 'w'}, - /* 33 */ {'H', 'm', 'n', 'g'}, - /* 34 */ {'H', 'm', 'n', 'p'}, - /* 35 */ {'I', 't', 'a', 'l'}, - /* 36 */ {'J', 'p', 'a', 'n'}, - /* 37 */ {'K', 'a', 'l', 'i'}, - /* 38 */ {'K', 'a', 'n', 'a'}, - /* 39 */ {'K', 'h', 'a', 'r'}, - /* 40 */ {'K', 'h', 'm', 'r'}, - /* 41 */ {'K', 'i', 't', 's'}, - /* 42 */ {'K', 'n', 'd', 'a'}, - /* 43 */ {'K', 'o', 'r', 'e'}, - /* 44 */ {'L', 'a', 'n', 'a'}, - /* 45 */ {'L', 'a', 'o', 'o'}, - /* 46 */ {'L', 'a', 't', 'n'}, - /* 47 */ {'L', 'e', 'p', 'c'}, - /* 48 */ {'L', 'i', 'n', 'a'}, - /* 49 */ {'L', 'i', 's', 'u'}, - /* 50 */ {'L', 'y', 'c', 'i'}, - /* 51 */ {'L', 'y', 'd', 'i'}, - /* 52 */ {'M', 'a', 'n', 'd'}, - /* 53 */ {'M', 'a', 'n', 'i'}, - /* 54 */ {'M', 'e', 'd', 'f'}, - /* 55 */ {'M', 'e', 'r', 'c'}, - /* 56 */ {'M', 'l', 'y', 'm'}, - /* 57 */ {'M', 'o', 'n', 'g'}, - /* 58 */ {'M', 'r', 'o', 'o'}, - /* 59 */ {'M', 'y', 'm', 'r'}, - /* 60 */ {'N', 'a', 'r', 'b'}, - /* 61 */ {'N', 'k', 'o', 'o'}, - /* 62 */ {'N', 's', 'h', 'u'}, - /* 63 */ {'O', 'g', 'a', 'm'}, - /* 64 */ {'O', 'l', 'c', 'k'}, - /* 65 */ {'O', 'r', 'k', 'h'}, - /* 66 */ {'O', 'r', 'y', 'a'}, - /* 67 */ {'O', 's', 'g', 'e'}, + /* 33 */ {'H', 'm', 'n', 'p'}, + /* 34 */ {'I', 't', 'a', 'l'}, + /* 35 */ {'J', 'p', 'a', 'n'}, + /* 36 */ {'K', 'a', 'l', 'i'}, + /* 37 */ {'K', 'a', 'n', 'a'}, + /* 38 */ {'K', 'h', 'a', 'r'}, + /* 39 */ {'K', 'h', 'm', 'r'}, + /* 40 */ {'K', 'i', 't', 's'}, + /* 41 */ {'K', 'n', 'd', 'a'}, + /* 42 */ {'K', 'o', 'r', 'e'}, + /* 43 */ {'L', 'a', 'n', 'a'}, + /* 44 */ {'L', 'a', 'o', 'o'}, + /* 45 */ {'L', 'a', 't', 'n'}, + /* 46 */ {'L', 'e', 'p', 'c'}, + /* 47 */ {'L', 'i', 'n', 'a'}, + /* 48 */ {'L', 'i', 's', 'u'}, + /* 49 */ {'L', 'y', 'c', 'i'}, + /* 50 */ {'L', 'y', 'd', 'i'}, + /* 51 */ {'M', 'a', 'n', 'd'}, + /* 52 */ {'M', 'a', 'n', 'i'}, + /* 53 */ {'M', 'e', 'd', 'f'}, + /* 54 */ {'M', 'e', 'r', 'c'}, + /* 55 */ {'M', 'l', 'y', 'm'}, + /* 56 */ {'M', 'o', 'n', 'g'}, + /* 57 */ {'M', 'r', 'o', 'o'}, + /* 58 */ {'M', 'y', 'm', 'r'}, + /* 59 */ {'N', 'a', 'r', 'b'}, + /* 60 */ {'N', 'k', 'o', 'o'}, + /* 61 */ {'N', 's', 'h', 'u'}, + /* 62 */ {'O', 'g', 'a', 'm'}, + /* 63 */ {'O', 'l', 'c', 'k'}, + /* 64 */ {'O', 'r', 'k', 'h'}, + /* 65 */ {'O', 'r', 'y', 'a'}, + /* 66 */ {'O', 's', 'g', 'e'}, + /* 67 */ {'O', 'u', 'g', 'r'}, /* 68 */ {'P', 'a', 'u', 'c'}, /* 69 */ {'P', 'h', 'l', 'i'}, /* 70 */ {'P', 'h', 'n', 'x'}, /* 71 */ {'P', 'l', 'r', 'd'}, /* 72 */ {'P', 'r', 't', 'i'}, - /* 73 */ {'R', 'u', 'n', 'r'}, - /* 74 */ {'S', 'a', 'm', 'r'}, - /* 75 */ {'S', 'a', 'r', 'b'}, - /* 76 */ {'S', 'a', 'u', 'r'}, - /* 77 */ {'S', 'g', 'n', 'w'}, - /* 78 */ {'S', 'i', 'n', 'h'}, - /* 79 */ {'S', 'o', 'g', 'd'}, - /* 80 */ {'S', 'o', 'r', 'a'}, - /* 81 */ {'S', 'o', 'y', 'o'}, - /* 82 */ {'S', 'y', 'r', 'c'}, - /* 83 */ {'T', 'a', 'l', 'e'}, - /* 84 */ {'T', 'a', 'l', 'u'}, - /* 85 */ {'T', 'a', 'm', 'l'}, - /* 86 */ {'T', 'a', 'n', 'g'}, - /* 87 */ {'T', 'a', 'v', 't'}, - /* 88 */ {'T', 'e', 'l', 'u'}, - /* 89 */ {'T', 'f', 'n', 'g'}, - /* 90 */ {'T', 'h', 'a', 'a'}, - /* 91 */ {'T', 'h', 'a', 'i'}, - /* 92 */ {'T', 'i', 'b', 't'}, - /* 93 */ {'U', 'g', 'a', 'r'}, - /* 94 */ {'V', 'a', 'i', 'i'}, - /* 95 */ {'W', 'c', 'h', 'o'}, - /* 96 */ {'X', 'p', 'e', 'o'}, - /* 97 */ {'X', 's', 'u', 'x'}, - /* 98 */ {'Y', 'i', 'i', 'i'}, - /* 99 */ {'~', '~', '~', 'A'}, - /* 100 */ {'~', '~', '~', 'B'}, + /* 73 */ {'R', 'o', 'h', 'g'}, + /* 74 */ {'R', 'u', 'n', 'r'}, + /* 75 */ {'S', 'a', 'm', 'r'}, + /* 76 */ {'S', 'a', 'r', 'b'}, + /* 77 */ {'S', 'a', 'u', 'r'}, + /* 78 */ {'S', 'g', 'n', 'w'}, + /* 79 */ {'S', 'i', 'n', 'h'}, + /* 80 */ {'S', 'o', 'g', 'd'}, + /* 81 */ {'S', 'o', 'r', 'a'}, + /* 82 */ {'S', 'o', 'y', 'o'}, + /* 83 */ {'S', 'y', 'r', 'c'}, + /* 84 */ {'T', 'a', 'l', 'e'}, + /* 85 */ {'T', 'a', 'l', 'u'}, + /* 86 */ {'T', 'a', 'm', 'l'}, + /* 87 */ {'T', 'a', 'n', 'g'}, + /* 88 */ {'T', 'a', 'v', 't'}, + /* 89 */ {'T', 'e', 'l', 'u'}, + /* 90 */ {'T', 'f', 'n', 'g'}, + /* 91 */ {'T', 'h', 'a', 'a'}, + /* 92 */ {'T', 'h', 'a', 'i'}, + /* 93 */ {'T', 'i', 'b', 't'}, + /* 94 */ {'T', 'n', 's', 'a'}, + /* 95 */ {'T', 'o', 't', 'o'}, + /* 96 */ {'U', 'g', 'a', 'r'}, + /* 97 */ {'V', 'a', 'i', 'i'}, + /* 98 */ {'W', 'c', 'h', 'o'}, + /* 99 */ {'X', 'p', 'e', 'o'}, + /* 100 */ {'X', 's', 'u', 'x'}, + /* 101 */ {'Y', 'i', 'i', 'i'}, + /* 102 */ {'~', '~', '~', 'A'}, + /* 103 */ {'~', '~', '~', 'B'}, }; const std::unordered_map<uint32_t, uint8_t> LIKELY_SCRIPTS({ - {0x61610000u, 46u}, // aa -> Latn - {0xA0000000u, 46u}, // aai -> Latn - {0xA8000000u, 46u}, // aak -> Latn - {0xD0000000u, 46u}, // aau -> Latn + {0x61610000u, 45u}, // aa -> Latn + {0xA0000000u, 45u}, // aai -> Latn + {0xA8000000u, 45u}, // aak -> Latn + {0xD0000000u, 45u}, // aau -> Latn {0x61620000u, 18u}, // ab -> Cyrl - {0xA0200000u, 46u}, // abi -> Latn + {0xA0200000u, 45u}, // abi -> Latn {0xC0200000u, 18u}, // abq -> Cyrl - {0xC4200000u, 46u}, // abr -> Latn - {0xCC200000u, 46u}, // abt -> Latn - {0xE0200000u, 46u}, // aby -> Latn - {0x8C400000u, 46u}, // acd -> Latn - {0x90400000u, 46u}, // ace -> Latn - {0x9C400000u, 46u}, // ach -> Latn - {0x80600000u, 46u}, // ada -> Latn - {0x90600000u, 46u}, // ade -> Latn - {0xA4600000u, 46u}, // adj -> Latn - {0xBC600000u, 92u}, // adp -> Tibt + {0xC4200000u, 45u}, // abr -> Latn + {0xCC200000u, 45u}, // abt -> Latn + {0xE0200000u, 45u}, // aby -> Latn + {0x8C400000u, 45u}, // acd -> Latn + {0x90400000u, 45u}, // ace -> Latn + {0x9C400000u, 45u}, // ach -> Latn + {0x80600000u, 45u}, // ada -> Latn + {0x90600000u, 45u}, // ade -> Latn + {0xA4600000u, 45u}, // adj -> Latn + {0xBC600000u, 93u}, // adp -> Tibt {0xE0600000u, 18u}, // ady -> Cyrl - {0xE4600000u, 46u}, // adz -> Latn + {0xE4600000u, 45u}, // adz -> Latn {0x61650000u, 5u}, // ae -> Avst {0x84800000u, 2u}, // aeb -> Arab - {0xE0800000u, 46u}, // aey -> Latn - {0x61660000u, 46u}, // af -> Latn - {0x88C00000u, 46u}, // agc -> Latn - {0x8CC00000u, 46u}, // agd -> Latn - {0x98C00000u, 46u}, // agg -> Latn - {0xB0C00000u, 46u}, // agm -> Latn - {0xB8C00000u, 46u}, // ago -> Latn - {0xC0C00000u, 46u}, // agq -> Latn - {0x80E00000u, 46u}, // aha -> Latn - {0xACE00000u, 46u}, // ahl -> Latn + {0xE0800000u, 45u}, // aey -> Latn + {0x61660000u, 45u}, // af -> Latn + {0x88C00000u, 45u}, // agc -> Latn + {0x8CC00000u, 45u}, // agd -> Latn + {0x98C00000u, 45u}, // agg -> Latn + {0xB0C00000u, 45u}, // agm -> Latn + {0xB8C00000u, 45u}, // ago -> Latn + {0xC0C00000u, 45u}, // agq -> Latn + {0x80E00000u, 45u}, // aha -> Latn + {0xACE00000u, 45u}, // ahl -> Latn {0xB8E00000u, 1u}, // aho -> Ahom - {0x99200000u, 46u}, // ajg -> Latn - {0x616B0000u, 46u}, // ak -> Latn - {0xA9400000u, 97u}, // akk -> Xsux - {0x81600000u, 46u}, // ala -> Latn - {0xA1600000u, 46u}, // ali -> Latn - {0xB5600000u, 46u}, // aln -> Latn + {0x99200000u, 45u}, // ajg -> Latn + {0x616B0000u, 45u}, // ak -> Latn + {0xA9400000u, 100u}, // akk -> Xsux + {0x81600000u, 45u}, // ala -> Latn + {0xA1600000u, 45u}, // ali -> Latn + {0xB5600000u, 45u}, // aln -> Latn {0xCD600000u, 18u}, // alt -> Cyrl {0x616D0000u, 21u}, // am -> Ethi - {0xB1800000u, 46u}, // amm -> Latn - {0xB5800000u, 46u}, // amn -> Latn - {0xB9800000u, 46u}, // amo -> Latn - {0xBD800000u, 46u}, // amp -> Latn - {0x616E0000u, 46u}, // an -> Latn - {0x89A00000u, 46u}, // anc -> Latn - {0xA9A00000u, 46u}, // ank -> Latn - {0xB5A00000u, 46u}, // ann -> Latn - {0xE1A00000u, 46u}, // any -> Latn - {0xA5C00000u, 46u}, // aoj -> Latn - {0xB1C00000u, 46u}, // aom -> Latn - {0xE5C00000u, 46u}, // aoz -> Latn + {0xB1800000u, 45u}, // amm -> Latn + {0xB5800000u, 45u}, // amn -> Latn + {0xB9800000u, 45u}, // amo -> Latn + {0xBD800000u, 45u}, // amp -> Latn + {0x616E0000u, 45u}, // an -> Latn + {0x89A00000u, 45u}, // anc -> Latn + {0xA9A00000u, 45u}, // ank -> Latn + {0xB5A00000u, 45u}, // ann -> Latn + {0xE1A00000u, 45u}, // any -> Latn + {0xA5C00000u, 45u}, // aoj -> Latn + {0xB1C00000u, 45u}, // aom -> Latn + {0xE5C00000u, 45u}, // aoz -> Latn {0x89E00000u, 2u}, // apc -> Arab {0x8DE00000u, 2u}, // apd -> Arab - {0x91E00000u, 46u}, // ape -> Latn - {0xC5E00000u, 46u}, // apr -> Latn - {0xC9E00000u, 46u}, // aps -> Latn - {0xE5E00000u, 46u}, // apz -> Latn + {0x91E00000u, 45u}, // ape -> Latn + {0xC5E00000u, 45u}, // apr -> Latn + {0xC9E00000u, 45u}, // aps -> Latn + {0xE5E00000u, 45u}, // apz -> Latn {0x61720000u, 2u}, // ar -> Arab - {0x61725842u, 100u}, // ar-XB -> ~~~B + {0x61725842u, 103u}, // ar-XB -> ~~~B {0x8A200000u, 3u}, // arc -> Armi - {0x9E200000u, 46u}, // arh -> Latn - {0xB6200000u, 46u}, // arn -> Latn - {0xBA200000u, 46u}, // aro -> Latn + {0x9E200000u, 45u}, // arh -> Latn + {0xB6200000u, 45u}, // arn -> Latn + {0xBA200000u, 45u}, // aro -> Latn {0xC2200000u, 2u}, // arq -> Arab {0xCA200000u, 2u}, // ars -> Arab {0xE2200000u, 2u}, // ary -> Arab {0xE6200000u, 2u}, // arz -> Arab {0x61730000u, 8u}, // as -> Beng - {0x82400000u, 46u}, // asa -> Latn - {0x92400000u, 77u}, // ase -> Sgnw - {0x9A400000u, 46u}, // asg -> Latn - {0xBA400000u, 46u}, // aso -> Latn - {0xCE400000u, 46u}, // ast -> Latn - {0x82600000u, 46u}, // ata -> Latn - {0x9A600000u, 46u}, // atg -> Latn - {0xA6600000u, 46u}, // atj -> Latn - {0xE2800000u, 46u}, // auy -> Latn + {0x82400000u, 45u}, // asa -> Latn + {0x92400000u, 78u}, // ase -> Sgnw + {0x9A400000u, 45u}, // asg -> Latn + {0xBA400000u, 45u}, // aso -> Latn + {0xCE400000u, 45u}, // ast -> Latn + {0x82600000u, 45u}, // ata -> Latn + {0x9A600000u, 45u}, // atg -> Latn + {0xA6600000u, 45u}, // atj -> Latn + {0xE2800000u, 45u}, // auy -> Latn {0x61760000u, 18u}, // av -> Cyrl {0xAEA00000u, 2u}, // avl -> Arab - {0xB6A00000u, 46u}, // avn -> Latn - {0xCEA00000u, 46u}, // avt -> Latn - {0xD2A00000u, 46u}, // avu -> Latn + {0xB6A00000u, 45u}, // avn -> Latn + {0xCEA00000u, 45u}, // avt -> Latn + {0xD2A00000u, 45u}, // avu -> Latn {0x82C00000u, 19u}, // awa -> Deva - {0x86C00000u, 46u}, // awb -> Latn - {0xBAC00000u, 46u}, // awo -> Latn - {0xDEC00000u, 46u}, // awx -> Latn - {0x61790000u, 46u}, // ay -> Latn - {0x87000000u, 46u}, // ayb -> Latn - {0x617A0000u, 46u}, // az -> Latn + {0x86C00000u, 45u}, // awb -> Latn + {0xBAC00000u, 45u}, // awo -> Latn + {0xDEC00000u, 45u}, // awx -> Latn + {0x61790000u, 45u}, // ay -> Latn + {0x87000000u, 45u}, // ayb -> Latn + {0x617A0000u, 45u}, // az -> Latn {0x617A4951u, 2u}, // az-IQ -> Arab {0x617A4952u, 2u}, // az-IR -> Arab {0x617A5255u, 18u}, // az-RU -> Cyrl {0x62610000u, 18u}, // ba -> Cyrl {0xAC010000u, 2u}, // bal -> Arab - {0xB4010000u, 46u}, // ban -> Latn + {0xB4010000u, 45u}, // ban -> Latn {0xBC010000u, 19u}, // bap -> Deva - {0xC4010000u, 46u}, // bar -> Latn - {0xC8010000u, 46u}, // bas -> Latn - {0xD4010000u, 46u}, // bav -> Latn + {0xC4010000u, 45u}, // bar -> Latn + {0xC8010000u, 45u}, // bas -> Latn + {0xD4010000u, 45u}, // bav -> Latn {0xDC010000u, 6u}, // bax -> Bamu - {0x80210000u, 46u}, // bba -> Latn - {0x84210000u, 46u}, // bbb -> Latn - {0x88210000u, 46u}, // bbc -> Latn - {0x8C210000u, 46u}, // bbd -> Latn - {0xA4210000u, 46u}, // bbj -> Latn - {0xBC210000u, 46u}, // bbp -> Latn - {0xC4210000u, 46u}, // bbr -> Latn - {0x94410000u, 46u}, // bcf -> Latn - {0x9C410000u, 46u}, // bch -> Latn - {0xA0410000u, 46u}, // bci -> Latn - {0xB0410000u, 46u}, // bcm -> Latn - {0xB4410000u, 46u}, // bcn -> Latn - {0xB8410000u, 46u}, // bco -> Latn + {0x80210000u, 45u}, // bba -> Latn + {0x84210000u, 45u}, // bbb -> Latn + {0x88210000u, 45u}, // bbc -> Latn + {0x8C210000u, 45u}, // bbd -> Latn + {0xA4210000u, 45u}, // bbj -> Latn + {0xBC210000u, 45u}, // bbp -> Latn + {0xC4210000u, 45u}, // bbr -> Latn + {0x94410000u, 45u}, // bcf -> Latn + {0x9C410000u, 45u}, // bch -> Latn + {0xA0410000u, 45u}, // bci -> Latn + {0xB0410000u, 45u}, // bcm -> Latn + {0xB4410000u, 45u}, // bcn -> Latn + {0xB8410000u, 45u}, // bco -> Latn {0xC0410000u, 21u}, // bcq -> Ethi - {0xD0410000u, 46u}, // bcu -> Latn - {0x8C610000u, 46u}, // bdd -> Latn + {0xD0410000u, 45u}, // bcu -> Latn + {0x8C610000u, 45u}, // bdd -> Latn {0x62650000u, 18u}, // be -> Cyrl - {0x94810000u, 46u}, // bef -> Latn - {0x9C810000u, 46u}, // beh -> Latn + {0x94810000u, 45u}, // bef -> Latn + {0x9C810000u, 45u}, // beh -> Latn {0xA4810000u, 2u}, // bej -> Arab - {0xB0810000u, 46u}, // bem -> Latn - {0xCC810000u, 46u}, // bet -> Latn - {0xD8810000u, 46u}, // bew -> Latn - {0xDC810000u, 46u}, // bex -> Latn - {0xE4810000u, 46u}, // bez -> Latn - {0x8CA10000u, 46u}, // bfd -> Latn - {0xC0A10000u, 85u}, // bfq -> Taml + {0xB0810000u, 45u}, // bem -> Latn + {0xCC810000u, 45u}, // bet -> Latn + {0xD8810000u, 45u}, // bew -> Latn + {0xDC810000u, 45u}, // bex -> Latn + {0xE4810000u, 45u}, // bez -> Latn + {0x8CA10000u, 45u}, // bfd -> Latn + {0xC0A10000u, 86u}, // bfq -> Taml {0xCCA10000u, 2u}, // bft -> Arab {0xE0A10000u, 19u}, // bfy -> Deva {0x62670000u, 18u}, // bg -> Cyrl @@ -241,1235 +244,1239 @@ const std::unordered_map<uint32_t, uint8_t> LIKELY_SCRIPTS({ {0xB4C10000u, 2u}, // bgn -> Arab {0xDCC10000u, 26u}, // bgx -> Grek {0x84E10000u, 19u}, // bhb -> Deva - {0x98E10000u, 46u}, // bhg -> Latn + {0x98E10000u, 45u}, // bhg -> Latn {0xA0E10000u, 19u}, // bhi -> Deva - {0xACE10000u, 46u}, // bhl -> Latn + {0xACE10000u, 45u}, // bhl -> Latn {0xB8E10000u, 19u}, // bho -> Deva - {0xE0E10000u, 46u}, // bhy -> Latn - {0x62690000u, 46u}, // bi -> Latn - {0x85010000u, 46u}, // bib -> Latn - {0x99010000u, 46u}, // big -> Latn - {0xA9010000u, 46u}, // bik -> Latn - {0xB1010000u, 46u}, // bim -> Latn - {0xB5010000u, 46u}, // bin -> Latn - {0xB9010000u, 46u}, // bio -> Latn - {0xC1010000u, 46u}, // biq -> Latn - {0x9D210000u, 46u}, // bjh -> Latn + {0xE0E10000u, 45u}, // bhy -> Latn + {0x62690000u, 45u}, // bi -> Latn + {0x85010000u, 45u}, // bib -> Latn + {0x99010000u, 45u}, // big -> Latn + {0xA9010000u, 45u}, // bik -> Latn + {0xB1010000u, 45u}, // bim -> Latn + {0xB5010000u, 45u}, // bin -> Latn + {0xB9010000u, 45u}, // bio -> Latn + {0xC1010000u, 45u}, // biq -> Latn + {0x9D210000u, 45u}, // bjh -> Latn {0xA1210000u, 21u}, // bji -> Ethi {0xA5210000u, 19u}, // bjj -> Deva - {0xB5210000u, 46u}, // bjn -> Latn - {0xB9210000u, 46u}, // bjo -> Latn - {0xC5210000u, 46u}, // bjr -> Latn - {0xCD210000u, 46u}, // bjt -> Latn - {0xE5210000u, 46u}, // bjz -> Latn - {0x89410000u, 46u}, // bkc -> Latn - {0xB1410000u, 46u}, // bkm -> Latn - {0xC1410000u, 46u}, // bkq -> Latn - {0xD1410000u, 46u}, // bku -> Latn - {0xD5410000u, 46u}, // bkv -> Latn - {0xCD610000u, 87u}, // blt -> Tavt - {0x626D0000u, 46u}, // bm -> Latn - {0x9D810000u, 46u}, // bmh -> Latn - {0xA9810000u, 46u}, // bmk -> Latn - {0xC1810000u, 46u}, // bmq -> Latn - {0xD1810000u, 46u}, // bmu -> Latn + {0xB5210000u, 45u}, // bjn -> Latn + {0xB9210000u, 45u}, // bjo -> Latn + {0xC5210000u, 45u}, // bjr -> Latn + {0xCD210000u, 45u}, // bjt -> Latn + {0xE5210000u, 45u}, // bjz -> Latn + {0x89410000u, 45u}, // bkc -> Latn + {0xB1410000u, 45u}, // bkm -> Latn + {0xC1410000u, 45u}, // bkq -> Latn + {0xD1410000u, 45u}, // bku -> Latn + {0xD5410000u, 45u}, // bkv -> Latn + {0x99610000u, 45u}, // blg -> Latn + {0xCD610000u, 88u}, // blt -> Tavt + {0x626D0000u, 45u}, // bm -> Latn + {0x9D810000u, 45u}, // bmh -> Latn + {0xA9810000u, 45u}, // bmk -> Latn + {0xC1810000u, 45u}, // bmq -> Latn + {0xD1810000u, 45u}, // bmu -> Latn {0x626E0000u, 8u}, // bn -> Beng - {0x99A10000u, 46u}, // bng -> Latn - {0xB1A10000u, 46u}, // bnm -> Latn - {0xBDA10000u, 46u}, // bnp -> Latn - {0x626F0000u, 92u}, // bo -> Tibt - {0xA5C10000u, 46u}, // boj -> Latn - {0xB1C10000u, 46u}, // bom -> Latn - {0xB5C10000u, 46u}, // bon -> Latn + {0x99A10000u, 45u}, // bng -> Latn + {0xB1A10000u, 45u}, // bnm -> Latn + {0xBDA10000u, 45u}, // bnp -> Latn + {0x626F0000u, 93u}, // bo -> Tibt + {0xA5C10000u, 45u}, // boj -> Latn + {0xB1C10000u, 45u}, // bom -> Latn + {0xB5C10000u, 45u}, // bon -> Latn {0xE1E10000u, 8u}, // bpy -> Beng - {0x8A010000u, 46u}, // bqc -> Latn + {0x8A010000u, 45u}, // bqc -> Latn {0xA2010000u, 2u}, // bqi -> Arab - {0xBE010000u, 46u}, // bqp -> Latn - {0xD6010000u, 46u}, // bqv -> Latn - {0x62720000u, 46u}, // br -> Latn + {0xBE010000u, 45u}, // bqp -> Latn + {0xD6010000u, 45u}, // bqv -> Latn + {0x62720000u, 45u}, // br -> Latn {0x82210000u, 19u}, // bra -> Deva {0x9E210000u, 2u}, // brh -> Arab {0xDE210000u, 19u}, // brx -> Deva - {0xE6210000u, 46u}, // brz -> Latn - {0x62730000u, 46u}, // bs -> Latn - {0xA6410000u, 46u}, // bsj -> Latn + {0xE6210000u, 45u}, // brz -> Latn + {0x62730000u, 45u}, // bs -> Latn + {0xA6410000u, 45u}, // bsj -> Latn {0xC2410000u, 7u}, // bsq -> Bass - {0xCA410000u, 46u}, // bss -> Latn + {0xCA410000u, 45u}, // bss -> Latn {0xCE410000u, 21u}, // bst -> Ethi - {0xBA610000u, 46u}, // bto -> Latn - {0xCE610000u, 46u}, // btt -> Latn + {0xBA610000u, 45u}, // bto -> Latn + {0xCE610000u, 45u}, // btt -> Latn {0xD6610000u, 19u}, // btv -> Deva {0x82810000u, 18u}, // bua -> Cyrl - {0x8A810000u, 46u}, // buc -> Latn - {0x8E810000u, 46u}, // bud -> Latn - {0x9A810000u, 46u}, // bug -> Latn - {0xAA810000u, 46u}, // buk -> Latn - {0xB2810000u, 46u}, // bum -> Latn - {0xBA810000u, 46u}, // buo -> Latn - {0xCA810000u, 46u}, // bus -> Latn - {0xD2810000u, 46u}, // buu -> Latn - {0x86A10000u, 46u}, // bvb -> Latn - {0x8EC10000u, 46u}, // bwd -> Latn - {0xC6C10000u, 46u}, // bwr -> Latn - {0x9EE10000u, 46u}, // bxh -> Latn - {0x93010000u, 46u}, // bye -> Latn + {0x8A810000u, 45u}, // buc -> Latn + {0x8E810000u, 45u}, // bud -> Latn + {0x9A810000u, 45u}, // bug -> Latn + {0xAA810000u, 45u}, // buk -> Latn + {0xB2810000u, 45u}, // bum -> Latn + {0xBA810000u, 45u}, // buo -> Latn + {0xCA810000u, 45u}, // bus -> Latn + {0xD2810000u, 45u}, // buu -> Latn + {0x86A10000u, 45u}, // bvb -> Latn + {0x8EC10000u, 45u}, // bwd -> Latn + {0xC6C10000u, 45u}, // bwr -> Latn + {0x9EE10000u, 45u}, // bxh -> Latn + {0x93010000u, 45u}, // bye -> Latn {0xB7010000u, 21u}, // byn -> Ethi - {0xC7010000u, 46u}, // byr -> Latn - {0xCB010000u, 46u}, // bys -> Latn - {0xD7010000u, 46u}, // byv -> Latn - {0xDF010000u, 46u}, // byx -> Latn - {0x83210000u, 46u}, // bza -> Latn - {0x93210000u, 46u}, // bze -> Latn - {0x97210000u, 46u}, // bzf -> Latn - {0x9F210000u, 46u}, // bzh -> Latn - {0xDB210000u, 46u}, // bzw -> Latn - {0x63610000u, 46u}, // ca -> Latn - {0x8C020000u, 46u}, // cad -> Latn - {0xB4020000u, 46u}, // can -> Latn - {0xA4220000u, 46u}, // cbj -> Latn - {0x9C420000u, 46u}, // cch -> Latn + {0xC7010000u, 45u}, // byr -> Latn + {0xCB010000u, 45u}, // bys -> Latn + {0xD7010000u, 45u}, // byv -> Latn + {0xDF010000u, 45u}, // byx -> Latn + {0x83210000u, 45u}, // bza -> Latn + {0x93210000u, 45u}, // bze -> Latn + {0x97210000u, 45u}, // bzf -> Latn + {0x9F210000u, 45u}, // bzh -> Latn + {0xDB210000u, 45u}, // bzw -> Latn + {0x63610000u, 45u}, // ca -> Latn + {0x8C020000u, 45u}, // cad -> Latn + {0xB4020000u, 45u}, // can -> Latn + {0xA4220000u, 45u}, // cbj -> Latn + {0x9C420000u, 45u}, // cch -> Latn {0xBC420000u, 10u}, // ccp -> Cakm {0x63650000u, 18u}, // ce -> Cyrl - {0x84820000u, 46u}, // ceb -> Latn - {0x80A20000u, 46u}, // cfa -> Latn - {0x98C20000u, 46u}, // cgg -> Latn - {0x63680000u, 46u}, // ch -> Latn - {0xA8E20000u, 46u}, // chk -> Latn + {0x84820000u, 45u}, // ceb -> Latn + {0x80A20000u, 45u}, // cfa -> Latn + {0x98C20000u, 45u}, // cgg -> Latn + {0x63680000u, 45u}, // ch -> Latn + {0xA8E20000u, 45u}, // chk -> Latn {0xB0E20000u, 18u}, // chm -> Cyrl - {0xB8E20000u, 46u}, // cho -> Latn - {0xBCE20000u, 46u}, // chp -> Latn + {0xB8E20000u, 45u}, // cho -> Latn + {0xBCE20000u, 45u}, // chp -> Latn {0xC4E20000u, 14u}, // chr -> Cher - {0x89020000u, 46u}, // cic -> Latn + {0x89020000u, 45u}, // cic -> Latn {0x81220000u, 2u}, // cja -> Arab {0xB1220000u, 13u}, // cjm -> Cham - {0xD5220000u, 46u}, // cjv -> Latn + {0xD5220000u, 45u}, // cjv -> Latn {0x85420000u, 2u}, // ckb -> Arab - {0xAD420000u, 46u}, // ckl -> Latn - {0xB9420000u, 46u}, // cko -> Latn - {0xE1420000u, 46u}, // cky -> Latn - {0x81620000u, 46u}, // cla -> Latn - {0x91820000u, 46u}, // cme -> Latn - {0x99820000u, 81u}, // cmg -> Soyo - {0x636F0000u, 46u}, // co -> Latn + {0xAD420000u, 45u}, // ckl -> Latn + {0xB9420000u, 45u}, // cko -> Latn + {0xE1420000u, 45u}, // cky -> Latn + {0x81620000u, 45u}, // cla -> Latn + {0x91820000u, 45u}, // cme -> Latn + {0x99820000u, 82u}, // cmg -> Soyo + {0x636F0000u, 45u}, // co -> Latn {0xBDC20000u, 16u}, // cop -> Copt - {0xC9E20000u, 46u}, // cps -> Latn + {0xC9E20000u, 45u}, // cps -> Latn {0x63720000u, 11u}, // cr -> Cans {0x9E220000u, 18u}, // crh -> Cyrl {0xA6220000u, 11u}, // crj -> Cans {0xAA220000u, 11u}, // crk -> Cans {0xAE220000u, 11u}, // crl -> Cans {0xB2220000u, 11u}, // crm -> Cans - {0xCA220000u, 46u}, // crs -> Latn - {0x63730000u, 46u}, // cs -> Latn - {0x86420000u, 46u}, // csb -> Latn + {0xCA220000u, 45u}, // crs -> Latn + {0x63730000u, 45u}, // cs -> Latn + {0x86420000u, 45u}, // csb -> Latn {0xDA420000u, 11u}, // csw -> Cans {0x8E620000u, 68u}, // ctd -> Pauc {0x63750000u, 18u}, // cu -> Cyrl {0x63760000u, 18u}, // cv -> Cyrl - {0x63790000u, 46u}, // cy -> Latn - {0x64610000u, 46u}, // da -> Latn - {0x8C030000u, 46u}, // dad -> Latn - {0x94030000u, 46u}, // daf -> Latn - {0x98030000u, 46u}, // dag -> Latn - {0x9C030000u, 46u}, // dah -> Latn - {0xA8030000u, 46u}, // dak -> Latn + {0x63790000u, 45u}, // cy -> Latn + {0x64610000u, 45u}, // da -> Latn + {0x8C030000u, 45u}, // dad -> Latn + {0x94030000u, 45u}, // daf -> Latn + {0x98030000u, 45u}, // dag -> Latn + {0x9C030000u, 45u}, // dah -> Latn + {0xA8030000u, 45u}, // dak -> Latn {0xC4030000u, 18u}, // dar -> Cyrl - {0xD4030000u, 46u}, // dav -> Latn - {0x8C230000u, 46u}, // dbd -> Latn - {0xC0230000u, 46u}, // dbq -> Latn + {0xD4030000u, 45u}, // dav -> Latn + {0x8C230000u, 45u}, // dbd -> Latn + {0xC0230000u, 45u}, // dbq -> Latn {0x88430000u, 2u}, // dcc -> Arab - {0xB4630000u, 46u}, // ddn -> Latn - {0x64650000u, 46u}, // de -> Latn - {0x8C830000u, 46u}, // ded -> Latn - {0xB4830000u, 46u}, // den -> Latn - {0x80C30000u, 46u}, // dga -> Latn - {0x9CC30000u, 46u}, // dgh -> Latn - {0xA0C30000u, 46u}, // dgi -> Latn + {0xB4630000u, 45u}, // ddn -> Latn + {0x64650000u, 45u}, // de -> Latn + {0x8C830000u, 45u}, // ded -> Latn + {0xB4830000u, 45u}, // den -> Latn + {0x80C30000u, 45u}, // dga -> Latn + {0x9CC30000u, 45u}, // dgh -> Latn + {0xA0C30000u, 45u}, // dgi -> Latn {0xACC30000u, 2u}, // dgl -> Arab - {0xC4C30000u, 46u}, // dgr -> Latn - {0xE4C30000u, 46u}, // dgz -> Latn - {0x81030000u, 46u}, // dia -> Latn - {0x91230000u, 46u}, // dje -> Latn - {0x95830000u, 54u}, // dmf -> Medf - {0xA5A30000u, 46u}, // dnj -> Latn - {0x85C30000u, 46u}, // dob -> Latn + {0xC4C30000u, 45u}, // dgr -> Latn + {0xE4C30000u, 45u}, // dgz -> Latn + {0x81030000u, 45u}, // dia -> Latn + {0x91230000u, 45u}, // dje -> Latn + {0x95830000u, 53u}, // dmf -> Medf + {0xA5A30000u, 45u}, // dnj -> Latn + {0x85C30000u, 45u}, // dob -> Latn {0xA1C30000u, 19u}, // doi -> Deva - {0xBDC30000u, 46u}, // dop -> Latn - {0xD9C30000u, 46u}, // dow -> Latn - {0x9E230000u, 57u}, // drh -> Mong - {0xA2230000u, 46u}, // dri -> Latn + {0xBDC30000u, 45u}, // dop -> Latn + {0xD9C30000u, 45u}, // dow -> Latn + {0x9E230000u, 56u}, // drh -> Mong + {0xA2230000u, 45u}, // dri -> Latn {0xCA230000u, 21u}, // drs -> Ethi - {0x86430000u, 46u}, // dsb -> Latn - {0xB2630000u, 46u}, // dtm -> Latn - {0xBE630000u, 46u}, // dtp -> Latn - {0xCA630000u, 46u}, // dts -> Latn + {0x86430000u, 45u}, // dsb -> Latn + {0xB2630000u, 45u}, // dtm -> Latn + {0xBE630000u, 45u}, // dtp -> Latn + {0xCA630000u, 45u}, // dts -> Latn {0xE2630000u, 19u}, // dty -> Deva - {0x82830000u, 46u}, // dua -> Latn - {0x8A830000u, 46u}, // duc -> Latn - {0x8E830000u, 46u}, // dud -> Latn - {0x9A830000u, 46u}, // dug -> Latn - {0x64760000u, 90u}, // dv -> Thaa - {0x82A30000u, 46u}, // dva -> Latn - {0xDAC30000u, 46u}, // dww -> Latn - {0xBB030000u, 46u}, // dyo -> Latn - {0xD3030000u, 46u}, // dyu -> Latn - {0x647A0000u, 92u}, // dz -> Tibt - {0x9B230000u, 46u}, // dzg -> Latn - {0xD0240000u, 46u}, // ebu -> Latn - {0x65650000u, 46u}, // ee -> Latn - {0xA0A40000u, 46u}, // efi -> Latn - {0xACC40000u, 46u}, // egl -> Latn + {0x82830000u, 45u}, // dua -> Latn + {0x8A830000u, 45u}, // duc -> Latn + {0x8E830000u, 45u}, // dud -> Latn + {0x9A830000u, 45u}, // dug -> Latn + {0x64760000u, 91u}, // dv -> Thaa + {0x82A30000u, 45u}, // dva -> Latn + {0xDAC30000u, 45u}, // dww -> Latn + {0xBB030000u, 45u}, // dyo -> Latn + {0xD3030000u, 45u}, // dyu -> Latn + {0x647A0000u, 93u}, // dz -> Tibt + {0x9B230000u, 45u}, // dzg -> Latn + {0xD0240000u, 45u}, // ebu -> Latn + {0x65650000u, 45u}, // ee -> Latn + {0xA0A40000u, 45u}, // efi -> Latn + {0xACC40000u, 45u}, // egl -> Latn {0xE0C40000u, 20u}, // egy -> Egyp - {0x81440000u, 46u}, // eka -> Latn - {0xE1440000u, 37u}, // eky -> Kali + {0x81440000u, 45u}, // eka -> Latn + {0xE1440000u, 36u}, // eky -> Kali {0x656C0000u, 26u}, // el -> Grek - {0x81840000u, 46u}, // ema -> Latn - {0xA1840000u, 46u}, // emi -> Latn - {0x656E0000u, 46u}, // en -> Latn - {0x656E5841u, 99u}, // en-XA -> ~~~A - {0xB5A40000u, 46u}, // enn -> Latn - {0xC1A40000u, 46u}, // enq -> Latn - {0x656F0000u, 46u}, // eo -> Latn - {0xA2240000u, 46u}, // eri -> Latn - {0x65730000u, 46u}, // es -> Latn + {0x81840000u, 45u}, // ema -> Latn + {0xA1840000u, 45u}, // emi -> Latn + {0x656E0000u, 45u}, // en -> Latn + {0x656E5841u, 102u}, // en-XA -> ~~~A + {0xB5A40000u, 45u}, // enn -> Latn + {0xC1A40000u, 45u}, // enq -> Latn + {0x656F0000u, 45u}, // eo -> Latn + {0xA2240000u, 45u}, // eri -> Latn + {0x65730000u, 45u}, // es -> Latn {0x9A440000u, 24u}, // esg -> Gonm - {0xD2440000u, 46u}, // esu -> Latn - {0x65740000u, 46u}, // et -> Latn - {0xC6640000u, 46u}, // etr -> Latn - {0xCE640000u, 35u}, // ett -> Ital - {0xD2640000u, 46u}, // etu -> Latn - {0xDE640000u, 46u}, // etx -> Latn - {0x65750000u, 46u}, // eu -> Latn - {0xBAC40000u, 46u}, // ewo -> Latn - {0xCEE40000u, 46u}, // ext -> Latn - {0x83240000u, 46u}, // eza -> Latn + {0xD2440000u, 45u}, // esu -> Latn + {0x65740000u, 45u}, // et -> Latn + {0xC6640000u, 45u}, // etr -> Latn + {0xCE640000u, 34u}, // ett -> Ital + {0xD2640000u, 45u}, // etu -> Latn + {0xDE640000u, 45u}, // etx -> Latn + {0x65750000u, 45u}, // eu -> Latn + {0xBAC40000u, 45u}, // ewo -> Latn + {0xCEE40000u, 45u}, // ext -> Latn + {0x83240000u, 45u}, // eza -> Latn {0x66610000u, 2u}, // fa -> Arab - {0x80050000u, 46u}, // faa -> Latn - {0x84050000u, 46u}, // fab -> Latn - {0x98050000u, 46u}, // fag -> Latn - {0xA0050000u, 46u}, // fai -> Latn - {0xB4050000u, 46u}, // fan -> Latn - {0x66660000u, 46u}, // ff -> Latn - {0xA0A50000u, 46u}, // ffi -> Latn - {0xB0A50000u, 46u}, // ffm -> Latn - {0x66690000u, 46u}, // fi -> Latn + {0x80050000u, 45u}, // faa -> Latn + {0x84050000u, 45u}, // fab -> Latn + {0x98050000u, 45u}, // fag -> Latn + {0xA0050000u, 45u}, // fai -> Latn + {0xB4050000u, 45u}, // fan -> Latn + {0x66660000u, 45u}, // ff -> Latn + {0xA0A50000u, 45u}, // ffi -> Latn + {0xB0A50000u, 45u}, // ffm -> Latn + {0x66690000u, 45u}, // fi -> Latn {0x81050000u, 2u}, // fia -> Arab - {0xAD050000u, 46u}, // fil -> Latn - {0xCD050000u, 46u}, // fit -> Latn - {0x666A0000u, 46u}, // fj -> Latn - {0xC5650000u, 46u}, // flr -> Latn - {0xBD850000u, 46u}, // fmp -> Latn - {0x666F0000u, 46u}, // fo -> Latn - {0x8DC50000u, 46u}, // fod -> Latn - {0xB5C50000u, 46u}, // fon -> Latn - {0xC5C50000u, 46u}, // for -> Latn - {0x91E50000u, 46u}, // fpe -> Latn - {0xCA050000u, 46u}, // fqs -> Latn - {0x66720000u, 46u}, // fr -> Latn - {0x8A250000u, 46u}, // frc -> Latn - {0xBE250000u, 46u}, // frp -> Latn - {0xC6250000u, 46u}, // frr -> Latn - {0xCA250000u, 46u}, // frs -> Latn + {0xAD050000u, 45u}, // fil -> Latn + {0xCD050000u, 45u}, // fit -> Latn + {0x666A0000u, 45u}, // fj -> Latn + {0xC5650000u, 45u}, // flr -> Latn + {0xBD850000u, 45u}, // fmp -> Latn + {0x666F0000u, 45u}, // fo -> Latn + {0x8DC50000u, 45u}, // fod -> Latn + {0xB5C50000u, 45u}, // fon -> Latn + {0xC5C50000u, 45u}, // for -> Latn + {0x91E50000u, 45u}, // fpe -> Latn + {0xCA050000u, 45u}, // fqs -> Latn + {0x66720000u, 45u}, // fr -> Latn + {0x8A250000u, 45u}, // frc -> Latn + {0xBE250000u, 45u}, // frp -> Latn + {0xC6250000u, 45u}, // frr -> Latn + {0xCA250000u, 45u}, // frs -> Latn {0x86850000u, 2u}, // fub -> Arab - {0x8E850000u, 46u}, // fud -> Latn - {0x92850000u, 46u}, // fue -> Latn - {0x96850000u, 46u}, // fuf -> Latn - {0x9E850000u, 46u}, // fuh -> Latn - {0xC2850000u, 46u}, // fuq -> Latn - {0xC6850000u, 46u}, // fur -> Latn - {0xD6850000u, 46u}, // fuv -> Latn - {0xE2850000u, 46u}, // fuy -> Latn - {0xC6A50000u, 46u}, // fvr -> Latn - {0x66790000u, 46u}, // fy -> Latn - {0x67610000u, 46u}, // ga -> Latn - {0x80060000u, 46u}, // gaa -> Latn - {0x94060000u, 46u}, // gaf -> Latn - {0x98060000u, 46u}, // gag -> Latn - {0x9C060000u, 46u}, // gah -> Latn - {0xA4060000u, 46u}, // gaj -> Latn - {0xB0060000u, 46u}, // gam -> Latn + {0x8E850000u, 45u}, // fud -> Latn + {0x92850000u, 45u}, // fue -> Latn + {0x96850000u, 45u}, // fuf -> Latn + {0x9E850000u, 45u}, // fuh -> Latn + {0xC2850000u, 45u}, // fuq -> Latn + {0xC6850000u, 45u}, // fur -> Latn + {0xD6850000u, 45u}, // fuv -> Latn + {0xE2850000u, 45u}, // fuy -> Latn + {0xC6A50000u, 45u}, // fvr -> Latn + {0x66790000u, 45u}, // fy -> Latn + {0x67610000u, 45u}, // ga -> Latn + {0x80060000u, 45u}, // gaa -> Latn + {0x94060000u, 45u}, // gaf -> Latn + {0x98060000u, 45u}, // gag -> Latn + {0x9C060000u, 45u}, // gah -> Latn + {0xA4060000u, 45u}, // gaj -> Latn + {0xB0060000u, 45u}, // gam -> Latn {0xB4060000u, 29u}, // gan -> Hans - {0xD8060000u, 46u}, // gaw -> Latn - {0xE0060000u, 46u}, // gay -> Latn - {0x80260000u, 46u}, // gba -> Latn - {0x94260000u, 46u}, // gbf -> Latn + {0xD8060000u, 45u}, // gaw -> Latn + {0xE0060000u, 45u}, // gay -> Latn + {0x80260000u, 45u}, // gba -> Latn + {0x94260000u, 45u}, // gbf -> Latn {0xB0260000u, 19u}, // gbm -> Deva - {0xE0260000u, 46u}, // gby -> Latn + {0xE0260000u, 45u}, // gby -> Latn {0xE4260000u, 2u}, // gbz -> Arab - {0xC4460000u, 46u}, // gcr -> Latn - {0x67640000u, 46u}, // gd -> Latn - {0x90660000u, 46u}, // gde -> Latn - {0xB4660000u, 46u}, // gdn -> Latn - {0xC4660000u, 46u}, // gdr -> Latn - {0x84860000u, 46u}, // geb -> Latn - {0xA4860000u, 46u}, // gej -> Latn - {0xAC860000u, 46u}, // gel -> Latn + {0xC4460000u, 45u}, // gcr -> Latn + {0x67640000u, 45u}, // gd -> Latn + {0x90660000u, 45u}, // gde -> Latn + {0xB4660000u, 45u}, // gdn -> Latn + {0xC4660000u, 45u}, // gdr -> Latn + {0x84860000u, 45u}, // geb -> Latn + {0xA4860000u, 45u}, // gej -> Latn + {0xAC860000u, 45u}, // gel -> Latn {0xE4860000u, 21u}, // gez -> Ethi - {0xA8A60000u, 46u}, // gfk -> Latn + {0xA8A60000u, 45u}, // gfk -> Latn {0xB4C60000u, 19u}, // ggn -> Deva - {0xC8E60000u, 46u}, // ghs -> Latn - {0xAD060000u, 46u}, // gil -> Latn - {0xB1060000u, 46u}, // gim -> Latn + {0xC8E60000u, 45u}, // ghs -> Latn + {0xAD060000u, 45u}, // gil -> Latn + {0xB1060000u, 45u}, // gim -> Latn {0xA9260000u, 2u}, // gjk -> Arab - {0xB5260000u, 46u}, // gjn -> Latn + {0xB5260000u, 45u}, // gjn -> Latn {0xD1260000u, 2u}, // gju -> Arab - {0xB5460000u, 46u}, // gkn -> Latn - {0xBD460000u, 46u}, // gkp -> Latn - {0x676C0000u, 46u}, // gl -> Latn + {0xB5460000u, 45u}, // gkn -> Latn + {0xBD460000u, 45u}, // gkp -> Latn + {0x676C0000u, 45u}, // gl -> Latn {0xA9660000u, 2u}, // glk -> Arab - {0xB1860000u, 46u}, // gmm -> Latn + {0xB1860000u, 45u}, // gmm -> Latn {0xD5860000u, 21u}, // gmv -> Ethi - {0x676E0000u, 46u}, // gn -> Latn - {0x8DA60000u, 46u}, // gnd -> Latn - {0x99A60000u, 46u}, // gng -> Latn - {0x8DC60000u, 46u}, // god -> Latn + {0x676E0000u, 45u}, // gn -> Latn + {0x8DA60000u, 45u}, // gnd -> Latn + {0x99A60000u, 45u}, // gng -> Latn + {0x8DC60000u, 45u}, // god -> Latn {0x95C60000u, 21u}, // gof -> Ethi - {0xA1C60000u, 46u}, // goi -> Latn + {0xA1C60000u, 45u}, // goi -> Latn {0xB1C60000u, 19u}, // gom -> Deva - {0xB5C60000u, 88u}, // gon -> Telu - {0xC5C60000u, 46u}, // gor -> Latn - {0xC9C60000u, 46u}, // gos -> Latn + {0xB5C60000u, 89u}, // gon -> Telu + {0xC5C60000u, 45u}, // gor -> Latn + {0xC9C60000u, 45u}, // gos -> Latn {0xCDC60000u, 25u}, // got -> Goth - {0x86260000u, 46u}, // grb -> Latn + {0x86260000u, 45u}, // grb -> Latn {0x8A260000u, 17u}, // grc -> Cprt {0xCE260000u, 8u}, // grt -> Beng - {0xDA260000u, 46u}, // grw -> Latn - {0xDA460000u, 46u}, // gsw -> Latn + {0xDA260000u, 45u}, // grw -> Latn + {0xDA460000u, 45u}, // gsw -> Latn {0x67750000u, 27u}, // gu -> Gujr - {0x86860000u, 46u}, // gub -> Latn - {0x8A860000u, 46u}, // guc -> Latn - {0x8E860000u, 46u}, // gud -> Latn - {0xC6860000u, 46u}, // gur -> Latn - {0xDA860000u, 46u}, // guw -> Latn - {0xDE860000u, 46u}, // gux -> Latn - {0xE6860000u, 46u}, // guz -> Latn - {0x67760000u, 46u}, // gv -> Latn - {0x96A60000u, 46u}, // gvf -> Latn + {0x86860000u, 45u}, // gub -> Latn + {0x8A860000u, 45u}, // guc -> Latn + {0x8E860000u, 45u}, // gud -> Latn + {0xC6860000u, 45u}, // gur -> Latn + {0xDA860000u, 45u}, // guw -> Latn + {0xDE860000u, 45u}, // gux -> Latn + {0xE6860000u, 45u}, // guz -> Latn + {0x67760000u, 45u}, // gv -> Latn + {0x96A60000u, 45u}, // gvf -> Latn {0xC6A60000u, 19u}, // gvr -> Deva - {0xCAA60000u, 46u}, // gvs -> Latn + {0xCAA60000u, 45u}, // gvs -> Latn {0x8AC60000u, 2u}, // gwc -> Arab - {0xA2C60000u, 46u}, // gwi -> Latn + {0xA2C60000u, 45u}, // gwi -> Latn {0xCEC60000u, 2u}, // gwt -> Arab - {0xA3060000u, 46u}, // gyi -> Latn - {0x68610000u, 46u}, // ha -> Latn + {0xA3060000u, 45u}, // gyi -> Latn + {0x68610000u, 45u}, // ha -> Latn {0x6861434Du, 2u}, // ha-CM -> Arab {0x68615344u, 2u}, // ha-SD -> Arab - {0x98070000u, 46u}, // hag -> Latn + {0x98070000u, 45u}, // hag -> Latn {0xA8070000u, 29u}, // hak -> Hans - {0xB0070000u, 46u}, // ham -> Latn - {0xD8070000u, 46u}, // haw -> Latn + {0xB0070000u, 45u}, // ham -> Latn + {0xD8070000u, 45u}, // haw -> Latn {0xE4070000u, 2u}, // haz -> Arab - {0x84270000u, 46u}, // hbb -> Latn + {0x84270000u, 45u}, // hbb -> Latn {0xE0670000u, 21u}, // hdy -> Ethi {0x68650000u, 31u}, // he -> Hebr - {0xE0E70000u, 46u}, // hhy -> Latn + {0xE0E70000u, 45u}, // hhy -> Latn {0x68690000u, 19u}, // hi -> Deva - {0x81070000u, 46u}, // hia -> Latn - {0x95070000u, 46u}, // hif -> Latn - {0x99070000u, 46u}, // hig -> Latn - {0x9D070000u, 46u}, // hih -> Latn - {0xAD070000u, 46u}, // hil -> Latn - {0x81670000u, 46u}, // hla -> Latn + {0x81070000u, 45u}, // hia -> Latn + {0x95070000u, 45u}, // hif -> Latn + {0x99070000u, 45u}, // hig -> Latn + {0x9D070000u, 45u}, // hih -> Latn + {0xAD070000u, 45u}, // hil -> Latn + {0x81670000u, 45u}, // hla -> Latn {0xD1670000u, 32u}, // hlu -> Hluw {0x8D870000u, 71u}, // hmd -> Plrd - {0xCD870000u, 46u}, // hmt -> Latn + {0xCD870000u, 45u}, // hmt -> Latn {0x8DA70000u, 2u}, // hnd -> Arab {0x91A70000u, 19u}, // hne -> Deva - {0xA5A70000u, 33u}, // hnj -> Hmng - {0xB5A70000u, 46u}, // hnn -> Latn + {0xA5A70000u, 33u}, // hnj -> Hmnp + {0xB5A70000u, 45u}, // hnn -> Latn {0xB9A70000u, 2u}, // hno -> Arab - {0x686F0000u, 46u}, // ho -> Latn + {0x686F0000u, 45u}, // ho -> Latn {0x89C70000u, 19u}, // hoc -> Deva {0xA5C70000u, 19u}, // hoj -> Deva - {0xCDC70000u, 46u}, // hot -> Latn - {0x68720000u, 46u}, // hr -> Latn - {0x86470000u, 46u}, // hsb -> Latn + {0xCDC70000u, 45u}, // hot -> Latn + {0x68720000u, 45u}, // hr -> Latn + {0x86470000u, 45u}, // hsb -> Latn {0xB6470000u, 29u}, // hsn -> Hans - {0x68740000u, 46u}, // ht -> Latn - {0x68750000u, 46u}, // hu -> Latn - {0xA2870000u, 46u}, // hui -> Latn + {0x68740000u, 45u}, // ht -> Latn + {0x68750000u, 45u}, // hu -> Latn + {0xA2870000u, 45u}, // hui -> Latn {0x68790000u, 4u}, // hy -> Armn - {0x687A0000u, 46u}, // hz -> Latn - {0x69610000u, 46u}, // ia -> Latn - {0xB4080000u, 46u}, // ian -> Latn - {0xC4080000u, 46u}, // iar -> Latn - {0x80280000u, 46u}, // iba -> Latn - {0x84280000u, 46u}, // ibb -> Latn - {0xE0280000u, 46u}, // iby -> Latn - {0x80480000u, 46u}, // ica -> Latn - {0x9C480000u, 46u}, // ich -> Latn - {0x69640000u, 46u}, // id -> Latn - {0x8C680000u, 46u}, // idd -> Latn - {0xA0680000u, 46u}, // idi -> Latn - {0xD0680000u, 46u}, // idu -> Latn - {0x90A80000u, 46u}, // ife -> Latn - {0x69670000u, 46u}, // ig -> Latn - {0x84C80000u, 46u}, // igb -> Latn - {0x90C80000u, 46u}, // ige -> Latn - {0x69690000u, 98u}, // ii -> Yiii - {0xA5280000u, 46u}, // ijj -> Latn - {0x696B0000u, 46u}, // ik -> Latn - {0xA9480000u, 46u}, // ikk -> Latn - {0xCD480000u, 46u}, // ikt -> Latn - {0xD9480000u, 46u}, // ikw -> Latn - {0xDD480000u, 46u}, // ikx -> Latn - {0xB9680000u, 46u}, // ilo -> Latn - {0xB9880000u, 46u}, // imo -> Latn - {0x696E0000u, 46u}, // in -> Latn + {0x687A0000u, 45u}, // hz -> Latn + {0x69610000u, 45u}, // ia -> Latn + {0xB4080000u, 45u}, // ian -> Latn + {0xC4080000u, 45u}, // iar -> Latn + {0x80280000u, 45u}, // iba -> Latn + {0x84280000u, 45u}, // ibb -> Latn + {0xE0280000u, 45u}, // iby -> Latn + {0x80480000u, 45u}, // ica -> Latn + {0x9C480000u, 45u}, // ich -> Latn + {0x69640000u, 45u}, // id -> Latn + {0x8C680000u, 45u}, // idd -> Latn + {0xA0680000u, 45u}, // idi -> Latn + {0xD0680000u, 45u}, // idu -> Latn + {0x90A80000u, 45u}, // ife -> Latn + {0x69670000u, 45u}, // ig -> Latn + {0x84C80000u, 45u}, // igb -> Latn + {0x90C80000u, 45u}, // ige -> Latn + {0x69690000u, 101u}, // ii -> Yiii + {0xA5280000u, 45u}, // ijj -> Latn + {0x696B0000u, 45u}, // ik -> Latn + {0xA9480000u, 45u}, // ikk -> Latn + {0xCD480000u, 45u}, // ikt -> Latn + {0xD9480000u, 45u}, // ikw -> Latn + {0xDD480000u, 45u}, // ikx -> Latn + {0xB9680000u, 45u}, // ilo -> Latn + {0xB9880000u, 45u}, // imo -> Latn + {0x696E0000u, 45u}, // in -> Latn {0x9DA80000u, 18u}, // inh -> Cyrl - {0x696F0000u, 46u}, // io -> Latn - {0xD1C80000u, 46u}, // iou -> Latn - {0xA2280000u, 46u}, // iri -> Latn - {0x69730000u, 46u}, // is -> Latn - {0x69740000u, 46u}, // it -> Latn + {0x696F0000u, 45u}, // io -> Latn + {0xD1C80000u, 45u}, // iou -> Latn + {0xA2280000u, 45u}, // iri -> Latn + {0x69730000u, 45u}, // is -> Latn + {0x69740000u, 45u}, // it -> Latn {0x69750000u, 11u}, // iu -> Cans {0x69770000u, 31u}, // iw -> Hebr - {0xB2C80000u, 46u}, // iwm -> Latn - {0xCAC80000u, 46u}, // iws -> Latn - {0x9F280000u, 46u}, // izh -> Latn - {0xA3280000u, 46u}, // izi -> Latn - {0x6A610000u, 36u}, // ja -> Jpan - {0x84090000u, 46u}, // jab -> Latn - {0xB0090000u, 46u}, // jam -> Latn - {0xC4090000u, 46u}, // jar -> Latn - {0xB8290000u, 46u}, // jbo -> Latn - {0xD0290000u, 46u}, // jbu -> Latn - {0xB4890000u, 46u}, // jen -> Latn - {0xA8C90000u, 46u}, // jgk -> Latn - {0xB8C90000u, 46u}, // jgo -> Latn + {0xB2C80000u, 45u}, // iwm -> Latn + {0xCAC80000u, 45u}, // iws -> Latn + {0x9F280000u, 45u}, // izh -> Latn + {0xA3280000u, 45u}, // izi -> Latn + {0x6A610000u, 35u}, // ja -> Jpan + {0x84090000u, 45u}, // jab -> Latn + {0xB0090000u, 45u}, // jam -> Latn + {0xC4090000u, 45u}, // jar -> Latn + {0xB8290000u, 45u}, // jbo -> Latn + {0xD0290000u, 45u}, // jbu -> Latn + {0xB4890000u, 45u}, // jen -> Latn + {0xA8C90000u, 45u}, // jgk -> Latn + {0xB8C90000u, 45u}, // jgo -> Latn {0x6A690000u, 31u}, // ji -> Hebr - {0x85090000u, 46u}, // jib -> Latn - {0x89890000u, 46u}, // jmc -> Latn + {0x85090000u, 45u}, // jib -> Latn + {0x89890000u, 45u}, // jmc -> Latn {0xAD890000u, 19u}, // jml -> Deva - {0x82290000u, 46u}, // jra -> Latn - {0xCE890000u, 46u}, // jut -> Latn - {0x6A760000u, 46u}, // jv -> Latn - {0x6A770000u, 46u}, // jw -> Latn + {0x82290000u, 45u}, // jra -> Latn + {0xCE890000u, 45u}, // jut -> Latn + {0x6A760000u, 45u}, // jv -> Latn + {0x6A770000u, 45u}, // jw -> Latn {0x6B610000u, 22u}, // ka -> Geor {0x800A0000u, 18u}, // kaa -> Cyrl - {0x840A0000u, 46u}, // kab -> Latn - {0x880A0000u, 46u}, // kac -> Latn - {0x8C0A0000u, 46u}, // kad -> Latn - {0xA00A0000u, 46u}, // kai -> Latn - {0xA40A0000u, 46u}, // kaj -> Latn - {0xB00A0000u, 46u}, // kam -> Latn - {0xB80A0000u, 46u}, // kao -> Latn + {0x840A0000u, 45u}, // kab -> Latn + {0x880A0000u, 45u}, // kac -> Latn + {0x8C0A0000u, 45u}, // kad -> Latn + {0xA00A0000u, 45u}, // kai -> Latn + {0xA40A0000u, 45u}, // kaj -> Latn + {0xB00A0000u, 45u}, // kam -> Latn + {0xB80A0000u, 45u}, // kao -> Latn {0x8C2A0000u, 18u}, // kbd -> Cyrl - {0xB02A0000u, 46u}, // kbm -> Latn - {0xBC2A0000u, 46u}, // kbp -> Latn - {0xC02A0000u, 46u}, // kbq -> Latn - {0xDC2A0000u, 46u}, // kbx -> Latn + {0xB02A0000u, 45u}, // kbm -> Latn + {0xBC2A0000u, 45u}, // kbp -> Latn + {0xC02A0000u, 45u}, // kbq -> Latn + {0xDC2A0000u, 45u}, // kbx -> Latn {0xE02A0000u, 2u}, // kby -> Arab - {0x984A0000u, 46u}, // kcg -> Latn - {0xA84A0000u, 46u}, // kck -> Latn - {0xAC4A0000u, 46u}, // kcl -> Latn - {0xCC4A0000u, 46u}, // kct -> Latn - {0x906A0000u, 46u}, // kde -> Latn - {0x9C6A0000u, 2u}, // kdh -> Arab - {0xAC6A0000u, 46u}, // kdl -> Latn - {0xCC6A0000u, 91u}, // kdt -> Thai - {0x808A0000u, 46u}, // kea -> Latn - {0xB48A0000u, 46u}, // ken -> Latn - {0xE48A0000u, 46u}, // kez -> Latn - {0xB8AA0000u, 46u}, // kfo -> Latn + {0x984A0000u, 45u}, // kcg -> Latn + {0xA84A0000u, 45u}, // kck -> Latn + {0xAC4A0000u, 45u}, // kcl -> Latn + {0xCC4A0000u, 45u}, // kct -> Latn + {0x906A0000u, 45u}, // kde -> Latn + {0x9C6A0000u, 45u}, // kdh -> Latn + {0xAC6A0000u, 45u}, // kdl -> Latn + {0xCC6A0000u, 92u}, // kdt -> Thai + {0x808A0000u, 45u}, // kea -> Latn + {0xB48A0000u, 45u}, // ken -> Latn + {0xE48A0000u, 45u}, // kez -> Latn + {0xB8AA0000u, 45u}, // kfo -> Latn {0xC4AA0000u, 19u}, // kfr -> Deva {0xE0AA0000u, 19u}, // kfy -> Deva - {0x6B670000u, 46u}, // kg -> Latn - {0x90CA0000u, 46u}, // kge -> Latn - {0x94CA0000u, 46u}, // kgf -> Latn - {0xBCCA0000u, 46u}, // kgp -> Latn - {0x80EA0000u, 46u}, // kha -> Latn - {0x84EA0000u, 84u}, // khb -> Talu + {0x6B670000u, 45u}, // kg -> Latn + {0x90CA0000u, 45u}, // kge -> Latn + {0x94CA0000u, 45u}, // kgf -> Latn + {0xBCCA0000u, 45u}, // kgp -> Latn + {0x80EA0000u, 45u}, // kha -> Latn + {0x84EA0000u, 85u}, // khb -> Talu {0xB4EA0000u, 19u}, // khn -> Deva - {0xC0EA0000u, 46u}, // khq -> Latn - {0xC8EA0000u, 46u}, // khs -> Latn - {0xCCEA0000u, 59u}, // kht -> Mymr + {0xC0EA0000u, 45u}, // khq -> Latn + {0xC8EA0000u, 45u}, // khs -> Latn + {0xCCEA0000u, 58u}, // kht -> Mymr {0xD8EA0000u, 2u}, // khw -> Arab - {0xE4EA0000u, 46u}, // khz -> Latn - {0x6B690000u, 46u}, // ki -> Latn - {0xA50A0000u, 46u}, // kij -> Latn - {0xD10A0000u, 46u}, // kiu -> Latn - {0xD90A0000u, 46u}, // kiw -> Latn - {0x6B6A0000u, 46u}, // kj -> Latn - {0x8D2A0000u, 46u}, // kjd -> Latn - {0x992A0000u, 45u}, // kjg -> Laoo - {0xC92A0000u, 46u}, // kjs -> Latn - {0xE12A0000u, 46u}, // kjy -> Latn + {0xE4EA0000u, 45u}, // khz -> Latn + {0x6B690000u, 45u}, // ki -> Latn + {0xA50A0000u, 45u}, // kij -> Latn + {0xD10A0000u, 45u}, // kiu -> Latn + {0xD90A0000u, 45u}, // kiw -> Latn + {0x6B6A0000u, 45u}, // kj -> Latn + {0x8D2A0000u, 45u}, // kjd -> Latn + {0x992A0000u, 44u}, // kjg -> Laoo + {0xC92A0000u, 45u}, // kjs -> Latn + {0xE12A0000u, 45u}, // kjy -> Latn {0x6B6B0000u, 18u}, // kk -> Cyrl {0x6B6B4146u, 2u}, // kk-AF -> Arab {0x6B6B434Eu, 2u}, // kk-CN -> Arab {0x6B6B4952u, 2u}, // kk-IR -> Arab {0x6B6B4D4Eu, 2u}, // kk-MN -> Arab - {0x894A0000u, 46u}, // kkc -> Latn - {0xA54A0000u, 46u}, // kkj -> Latn - {0x6B6C0000u, 46u}, // kl -> Latn - {0xB56A0000u, 46u}, // kln -> Latn - {0xC16A0000u, 46u}, // klq -> Latn - {0xCD6A0000u, 46u}, // klt -> Latn - {0xDD6A0000u, 46u}, // klx -> Latn - {0x6B6D0000u, 40u}, // km -> Khmr - {0x858A0000u, 46u}, // kmb -> Latn - {0x9D8A0000u, 46u}, // kmh -> Latn - {0xB98A0000u, 46u}, // kmo -> Latn - {0xC98A0000u, 46u}, // kms -> Latn - {0xD18A0000u, 46u}, // kmu -> Latn - {0xD98A0000u, 46u}, // kmw -> Latn - {0x6B6E0000u, 42u}, // kn -> Knda - {0x95AA0000u, 46u}, // knf -> Latn - {0xBDAA0000u, 46u}, // knp -> Latn - {0x6B6F0000u, 43u}, // ko -> Kore + {0x894A0000u, 45u}, // kkc -> Latn + {0xA54A0000u, 45u}, // kkj -> Latn + {0x6B6C0000u, 45u}, // kl -> Latn + {0xB56A0000u, 45u}, // kln -> Latn + {0xC16A0000u, 45u}, // klq -> Latn + {0xCD6A0000u, 45u}, // klt -> Latn + {0xDD6A0000u, 45u}, // klx -> Latn + {0x6B6D0000u, 39u}, // km -> Khmr + {0x858A0000u, 45u}, // kmb -> Latn + {0x9D8A0000u, 45u}, // kmh -> Latn + {0xB98A0000u, 45u}, // kmo -> Latn + {0xC98A0000u, 45u}, // kms -> Latn + {0xD18A0000u, 45u}, // kmu -> Latn + {0xD98A0000u, 45u}, // kmw -> Latn + {0x6B6E0000u, 41u}, // kn -> Knda + {0x95AA0000u, 45u}, // knf -> Latn + {0xBDAA0000u, 45u}, // knp -> Latn + {0x6B6F0000u, 42u}, // ko -> Kore {0xA1CA0000u, 18u}, // koi -> Cyrl {0xA9CA0000u, 19u}, // kok -> Deva - {0xADCA0000u, 46u}, // kol -> Latn - {0xC9CA0000u, 46u}, // kos -> Latn - {0xE5CA0000u, 46u}, // koz -> Latn - {0x91EA0000u, 46u}, // kpe -> Latn - {0x95EA0000u, 46u}, // kpf -> Latn - {0xB9EA0000u, 46u}, // kpo -> Latn - {0xC5EA0000u, 46u}, // kpr -> Latn - {0xDDEA0000u, 46u}, // kpx -> Latn - {0x860A0000u, 46u}, // kqb -> Latn - {0x960A0000u, 46u}, // kqf -> Latn - {0xCA0A0000u, 46u}, // kqs -> Latn + {0xADCA0000u, 45u}, // kol -> Latn + {0xC9CA0000u, 45u}, // kos -> Latn + {0xE5CA0000u, 45u}, // koz -> Latn + {0x91EA0000u, 45u}, // kpe -> Latn + {0x95EA0000u, 45u}, // kpf -> Latn + {0xB9EA0000u, 45u}, // kpo -> Latn + {0xC5EA0000u, 45u}, // kpr -> Latn + {0xDDEA0000u, 45u}, // kpx -> Latn + {0x860A0000u, 45u}, // kqb -> Latn + {0x960A0000u, 45u}, // kqf -> Latn + {0xCA0A0000u, 45u}, // kqs -> Latn {0xE20A0000u, 21u}, // kqy -> Ethi - {0x6B720000u, 46u}, // kr -> Latn + {0x6B720000u, 45u}, // kr -> Latn {0x8A2A0000u, 18u}, // krc -> Cyrl - {0xA22A0000u, 46u}, // kri -> Latn - {0xA62A0000u, 46u}, // krj -> Latn - {0xAE2A0000u, 46u}, // krl -> Latn - {0xCA2A0000u, 46u}, // krs -> Latn + {0xA22A0000u, 45u}, // kri -> Latn + {0xA62A0000u, 45u}, // krj -> Latn + {0xAE2A0000u, 45u}, // krl -> Latn + {0xCA2A0000u, 45u}, // krs -> Latn {0xD22A0000u, 19u}, // kru -> Deva {0x6B730000u, 2u}, // ks -> Arab - {0x864A0000u, 46u}, // ksb -> Latn - {0x8E4A0000u, 46u}, // ksd -> Latn - {0x964A0000u, 46u}, // ksf -> Latn - {0x9E4A0000u, 46u}, // ksh -> Latn - {0xA64A0000u, 46u}, // ksj -> Latn - {0xC64A0000u, 46u}, // ksr -> Latn + {0x864A0000u, 45u}, // ksb -> Latn + {0x8E4A0000u, 45u}, // ksd -> Latn + {0x964A0000u, 45u}, // ksf -> Latn + {0x9E4A0000u, 45u}, // ksh -> Latn + {0xA64A0000u, 45u}, // ksj -> Latn + {0xC64A0000u, 45u}, // ksr -> Latn {0x866A0000u, 21u}, // ktb -> Ethi - {0xB26A0000u, 46u}, // ktm -> Latn - {0xBA6A0000u, 46u}, // kto -> Latn - {0xC66A0000u, 46u}, // ktr -> Latn - {0x6B750000u, 46u}, // ku -> Latn + {0xB26A0000u, 45u}, // ktm -> Latn + {0xBA6A0000u, 45u}, // kto -> Latn + {0xC66A0000u, 45u}, // ktr -> Latn + {0x6B750000u, 45u}, // ku -> Latn {0x6B754952u, 2u}, // ku-IR -> Arab {0x6B754C42u, 2u}, // ku-LB -> Arab - {0x868A0000u, 46u}, // kub -> Latn - {0x8E8A0000u, 46u}, // kud -> Latn - {0x928A0000u, 46u}, // kue -> Latn - {0xA68A0000u, 46u}, // kuj -> Latn + {0x868A0000u, 45u}, // kub -> Latn + {0x8E8A0000u, 45u}, // kud -> Latn + {0x928A0000u, 45u}, // kue -> Latn + {0xA68A0000u, 45u}, // kuj -> Latn {0xB28A0000u, 18u}, // kum -> Cyrl - {0xB68A0000u, 46u}, // kun -> Latn - {0xBE8A0000u, 46u}, // kup -> Latn - {0xCA8A0000u, 46u}, // kus -> Latn + {0xB68A0000u, 45u}, // kun -> Latn + {0xBE8A0000u, 45u}, // kup -> Latn + {0xCA8A0000u, 45u}, // kus -> Latn {0x6B760000u, 18u}, // kv -> Cyrl - {0x9AAA0000u, 46u}, // kvg -> Latn - {0xC6AA0000u, 46u}, // kvr -> Latn + {0x9AAA0000u, 45u}, // kvg -> Latn + {0xC6AA0000u, 45u}, // kvr -> Latn {0xDEAA0000u, 2u}, // kvx -> Arab - {0x6B770000u, 46u}, // kw -> Latn - {0xA6CA0000u, 46u}, // kwj -> Latn - {0xBACA0000u, 46u}, // kwo -> Latn - {0xC2CA0000u, 46u}, // kwq -> Latn - {0x82EA0000u, 46u}, // kxa -> Latn + {0x6B770000u, 45u}, // kw -> Latn + {0xA6CA0000u, 45u}, // kwj -> Latn + {0xBACA0000u, 45u}, // kwo -> Latn + {0xC2CA0000u, 45u}, // kwq -> Latn + {0x82EA0000u, 45u}, // kxa -> Latn {0x8AEA0000u, 21u}, // kxc -> Ethi - {0x92EA0000u, 46u}, // kxe -> Latn + {0x92EA0000u, 45u}, // kxe -> Latn {0xAEEA0000u, 19u}, // kxl -> Deva - {0xB2EA0000u, 91u}, // kxm -> Thai + {0xB2EA0000u, 92u}, // kxm -> Thai {0xBEEA0000u, 2u}, // kxp -> Arab - {0xDAEA0000u, 46u}, // kxw -> Latn - {0xE6EA0000u, 46u}, // kxz -> Latn + {0xDAEA0000u, 45u}, // kxw -> Latn + {0xE6EA0000u, 45u}, // kxz -> Latn {0x6B790000u, 18u}, // ky -> Cyrl {0x6B79434Eu, 2u}, // ky-CN -> Arab - {0x6B795452u, 46u}, // ky-TR -> Latn - {0x930A0000u, 46u}, // kye -> Latn - {0xDF0A0000u, 46u}, // kyx -> Latn + {0x6B795452u, 45u}, // ky-TR -> Latn + {0x930A0000u, 45u}, // kye -> Latn + {0xDF0A0000u, 45u}, // kyx -> Latn {0x9F2A0000u, 2u}, // kzh -> Arab - {0xA72A0000u, 46u}, // kzj -> Latn - {0xC72A0000u, 46u}, // kzr -> Latn - {0xCF2A0000u, 46u}, // kzt -> Latn - {0x6C610000u, 46u}, // la -> Latn - {0x840B0000u, 48u}, // lab -> Lina + {0xA72A0000u, 45u}, // kzj -> Latn + {0xC72A0000u, 45u}, // kzr -> Latn + {0xCF2A0000u, 45u}, // kzt -> Latn + {0x6C610000u, 45u}, // la -> Latn + {0x840B0000u, 47u}, // lab -> Lina {0x8C0B0000u, 31u}, // lad -> Hebr - {0x980B0000u, 46u}, // lag -> Latn + {0x980B0000u, 45u}, // lag -> Latn {0x9C0B0000u, 2u}, // lah -> Arab - {0xA40B0000u, 46u}, // laj -> Latn - {0xC80B0000u, 46u}, // las -> Latn - {0x6C620000u, 46u}, // lb -> Latn + {0xA40B0000u, 45u}, // laj -> Latn + {0xC80B0000u, 45u}, // las -> Latn + {0x6C620000u, 45u}, // lb -> Latn {0x902B0000u, 18u}, // lbe -> Cyrl - {0xD02B0000u, 46u}, // lbu -> Latn - {0xD82B0000u, 46u}, // lbw -> Latn - {0xB04B0000u, 46u}, // lcm -> Latn - {0xBC4B0000u, 91u}, // lcp -> Thai - {0x846B0000u, 46u}, // ldb -> Latn - {0x8C8B0000u, 46u}, // led -> Latn - {0x908B0000u, 46u}, // lee -> Latn - {0xB08B0000u, 46u}, // lem -> Latn - {0xBC8B0000u, 47u}, // lep -> Lepc - {0xC08B0000u, 46u}, // leq -> Latn - {0xD08B0000u, 46u}, // leu -> Latn + {0xD02B0000u, 45u}, // lbu -> Latn + {0xD82B0000u, 45u}, // lbw -> Latn + {0xB04B0000u, 45u}, // lcm -> Latn + {0xBC4B0000u, 92u}, // lcp -> Thai + {0x846B0000u, 45u}, // ldb -> Latn + {0x8C8B0000u, 45u}, // led -> Latn + {0x908B0000u, 45u}, // lee -> Latn + {0xB08B0000u, 45u}, // lem -> Latn + {0xBC8B0000u, 46u}, // lep -> Lepc + {0xC08B0000u, 45u}, // leq -> Latn + {0xD08B0000u, 45u}, // leu -> Latn {0xE48B0000u, 18u}, // lez -> Cyrl - {0x6C670000u, 46u}, // lg -> Latn - {0x98CB0000u, 46u}, // lgg -> Latn - {0x6C690000u, 46u}, // li -> Latn - {0x810B0000u, 46u}, // lia -> Latn - {0x8D0B0000u, 46u}, // lid -> Latn + {0x6C670000u, 45u}, // lg -> Latn + {0x98CB0000u, 45u}, // lgg -> Latn + {0x6C690000u, 45u}, // li -> Latn + {0x810B0000u, 45u}, // lia -> Latn + {0x8D0B0000u, 45u}, // lid -> Latn {0x950B0000u, 19u}, // lif -> Deva - {0x990B0000u, 46u}, // lig -> Latn - {0x9D0B0000u, 46u}, // lih -> Latn - {0xA50B0000u, 46u}, // lij -> Latn - {0xC90B0000u, 49u}, // lis -> Lisu - {0xBD2B0000u, 46u}, // ljp -> Latn + {0x990B0000u, 45u}, // lig -> Latn + {0x9D0B0000u, 45u}, // lih -> Latn + {0xA50B0000u, 45u}, // lij -> Latn + {0xC90B0000u, 48u}, // lis -> Lisu + {0xBD2B0000u, 45u}, // ljp -> Latn {0xA14B0000u, 2u}, // lki -> Arab - {0xCD4B0000u, 46u}, // lkt -> Latn - {0x916B0000u, 46u}, // lle -> Latn - {0xB56B0000u, 46u}, // lln -> Latn - {0xB58B0000u, 88u}, // lmn -> Telu - {0xB98B0000u, 46u}, // lmo -> Latn - {0xBD8B0000u, 46u}, // lmp -> Latn - {0x6C6E0000u, 46u}, // ln -> Latn - {0xC9AB0000u, 46u}, // lns -> Latn - {0xD1AB0000u, 46u}, // lnu -> Latn - {0x6C6F0000u, 45u}, // lo -> Laoo - {0xA5CB0000u, 46u}, // loj -> Latn - {0xA9CB0000u, 46u}, // lok -> Latn - {0xADCB0000u, 46u}, // lol -> Latn - {0xC5CB0000u, 46u}, // lor -> Latn - {0xC9CB0000u, 46u}, // los -> Latn - {0xE5CB0000u, 46u}, // loz -> Latn + {0xCD4B0000u, 45u}, // lkt -> Latn + {0x916B0000u, 45u}, // lle -> Latn + {0xB56B0000u, 45u}, // lln -> Latn + {0xB58B0000u, 89u}, // lmn -> Telu + {0xB98B0000u, 45u}, // lmo -> Latn + {0xBD8B0000u, 45u}, // lmp -> Latn + {0x6C6E0000u, 45u}, // ln -> Latn + {0xC9AB0000u, 45u}, // lns -> Latn + {0xD1AB0000u, 45u}, // lnu -> Latn + {0x6C6F0000u, 44u}, // lo -> Laoo + {0xA5CB0000u, 45u}, // loj -> Latn + {0xA9CB0000u, 45u}, // lok -> Latn + {0xADCB0000u, 45u}, // lol -> Latn + {0xC5CB0000u, 45u}, // lor -> Latn + {0xC9CB0000u, 45u}, // los -> Latn + {0xE5CB0000u, 45u}, // loz -> Latn {0x8A2B0000u, 2u}, // lrc -> Arab - {0x6C740000u, 46u}, // lt -> Latn - {0x9A6B0000u, 46u}, // ltg -> Latn - {0x6C750000u, 46u}, // lu -> Latn - {0x828B0000u, 46u}, // lua -> Latn - {0xBA8B0000u, 46u}, // luo -> Latn - {0xE28B0000u, 46u}, // luy -> Latn + {0x6C740000u, 45u}, // lt -> Latn + {0x9A6B0000u, 45u}, // ltg -> Latn + {0x6C750000u, 45u}, // lu -> Latn + {0x828B0000u, 45u}, // lua -> Latn + {0xBA8B0000u, 45u}, // luo -> Latn + {0xE28B0000u, 45u}, // luy -> Latn {0xE68B0000u, 2u}, // luz -> Arab - {0x6C760000u, 46u}, // lv -> Latn - {0xAECB0000u, 91u}, // lwl -> Thai + {0x6C760000u, 45u}, // lv -> Latn + {0xAECB0000u, 92u}, // lwl -> Thai {0x9F2B0000u, 29u}, // lzh -> Hans - {0xE72B0000u, 46u}, // lzz -> Latn - {0x8C0C0000u, 46u}, // mad -> Latn - {0x940C0000u, 46u}, // maf -> Latn + {0xE72B0000u, 45u}, // lzz -> Latn + {0x8C0C0000u, 45u}, // mad -> Latn + {0x940C0000u, 45u}, // maf -> Latn {0x980C0000u, 19u}, // mag -> Deva {0xA00C0000u, 19u}, // mai -> Deva - {0xA80C0000u, 46u}, // mak -> Latn - {0xB40C0000u, 46u}, // man -> Latn - {0xB40C474Eu, 61u}, // man-GN -> Nkoo - {0xC80C0000u, 46u}, // mas -> Latn - {0xD80C0000u, 46u}, // maw -> Latn - {0xE40C0000u, 46u}, // maz -> Latn - {0x9C2C0000u, 46u}, // mbh -> Latn - {0xB82C0000u, 46u}, // mbo -> Latn - {0xC02C0000u, 46u}, // mbq -> Latn - {0xD02C0000u, 46u}, // mbu -> Latn - {0xD82C0000u, 46u}, // mbw -> Latn - {0xA04C0000u, 46u}, // mci -> Latn - {0xBC4C0000u, 46u}, // mcp -> Latn - {0xC04C0000u, 46u}, // mcq -> Latn - {0xC44C0000u, 46u}, // mcr -> Latn - {0xD04C0000u, 46u}, // mcu -> Latn - {0x806C0000u, 46u}, // mda -> Latn + {0xA80C0000u, 45u}, // mak -> Latn + {0xB40C0000u, 45u}, // man -> Latn + {0xB40C474Eu, 60u}, // man-GN -> Nkoo + {0xC80C0000u, 45u}, // mas -> Latn + {0xD80C0000u, 45u}, // maw -> Latn + {0xE40C0000u, 45u}, // maz -> Latn + {0x9C2C0000u, 45u}, // mbh -> Latn + {0xB82C0000u, 45u}, // mbo -> Latn + {0xC02C0000u, 45u}, // mbq -> Latn + {0xD02C0000u, 45u}, // mbu -> Latn + {0xD82C0000u, 45u}, // mbw -> Latn + {0xA04C0000u, 45u}, // mci -> Latn + {0xBC4C0000u, 45u}, // mcp -> Latn + {0xC04C0000u, 45u}, // mcq -> Latn + {0xC44C0000u, 45u}, // mcr -> Latn + {0xD04C0000u, 45u}, // mcu -> Latn + {0x806C0000u, 45u}, // mda -> Latn {0x906C0000u, 2u}, // mde -> Arab {0x946C0000u, 18u}, // mdf -> Cyrl - {0x9C6C0000u, 46u}, // mdh -> Latn - {0xA46C0000u, 46u}, // mdj -> Latn - {0xC46C0000u, 46u}, // mdr -> Latn + {0x9C6C0000u, 45u}, // mdh -> Latn + {0xA46C0000u, 45u}, // mdj -> Latn + {0xC46C0000u, 45u}, // mdr -> Latn {0xDC6C0000u, 21u}, // mdx -> Ethi - {0x8C8C0000u, 46u}, // med -> Latn - {0x908C0000u, 46u}, // mee -> Latn - {0xA88C0000u, 46u}, // mek -> Latn - {0xB48C0000u, 46u}, // men -> Latn - {0xC48C0000u, 46u}, // mer -> Latn - {0xCC8C0000u, 46u}, // met -> Latn - {0xD08C0000u, 46u}, // meu -> Latn + {0x8C8C0000u, 45u}, // med -> Latn + {0x908C0000u, 45u}, // mee -> Latn + {0xA88C0000u, 45u}, // mek -> Latn + {0xB48C0000u, 45u}, // men -> Latn + {0xC48C0000u, 45u}, // mer -> Latn + {0xCC8C0000u, 45u}, // met -> Latn + {0xD08C0000u, 45u}, // meu -> Latn {0x80AC0000u, 2u}, // mfa -> Arab - {0x90AC0000u, 46u}, // mfe -> Latn - {0xB4AC0000u, 46u}, // mfn -> Latn - {0xB8AC0000u, 46u}, // mfo -> Latn - {0xC0AC0000u, 46u}, // mfq -> Latn - {0x6D670000u, 46u}, // mg -> Latn - {0x9CCC0000u, 46u}, // mgh -> Latn - {0xACCC0000u, 46u}, // mgl -> Latn - {0xB8CC0000u, 46u}, // mgo -> Latn + {0x90AC0000u, 45u}, // mfe -> Latn + {0xB4AC0000u, 45u}, // mfn -> Latn + {0xB8AC0000u, 45u}, // mfo -> Latn + {0xC0AC0000u, 45u}, // mfq -> Latn + {0x6D670000u, 45u}, // mg -> Latn + {0x9CCC0000u, 45u}, // mgh -> Latn + {0xACCC0000u, 45u}, // mgl -> Latn + {0xB8CC0000u, 45u}, // mgo -> Latn {0xBCCC0000u, 19u}, // mgp -> Deva - {0xE0CC0000u, 46u}, // mgy -> Latn - {0x6D680000u, 46u}, // mh -> Latn - {0xA0EC0000u, 46u}, // mhi -> Latn - {0xACEC0000u, 46u}, // mhl -> Latn - {0x6D690000u, 46u}, // mi -> Latn - {0x950C0000u, 46u}, // mif -> Latn - {0xB50C0000u, 46u}, // min -> Latn - {0xD90C0000u, 46u}, // miw -> Latn + {0xE0CC0000u, 45u}, // mgy -> Latn + {0x6D680000u, 45u}, // mh -> Latn + {0xA0EC0000u, 45u}, // mhi -> Latn + {0xACEC0000u, 45u}, // mhl -> Latn + {0x6D690000u, 45u}, // mi -> Latn + {0x950C0000u, 45u}, // mif -> Latn + {0xB50C0000u, 45u}, // min -> Latn + {0xD90C0000u, 45u}, // miw -> Latn {0x6D6B0000u, 18u}, // mk -> Cyrl {0xA14C0000u, 2u}, // mki -> Arab - {0xAD4C0000u, 46u}, // mkl -> Latn - {0xBD4C0000u, 46u}, // mkp -> Latn - {0xD94C0000u, 46u}, // mkw -> Latn - {0x6D6C0000u, 56u}, // ml -> Mlym - {0x916C0000u, 46u}, // mle -> Latn - {0xBD6C0000u, 46u}, // mlp -> Latn - {0xC96C0000u, 46u}, // mls -> Latn - {0xB98C0000u, 46u}, // mmo -> Latn - {0xD18C0000u, 46u}, // mmu -> Latn - {0xDD8C0000u, 46u}, // mmx -> Latn + {0xAD4C0000u, 45u}, // mkl -> Latn + {0xBD4C0000u, 45u}, // mkp -> Latn + {0xD94C0000u, 45u}, // mkw -> Latn + {0x6D6C0000u, 55u}, // ml -> Mlym + {0x916C0000u, 45u}, // mle -> Latn + {0xBD6C0000u, 45u}, // mlp -> Latn + {0xC96C0000u, 45u}, // mls -> Latn + {0xB98C0000u, 45u}, // mmo -> Latn + {0xD18C0000u, 45u}, // mmu -> Latn + {0xDD8C0000u, 45u}, // mmx -> Latn {0x6D6E0000u, 18u}, // mn -> Cyrl - {0x6D6E434Eu, 57u}, // mn-CN -> Mong - {0x81AC0000u, 46u}, // mna -> Latn - {0x95AC0000u, 46u}, // mnf -> Latn + {0x6D6E434Eu, 56u}, // mn-CN -> Mong + {0x81AC0000u, 45u}, // mna -> Latn + {0x95AC0000u, 45u}, // mnf -> Latn {0xA1AC0000u, 8u}, // mni -> Beng - {0xD9AC0000u, 59u}, // mnw -> Mymr - {0x6D6F0000u, 46u}, // mo -> Latn - {0x81CC0000u, 46u}, // moa -> Latn - {0x91CC0000u, 46u}, // moe -> Latn - {0x9DCC0000u, 46u}, // moh -> Latn - {0xC9CC0000u, 46u}, // mos -> Latn - {0xDDCC0000u, 46u}, // mox -> Latn - {0xBDEC0000u, 46u}, // mpp -> Latn - {0xC9EC0000u, 46u}, // mps -> Latn - {0xCDEC0000u, 46u}, // mpt -> Latn - {0xDDEC0000u, 46u}, // mpx -> Latn - {0xAE0C0000u, 46u}, // mql -> Latn + {0xD9AC0000u, 58u}, // mnw -> Mymr + {0x6D6F0000u, 45u}, // mo -> Latn + {0x81CC0000u, 45u}, // moa -> Latn + {0x91CC0000u, 45u}, // moe -> Latn + {0x9DCC0000u, 45u}, // moh -> Latn + {0xC9CC0000u, 45u}, // mos -> Latn + {0xDDCC0000u, 45u}, // mox -> Latn + {0xBDEC0000u, 45u}, // mpp -> Latn + {0xC9EC0000u, 45u}, // mps -> Latn + {0xCDEC0000u, 45u}, // mpt -> Latn + {0xDDEC0000u, 45u}, // mpx -> Latn + {0xAE0C0000u, 45u}, // mql -> Latn {0x6D720000u, 19u}, // mr -> Deva {0x8E2C0000u, 19u}, // mrd -> Deva {0xA62C0000u, 18u}, // mrj -> Cyrl - {0xBA2C0000u, 58u}, // mro -> Mroo - {0x6D730000u, 46u}, // ms -> Latn + {0xBA2C0000u, 57u}, // mro -> Mroo + {0x6D730000u, 45u}, // ms -> Latn {0x6D734343u, 2u}, // ms-CC -> Arab - {0x6D740000u, 46u}, // mt -> Latn - {0x8A6C0000u, 46u}, // mtc -> Latn - {0x966C0000u, 46u}, // mtf -> Latn - {0xA26C0000u, 46u}, // mti -> Latn + {0x6D740000u, 45u}, // mt -> Latn + {0x8A6C0000u, 45u}, // mtc -> Latn + {0x966C0000u, 45u}, // mtf -> Latn + {0xA26C0000u, 45u}, // mti -> Latn {0xC66C0000u, 19u}, // mtr -> Deva - {0x828C0000u, 46u}, // mua -> Latn - {0xC68C0000u, 46u}, // mur -> Latn - {0xCA8C0000u, 46u}, // mus -> Latn - {0x82AC0000u, 46u}, // mva -> Latn - {0xB6AC0000u, 46u}, // mvn -> Latn + {0x828C0000u, 45u}, // mua -> Latn + {0xC68C0000u, 45u}, // mur -> Latn + {0xCA8C0000u, 45u}, // mus -> Latn + {0x82AC0000u, 45u}, // mva -> Latn + {0xB6AC0000u, 45u}, // mvn -> Latn {0xE2AC0000u, 2u}, // mvy -> Arab - {0xAACC0000u, 46u}, // mwk -> Latn + {0xAACC0000u, 45u}, // mwk -> Latn {0xC6CC0000u, 19u}, // mwr -> Deva - {0xD6CC0000u, 46u}, // mwv -> Latn - {0xDACC0000u, 34u}, // mww -> Hmnp - {0x8AEC0000u, 46u}, // mxc -> Latn - {0xB2EC0000u, 46u}, // mxm -> Latn - {0x6D790000u, 59u}, // my -> Mymr - {0xAB0C0000u, 46u}, // myk -> Latn + {0xD6CC0000u, 45u}, // mwv -> Latn + {0xDACC0000u, 33u}, // mww -> Hmnp + {0x8AEC0000u, 45u}, // mxc -> Latn + {0xB2EC0000u, 45u}, // mxm -> Latn + {0x6D790000u, 58u}, // my -> Mymr + {0xAB0C0000u, 45u}, // myk -> Latn {0xB30C0000u, 21u}, // mym -> Ethi {0xD70C0000u, 18u}, // myv -> Cyrl - {0xDB0C0000u, 46u}, // myw -> Latn - {0xDF0C0000u, 46u}, // myx -> Latn - {0xE70C0000u, 52u}, // myz -> Mand - {0xAB2C0000u, 46u}, // mzk -> Latn - {0xB32C0000u, 46u}, // mzm -> Latn + {0xDB0C0000u, 45u}, // myw -> Latn + {0xDF0C0000u, 45u}, // myx -> Latn + {0xE70C0000u, 51u}, // myz -> Mand + {0xAB2C0000u, 45u}, // mzk -> Latn + {0xB32C0000u, 45u}, // mzm -> Latn {0xB72C0000u, 2u}, // mzn -> Arab - {0xBF2C0000u, 46u}, // mzp -> Latn - {0xDB2C0000u, 46u}, // mzw -> Latn - {0xE72C0000u, 46u}, // mzz -> Latn - {0x6E610000u, 46u}, // na -> Latn - {0x880D0000u, 46u}, // nac -> Latn - {0x940D0000u, 46u}, // naf -> Latn - {0xA80D0000u, 46u}, // nak -> Latn + {0xBF2C0000u, 45u}, // mzp -> Latn + {0xDB2C0000u, 45u}, // mzw -> Latn + {0xE72C0000u, 45u}, // mzz -> Latn + {0x6E610000u, 45u}, // na -> Latn + {0x880D0000u, 45u}, // nac -> Latn + {0x940D0000u, 45u}, // naf -> Latn + {0xA80D0000u, 45u}, // nak -> Latn {0xB40D0000u, 29u}, // nan -> Hans - {0xBC0D0000u, 46u}, // nap -> Latn - {0xC00D0000u, 46u}, // naq -> Latn - {0xC80D0000u, 46u}, // nas -> Latn - {0x6E620000u, 46u}, // nb -> Latn - {0x804D0000u, 46u}, // nca -> Latn - {0x904D0000u, 46u}, // nce -> Latn - {0x944D0000u, 46u}, // ncf -> Latn - {0x9C4D0000u, 46u}, // nch -> Latn - {0xB84D0000u, 46u}, // nco -> Latn - {0xD04D0000u, 46u}, // ncu -> Latn - {0x6E640000u, 46u}, // nd -> Latn - {0x886D0000u, 46u}, // ndc -> Latn - {0xC86D0000u, 46u}, // nds -> Latn + {0xBC0D0000u, 45u}, // nap -> Latn + {0xC00D0000u, 45u}, // naq -> Latn + {0xC80D0000u, 45u}, // nas -> Latn + {0x6E620000u, 45u}, // nb -> Latn + {0x804D0000u, 45u}, // nca -> Latn + {0x904D0000u, 45u}, // nce -> Latn + {0x944D0000u, 45u}, // ncf -> Latn + {0x9C4D0000u, 45u}, // nch -> Latn + {0xB84D0000u, 45u}, // nco -> Latn + {0xD04D0000u, 45u}, // ncu -> Latn + {0x6E640000u, 45u}, // nd -> Latn + {0x886D0000u, 45u}, // ndc -> Latn + {0xC86D0000u, 45u}, // nds -> Latn {0x6E650000u, 19u}, // ne -> Deva - {0x848D0000u, 46u}, // neb -> Latn + {0x848D0000u, 45u}, // neb -> Latn {0xD88D0000u, 19u}, // new -> Deva - {0xDC8D0000u, 46u}, // nex -> Latn - {0xC4AD0000u, 46u}, // nfr -> Latn - {0x6E670000u, 46u}, // ng -> Latn - {0x80CD0000u, 46u}, // nga -> Latn - {0x84CD0000u, 46u}, // ngb -> Latn - {0xACCD0000u, 46u}, // ngl -> Latn - {0x84ED0000u, 46u}, // nhb -> Latn - {0x90ED0000u, 46u}, // nhe -> Latn - {0xD8ED0000u, 46u}, // nhw -> Latn - {0x950D0000u, 46u}, // nif -> Latn - {0xA10D0000u, 46u}, // nii -> Latn - {0xA50D0000u, 46u}, // nij -> Latn - {0xB50D0000u, 46u}, // nin -> Latn - {0xD10D0000u, 46u}, // niu -> Latn - {0xE10D0000u, 46u}, // niy -> Latn - {0xE50D0000u, 46u}, // niz -> Latn - {0xB92D0000u, 46u}, // njo -> Latn - {0x994D0000u, 46u}, // nkg -> Latn - {0xB94D0000u, 46u}, // nko -> Latn - {0x6E6C0000u, 46u}, // nl -> Latn - {0x998D0000u, 46u}, // nmg -> Latn - {0xE58D0000u, 46u}, // nmz -> Latn - {0x6E6E0000u, 46u}, // nn -> Latn - {0x95AD0000u, 46u}, // nnf -> Latn - {0x9DAD0000u, 46u}, // nnh -> Latn - {0xA9AD0000u, 46u}, // nnk -> Latn - {0xB1AD0000u, 46u}, // nnm -> Latn - {0xBDAD0000u, 95u}, // nnp -> Wcho - {0x6E6F0000u, 46u}, // no -> Latn - {0x8DCD0000u, 44u}, // nod -> Lana + {0xDC8D0000u, 45u}, // nex -> Latn + {0xC4AD0000u, 45u}, // nfr -> Latn + {0x6E670000u, 45u}, // ng -> Latn + {0x80CD0000u, 45u}, // nga -> Latn + {0x84CD0000u, 45u}, // ngb -> Latn + {0xACCD0000u, 45u}, // ngl -> Latn + {0x84ED0000u, 45u}, // nhb -> Latn + {0x90ED0000u, 45u}, // nhe -> Latn + {0xD8ED0000u, 45u}, // nhw -> Latn + {0x950D0000u, 45u}, // nif -> Latn + {0xA10D0000u, 45u}, // nii -> Latn + {0xA50D0000u, 45u}, // nij -> Latn + {0xB50D0000u, 45u}, // nin -> Latn + {0xD10D0000u, 45u}, // niu -> Latn + {0xE10D0000u, 45u}, // niy -> Latn + {0xE50D0000u, 45u}, // niz -> Latn + {0xB92D0000u, 45u}, // njo -> Latn + {0x994D0000u, 45u}, // nkg -> Latn + {0xB94D0000u, 45u}, // nko -> Latn + {0x6E6C0000u, 45u}, // nl -> Latn + {0x998D0000u, 45u}, // nmg -> Latn + {0xE58D0000u, 45u}, // nmz -> Latn + {0x6E6E0000u, 45u}, // nn -> Latn + {0x95AD0000u, 45u}, // nnf -> Latn + {0x9DAD0000u, 45u}, // nnh -> Latn + {0xA9AD0000u, 45u}, // nnk -> Latn + {0xB1AD0000u, 45u}, // nnm -> Latn + {0xBDAD0000u, 98u}, // nnp -> Wcho + {0x6E6F0000u, 45u}, // no -> Latn + {0x8DCD0000u, 43u}, // nod -> Lana {0x91CD0000u, 19u}, // noe -> Deva - {0xB5CD0000u, 73u}, // non -> Runr - {0xBDCD0000u, 46u}, // nop -> Latn - {0xD1CD0000u, 46u}, // nou -> Latn - {0xBA0D0000u, 61u}, // nqo -> Nkoo - {0x6E720000u, 46u}, // nr -> Latn - {0x862D0000u, 46u}, // nrb -> Latn + {0xB5CD0000u, 74u}, // non -> Runr + {0xBDCD0000u, 45u}, // nop -> Latn + {0xD1CD0000u, 45u}, // nou -> Latn + {0xBA0D0000u, 60u}, // nqo -> Nkoo + {0x6E720000u, 45u}, // nr -> Latn + {0x862D0000u, 45u}, // nrb -> Latn {0xAA4D0000u, 11u}, // nsk -> Cans - {0xB64D0000u, 46u}, // nsn -> Latn - {0xBA4D0000u, 46u}, // nso -> Latn - {0xCA4D0000u, 46u}, // nss -> Latn - {0xB26D0000u, 46u}, // ntm -> Latn - {0xC66D0000u, 46u}, // ntr -> Latn - {0xA28D0000u, 46u}, // nui -> Latn - {0xBE8D0000u, 46u}, // nup -> Latn - {0xCA8D0000u, 46u}, // nus -> Latn - {0xD68D0000u, 46u}, // nuv -> Latn - {0xDE8D0000u, 46u}, // nux -> Latn - {0x6E760000u, 46u}, // nv -> Latn - {0x86CD0000u, 46u}, // nwb -> Latn - {0xC2ED0000u, 46u}, // nxq -> Latn - {0xC6ED0000u, 46u}, // nxr -> Latn - {0x6E790000u, 46u}, // ny -> Latn - {0xB30D0000u, 46u}, // nym -> Latn - {0xB70D0000u, 46u}, // nyn -> Latn - {0xA32D0000u, 46u}, // nzi -> Latn - {0x6F630000u, 46u}, // oc -> Latn - {0x88CE0000u, 46u}, // ogc -> Latn - {0xC54E0000u, 46u}, // okr -> Latn - {0xD54E0000u, 46u}, // okv -> Latn - {0x6F6D0000u, 46u}, // om -> Latn - {0x99AE0000u, 46u}, // ong -> Latn - {0xB5AE0000u, 46u}, // onn -> Latn - {0xC9AE0000u, 46u}, // ons -> Latn - {0xB1EE0000u, 46u}, // opm -> Latn - {0x6F720000u, 66u}, // or -> Orya - {0xBA2E0000u, 46u}, // oro -> Latn + {0xB64D0000u, 45u}, // nsn -> Latn + {0xBA4D0000u, 45u}, // nso -> Latn + {0xCA4D0000u, 45u}, // nss -> Latn + {0xCE4D0000u, 94u}, // nst -> Tnsa + {0xB26D0000u, 45u}, // ntm -> Latn + {0xC66D0000u, 45u}, // ntr -> Latn + {0xA28D0000u, 45u}, // nui -> Latn + {0xBE8D0000u, 45u}, // nup -> Latn + {0xCA8D0000u, 45u}, // nus -> Latn + {0xD68D0000u, 45u}, // nuv -> Latn + {0xDE8D0000u, 45u}, // nux -> Latn + {0x6E760000u, 45u}, // nv -> Latn + {0x86CD0000u, 45u}, // nwb -> Latn + {0xC2ED0000u, 45u}, // nxq -> Latn + {0xC6ED0000u, 45u}, // nxr -> Latn + {0x6E790000u, 45u}, // ny -> Latn + {0xB30D0000u, 45u}, // nym -> Latn + {0xB70D0000u, 45u}, // nyn -> Latn + {0xA32D0000u, 45u}, // nzi -> Latn + {0x6F630000u, 45u}, // oc -> Latn + {0x88CE0000u, 45u}, // ogc -> Latn + {0xC54E0000u, 45u}, // okr -> Latn + {0xD54E0000u, 45u}, // okv -> Latn + {0x6F6D0000u, 45u}, // om -> Latn + {0x99AE0000u, 45u}, // ong -> Latn + {0xB5AE0000u, 45u}, // onn -> Latn + {0xC9AE0000u, 45u}, // ons -> Latn + {0xB1EE0000u, 45u}, // opm -> Latn + {0x6F720000u, 65u}, // or -> Orya + {0xBA2E0000u, 45u}, // oro -> Latn {0xD22E0000u, 2u}, // oru -> Arab {0x6F730000u, 18u}, // os -> Cyrl - {0x824E0000u, 67u}, // osa -> Osge + {0x824E0000u, 66u}, // osa -> Osge {0x826E0000u, 2u}, // ota -> Arab - {0xAA6E0000u, 65u}, // otk -> Orkh - {0xB32E0000u, 46u}, // ozm -> Latn + {0xAA6E0000u, 64u}, // otk -> Orkh + {0xA28E0000u, 67u}, // oui -> Ougr + {0xB32E0000u, 45u}, // ozm -> Latn {0x70610000u, 28u}, // pa -> Guru {0x7061504Bu, 2u}, // pa-PK -> Arab - {0x980F0000u, 46u}, // pag -> Latn + {0x980F0000u, 45u}, // pag -> Latn {0xAC0F0000u, 69u}, // pal -> Phli - {0xB00F0000u, 46u}, // pam -> Latn - {0xBC0F0000u, 46u}, // pap -> Latn - {0xD00F0000u, 46u}, // pau -> Latn - {0xA02F0000u, 46u}, // pbi -> Latn - {0x8C4F0000u, 46u}, // pcd -> Latn - {0xB04F0000u, 46u}, // pcm -> Latn - {0x886F0000u, 46u}, // pdc -> Latn - {0xCC6F0000u, 46u}, // pdt -> Latn - {0x8C8F0000u, 46u}, // ped -> Latn - {0xB88F0000u, 96u}, // peo -> Xpeo - {0xDC8F0000u, 46u}, // pex -> Latn - {0xACAF0000u, 46u}, // pfl -> Latn + {0xB00F0000u, 45u}, // pam -> Latn + {0xBC0F0000u, 45u}, // pap -> Latn + {0xD00F0000u, 45u}, // pau -> Latn + {0xA02F0000u, 45u}, // pbi -> Latn + {0x8C4F0000u, 45u}, // pcd -> Latn + {0xB04F0000u, 45u}, // pcm -> Latn + {0x886F0000u, 45u}, // pdc -> Latn + {0xCC6F0000u, 45u}, // pdt -> Latn + {0x8C8F0000u, 45u}, // ped -> Latn + {0xB88F0000u, 99u}, // peo -> Xpeo + {0xDC8F0000u, 45u}, // pex -> Latn + {0xACAF0000u, 45u}, // pfl -> Latn {0xACEF0000u, 2u}, // phl -> Arab {0xB4EF0000u, 70u}, // phn -> Phnx - {0xAD0F0000u, 46u}, // pil -> Latn - {0xBD0F0000u, 46u}, // pip -> Latn + {0xAD0F0000u, 45u}, // pil -> Latn + {0xBD0F0000u, 45u}, // pip -> Latn {0x814F0000u, 9u}, // pka -> Brah - {0xB94F0000u, 46u}, // pko -> Latn - {0x706C0000u, 46u}, // pl -> Latn - {0x816F0000u, 46u}, // pla -> Latn - {0xC98F0000u, 46u}, // pms -> Latn - {0x99AF0000u, 46u}, // png -> Latn - {0xB5AF0000u, 46u}, // pnn -> Latn + {0xB94F0000u, 45u}, // pko -> Latn + {0x706C0000u, 45u}, // pl -> Latn + {0x816F0000u, 45u}, // pla -> Latn + {0xC98F0000u, 45u}, // pms -> Latn + {0x99AF0000u, 45u}, // png -> Latn + {0xB5AF0000u, 45u}, // pnn -> Latn {0xCDAF0000u, 26u}, // pnt -> Grek - {0xB5CF0000u, 46u}, // pon -> Latn + {0xB5CF0000u, 45u}, // pon -> Latn {0x81EF0000u, 19u}, // ppa -> Deva - {0xB9EF0000u, 46u}, // ppo -> Latn - {0x822F0000u, 39u}, // pra -> Khar + {0xB9EF0000u, 45u}, // ppo -> Latn + {0x822F0000u, 38u}, // pra -> Khar {0x8E2F0000u, 2u}, // prd -> Arab - {0x9A2F0000u, 46u}, // prg -> Latn + {0x9A2F0000u, 45u}, // prg -> Latn {0x70730000u, 2u}, // ps -> Arab - {0xCA4F0000u, 46u}, // pss -> Latn - {0x70740000u, 46u}, // pt -> Latn - {0xBE6F0000u, 46u}, // ptp -> Latn - {0xD28F0000u, 46u}, // puu -> Latn - {0x82CF0000u, 46u}, // pwa -> Latn - {0x71750000u, 46u}, // qu -> Latn - {0x8A900000u, 46u}, // quc -> Latn - {0x9A900000u, 46u}, // qug -> Latn - {0xA0110000u, 46u}, // rai -> Latn + {0xCA4F0000u, 45u}, // pss -> Latn + {0x70740000u, 45u}, // pt -> Latn + {0xBE6F0000u, 45u}, // ptp -> Latn + {0xD28F0000u, 45u}, // puu -> Latn + {0x82CF0000u, 45u}, // pwa -> Latn + {0x71750000u, 45u}, // qu -> Latn + {0x8A900000u, 45u}, // quc -> Latn + {0x9A900000u, 45u}, // qug -> Latn + {0xA0110000u, 45u}, // rai -> Latn {0xA4110000u, 19u}, // raj -> Deva - {0xB8110000u, 46u}, // rao -> Latn - {0x94510000u, 46u}, // rcf -> Latn - {0xA4910000u, 46u}, // rej -> Latn - {0xAC910000u, 46u}, // rel -> Latn - {0xC8910000u, 46u}, // res -> Latn - {0xB4D10000u, 46u}, // rgn -> Latn - {0x98F10000u, 2u}, // rhg -> Arab - {0x81110000u, 46u}, // ria -> Latn - {0x95110000u, 89u}, // rif -> Tfng - {0x95114E4Cu, 46u}, // rif-NL -> Latn + {0xB8110000u, 45u}, // rao -> Latn + {0x94510000u, 45u}, // rcf -> Latn + {0xA4910000u, 45u}, // rej -> Latn + {0xAC910000u, 45u}, // rel -> Latn + {0xC8910000u, 45u}, // res -> Latn + {0xB4D10000u, 45u}, // rgn -> Latn + {0x98F10000u, 73u}, // rhg -> Rohg + {0x81110000u, 45u}, // ria -> Latn + {0x95110000u, 90u}, // rif -> Tfng + {0x95114E4Cu, 45u}, // rif-NL -> Latn {0xC9310000u, 19u}, // rjs -> Deva {0xCD510000u, 8u}, // rkt -> Beng - {0x726D0000u, 46u}, // rm -> Latn - {0x95910000u, 46u}, // rmf -> Latn - {0xB9910000u, 46u}, // rmo -> Latn + {0x726D0000u, 45u}, // rm -> Latn + {0x95910000u, 45u}, // rmf -> Latn + {0xB9910000u, 45u}, // rmo -> Latn {0xCD910000u, 2u}, // rmt -> Arab - {0xD1910000u, 46u}, // rmu -> Latn - {0x726E0000u, 46u}, // rn -> Latn - {0x81B10000u, 46u}, // rna -> Latn - {0x99B10000u, 46u}, // rng -> Latn - {0x726F0000u, 46u}, // ro -> Latn - {0x85D10000u, 46u}, // rob -> Latn - {0x95D10000u, 46u}, // rof -> Latn - {0xB9D10000u, 46u}, // roo -> Latn - {0xBA310000u, 46u}, // rro -> Latn - {0xB2710000u, 46u}, // rtm -> Latn + {0xD1910000u, 45u}, // rmu -> Latn + {0x726E0000u, 45u}, // rn -> Latn + {0x81B10000u, 45u}, // rna -> Latn + {0x99B10000u, 45u}, // rng -> Latn + {0x726F0000u, 45u}, // ro -> Latn + {0x85D10000u, 45u}, // rob -> Latn + {0x95D10000u, 45u}, // rof -> Latn + {0xB9D10000u, 45u}, // roo -> Latn + {0xBA310000u, 45u}, // rro -> Latn + {0xB2710000u, 45u}, // rtm -> Latn {0x72750000u, 18u}, // ru -> Cyrl {0x92910000u, 18u}, // rue -> Cyrl - {0x9A910000u, 46u}, // rug -> Latn - {0x72770000u, 46u}, // rw -> Latn - {0xAAD10000u, 46u}, // rwk -> Latn - {0xBAD10000u, 46u}, // rwo -> Latn - {0xD3110000u, 38u}, // ryu -> Kana + {0x9A910000u, 45u}, // rug -> Latn + {0x72770000u, 45u}, // rw -> Latn + {0xAAD10000u, 45u}, // rwk -> Latn + {0xBAD10000u, 45u}, // rwo -> Latn + {0xD3110000u, 37u}, // ryu -> Kana {0x73610000u, 19u}, // sa -> Deva - {0x94120000u, 46u}, // saf -> Latn + {0x94120000u, 45u}, // saf -> Latn {0x9C120000u, 18u}, // sah -> Cyrl - {0xC0120000u, 46u}, // saq -> Latn - {0xC8120000u, 46u}, // sas -> Latn - {0xCC120000u, 64u}, // sat -> Olck - {0xD4120000u, 46u}, // sav -> Latn - {0xE4120000u, 76u}, // saz -> Saur - {0x80320000u, 46u}, // sba -> Latn - {0x90320000u, 46u}, // sbe -> Latn - {0xBC320000u, 46u}, // sbp -> Latn - {0x73630000u, 46u}, // sc -> Latn + {0xC0120000u, 45u}, // saq -> Latn + {0xC8120000u, 45u}, // sas -> Latn + {0xCC120000u, 63u}, // sat -> Olck + {0xD4120000u, 45u}, // sav -> Latn + {0xE4120000u, 77u}, // saz -> Saur + {0x80320000u, 45u}, // sba -> Latn + {0x90320000u, 45u}, // sbe -> Latn + {0xBC320000u, 45u}, // sbp -> Latn + {0x73630000u, 45u}, // sc -> Latn {0xA8520000u, 19u}, // sck -> Deva {0xAC520000u, 2u}, // scl -> Arab - {0xB4520000u, 46u}, // scn -> Latn - {0xB8520000u, 46u}, // sco -> Latn - {0xC8520000u, 46u}, // scs -> Latn + {0xB4520000u, 45u}, // scn -> Latn + {0xB8520000u, 45u}, // sco -> Latn + {0xC8520000u, 45u}, // scs -> Latn {0x73640000u, 2u}, // sd -> Arab - {0x88720000u, 46u}, // sdc -> Latn + {0x88720000u, 45u}, // sdc -> Latn {0x9C720000u, 2u}, // sdh -> Arab - {0x73650000u, 46u}, // se -> Latn - {0x94920000u, 46u}, // sef -> Latn - {0x9C920000u, 46u}, // seh -> Latn - {0xA0920000u, 46u}, // sei -> Latn - {0xC8920000u, 46u}, // ses -> Latn - {0x73670000u, 46u}, // sg -> Latn - {0x80D20000u, 63u}, // sga -> Ogam - {0xC8D20000u, 46u}, // sgs -> Latn + {0x73650000u, 45u}, // se -> Latn + {0x94920000u, 45u}, // sef -> Latn + {0x9C920000u, 45u}, // seh -> Latn + {0xA0920000u, 45u}, // sei -> Latn + {0xC8920000u, 45u}, // ses -> Latn + {0x73670000u, 45u}, // sg -> Latn + {0x80D20000u, 62u}, // sga -> Ogam + {0xC8D20000u, 45u}, // sgs -> Latn {0xD8D20000u, 21u}, // sgw -> Ethi - {0xE4D20000u, 46u}, // sgz -> Latn - {0x73680000u, 46u}, // sh -> Latn - {0xA0F20000u, 89u}, // shi -> Tfng - {0xA8F20000u, 46u}, // shk -> Latn - {0xB4F20000u, 59u}, // shn -> Mymr + {0xE4D20000u, 45u}, // sgz -> Latn + {0x73680000u, 45u}, // sh -> Latn + {0xA0F20000u, 90u}, // shi -> Tfng + {0xA8F20000u, 45u}, // shk -> Latn + {0xB4F20000u, 58u}, // shn -> Mymr {0xD0F20000u, 2u}, // shu -> Arab - {0x73690000u, 78u}, // si -> Sinh - {0x8D120000u, 46u}, // sid -> Latn - {0x99120000u, 46u}, // sig -> Latn - {0xAD120000u, 46u}, // sil -> Latn - {0xB1120000u, 46u}, // sim -> Latn - {0xC5320000u, 46u}, // sjr -> Latn - {0x736B0000u, 46u}, // sk -> Latn - {0x89520000u, 46u}, // skc -> Latn + {0x73690000u, 79u}, // si -> Sinh + {0x8D120000u, 45u}, // sid -> Latn + {0x99120000u, 45u}, // sig -> Latn + {0xAD120000u, 45u}, // sil -> Latn + {0xB1120000u, 45u}, // sim -> Latn + {0xC5320000u, 45u}, // sjr -> Latn + {0x736B0000u, 45u}, // sk -> Latn + {0x89520000u, 45u}, // skc -> Latn {0xC5520000u, 2u}, // skr -> Arab - {0xC9520000u, 46u}, // sks -> Latn - {0x736C0000u, 46u}, // sl -> Latn - {0x8D720000u, 46u}, // sld -> Latn - {0xA1720000u, 46u}, // sli -> Latn - {0xAD720000u, 46u}, // sll -> Latn - {0xE1720000u, 46u}, // sly -> Latn - {0x736D0000u, 46u}, // sm -> Latn - {0x81920000u, 46u}, // sma -> Latn - {0xA5920000u, 46u}, // smj -> Latn - {0xB5920000u, 46u}, // smn -> Latn - {0xBD920000u, 74u}, // smp -> Samr - {0xC1920000u, 46u}, // smq -> Latn - {0xC9920000u, 46u}, // sms -> Latn - {0x736E0000u, 46u}, // sn -> Latn - {0x89B20000u, 46u}, // snc -> Latn - {0xA9B20000u, 46u}, // snk -> Latn - {0xBDB20000u, 46u}, // snp -> Latn - {0xDDB20000u, 46u}, // snx -> Latn - {0xE1B20000u, 46u}, // sny -> Latn - {0x736F0000u, 46u}, // so -> Latn - {0x99D20000u, 79u}, // sog -> Sogd - {0xA9D20000u, 46u}, // sok -> Latn - {0xC1D20000u, 46u}, // soq -> Latn - {0xD1D20000u, 91u}, // sou -> Thai - {0xE1D20000u, 46u}, // soy -> Latn - {0x8DF20000u, 46u}, // spd -> Latn - {0xADF20000u, 46u}, // spl -> Latn - {0xC9F20000u, 46u}, // sps -> Latn - {0x73710000u, 46u}, // sq -> Latn + {0xC9520000u, 45u}, // sks -> Latn + {0x736C0000u, 45u}, // sl -> Latn + {0x8D720000u, 45u}, // sld -> Latn + {0xA1720000u, 45u}, // sli -> Latn + {0xAD720000u, 45u}, // sll -> Latn + {0xE1720000u, 45u}, // sly -> Latn + {0x736D0000u, 45u}, // sm -> Latn + {0x81920000u, 45u}, // sma -> Latn + {0xA5920000u, 45u}, // smj -> Latn + {0xB5920000u, 45u}, // smn -> Latn + {0xBD920000u, 75u}, // smp -> Samr + {0xC1920000u, 45u}, // smq -> Latn + {0xC9920000u, 45u}, // sms -> Latn + {0x736E0000u, 45u}, // sn -> Latn + {0x89B20000u, 45u}, // snc -> Latn + {0xA9B20000u, 45u}, // snk -> Latn + {0xBDB20000u, 45u}, // snp -> Latn + {0xDDB20000u, 45u}, // snx -> Latn + {0xE1B20000u, 45u}, // sny -> Latn + {0x736F0000u, 45u}, // so -> Latn + {0x99D20000u, 80u}, // sog -> Sogd + {0xA9D20000u, 45u}, // sok -> Latn + {0xC1D20000u, 45u}, // soq -> Latn + {0xD1D20000u, 92u}, // sou -> Thai + {0xE1D20000u, 45u}, // soy -> Latn + {0x8DF20000u, 45u}, // spd -> Latn + {0xADF20000u, 45u}, // spl -> Latn + {0xC9F20000u, 45u}, // sps -> Latn + {0x73710000u, 45u}, // sq -> Latn {0x73720000u, 18u}, // sr -> Cyrl - {0x73724D45u, 46u}, // sr-ME -> Latn - {0x7372524Fu, 46u}, // sr-RO -> Latn - {0x73725255u, 46u}, // sr-RU -> Latn - {0x73725452u, 46u}, // sr-TR -> Latn - {0x86320000u, 80u}, // srb -> Sora - {0xB6320000u, 46u}, // srn -> Latn - {0xC6320000u, 46u}, // srr -> Latn + {0x73724D45u, 45u}, // sr-ME -> Latn + {0x7372524Fu, 45u}, // sr-RO -> Latn + {0x73725255u, 45u}, // sr-RU -> Latn + {0x73725452u, 45u}, // sr-TR -> Latn + {0x86320000u, 81u}, // srb -> Sora + {0xB6320000u, 45u}, // srn -> Latn + {0xC6320000u, 45u}, // srr -> Latn {0xDE320000u, 19u}, // srx -> Deva - {0x73730000u, 46u}, // ss -> Latn - {0x8E520000u, 46u}, // ssd -> Latn - {0x9A520000u, 46u}, // ssg -> Latn - {0xE2520000u, 46u}, // ssy -> Latn - {0x73740000u, 46u}, // st -> Latn - {0xAA720000u, 46u}, // stk -> Latn - {0xC2720000u, 46u}, // stq -> Latn - {0x73750000u, 46u}, // su -> Latn - {0x82920000u, 46u}, // sua -> Latn - {0x92920000u, 46u}, // sue -> Latn - {0xAA920000u, 46u}, // suk -> Latn - {0xC6920000u, 46u}, // sur -> Latn - {0xCA920000u, 46u}, // sus -> Latn - {0x73760000u, 46u}, // sv -> Latn - {0x73770000u, 46u}, // sw -> Latn + {0x73730000u, 45u}, // ss -> Latn + {0x8E520000u, 45u}, // ssd -> Latn + {0x9A520000u, 45u}, // ssg -> Latn + {0xE2520000u, 45u}, // ssy -> Latn + {0x73740000u, 45u}, // st -> Latn + {0xAA720000u, 45u}, // stk -> Latn + {0xC2720000u, 45u}, // stq -> Latn + {0x73750000u, 45u}, // su -> Latn + {0x82920000u, 45u}, // sua -> Latn + {0x92920000u, 45u}, // sue -> Latn + {0xAA920000u, 45u}, // suk -> Latn + {0xC6920000u, 45u}, // sur -> Latn + {0xCA920000u, 45u}, // sus -> Latn + {0x73760000u, 45u}, // sv -> Latn + {0x73770000u, 45u}, // sw -> Latn {0x86D20000u, 2u}, // swb -> Arab - {0x8AD20000u, 46u}, // swc -> Latn - {0x9AD20000u, 46u}, // swg -> Latn - {0xBED20000u, 46u}, // swp -> Latn + {0x8AD20000u, 45u}, // swc -> Latn + {0x9AD20000u, 45u}, // swg -> Latn + {0xBED20000u, 45u}, // swp -> Latn {0xD6D20000u, 19u}, // swv -> Deva - {0xB6F20000u, 46u}, // sxn -> Latn - {0xDAF20000u, 46u}, // sxw -> Latn + {0xB6F20000u, 45u}, // sxn -> Latn + {0xDAF20000u, 45u}, // sxw -> Latn {0xAF120000u, 8u}, // syl -> Beng - {0xC7120000u, 82u}, // syr -> Syrc - {0xAF320000u, 46u}, // szl -> Latn - {0x74610000u, 85u}, // ta -> Taml + {0xC7120000u, 83u}, // syr -> Syrc + {0xAF320000u, 45u}, // szl -> Latn + {0x74610000u, 86u}, // ta -> Taml {0xA4130000u, 19u}, // taj -> Deva - {0xAC130000u, 46u}, // tal -> Latn - {0xB4130000u, 46u}, // tan -> Latn - {0xC0130000u, 46u}, // taq -> Latn - {0x88330000u, 46u}, // tbc -> Latn - {0x8C330000u, 46u}, // tbd -> Latn - {0x94330000u, 46u}, // tbf -> Latn - {0x98330000u, 46u}, // tbg -> Latn - {0xB8330000u, 46u}, // tbo -> Latn - {0xD8330000u, 46u}, // tbw -> Latn - {0xE4330000u, 46u}, // tbz -> Latn - {0xA0530000u, 46u}, // tci -> Latn - {0xE0530000u, 42u}, // tcy -> Knda - {0x8C730000u, 83u}, // tdd -> Tale + {0xAC130000u, 45u}, // tal -> Latn + {0xB4130000u, 45u}, // tan -> Latn + {0xC0130000u, 45u}, // taq -> Latn + {0x88330000u, 45u}, // tbc -> Latn + {0x8C330000u, 45u}, // tbd -> Latn + {0x94330000u, 45u}, // tbf -> Latn + {0x98330000u, 45u}, // tbg -> Latn + {0xB8330000u, 45u}, // tbo -> Latn + {0xD8330000u, 45u}, // tbw -> Latn + {0xE4330000u, 45u}, // tbz -> Latn + {0xA0530000u, 45u}, // tci -> Latn + {0xE0530000u, 41u}, // tcy -> Knda + {0x8C730000u, 84u}, // tdd -> Tale {0x98730000u, 19u}, // tdg -> Deva {0x9C730000u, 19u}, // tdh -> Deva - {0xD0730000u, 46u}, // tdu -> Latn - {0x74650000u, 88u}, // te -> Telu - {0x8C930000u, 46u}, // ted -> Latn - {0xB0930000u, 46u}, // tem -> Latn - {0xB8930000u, 46u}, // teo -> Latn - {0xCC930000u, 46u}, // tet -> Latn - {0xA0B30000u, 46u}, // tfi -> Latn + {0xD0730000u, 45u}, // tdu -> Latn + {0x74650000u, 89u}, // te -> Telu + {0x8C930000u, 45u}, // ted -> Latn + {0xB0930000u, 45u}, // tem -> Latn + {0xB8930000u, 45u}, // teo -> Latn + {0xCC930000u, 45u}, // tet -> Latn + {0xA0B30000u, 45u}, // tfi -> Latn {0x74670000u, 18u}, // tg -> Cyrl {0x7467504Bu, 2u}, // tg-PK -> Arab - {0x88D30000u, 46u}, // tgc -> Latn - {0xB8D30000u, 46u}, // tgo -> Latn - {0xD0D30000u, 46u}, // tgu -> Latn - {0x74680000u, 91u}, // th -> Thai + {0x88D30000u, 45u}, // tgc -> Latn + {0xB8D30000u, 45u}, // tgo -> Latn + {0xD0D30000u, 45u}, // tgu -> Latn + {0x74680000u, 92u}, // th -> Thai {0xACF30000u, 19u}, // thl -> Deva {0xC0F30000u, 19u}, // thq -> Deva {0xC4F30000u, 19u}, // thr -> Deva {0x74690000u, 21u}, // ti -> Ethi - {0x95130000u, 46u}, // tif -> Latn + {0x95130000u, 45u}, // tif -> Latn {0x99130000u, 21u}, // tig -> Ethi - {0xA9130000u, 46u}, // tik -> Latn - {0xB1130000u, 46u}, // tim -> Latn - {0xB9130000u, 46u}, // tio -> Latn - {0xD5130000u, 46u}, // tiv -> Latn - {0x746B0000u, 46u}, // tk -> Latn - {0xAD530000u, 46u}, // tkl -> Latn - {0xC5530000u, 46u}, // tkr -> Latn + {0xA9130000u, 45u}, // tik -> Latn + {0xB1130000u, 45u}, // tim -> Latn + {0xB9130000u, 45u}, // tio -> Latn + {0xD5130000u, 45u}, // tiv -> Latn + {0x746B0000u, 45u}, // tk -> Latn + {0xAD530000u, 45u}, // tkl -> Latn + {0xC5530000u, 45u}, // tkr -> Latn {0xCD530000u, 19u}, // tkt -> Deva - {0x746C0000u, 46u}, // tl -> Latn - {0x95730000u, 46u}, // tlf -> Latn - {0xDD730000u, 46u}, // tlx -> Latn - {0xE1730000u, 46u}, // tly -> Latn - {0x9D930000u, 46u}, // tmh -> Latn - {0xE1930000u, 46u}, // tmy -> Latn - {0x746E0000u, 46u}, // tn -> Latn - {0x9DB30000u, 46u}, // tnh -> Latn - {0x746F0000u, 46u}, // to -> Latn - {0x95D30000u, 46u}, // tof -> Latn - {0x99D30000u, 46u}, // tog -> Latn - {0xC1D30000u, 46u}, // toq -> Latn - {0xA1F30000u, 46u}, // tpi -> Latn - {0xB1F30000u, 46u}, // tpm -> Latn - {0xE5F30000u, 46u}, // tpz -> Latn - {0xBA130000u, 46u}, // tqo -> Latn - {0x74720000u, 46u}, // tr -> Latn - {0xD2330000u, 46u}, // tru -> Latn - {0xD6330000u, 46u}, // trv -> Latn + {0x746C0000u, 45u}, // tl -> Latn + {0x95730000u, 45u}, // tlf -> Latn + {0xDD730000u, 45u}, // tlx -> Latn + {0xE1730000u, 45u}, // tly -> Latn + {0x9D930000u, 45u}, // tmh -> Latn + {0xE1930000u, 45u}, // tmy -> Latn + {0x746E0000u, 45u}, // tn -> Latn + {0x9DB30000u, 45u}, // tnh -> Latn + {0x746F0000u, 45u}, // to -> Latn + {0x95D30000u, 45u}, // tof -> Latn + {0x99D30000u, 45u}, // tog -> Latn + {0xC1D30000u, 45u}, // toq -> Latn + {0xA1F30000u, 45u}, // tpi -> Latn + {0xB1F30000u, 45u}, // tpm -> Latn + {0xE5F30000u, 45u}, // tpz -> Latn + {0xBA130000u, 45u}, // tqo -> Latn + {0x74720000u, 45u}, // tr -> Latn + {0xD2330000u, 45u}, // tru -> Latn + {0xD6330000u, 45u}, // trv -> Latn {0xDA330000u, 2u}, // trw -> Arab - {0x74730000u, 46u}, // ts -> Latn + {0x74730000u, 45u}, // ts -> Latn {0x8E530000u, 26u}, // tsd -> Grek {0x96530000u, 19u}, // tsf -> Deva - {0x9A530000u, 46u}, // tsg -> Latn - {0xA6530000u, 92u}, // tsj -> Tibt - {0xDA530000u, 46u}, // tsw -> Latn + {0x9A530000u, 45u}, // tsg -> Latn + {0xA6530000u, 93u}, // tsj -> Tibt + {0xDA530000u, 45u}, // tsw -> Latn {0x74740000u, 18u}, // tt -> Cyrl - {0x8E730000u, 46u}, // ttd -> Latn - {0x92730000u, 46u}, // tte -> Latn - {0xA6730000u, 46u}, // ttj -> Latn - {0xC6730000u, 46u}, // ttr -> Latn - {0xCA730000u, 91u}, // tts -> Thai - {0xCE730000u, 46u}, // ttt -> Latn - {0x9E930000u, 46u}, // tuh -> Latn - {0xAE930000u, 46u}, // tul -> Latn - {0xB2930000u, 46u}, // tum -> Latn - {0xC2930000u, 46u}, // tuq -> Latn - {0x8EB30000u, 46u}, // tvd -> Latn - {0xAEB30000u, 46u}, // tvl -> Latn - {0xD2B30000u, 46u}, // tvu -> Latn - {0x9ED30000u, 46u}, // twh -> Latn - {0xC2D30000u, 46u}, // twq -> Latn - {0x9AF30000u, 86u}, // txg -> Tang - {0x74790000u, 46u}, // ty -> Latn - {0x83130000u, 46u}, // tya -> Latn + {0x8E730000u, 45u}, // ttd -> Latn + {0x92730000u, 45u}, // tte -> Latn + {0xA6730000u, 45u}, // ttj -> Latn + {0xC6730000u, 45u}, // ttr -> Latn + {0xCA730000u, 92u}, // tts -> Thai + {0xCE730000u, 45u}, // ttt -> Latn + {0x9E930000u, 45u}, // tuh -> Latn + {0xAE930000u, 45u}, // tul -> Latn + {0xB2930000u, 45u}, // tum -> Latn + {0xC2930000u, 45u}, // tuq -> Latn + {0x8EB30000u, 45u}, // tvd -> Latn + {0xAEB30000u, 45u}, // tvl -> Latn + {0xD2B30000u, 45u}, // tvu -> Latn + {0x9ED30000u, 45u}, // twh -> Latn + {0xC2D30000u, 45u}, // twq -> Latn + {0x9AF30000u, 87u}, // txg -> Tang + {0xBAF30000u, 95u}, // txo -> Toto + {0x74790000u, 45u}, // ty -> Latn + {0x83130000u, 45u}, // tya -> Latn {0xD7130000u, 18u}, // tyv -> Cyrl - {0xB3330000u, 46u}, // tzm -> Latn - {0xD0340000u, 46u}, // ubu -> Latn + {0xB3330000u, 45u}, // tzm -> Latn + {0xD0340000u, 45u}, // ubu -> Latn {0xA0740000u, 0u}, // udi -> Aghb {0xB0740000u, 18u}, // udm -> Cyrl {0x75670000u, 2u}, // ug -> Arab {0x75674B5Au, 18u}, // ug-KZ -> Cyrl {0x75674D4Eu, 18u}, // ug-MN -> Cyrl - {0x80D40000u, 93u}, // uga -> Ugar + {0x80D40000u, 96u}, // uga -> Ugar {0x756B0000u, 18u}, // uk -> Cyrl - {0xA1740000u, 46u}, // uli -> Latn - {0x85940000u, 46u}, // umb -> Latn + {0xA1740000u, 45u}, // uli -> Latn + {0x85940000u, 45u}, // umb -> Latn {0xC5B40000u, 8u}, // unr -> Beng {0xC5B44E50u, 19u}, // unr-NP -> Deva {0xDDB40000u, 8u}, // unx -> Beng - {0xA9D40000u, 46u}, // uok -> Latn + {0xA9D40000u, 45u}, // uok -> Latn {0x75720000u, 2u}, // ur -> Arab - {0xA2340000u, 46u}, // uri -> Latn - {0xCE340000u, 46u}, // urt -> Latn - {0xDA340000u, 46u}, // urw -> Latn - {0x82540000u, 46u}, // usa -> Latn - {0x9E740000u, 46u}, // uth -> Latn - {0xC6740000u, 46u}, // utr -> Latn - {0x9EB40000u, 46u}, // uvh -> Latn - {0xAEB40000u, 46u}, // uvl -> Latn - {0x757A0000u, 46u}, // uz -> Latn + {0xA2340000u, 45u}, // uri -> Latn + {0xCE340000u, 45u}, // urt -> Latn + {0xDA340000u, 45u}, // urw -> Latn + {0x82540000u, 45u}, // usa -> Latn + {0x9E740000u, 45u}, // uth -> Latn + {0xC6740000u, 45u}, // utr -> Latn + {0x9EB40000u, 45u}, // uvh -> Latn + {0xAEB40000u, 45u}, // uvl -> Latn + {0x757A0000u, 45u}, // uz -> Latn {0x757A4146u, 2u}, // uz-AF -> Arab {0x757A434Eu, 18u}, // uz-CN -> Cyrl - {0x98150000u, 46u}, // vag -> Latn - {0xA0150000u, 94u}, // vai -> Vaii - {0xB4150000u, 46u}, // van -> Latn - {0x76650000u, 46u}, // ve -> Latn - {0x88950000u, 46u}, // vec -> Latn - {0xBC950000u, 46u}, // vep -> Latn - {0x76690000u, 46u}, // vi -> Latn - {0x89150000u, 46u}, // vic -> Latn - {0xD5150000u, 46u}, // viv -> Latn - {0xC9750000u, 46u}, // vls -> Latn - {0x95950000u, 46u}, // vmf -> Latn - {0xD9950000u, 46u}, // vmw -> Latn - {0x766F0000u, 46u}, // vo -> Latn - {0xCDD50000u, 46u}, // vot -> Latn - {0xBA350000u, 46u}, // vro -> Latn - {0xB6950000u, 46u}, // vun -> Latn - {0xCE950000u, 46u}, // vut -> Latn - {0x77610000u, 46u}, // wa -> Latn - {0x90160000u, 46u}, // wae -> Latn - {0xA4160000u, 46u}, // waj -> Latn + {0x98150000u, 45u}, // vag -> Latn + {0xA0150000u, 97u}, // vai -> Vaii + {0xB4150000u, 45u}, // van -> Latn + {0x76650000u, 45u}, // ve -> Latn + {0x88950000u, 45u}, // vec -> Latn + {0xBC950000u, 45u}, // vep -> Latn + {0x76690000u, 45u}, // vi -> Latn + {0x89150000u, 45u}, // vic -> Latn + {0xD5150000u, 45u}, // viv -> Latn + {0xC9750000u, 45u}, // vls -> Latn + {0x95950000u, 45u}, // vmf -> Latn + {0xD9950000u, 45u}, // vmw -> Latn + {0x766F0000u, 45u}, // vo -> Latn + {0xCDD50000u, 45u}, // vot -> Latn + {0xBA350000u, 45u}, // vro -> Latn + {0xB6950000u, 45u}, // vun -> Latn + {0xCE950000u, 45u}, // vut -> Latn + {0x77610000u, 45u}, // wa -> Latn + {0x90160000u, 45u}, // wae -> Latn + {0xA4160000u, 45u}, // waj -> Latn {0xAC160000u, 21u}, // wal -> Ethi - {0xB4160000u, 46u}, // wan -> Latn - {0xC4160000u, 46u}, // war -> Latn - {0xBC360000u, 46u}, // wbp -> Latn - {0xC0360000u, 88u}, // wbq -> Telu + {0xB4160000u, 45u}, // wan -> Latn + {0xC4160000u, 45u}, // war -> Latn + {0xBC360000u, 45u}, // wbp -> Latn + {0xC0360000u, 89u}, // wbq -> Telu {0xC4360000u, 19u}, // wbr -> Deva - {0xA0560000u, 46u}, // wci -> Latn - {0xC4960000u, 46u}, // wer -> Latn - {0xA0D60000u, 46u}, // wgi -> Latn - {0x98F60000u, 46u}, // whg -> Latn - {0x85160000u, 46u}, // wib -> Latn - {0xD1160000u, 46u}, // wiu -> Latn - {0xD5160000u, 46u}, // wiv -> Latn - {0x81360000u, 46u}, // wja -> Latn - {0xA1360000u, 46u}, // wji -> Latn - {0xC9760000u, 46u}, // wls -> Latn - {0xB9960000u, 46u}, // wmo -> Latn - {0x89B60000u, 46u}, // wnc -> Latn + {0xA0560000u, 45u}, // wci -> Latn + {0xC4960000u, 45u}, // wer -> Latn + {0xA0D60000u, 45u}, // wgi -> Latn + {0x98F60000u, 45u}, // whg -> Latn + {0x85160000u, 45u}, // wib -> Latn + {0xD1160000u, 45u}, // wiu -> Latn + {0xD5160000u, 45u}, // wiv -> Latn + {0x81360000u, 45u}, // wja -> Latn + {0xA1360000u, 45u}, // wji -> Latn + {0xC9760000u, 45u}, // wls -> Latn + {0xB9960000u, 45u}, // wmo -> Latn + {0x89B60000u, 45u}, // wnc -> Latn {0xA1B60000u, 2u}, // wni -> Arab - {0xD1B60000u, 46u}, // wnu -> Latn - {0x776F0000u, 46u}, // wo -> Latn - {0x85D60000u, 46u}, // wob -> Latn - {0xC9D60000u, 46u}, // wos -> Latn - {0xCA360000u, 46u}, // wrs -> Latn + {0xD1B60000u, 45u}, // wnu -> Latn + {0x776F0000u, 45u}, // wo -> Latn + {0x85D60000u, 45u}, // wob -> Latn + {0xC9D60000u, 45u}, // wos -> Latn + {0xCA360000u, 45u}, // wrs -> Latn {0x9A560000u, 23u}, // wsg -> Gong - {0xAA560000u, 46u}, // wsk -> Latn + {0xAA560000u, 45u}, // wsk -> Latn {0xB2760000u, 19u}, // wtm -> Deva {0xD2960000u, 29u}, // wuu -> Hans - {0xD6960000u, 46u}, // wuv -> Latn - {0x82D60000u, 46u}, // wwa -> Latn - {0xD4170000u, 46u}, // xav -> Latn - {0xA0370000u, 46u}, // xbi -> Latn + {0xD6960000u, 45u}, // wuv -> Latn + {0x82D60000u, 45u}, // wwa -> Latn + {0xD4170000u, 45u}, // xav -> Latn + {0xA0370000u, 45u}, // xbi -> Latn {0xB8570000u, 15u}, // xco -> Chrs {0xC4570000u, 12u}, // xcr -> Cari - {0xC8970000u, 46u}, // xes -> Latn - {0x78680000u, 46u}, // xh -> Latn - {0x81770000u, 46u}, // xla -> Latn - {0x89770000u, 50u}, // xlc -> Lyci - {0x8D770000u, 51u}, // xld -> Lydi + {0xC8970000u, 45u}, // xes -> Latn + {0x78680000u, 45u}, // xh -> Latn + {0x81770000u, 45u}, // xla -> Latn + {0x89770000u, 49u}, // xlc -> Lyci + {0x8D770000u, 50u}, // xld -> Lydi {0x95970000u, 22u}, // xmf -> Geor - {0xB5970000u, 53u}, // xmn -> Mani - {0xC5970000u, 55u}, // xmr -> Merc - {0x81B70000u, 60u}, // xna -> Narb + {0xB5970000u, 52u}, // xmn -> Mani + {0xC5970000u, 54u}, // xmr -> Merc + {0x81B70000u, 59u}, // xna -> Narb {0xC5B70000u, 19u}, // xnr -> Deva - {0x99D70000u, 46u}, // xog -> Latn - {0xB5D70000u, 46u}, // xon -> Latn + {0x99D70000u, 45u}, // xog -> Latn + {0xB5D70000u, 45u}, // xon -> Latn {0xC5F70000u, 72u}, // xpr -> Prti - {0x86370000u, 46u}, // xrb -> Latn - {0x82570000u, 75u}, // xsa -> Sarb - {0xA2570000u, 46u}, // xsi -> Latn - {0xB2570000u, 46u}, // xsm -> Latn + {0x86370000u, 45u}, // xrb -> Latn + {0x82570000u, 76u}, // xsa -> Sarb + {0xA2570000u, 45u}, // xsi -> Latn + {0xB2570000u, 45u}, // xsm -> Latn {0xC6570000u, 19u}, // xsr -> Deva - {0x92D70000u, 46u}, // xwe -> Latn - {0xB0180000u, 46u}, // yam -> Latn - {0xB8180000u, 46u}, // yao -> Latn - {0xBC180000u, 46u}, // yap -> Latn - {0xC8180000u, 46u}, // yas -> Latn - {0xCC180000u, 46u}, // yat -> Latn - {0xD4180000u, 46u}, // yav -> Latn - {0xE0180000u, 46u}, // yay -> Latn - {0xE4180000u, 46u}, // yaz -> Latn - {0x80380000u, 46u}, // yba -> Latn - {0x84380000u, 46u}, // ybb -> Latn - {0xE0380000u, 46u}, // yby -> Latn - {0xC4980000u, 46u}, // yer -> Latn - {0xC4D80000u, 46u}, // ygr -> Latn - {0xD8D80000u, 46u}, // ygw -> Latn + {0x92D70000u, 45u}, // xwe -> Latn + {0xB0180000u, 45u}, // yam -> Latn + {0xB8180000u, 45u}, // yao -> Latn + {0xBC180000u, 45u}, // yap -> Latn + {0xC8180000u, 45u}, // yas -> Latn + {0xCC180000u, 45u}, // yat -> Latn + {0xD4180000u, 45u}, // yav -> Latn + {0xE0180000u, 45u}, // yay -> Latn + {0xE4180000u, 45u}, // yaz -> Latn + {0x80380000u, 45u}, // yba -> Latn + {0x84380000u, 45u}, // ybb -> Latn + {0xE0380000u, 45u}, // yby -> Latn + {0xC4980000u, 45u}, // yer -> Latn + {0xC4D80000u, 45u}, // ygr -> Latn + {0xD8D80000u, 45u}, // ygw -> Latn {0x79690000u, 31u}, // yi -> Hebr - {0xB9580000u, 46u}, // yko -> Latn - {0x91780000u, 46u}, // yle -> Latn - {0x99780000u, 46u}, // ylg -> Latn - {0xAD780000u, 46u}, // yll -> Latn - {0xAD980000u, 46u}, // yml -> Latn - {0x796F0000u, 46u}, // yo -> Latn - {0xB5D80000u, 46u}, // yon -> Latn - {0x86380000u, 46u}, // yrb -> Latn - {0x92380000u, 46u}, // yre -> Latn - {0xAE380000u, 46u}, // yrl -> Latn - {0xCA580000u, 46u}, // yss -> Latn - {0x82980000u, 46u}, // yua -> Latn + {0xB9580000u, 45u}, // yko -> Latn + {0x91780000u, 45u}, // yle -> Latn + {0x99780000u, 45u}, // ylg -> Latn + {0xAD780000u, 45u}, // yll -> Latn + {0xAD980000u, 45u}, // yml -> Latn + {0x796F0000u, 45u}, // yo -> Latn + {0xB5D80000u, 45u}, // yon -> Latn + {0x86380000u, 45u}, // yrb -> Latn + {0x92380000u, 45u}, // yre -> Latn + {0xAE380000u, 45u}, // yrl -> Latn + {0xCA580000u, 45u}, // yss -> Latn + {0x82980000u, 45u}, // yua -> Latn {0x92980000u, 30u}, // yue -> Hant {0x9298434Eu, 29u}, // yue-CN -> Hans - {0xA6980000u, 46u}, // yuj -> Latn - {0xCE980000u, 46u}, // yut -> Latn - {0xDA980000u, 46u}, // yuw -> Latn - {0x7A610000u, 46u}, // za -> Latn - {0x98190000u, 46u}, // zag -> Latn + {0xA6980000u, 45u}, // yuj -> Latn + {0xCE980000u, 45u}, // yut -> Latn + {0xDA980000u, 45u}, // yuw -> Latn + {0x7A610000u, 45u}, // za -> Latn + {0x98190000u, 45u}, // zag -> Latn {0xA4790000u, 2u}, // zdj -> Arab - {0x80990000u, 46u}, // zea -> Latn - {0x9CD90000u, 89u}, // zgh -> Tfng + {0x80990000u, 45u}, // zea -> Latn + {0x9CD90000u, 90u}, // zgh -> Tfng {0x7A680000u, 29u}, // zh -> Hans {0x7A684155u, 30u}, // zh-AU -> Hant {0x7A68424Eu, 30u}, // zh-BN -> Hant @@ -1486,14 +1493,14 @@ const std::unordered_map<uint32_t, uint8_t> LIKELY_SCRIPTS({ {0x7A685457u, 30u}, // zh-TW -> Hant {0x7A685553u, 30u}, // zh-US -> Hant {0x7A68564Eu, 30u}, // zh-VN -> Hant - {0xDCF90000u, 62u}, // zhx -> Nshu - {0x81190000u, 46u}, // zia -> Latn - {0xCD590000u, 41u}, // zkt -> Kits - {0xB1790000u, 46u}, // zlm -> Latn - {0xA1990000u, 46u}, // zmi -> Latn - {0x91B90000u, 46u}, // zne -> Latn - {0x7A750000u, 46u}, // zu -> Latn - {0x83390000u, 46u}, // zza -> Latn + {0xDCF90000u, 61u}, // zhx -> Nshu + {0x81190000u, 45u}, // zia -> Latn + {0xCD590000u, 40u}, // zkt -> Kits + {0xB1790000u, 45u}, // zlm -> Latn + {0xA1990000u, 45u}, // zmi -> Latn + {0x91B90000u, 45u}, // zne -> Latn + {0x7A750000u, 45u}, // zu -> Latn + {0x83390000u, 45u}, // zza -> Latn }); std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ @@ -1573,6 +1580,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ 0xCD21534E4C61746ELLU, // bjt_Latn_SN 0xB141434D4C61746ELLU, // bkm_Latn_CM 0xD14150484C61746ELLU, // bku_Latn_PH + 0x99614D594C61746ELLU, // blg_Latn_MY 0xCD61564E54617674LLU, // blt_Tavt_VN 0x626D4D4C4C61746ELLU, // bm_Latn_ML 0xC1814D4C4C61746ELLU, // bmq_Latn_ML @@ -1748,7 +1756,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ 0x8D87434E506C7264LLU, // hmd_Plrd_CN 0x8DA7504B41726162LLU, // hnd_Arab_PK 0x91A7494E44657661LLU, // hne_Deva_IN - 0xA5A74C41486D6E67LLU, // hnj_Hmng_LA + 0xA5A75553486D6E70LLU, // hnj_Hmnp_US 0xB5A750484C61746ELLU, // hnn_Latn_PH 0xB9A7504B41726162LLU, // hno_Arab_PK 0x686F50474C61746ELLU, // ho_Latn_PG @@ -1797,7 +1805,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ 0x984A4E474C61746ELLU, // kcg_Latn_NG 0xA84A5A574C61746ELLU, // kck_Latn_ZW 0x906A545A4C61746ELLU, // kde_Latn_TZ - 0x9C6A544741726162LLU, // kdh_Arab_TG + 0x9C6A54474C61746ELLU, // kdh_Latn_TG 0xCC6A544854686169LLU, // kdt_Thai_TH 0x808A43564C61746ELLU, // kea_Latn_CV 0xB48A434D4C61746ELLU, // ken_Latn_CM @@ -1982,6 +1990,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ 0x6E725A414C61746ELLU, // nr_Latn_ZA 0xAA4D434143616E73LLU, // nsk_Cans_CA 0xBA4D5A414C61746ELLU, // nso_Latn_ZA + 0xCE4D494E546E7361LLU, // nst_Tnsa_IN 0xCA8D53534C61746ELLU, // nus_Latn_SS 0x6E7655534C61746ELLU, // nv_Latn_US 0xC2ED434E4C61746ELLU, // nxq_Latn_CN @@ -1995,6 +2004,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ 0x6F7347454379726CLLU, // os_Cyrl_GE 0x824E55534F736765LLU, // osa_Osge_US 0xAA6E4D4E4F726B68LLU, // otk_Orkh_MN + 0xA28E8C814F756772LLU, // oui_Ougr_143 0x7061504B41726162LLU, // pa_Arab_PK 0x7061494E47757275LLU, // pa_Guru_IN 0x980F50484C61746ELLU, // pag_Latn_PH @@ -2029,7 +2039,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ 0x945152454C61746ELLU, // rcf_Latn_RE 0xA49149444C61746ELLU, // rej_Latn_ID 0xB4D149544C61746ELLU, // rgn_Latn_IT - 0x98F14D4D41726162LLU, // rhg_Arab_MM + 0x98F14D4D526F6867LLU, // rhg_Rohg_MM 0x8111494E4C61746ELLU, // ria_Latn_IN 0x95114D4154666E67LLU, // rif_Tfng_MA 0xC9314E5044657661LLU, // rjs_Deva_NP @@ -2172,6 +2182,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ 0xAEB354564C61746ELLU, // tvl_Latn_TV 0xC2D34E454C61746ELLU, // twq_Latn_NE 0x9AF3434E54616E67LLU, // txg_Tang_CN + 0xBAF3494E546F746FLLU, // txo_Toto_IN 0x747950464C61746ELLU, // ty_Latn_PF 0xD71352554379726CLLU, // tyv_Cyrl_RU 0xB3334D414C61746ELLU, // tzm_Latn_MA @@ -2256,6 +2267,7 @@ std::unordered_set<uint64_t> REPRESENTATIVE_LOCALES({ }); const std::unordered_map<uint32_t, uint32_t> ARAB_PARENTS({ + {0x61724145u, 0x61729420u}, // ar-AE -> ar-015 {0x6172445Au, 0x61729420u}, // ar-DZ -> ar-015 {0x61724548u, 0x61729420u}, // ar-EH -> ar-015 {0x61724C59u, 0x61729420u}, // ar-LY -> ar-015 @@ -2279,7 +2291,6 @@ const std::unordered_map<uint32_t, uint32_t> LATN_PARENTS({ {0x656E4253u, 0x656E8400u}, // en-BS -> en-001 {0x656E4257u, 0x656E8400u}, // en-BW -> en-001 {0x656E425Au, 0x656E8400u}, // en-BZ -> en-001 - {0x656E4341u, 0x656E8400u}, // en-CA -> en-001 {0x656E4343u, 0x656E8400u}, // en-CC -> en-001 {0x656E4348u, 0x656E80A1u}, // en-CH -> en-150 {0x656E434Bu, 0x656E8400u}, // en-CK -> en-001 @@ -2332,7 +2343,6 @@ const std::unordered_map<uint32_t, uint32_t> LATN_PARENTS({ {0x656E4E55u, 0x656E8400u}, // en-NU -> en-001 {0x656E4E5Au, 0x656E8400u}, // en-NZ -> en-001 {0x656E5047u, 0x656E8400u}, // en-PG -> en-001 - {0x656E5048u, 0x656E8400u}, // en-PH -> en-001 {0x656E504Bu, 0x656E8400u}, // en-PK -> en-001 {0x656E504Eu, 0x656E8400u}, // en-PN -> en-001 {0x656E5057u, 0x656E8400u}, // en-PW -> en-001 diff --git a/media/java/android/media/AudioManager.java b/media/java/android/media/AudioManager.java index c7f56961e498..60f4a5a226db 100644 --- a/media/java/android/media/AudioManager.java +++ b/media/java/android/media/AudioManager.java @@ -32,6 +32,7 @@ import android.app.NotificationManager; import android.app.PendingIntent; import android.bluetooth.BluetoothCodecConfig; import android.bluetooth.BluetoothDevice; +import android.bluetooth.BluetoothLeAudioCodecConfig; import android.compat.annotation.UnsupportedAppUsage; import android.content.ComponentName; import android.content.Context; @@ -6790,30 +6791,56 @@ public class AudioManager { /** * Returns a list of audio formats that corresponds to encoding formats - * supported on offload path for A2DP playback. + * supported on offload path for A2DP and LE audio playback. * + * @param deviceType Indicates the target device type {@link AudioSystem.DeviceType} * @return a list of {@link BluetoothCodecConfig} objects containing encoding formats - * supported for offload A2DP playback + * supported for offload A2DP playback or a list of {@link BluetoothLeAudioCodecConfig} + * objects containing encoding formats supported for offload LE Audio playback * @hide */ - public List<BluetoothCodecConfig> getHwOffloadEncodingFormatsSupportedForA2DP() { + public List<?> getHwOffloadFormatsSupportedForBluetoothMedia( + @AudioSystem.DeviceType int deviceType) { ArrayList<Integer> formatsList = new ArrayList<Integer>(); - ArrayList<BluetoothCodecConfig> codecConfigList = new ArrayList<BluetoothCodecConfig>(); + ArrayList<BluetoothCodecConfig> a2dpCodecConfigList = new ArrayList<BluetoothCodecConfig>(); + ArrayList<BluetoothLeAudioCodecConfig> leAudioCodecConfigList = + new ArrayList<BluetoothLeAudioCodecConfig>(); - int status = AudioSystem.getHwOffloadEncodingFormatsSupportedForA2DP(formatsList); + if (deviceType != AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP + && deviceType != AudioSystem.DEVICE_OUT_BLE_HEADSET) { + throw new IllegalArgumentException( + "Illegal devicetype for the getHwOffloadFormatsSupportedForBluetoothMedia"); + } + + int status = AudioSystem.getHwOffloadFormatsSupportedForBluetoothMedia(deviceType, + formatsList); if (status != AudioManager.SUCCESS) { - Log.e(TAG, "getHwOffloadEncodingFormatsSupportedForA2DP failed:" + status); - return codecConfigList; + Log.e(TAG, "getHwOffloadFormatsSupportedForBluetoothMedia for deviceType " + + deviceType + " failed:" + status); + return a2dpCodecConfigList; } - for (Integer format : formatsList) { - int btSourceCodec = AudioSystem.audioFormatToBluetoothSourceCodec(format); - if (btSourceCodec - != BluetoothCodecConfig.SOURCE_CODEC_TYPE_INVALID) { - codecConfigList.add(new BluetoothCodecConfig(btSourceCodec)); + if (deviceType == AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP) { + for (Integer format : formatsList) { + int btSourceCodec = AudioSystem.audioFormatToBluetoothSourceCodec(format); + if (btSourceCodec != BluetoothCodecConfig.SOURCE_CODEC_TYPE_INVALID) { + a2dpCodecConfigList.add(new BluetoothCodecConfig(btSourceCodec)); + } + } + return a2dpCodecConfigList; + } else if (deviceType == AudioSystem.DEVICE_OUT_BLE_HEADSET) { + for (Integer format : formatsList) { + int btLeAudioCodec = AudioSystem.audioFormatToBluetoothLeAudioSourceCodec(format); + if (btLeAudioCodec != BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_INVALID) { + leAudioCodecConfigList.add(new BluetoothLeAudioCodecConfig.Builder() + .setCodecType(btLeAudioCodec) + .build()); + } } + return leAudioCodecConfigList; } - return codecConfigList; + Log.e(TAG, "Input deviceType " + deviceType + " doesn't support."); + return a2dpCodecConfigList; } // Since we need to calculate the changes since THE LAST NOTIFICATION, and not since the diff --git a/media/java/android/media/AudioSystem.java b/media/java/android/media/AudioSystem.java index 69d1889d5762..f0e42c0550ff 100644 --- a/media/java/android/media/AudioSystem.java +++ b/media/java/android/media/AudioSystem.java @@ -21,6 +21,7 @@ import android.annotation.NonNull; import android.annotation.RequiresPermission; import android.annotation.TestApi; import android.bluetooth.BluetoothCodecConfig; +import android.bluetooth.BluetoothLeAudioCodecConfig; import android.compat.annotation.UnsupportedAppUsage; import android.content.Context; import android.content.pm.PackageManager; @@ -229,6 +230,9 @@ public class AudioSystem public static final int AUDIO_FORMAT_APTX_HD = 0x21000000; /** @hide */ public static final int AUDIO_FORMAT_LDAC = 0x23000000; + /** @hide */ + public static final int AUDIO_FORMAT_LC3 = 0x2B000000; + /** @hide */ @IntDef(flag = false, prefix = "AUDIO_FORMAT_", value = { @@ -238,11 +242,26 @@ public class AudioSystem AUDIO_FORMAT_SBC, AUDIO_FORMAT_APTX, AUDIO_FORMAT_APTX_HD, - AUDIO_FORMAT_LDAC } + AUDIO_FORMAT_LDAC} ) @Retention(RetentionPolicy.SOURCE) public @interface AudioFormatNativeEnumForBtCodec {} + /** @hide */ + @IntDef(flag = false, prefix = "AUDIO_FORMAT_", value = { + AUDIO_FORMAT_LC3} + ) + @Retention(RetentionPolicy.SOURCE) + public @interface AudioFormatNativeEnumForBtLeAudioCodec {} + + /** @hide */ + @IntDef(flag = false, prefix = "DEVICE_", value = { + DEVICE_OUT_BLUETOOTH_A2DP, + DEVICE_OUT_BLE_HEADSET} + ) + @Retention(RetentionPolicy.SOURCE) + public @interface DeviceType {} + /** * @hide * Convert audio format enum values to Bluetooth codec values @@ -264,6 +283,21 @@ public class AudioSystem /** * @hide + * Convert audio format enum values to Bluetooth LE audio codec values + */ + public static int audioFormatToBluetoothLeAudioSourceCodec( + @AudioFormatNativeEnumForBtLeAudioCodec int audioFormat) { + switch (audioFormat) { + case AUDIO_FORMAT_LC3: return BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_LC3; + default: + Log.e(TAG, "Unknown audio format 0x" + Integer.toHexString(audioFormat) + + " for conversion to BT LE audio codec"); + return BluetoothLeAudioCodecConfig.SOURCE_CODEC_TYPE_INVALID; + } + } + + /** + * @hide * Convert a Bluetooth codec to an audio format enum * @param btCodec the codec to convert. * @return the audio format, or {@link #AUDIO_FORMAT_DEFAULT} if unknown @@ -1754,10 +1788,10 @@ public class AudioSystem /** * @hide - * Returns a list of audio formats (codec) supported on the A2DP offload path. + * Returns a list of audio formats (codec) supported on the A2DP and LE audio offload path. */ - public static native int getHwOffloadEncodingFormatsSupportedForA2DP( - ArrayList<Integer> formatList); + public static native int getHwOffloadFormatsSupportedForBluetoothMedia( + @DeviceType int deviceType, ArrayList<Integer> formatList); /** @hide */ public static native int setSurroundFormatEnabled(int audioFormat, boolean enabled); diff --git a/media/jni/soundpool/SoundPool.cpp b/media/jni/soundpool/SoundPool.cpp index 253b4e3a8a09..00c4a9782f33 100644 --- a/media/jni/soundpool/SoundPool.cpp +++ b/media/jni/soundpool/SoundPool.cpp @@ -185,7 +185,7 @@ void SoundPool::stop(int32_t streamID) auto apiLock = kUseApiLock ? std::make_unique<std::lock_guard<std::mutex>>(mApiLock) : nullptr; soundpool::Stream* stream = mStreamManager.findStream(streamID); if (stream != nullptr && stream->requestStop(streamID)) { - mStreamManager.moveToRestartQueue(stream); + mStreamManager.moveToRestartQueue(stream, streamID); } } diff --git a/media/jni/soundpool/Stream.cpp b/media/jni/soundpool/Stream.cpp index bbbef3853b23..773cdc982af7 100644 --- a/media/jni/soundpool/Stream.cpp +++ b/media/jni/soundpool/Stream.cpp @@ -228,10 +228,9 @@ Stream* Stream::getPairStream() const return mStreamManager->getPairStream(this); } -Stream* Stream::playPairStream() { +Stream* Stream::playPairStream(std::vector<std::any>& garbage) { Stream* pairStream = getPairStream(); LOG_ALWAYS_FATAL_IF(pairStream == nullptr, "No pair stream!"); - sp<AudioTrack> releaseTracks[2]; { ALOGV("%s: track streamID: %d", __func__, (int)getStreamID()); // TODO: Do we really want to force a simultaneous synchronization between @@ -260,7 +259,7 @@ Stream* Stream::playPairStream() { const int pairState = pairStream->mState; pairStream->play_l(pairStream->mSound, pairStream->mStreamID, pairStream->mLeftVolume, pairStream->mRightVolume, pairStream->mPriority, - pairStream->mLoop, pairStream->mRate, releaseTracks); + pairStream->mLoop, pairStream->mRate, garbage); if (pairStream->mState == IDLE) { return nullptr; // AudioTrack error } @@ -269,17 +268,16 @@ Stream* Stream::playPairStream() { pairStream->mAudioTrack->pause(); } } - // release tracks outside of Stream lock return pairStream; } void Stream::play_l(const std::shared_ptr<Sound>& sound, int32_t nextStreamID, float leftVolume, float rightVolume, int32_t priority, int32_t loop, float rate, - sp<AudioTrack> releaseTracks[2]) + std::vector<std::any>& garbage) { - // These tracks are released without the lock. - sp<AudioTrack> &oldTrack = releaseTracks[0]; - sp<AudioTrack> &newTrack = releaseTracks[1]; + // oldTrack and newTrack are placeholders to be released by garbage without the lock. + sp<AudioTrack> oldTrack; + sp<AudioTrack> newTrack; status_t status = NO_ERROR; { @@ -383,8 +381,12 @@ exit: mState = IDLE; mSoundID = 0; mSound.reset(); - mAudioTrack.clear(); // actual release from releaseTracks[] + mAudioTrack.clear(); // actual release from garbage } + + // move tracks to garbage to be released later outside of lock. + if (newTrack) garbage.emplace_back(std::move(newTrack)); + if (oldTrack) garbage.emplace_back(std::move(oldTrack)); } /* static */ diff --git a/media/jni/soundpool/Stream.h b/media/jni/soundpool/Stream.h index d4e5c9fe7f8a..aa0eef5bc66e 100644 --- a/media/jni/soundpool/Stream.h +++ b/media/jni/soundpool/Stream.h @@ -18,6 +18,7 @@ #include "Sound.h" +#include <any> #include <android-base/thread_annotations.h> #include <audio_utils/clock.h> #include <media/AudioTrack.h> @@ -90,8 +91,9 @@ public: void mute(bool muting); void dump() const NO_THREAD_SAFETY_ANALYSIS; // disable for ALOGV (see func for details). - // returns the pair stream if successful, nullptr otherwise - Stream* playPairStream(); + // returns the pair stream if successful, nullptr otherwise. + // garbage is used to release tracks and data outside of any lock. + Stream* playPairStream(std::vector<std::any>& garbage); // These parameters are explicitly checked in the SoundPool class // so never deviate from the Java API specified values. @@ -123,9 +125,10 @@ public: Stream* getPairStream() const; private: + // garbage is used to release tracks and data outside of any lock. void play_l(const std::shared_ptr<Sound>& sound, int streamID, float leftVolume, float rightVolume, int priority, int loop, float rate, - sp<AudioTrack> releaseTracks[2]) REQUIRES(mLock); + std::vector<std::any>& garbage) REQUIRES(mLock); void stop_l() REQUIRES(mLock); void setVolume_l(float leftVolume, float rightVolume) REQUIRES(mLock); diff --git a/media/jni/soundpool/StreamManager.cpp b/media/jni/soundpool/StreamManager.cpp index 309d71cfd062..7f987e31d1d8 100644 --- a/media/jni/soundpool/StreamManager.cpp +++ b/media/jni/soundpool/StreamManager.cpp @@ -157,6 +157,7 @@ int32_t StreamManager::queueForPlay(const std::shared_ptr<Sound> &sound, __func__, sound.get(), soundID, leftVolume, rightVolume, priority, loop, rate); bool launchThread = false; int32_t streamID = 0; + std::vector<std::any> garbage; { // for lock std::unique_lock lock(mStreamManagerLock); @@ -243,7 +244,7 @@ int32_t StreamManager::queueForPlay(const std::shared_ptr<Sound> &sound, removeFromQueues_l(newStream); mProcessingStreams.emplace(newStream); lock.unlock(); - if (Stream* nextStream = newStream->playPairStream()) { + if (Stream* nextStream = newStream->playPairStream(garbage)) { lock.lock(); ALOGV("%s: starting streamID:%d", __func__, nextStream->getStreamID()); addToActiveQueue_l(nextStream); @@ -266,6 +267,7 @@ int32_t StreamManager::queueForPlay(const std::shared_ptr<Sound> &sound, ALOGV_IF(id != 0, "%s: launched thread %d", __func__, id); } ALOGV("%s: returning %d", __func__, streamID); + // garbage is cleared here outside mStreamManagerLock. return streamID; } @@ -359,6 +361,7 @@ void StreamManager::run(int32_t id) { ALOGV("%s(%d) entering", __func__, id); int64_t waitTimeNs = 0; // on thread start, mRestartStreams can be non-empty. + std::vector<std::any> garbage; // used for garbage collection std::unique_lock lock(mStreamManagerLock); while (!mQuit) { if (waitTimeNs > 0) { @@ -388,7 +391,7 @@ void StreamManager::run(int32_t id) if (!mLockStreamManagerStop) lock.unlock(); stream->stop(); ALOGV("%s(%d) stopping streamID:%d", __func__, id, stream->getStreamID()); - if (Stream* nextStream = stream->playPairStream()) { + if (Stream* nextStream = stream->playPairStream(garbage)) { ALOGV("%s(%d) starting streamID:%d", __func__, id, nextStream->getStreamID()); if (!mLockStreamManagerStop) lock.lock(); if (nextStream->getStopTimeNs() > 0) { @@ -405,6 +408,12 @@ void StreamManager::run(int32_t id) } mProcessingStreams.erase(stream); sanityCheckQueue_l(); + if (!garbage.empty()) { + lock.unlock(); + // garbage audio tracks (etc) are cleared here outside mStreamManagerLock. + garbage.clear(); + lock.lock(); + } } } ALOGV("%s(%d) exiting", __func__, id); diff --git a/packages/ConnectivityT/OWNERS b/packages/ConnectivityT/OWNERS new file mode 100644 index 000000000000..e267d19ad7e2 --- /dev/null +++ b/packages/ConnectivityT/OWNERS @@ -0,0 +1,2 @@ +file:platform/packages/modules/Connectivity:master:/OWNERS_core_networking +per-file **IpSec* = file:/services/core/java/com/android/server/vcn/OWNERS diff --git a/packages/ConnectivityT/framework-t/Android.bp b/packages/ConnectivityT/framework-t/Android.bp new file mode 100644 index 000000000000..931a55b27ddb --- /dev/null +++ b/packages/ConnectivityT/framework-t/Android.bp @@ -0,0 +1,139 @@ +// +// Copyright (C) 2021 The Android Open Source Project +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + +package { + // See: http://go/android-license-faq + default_applicable_licenses: ["Android-Apache-2.0"], +} + +// NetworkStats related libraries. + +filegroup { + name: "framework-connectivity-netstats-internal-sources", + srcs: [ + "src/android/app/usage/*.java", + "src/android/net/DataUsage*.*", + "src/android/net/INetworkStats*.*", + "src/android/net/NetworkIdentity*.java", + "src/android/net/NetworkStateSnapshot.*", + "src/android/net/NetworkStats*.*", + "src/android/net/NetworkTemplate.*", + "src/android/net/TrafficStats.java", + "src/android/net/UnderlyingNetworkInfo.*", + "src/android/net/netstats/**/*.*", + ], + path: "src", + visibility: [ + "//visibility:private", + ], +} + +filegroup { + name: "framework-connectivity-netstats-aidl-export-sources", + srcs: [ + "aidl-export/android/net/NetworkStats.aidl", + "aidl-export/android/net/NetworkTemplate.aidl", + ], + path: "aidl-export", + visibility: [ + "//visibility:private", + ], +} + +filegroup { + name: "framework-connectivity-netstats-sources", + srcs: [ + ":framework-connectivity-netstats-internal-sources", + ":framework-connectivity-netstats-aidl-export-sources", + ], + visibility: [ + "//visibility:private", + ], +} + +// Nsd related libraries. + +filegroup { + name: "framework-connectivity-nsd-internal-sources", + srcs: [ + "src/android/net/nsd/*.aidl", + "src/android/net/nsd/*.java", + ], + path: "src", + visibility: [ + "//visibility:private", + ], +} + +filegroup { + name: "framework-connectivity-nsd-aidl-export-sources", + srcs: [ + "aidl-export/android/net/nsd/*.aidl", + ], + path: "aidl-export", + visibility: [ + "//visibility:private", + ], +} + +filegroup { + name: "framework-connectivity-nsd-sources", + srcs: [ + ":framework-connectivity-nsd-internal-sources", + ":framework-connectivity-nsd-aidl-export-sources", + ], + visibility: [ + "//visibility:private", + ], +} + +// IpSec related libraries. + +filegroup { + name: "framework-connectivity-ipsec-sources", + srcs: [ + "src/android/net/IIpSecService.aidl", + "src/android/net/IpSec*.*", + ], + path: "src", + visibility: [ + "//visibility:private", + ], +} + +// Connectivity-T common libraries. + +filegroup { + name: "framework-connectivity-tiramisu-internal-sources", + srcs: [ + "src/android/net/ConnectivityFrameworkInitializerTiramisu.java", + ], + path: "src", + visibility: [ + "//visibility:private", + ], +} + +filegroup { + name: "framework-connectivity-tiramisu-sources", + srcs: [ + ":framework-connectivity-ipsec-sources", + ":framework-connectivity-netstats-sources", + ":framework-connectivity-nsd-sources", + ":framework-connectivity-tiramisu-internal-sources", + ], + visibility: ["//frameworks/base"], +} diff --git a/core/java/android/net/NetworkStats.aidl b/packages/ConnectivityT/framework-t/aidl-export/android/net/NetworkStats.aidl index d06ca65a3e0d..d06ca65a3e0d 100644 --- a/core/java/android/net/NetworkStats.aidl +++ b/packages/ConnectivityT/framework-t/aidl-export/android/net/NetworkStats.aidl diff --git a/core/java/android/net/NetworkTemplate.aidl b/packages/ConnectivityT/framework-t/aidl-export/android/net/NetworkTemplate.aidl index 3d37488d9881..3d37488d9881 100644 --- a/core/java/android/net/NetworkTemplate.aidl +++ b/packages/ConnectivityT/framework-t/aidl-export/android/net/NetworkTemplate.aidl diff --git a/packages/Nsd/framework/aidl-export/android/net/nsd/NsdServiceInfo.aidl b/packages/ConnectivityT/framework-t/aidl-export/android/net/nsd/NsdServiceInfo.aidl index 657bdd1e8706..657bdd1e8706 100644 --- a/packages/Nsd/framework/aidl-export/android/net/nsd/NsdServiceInfo.aidl +++ b/packages/ConnectivityT/framework-t/aidl-export/android/net/nsd/NsdServiceInfo.aidl diff --git a/core/java/android/app/usage/NetworkStats.java b/packages/ConnectivityT/framework-t/src/android/app/usage/NetworkStats.java index 216a4a0987f5..216a4a0987f5 100644 --- a/core/java/android/app/usage/NetworkStats.java +++ b/packages/ConnectivityT/framework-t/src/android/app/usage/NetworkStats.java diff --git a/core/java/android/app/usage/NetworkStatsManager.java b/packages/ConnectivityT/framework-t/src/android/app/usage/NetworkStatsManager.java index 8a6c85d54896..8a6c85d54896 100644 --- a/core/java/android/app/usage/NetworkStatsManager.java +++ b/packages/ConnectivityT/framework-t/src/android/app/usage/NetworkStatsManager.java diff --git a/packages/ConnectivityT/framework-t/src/android/net/ConnectivityFrameworkInitializerTiramisu.java b/packages/ConnectivityT/framework-t/src/android/net/ConnectivityFrameworkInitializerTiramisu.java new file mode 100644 index 000000000000..630f902ecfd7 --- /dev/null +++ b/packages/ConnectivityT/framework-t/src/android/net/ConnectivityFrameworkInitializerTiramisu.java @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2021 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package android.net; + +import android.annotation.SystemApi; +import android.app.SystemServiceRegistry; +import android.content.Context; +import android.net.nsd.INsdManager; +import android.net.nsd.NsdManager; + +/** + * Class for performing registration for Connectivity services which are exposed via updatable APIs + * since Android T. + * + * @hide + */ +@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) +public final class ConnectivityFrameworkInitializerTiramisu { + private ConnectivityFrameworkInitializerTiramisu() {} + + /** + * Called by {@link SystemServiceRegistry}'s static initializer and registers nsd services to + * {@link Context}, so that {@link Context#getSystemService} can return them. + * + * @throws IllegalStateException if this is called anywhere besides + * {@link SystemServiceRegistry}. + */ + public static void registerServiceWrappers() { + SystemServiceRegistry.registerContextAwareService( + Context.NSD_SERVICE, + NsdManager.class, + (context, serviceBinder) -> { + INsdManager service = INsdManager.Stub.asInterface(serviceBinder); + return new NsdManager(context, service); + } + ); + } +} diff --git a/core/java/android/net/DataUsageRequest.aidl b/packages/ConnectivityT/framework-t/src/android/net/DataUsageRequest.aidl index d1937c7b8c62..d1937c7b8c62 100644 --- a/core/java/android/net/DataUsageRequest.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/DataUsageRequest.aidl diff --git a/core/java/android/net/DataUsageRequest.java b/packages/ConnectivityT/framework-t/src/android/net/DataUsageRequest.java index b06d515b3acf..b06d515b3acf 100644 --- a/core/java/android/net/DataUsageRequest.java +++ b/packages/ConnectivityT/framework-t/src/android/net/DataUsageRequest.java diff --git a/core/java/android/net/IIpSecService.aidl b/packages/ConnectivityT/framework-t/src/android/net/IIpSecService.aidl index 933256a3b475..933256a3b475 100644 --- a/core/java/android/net/IIpSecService.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/IIpSecService.aidl diff --git a/core/java/android/net/INetworkStatsService.aidl b/packages/ConnectivityT/framework-t/src/android/net/INetworkStatsService.aidl index 12937b5cb2c7..12937b5cb2c7 100644 --- a/core/java/android/net/INetworkStatsService.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/INetworkStatsService.aidl diff --git a/core/java/android/net/INetworkStatsSession.aidl b/packages/ConnectivityT/framework-t/src/android/net/INetworkStatsSession.aidl index f13f2cb664ba..dfedf6633dcd 100644 --- a/core/java/android/net/INetworkStatsSession.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/INetworkStatsSession.aidl @@ -33,7 +33,17 @@ interface INetworkStatsSession { @UnsupportedAppUsage NetworkStatsHistory getHistoryForNetwork(in NetworkTemplate template, int fields); - /** Return network layer usage summary per UID for traffic that matches template. */ + /** + * Return network layer usage summary per UID for traffic that matches template. + * + * <p>The resulting {@code NetworkStats#getElapsedRealtime()} contains time delta between + * {@code start} and {@code end}. + * + * @param template - a predicate to filter netstats. + * @param start - start of the range, timestamp in milliseconds since the epoch. + * @param end - end of the range, timestamp in milliseconds since the epoch. + * @param includeTags - includes data usage tags if true. + */ @UnsupportedAppUsage NetworkStats getSummaryForAllUid(in NetworkTemplate template, long start, long end, boolean includeTags); /** Return historical network layer stats for specific UID traffic that matches template. */ diff --git a/core/java/android/net/IpSecAlgorithm.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecAlgorithm.java index 86052484eaf6..86052484eaf6 100644 --- a/core/java/android/net/IpSecAlgorithm.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecAlgorithm.java diff --git a/core/java/android/net/IpSecConfig.aidl b/packages/ConnectivityT/framework-t/src/android/net/IpSecConfig.aidl index eaefca74d3a0..eaefca74d3a0 100644 --- a/core/java/android/net/IpSecConfig.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecConfig.aidl diff --git a/core/java/android/net/IpSecConfig.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecConfig.java index 575c5ed968f8..575c5ed968f8 100644 --- a/core/java/android/net/IpSecConfig.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecConfig.java diff --git a/core/java/android/net/IpSecManager.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecManager.java index c10680761ff1..c10680761ff1 100644 --- a/core/java/android/net/IpSecManager.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecManager.java diff --git a/core/java/android/net/IpSecSpiResponse.aidl b/packages/ConnectivityT/framework-t/src/android/net/IpSecSpiResponse.aidl index 6484a0013c53..6484a0013c53 100644 --- a/core/java/android/net/IpSecSpiResponse.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecSpiResponse.aidl diff --git a/core/java/android/net/IpSecSpiResponse.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecSpiResponse.java index f99e570fb761..f99e570fb761 100644 --- a/core/java/android/net/IpSecSpiResponse.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecSpiResponse.java diff --git a/core/java/android/net/IpSecTransform.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecTransform.java index b48c1fdaf1b2..b48c1fdaf1b2 100644 --- a/core/java/android/net/IpSecTransform.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecTransform.java diff --git a/core/java/android/net/IpSecTransformResponse.aidl b/packages/ConnectivityT/framework-t/src/android/net/IpSecTransformResponse.aidl index 546230d5b888..546230d5b888 100644 --- a/core/java/android/net/IpSecTransformResponse.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecTransformResponse.aidl diff --git a/core/java/android/net/IpSecTransformResponse.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecTransformResponse.java index a38488954fc0..a38488954fc0 100644 --- a/core/java/android/net/IpSecTransformResponse.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecTransformResponse.java diff --git a/core/java/android/net/IpSecTunnelInterfaceResponse.aidl b/packages/ConnectivityT/framework-t/src/android/net/IpSecTunnelInterfaceResponse.aidl index 7239221415ce..7239221415ce 100644 --- a/core/java/android/net/IpSecTunnelInterfaceResponse.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecTunnelInterfaceResponse.aidl diff --git a/core/java/android/net/IpSecTunnelInterfaceResponse.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecTunnelInterfaceResponse.java index e3411e003d6b..e3411e003d6b 100644 --- a/core/java/android/net/IpSecTunnelInterfaceResponse.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecTunnelInterfaceResponse.java diff --git a/core/java/android/net/IpSecUdpEncapResponse.aidl b/packages/ConnectivityT/framework-t/src/android/net/IpSecUdpEncapResponse.aidl index 5e451f3651f1..5e451f3651f1 100644 --- a/core/java/android/net/IpSecUdpEncapResponse.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecUdpEncapResponse.aidl diff --git a/core/java/android/net/IpSecUdpEncapResponse.java b/packages/ConnectivityT/framework-t/src/android/net/IpSecUdpEncapResponse.java index 4e7ba9b515d0..4e7ba9b515d0 100644 --- a/core/java/android/net/IpSecUdpEncapResponse.java +++ b/packages/ConnectivityT/framework-t/src/android/net/IpSecUdpEncapResponse.java diff --git a/core/java/android/net/NetworkIdentity.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkIdentity.java index eb8f43e3d073..eb8f43e3d073 100644 --- a/core/java/android/net/NetworkIdentity.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkIdentity.java diff --git a/services/core/java/com/android/server/net/NetworkIdentitySet.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkIdentitySet.java index 22ed781da92d..abbebef85c8f 100644 --- a/services/core/java/com/android/server/net/NetworkIdentitySet.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkIdentitySet.java @@ -14,9 +14,10 @@ * limitations under the License. */ -package com.android.server.net; +package android.net; + +import static android.net.ConnectivityManager.TYPE_MOBILE; -import android.net.NetworkIdentity; import android.service.NetworkIdentitySetProto; import android.util.proto.ProtoOutputStream; @@ -25,8 +26,6 @@ import java.io.DataOutput; import java.io.IOException; import java.util.HashSet; -import static android.net.ConnectivityManager.TYPE_MOBILE; - /** * Identity of a {@code iface}, defined by the set of {@link NetworkIdentity} * active on that interface. @@ -97,6 +96,9 @@ public class NetworkIdentitySet extends HashSet<NetworkIdentity> implements } } + /** + * Method to serialize this object into a {@code DataOutput}. + */ public void writeToStream(DataOutput out) throws IOException { out.writeInt(VERSION_ADD_OEM_MANAGED_NETWORK); out.writeInt(size()); @@ -179,6 +181,9 @@ public class NetworkIdentitySet extends HashSet<NetworkIdentity> implements return ident.compareTo(anotherIdent); } + /** + * Method to dump this object into proto debug file. + */ public void dumpDebug(ProtoOutputStream proto, long tag) { final long start = proto.start(tag); diff --git a/core/java/android/net/NetworkStateSnapshot.aidl b/packages/ConnectivityT/framework-t/src/android/net/NetworkStateSnapshot.aidl index cb602d7927ce..cb602d7927ce 100644 --- a/core/java/android/net/NetworkStateSnapshot.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkStateSnapshot.aidl diff --git a/core/java/android/net/NetworkStateSnapshot.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkStateSnapshot.java index 39156343924d..39156343924d 100644 --- a/core/java/android/net/NetworkStateSnapshot.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkStateSnapshot.java diff --git a/core/java/android/net/NetworkStats.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkStats.java index 46c83df96b04..c7ffc1933829 100644 --- a/core/java/android/net/NetworkStats.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkStats.java @@ -220,8 +220,10 @@ public final class NetworkStats implements Parcelable { // TODO: move fields to "mVariable" notation /** - * {@link SystemClock#elapsedRealtime()} timestamp when this data was + * {@link SystemClock#elapsedRealtime()} timestamp in milliseconds when this data was * generated. + * It's a timestamps delta when {@link #subtract()}, + * {@code INetworkStatsSession#getSummaryForAllUid()} methods are used. */ private long elapsedRealtime; @UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553) diff --git a/services/core/java/com/android/server/net/NetworkStatsAccess.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsAccess.java index d25eae409d40..3885a9e6d5cb 100644 --- a/services/core/java/com/android/server/net/NetworkStatsAccess.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsAccess.java @@ -11,10 +11,10 @@ * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and - * limitations under the License + * limitations under the License. */ -package com.android.server.net; +package android.net; import static android.Manifest.permission.READ_NETWORK_USAGE_HISTORY; import static android.net.NetworkStats.UID_ALL; @@ -37,7 +37,11 @@ import com.android.server.LocalServices; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; -/** Utility methods for controlling access to network stats APIs. */ +/** + * Utility methods for controlling access to network stats APIs. + * + * @hide + */ public final class NetworkStatsAccess { private NetworkStatsAccess() {} diff --git a/services/core/java/com/android/server/net/NetworkStatsCollection.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsCollection.java index df372b1459af..0d3b9ed4e3d4 100644 --- a/services/core/java/com/android/server/net/NetworkStatsCollection.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsCollection.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.android.server.net; +package android.net; import static android.net.NetworkStats.DEFAULT_NETWORK_NO; import static android.net.NetworkStats.DEFAULT_NETWORK_YES; @@ -31,13 +31,7 @@ import static android.net.TrafficStats.UID_REMOVED; import static android.text.format.DateUtils.WEEK_IN_MILLIS; import static com.android.internal.net.NetworkUtilsInternal.multiplySafeByRational; -import static com.android.server.net.NetworkStatsService.TAG; -import android.net.NetworkIdentity; -import android.net.NetworkStats; -import android.net.NetworkStatsHistory; -import android.net.NetworkTemplate; -import android.net.TrafficStats; import android.os.Binder; import android.service.NetworkStatsCollectionKeyProto; import android.service.NetworkStatsCollectionProto; @@ -59,16 +53,15 @@ import com.android.internal.util.FastDataOutput; import com.android.internal.util.FileRotator; import com.android.internal.util.IndentingPrintWriter; -import libcore.io.IoUtils; - import com.google.android.collect.Lists; import com.google.android.collect.Maps; +import libcore.io.IoUtils; + import java.io.BufferedInputStream; import java.io.DataInput; import java.io.DataInputStream; import java.io.DataOutput; -import java.io.DataOutputStream; import java.io.File; import java.io.FileNotFoundException; import java.io.IOException; @@ -86,8 +79,11 @@ import java.util.Objects; /** * Collection of {@link NetworkStatsHistory}, stored based on combined key of * {@link NetworkIdentitySet}, UID, set, and tag. Knows how to persist itself. + * + * @hide */ public class NetworkStatsCollection implements FileRotator.Reader, FileRotator.Writer { + private static final String TAG = NetworkStatsCollection.class.getSimpleName(); /** File header magic number: "ANET" */ private static final int FILE_MAGIC = 0x414E4554; @@ -335,7 +331,13 @@ public class NetworkStatsCollection implements FileRotator.Reader, FileRotator.W /** * Summarize all {@link NetworkStatsHistory} in this collection which match - * the requested parameters. + * the requested parameters across the requested range. + * + * @param template - a predicate for filtering netstats. + * @param start - start of the range, timestamp in milliseconds since the epoch. + * @param end - end of the range, timestamp in milliseconds since the epoch. + * @param accessLevel - caller access level. + * @param callerUid - caller UID. */ public NetworkStats getSummary(NetworkTemplate template, long start, long end, @NetworkStatsAccess.Level int accessLevel, int callerUid) { @@ -361,8 +363,8 @@ public class NetworkStatsCollection implements FileRotator.Reader, FileRotator.W entry.uid = key.uid; entry.set = key.set; entry.tag = key.tag; - entry.defaultNetwork = key.ident.areAllMembersOnDefaultNetwork() ? - DEFAULT_NETWORK_YES : DEFAULT_NETWORK_NO; + entry.defaultNetwork = key.ident.areAllMembersOnDefaultNetwork() + ? DEFAULT_NETWORK_YES : DEFAULT_NETWORK_NO; entry.metered = key.ident.isAnyMemberMetered() ? METERED_YES : METERED_NO; entry.roaming = key.ident.isAnyMemberRoaming() ? ROAMING_YES : ROAMING_NO; entry.rxBytes = historyEntry.rxBytes; @@ -516,6 +518,12 @@ public class NetworkStatsCollection implements FileRotator.Reader, FileRotator.W } } + /** + * Read legacy network summary statistics file format into the collection, + * See {@code NetworkStatsService#maybeUpgradeLegacyStatsLocked}. + * + * @deprecated + */ @Deprecated public void readLegacyNetwork(File file) throws IOException { final AtomicFile inputFile = new AtomicFile(file); @@ -555,6 +563,12 @@ public class NetworkStatsCollection implements FileRotator.Reader, FileRotator.W } } + /** + * Read legacy Uid statistics file format into the collection, + * See {@code NetworkStatsService#maybeUpgradeLegacyStatsLocked}. + * + * @deprecated + */ @Deprecated public void readLegacyUid(File file, boolean onlyTags) throws IOException { final AtomicFile inputFile = new AtomicFile(file); @@ -769,19 +783,19 @@ public class NetworkStatsCollection implements FileRotator.Reader, FileRotator.W public final int set; public final int tag; - private final int hashCode; + private final int mHashCode; - public Key(NetworkIdentitySet ident, int uid, int set, int tag) { + Key(NetworkIdentitySet ident, int uid, int set, int tag) { this.ident = ident; this.uid = uid; this.set = set; this.tag = tag; - hashCode = Objects.hash(ident, uid, set, tag); + mHashCode = Objects.hash(ident, uid, set, tag); } @Override public int hashCode() { - return hashCode; + return mHashCode; } @Override diff --git a/core/java/android/net/NetworkStatsHistory.aidl b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsHistory.aidl index 8b9069f8fa48..8b9069f8fa48 100644 --- a/core/java/android/net/NetworkStatsHistory.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsHistory.aidl diff --git a/core/java/android/net/NetworkStatsHistory.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsHistory.java index f41306301d42..a875e1ad45a3 100644 --- a/core/java/android/net/NetworkStatsHistory.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkStatsHistory.java @@ -526,6 +526,13 @@ public class NetworkStatsHistory implements Parcelable { /** * Return interpolated data usage across the requested range. Interpolates * across buckets, so values may be rounded slightly. + * + * <p>If the active bucket is not completed yet, it returns the proportional value of it + * based on its duration and the {@code end} param. + * + * @param start - start of the range, timestamp in milliseconds since the epoch. + * @param end - end of the range, timestamp in milliseconds since the epoch. + * @param recycle - entry instance for performance, could be null. */ @UnsupportedAppUsage public Entry getValues(long start, long end, Entry recycle) { @@ -535,6 +542,11 @@ public class NetworkStatsHistory implements Parcelable { /** * Return interpolated data usage across the requested range. Interpolates * across buckets, so values may be rounded slightly. + * + * @param start - start of the range, timestamp in milliseconds since the epoch. + * @param end - end of the range, timestamp in milliseconds since the epoch. + * @param now - current timestamp in milliseconds since the epoch (wall clock). + * @param recycle - entry instance for performance, could be null. */ @UnsupportedAppUsage public Entry getValues(long start, long end, long now, Entry recycle) { diff --git a/core/java/android/net/NetworkTemplate.java b/packages/ConnectivityT/framework-t/src/android/net/NetworkTemplate.java index c906a13bf41b..8b9c14df7dc8 100644 --- a/core/java/android/net/NetworkTemplate.java +++ b/packages/ConnectivityT/framework-t/src/android/net/NetworkTemplate.java @@ -44,16 +44,10 @@ import android.os.Parcelable; import android.telephony.Annotation.NetworkType; import android.telephony.TelephonyManager; import android.text.TextUtils; -import android.util.BackupUtils; -import android.util.Log; import com.android.internal.util.ArrayUtils; import com.android.net.module.util.NetworkIdentityUtils; -import java.io.ByteArrayOutputStream; -import java.io.DataInputStream; -import java.io.DataOutputStream; -import java.io.IOException; import java.util.Arrays; import java.util.Collection; import java.util.HashSet; @@ -69,19 +63,6 @@ import java.util.Objects; public class NetworkTemplate implements Parcelable { private static final String TAG = "NetworkTemplate"; - /** - * Initial Version of the backup serializer. - */ - public static final int BACKUP_VERSION_1_INIT = 1; - /** - * Version of the backup serializer that added carrier template support. - */ - public static final int BACKUP_VERSION_2_SUPPORT_CARRIER_TEMPLATE = 2; - /** - * Current Version of the Backup Serializer. - */ - private static final int BACKUP_VERSION = BACKUP_VERSION_2_SUPPORT_CARRIER_TEMPLATE; - public static final int MATCH_MOBILE = 1; public static final int MATCH_WIFI = 4; public static final int MATCH_ETHERNET = 5; @@ -849,58 +830,4 @@ public class NetworkTemplate implements Parcelable { return new NetworkTemplate[size]; } }; - - public byte[] getBytesForBackup() throws IOException { - ByteArrayOutputStream baos = new ByteArrayOutputStream(); - DataOutputStream out = new DataOutputStream(baos); - - if (!isPersistable()) { - Log.wtf(TAG, "Trying to backup non-persistable template: " + this); - } - - out.writeInt(BACKUP_VERSION); - - out.writeInt(mMatchRule); - BackupUtils.writeString(out, mSubscriberId); - BackupUtils.writeString(out, mNetworkId); - out.writeInt(mMetered); - out.writeInt(mSubscriberIdMatchRule); - - return baos.toByteArray(); - } - - public static NetworkTemplate getNetworkTemplateFromBackup(DataInputStream in) - throws IOException, BackupUtils.BadVersionException { - int version = in.readInt(); - if (version < BACKUP_VERSION_1_INIT || version > BACKUP_VERSION) { - throw new BackupUtils.BadVersionException("Unknown Backup Serialization Version"); - } - - int matchRule = in.readInt(); - String subscriberId = BackupUtils.readString(in); - String networkId = BackupUtils.readString(in); - - final int metered; - final int subscriberIdMatchRule; - if (version >= BACKUP_VERSION_2_SUPPORT_CARRIER_TEMPLATE) { - metered = in.readInt(); - subscriberIdMatchRule = in.readInt(); - } else { - // For backward compatibility, fill the missing filters from match rules. - metered = (matchRule == MATCH_MOBILE || matchRule == MATCH_MOBILE_WILDCARD - || matchRule == MATCH_CARRIER) ? METERED_YES : METERED_ALL; - subscriberIdMatchRule = SUBSCRIBER_ID_MATCH_RULE_EXACT; - } - - try { - return new NetworkTemplate(matchRule, - subscriberId, new String[] { subscriberId }, - networkId, metered, NetworkStats.ROAMING_ALL, - NetworkStats.DEFAULT_NETWORK_ALL, NetworkTemplate.NETWORK_TYPE_ALL, - NetworkTemplate.OEM_MANAGED_ALL, subscriberIdMatchRule); - } catch (IllegalArgumentException e) { - throw new BackupUtils.BadVersionException( - "Restored network template contains unknown match rule " + matchRule, e); - } - } } diff --git a/core/java/android/net/TrafficStats.java b/packages/ConnectivityT/framework-t/src/android/net/TrafficStats.java index fa650617f380..fa650617f380 100644 --- a/core/java/android/net/TrafficStats.java +++ b/packages/ConnectivityT/framework-t/src/android/net/TrafficStats.java diff --git a/core/java/android/net/UnderlyingNetworkInfo.aidl b/packages/ConnectivityT/framework-t/src/android/net/UnderlyingNetworkInfo.aidl index a56f2f40583b..a56f2f40583b 100644 --- a/core/java/android/net/UnderlyingNetworkInfo.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/UnderlyingNetworkInfo.aidl diff --git a/core/java/android/net/UnderlyingNetworkInfo.java b/packages/ConnectivityT/framework-t/src/android/net/UnderlyingNetworkInfo.java index 33f9375c03bf..33f9375c03bf 100644 --- a/core/java/android/net/UnderlyingNetworkInfo.java +++ b/packages/ConnectivityT/framework-t/src/android/net/UnderlyingNetworkInfo.java diff --git a/core/java/android/net/netstats/provider/INetworkStatsProvider.aidl b/packages/ConnectivityT/framework-t/src/android/net/netstats/provider/INetworkStatsProvider.aidl index 74c3ba44b69e..74c3ba44b69e 100644 --- a/core/java/android/net/netstats/provider/INetworkStatsProvider.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/netstats/provider/INetworkStatsProvider.aidl diff --git a/core/java/android/net/netstats/provider/INetworkStatsProviderCallback.aidl b/packages/ConnectivityT/framework-t/src/android/net/netstats/provider/INetworkStatsProviderCallback.aidl index 7eaa01e262fe..7eaa01e262fe 100644 --- a/core/java/android/net/netstats/provider/INetworkStatsProviderCallback.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/netstats/provider/INetworkStatsProviderCallback.aidl diff --git a/core/java/android/net/netstats/provider/NetworkStatsProvider.java b/packages/ConnectivityT/framework-t/src/android/net/netstats/provider/NetworkStatsProvider.java index 23fc06927ef9..23fc06927ef9 100644 --- a/core/java/android/net/netstats/provider/NetworkStatsProvider.java +++ b/packages/ConnectivityT/framework-t/src/android/net/netstats/provider/NetworkStatsProvider.java diff --git a/packages/Nsd/framework/src/android/net/nsd/INsdManager.aidl b/packages/ConnectivityT/framework-t/src/android/net/nsd/INsdManager.aidl index 89e9cdbd4445..89e9cdbd4445 100644 --- a/packages/Nsd/framework/src/android/net/nsd/INsdManager.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/nsd/INsdManager.aidl diff --git a/packages/Nsd/framework/src/android/net/nsd/INsdManagerCallback.aidl b/packages/ConnectivityT/framework-t/src/android/net/nsd/INsdManagerCallback.aidl index 1a262ec0e9dd..1a262ec0e9dd 100644 --- a/packages/Nsd/framework/src/android/net/nsd/INsdManagerCallback.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/nsd/INsdManagerCallback.aidl diff --git a/packages/Nsd/framework/src/android/net/nsd/INsdServiceConnector.aidl b/packages/ConnectivityT/framework-t/src/android/net/nsd/INsdServiceConnector.aidl index b06ae55b150e..b06ae55b150e 100644 --- a/packages/Nsd/framework/src/android/net/nsd/INsdServiceConnector.aidl +++ b/packages/ConnectivityT/framework-t/src/android/net/nsd/INsdServiceConnector.aidl diff --git a/packages/Nsd/framework/src/android/net/nsd/NsdManager.java b/packages/ConnectivityT/framework-t/src/android/net/nsd/NsdManager.java index 6c597e26e042..0f21e55b9f27 100644 --- a/packages/Nsd/framework/src/android/net/nsd/NsdManager.java +++ b/packages/ConnectivityT/framework-t/src/android/net/nsd/NsdManager.java @@ -16,10 +16,6 @@ package android.net.nsd; -import static com.android.internal.util.Preconditions.checkArgument; -import static com.android.internal.util.Preconditions.checkNotNull; -import static com.android.internal.util.Preconditions.checkStringNotEmpty; - import android.annotation.SdkConstant; import android.annotation.SdkConstant.SdkConstantType; import android.annotation.SystemService; @@ -32,11 +28,13 @@ import android.os.HandlerThread; import android.os.Looper; import android.os.Message; import android.os.RemoteException; +import android.text.TextUtils; import android.util.Log; import android.util.SparseArray; import com.android.internal.annotations.VisibleForTesting; -import com.android.internal.util.Protocol; + +import java.util.Objects; /** * The Network Service Discovery Manager class provides the API to discover services @@ -175,65 +173,63 @@ public final class NsdManager { */ public static final int NSD_STATE_ENABLED = 2; - private static final int BASE = Protocol.BASE_NSD_MANAGER; - /** @hide */ - public static final int DISCOVER_SERVICES = BASE + 1; + public static final int DISCOVER_SERVICES = 1; /** @hide */ - public static final int DISCOVER_SERVICES_STARTED = BASE + 2; + public static final int DISCOVER_SERVICES_STARTED = 2; /** @hide */ - public static final int DISCOVER_SERVICES_FAILED = BASE + 3; + public static final int DISCOVER_SERVICES_FAILED = 3; /** @hide */ - public static final int SERVICE_FOUND = BASE + 4; + public static final int SERVICE_FOUND = 4; /** @hide */ - public static final int SERVICE_LOST = BASE + 5; + public static final int SERVICE_LOST = 5; /** @hide */ - public static final int STOP_DISCOVERY = BASE + 6; + public static final int STOP_DISCOVERY = 6; /** @hide */ - public static final int STOP_DISCOVERY_FAILED = BASE + 7; + public static final int STOP_DISCOVERY_FAILED = 7; /** @hide */ - public static final int STOP_DISCOVERY_SUCCEEDED = BASE + 8; + public static final int STOP_DISCOVERY_SUCCEEDED = 8; /** @hide */ - public static final int REGISTER_SERVICE = BASE + 9; + public static final int REGISTER_SERVICE = 9; /** @hide */ - public static final int REGISTER_SERVICE_FAILED = BASE + 10; + public static final int REGISTER_SERVICE_FAILED = 10; /** @hide */ - public static final int REGISTER_SERVICE_SUCCEEDED = BASE + 11; + public static final int REGISTER_SERVICE_SUCCEEDED = 11; /** @hide */ - public static final int UNREGISTER_SERVICE = BASE + 12; + public static final int UNREGISTER_SERVICE = 12; /** @hide */ - public static final int UNREGISTER_SERVICE_FAILED = BASE + 13; + public static final int UNREGISTER_SERVICE_FAILED = 13; /** @hide */ - public static final int UNREGISTER_SERVICE_SUCCEEDED = BASE + 14; + public static final int UNREGISTER_SERVICE_SUCCEEDED = 14; /** @hide */ - public static final int RESOLVE_SERVICE = BASE + 18; + public static final int RESOLVE_SERVICE = 15; /** @hide */ - public static final int RESOLVE_SERVICE_FAILED = BASE + 19; + public static final int RESOLVE_SERVICE_FAILED = 16; /** @hide */ - public static final int RESOLVE_SERVICE_SUCCEEDED = BASE + 20; + public static final int RESOLVE_SERVICE_SUCCEEDED = 17; /** @hide */ - public static final int DAEMON_CLEANUP = BASE + 21; + public static final int DAEMON_CLEANUP = 18; /** @hide */ - public static final int DAEMON_STARTUP = BASE + 22; + public static final int DAEMON_STARTUP = 19; /** @hide */ - public static final int ENABLE = BASE + 24; + public static final int ENABLE = 20; /** @hide */ - public static final int DISABLE = BASE + 25; + public static final int DISABLE = 21; /** @hide */ - public static final int NATIVE_DAEMON_EVENT = BASE + 26; + public static final int NATIVE_DAEMON_EVENT = 22; /** @hide */ - public static final int REGISTER_CLIENT = BASE + 27; + public static final int REGISTER_CLIENT = 23; /** @hide */ - public static final int UNREGISTER_CLIENT = BASE + 28; + public static final int UNREGISTER_CLIENT = 24; /** Dns based service discovery protocol */ public static final int PROTOCOL_DNS_SD = 0x0001; @@ -550,7 +546,9 @@ public final class NsdManager { final int key; synchronized (mMapLock) { int valueIndex = mListenerMap.indexOfValue(listener); - checkArgument(valueIndex == -1, "listener already in use"); + if (valueIndex != -1) { + throw new IllegalArgumentException("listener already in use"); + } key = nextListenerKey(); mListenerMap.put(key, listener); mServiceMap.put(key, s); @@ -569,7 +567,9 @@ public final class NsdManager { checkListener(listener); synchronized (mMapLock) { int valueIndex = mListenerMap.indexOfValue(listener); - checkArgument(valueIndex != -1, "listener not registered"); + if (valueIndex == -1) { + throw new IllegalArgumentException("listener not registered"); + } return mListenerMap.keyAt(valueIndex); } } @@ -598,7 +598,9 @@ public final class NsdManager { */ public void registerService(NsdServiceInfo serviceInfo, int protocolType, RegistrationListener listener) { - checkArgument(serviceInfo.getPort() > 0, "Invalid port number"); + if (serviceInfo.getPort() <= 0) { + throw new IllegalArgumentException("Invalid port number"); + } checkServiceInfo(serviceInfo); checkProtocol(protocolType); int key = putListener(listener, serviceInfo); @@ -660,7 +662,9 @@ public final class NsdManager { * Cannot be null. Cannot be in use for an active service discovery. */ public void discoverServices(String serviceType, int protocolType, DiscoveryListener listener) { - checkStringNotEmpty(serviceType, "Service type cannot be empty"); + if (TextUtils.isEmpty(serviceType)) { + throw new IllegalArgumentException("Service type cannot be empty"); + } checkProtocol(protocolType); NsdServiceInfo s = new NsdServiceInfo(); @@ -719,16 +723,22 @@ public final class NsdManager { } private static void checkListener(Object listener) { - checkNotNull(listener, "listener cannot be null"); + Objects.requireNonNull(listener, "listener cannot be null"); } private static void checkProtocol(int protocolType) { - checkArgument(protocolType == PROTOCOL_DNS_SD, "Unsupported protocol"); + if (protocolType != PROTOCOL_DNS_SD) { + throw new IllegalArgumentException("Unsupported protocol"); + } } private static void checkServiceInfo(NsdServiceInfo serviceInfo) { - checkNotNull(serviceInfo, "NsdServiceInfo cannot be null"); - checkStringNotEmpty(serviceInfo.getServiceName(), "Service name cannot be empty"); - checkStringNotEmpty(serviceInfo.getServiceType(), "Service type cannot be empty"); + Objects.requireNonNull(serviceInfo, "NsdServiceInfo cannot be null"); + if (TextUtils.isEmpty(serviceInfo.getServiceName())) { + throw new IllegalArgumentException("Service name cannot be empty"); + } + if (TextUtils.isEmpty(serviceInfo.getServiceType())) { + throw new IllegalArgumentException("Service type cannot be empty"); + } } } diff --git a/packages/Nsd/framework/src/android/net/nsd/NsdServiceInfo.java b/packages/ConnectivityT/framework-t/src/android/net/nsd/NsdServiceInfo.java index 0946499f164f..0946499f164f 100644 --- a/packages/Nsd/framework/src/android/net/nsd/NsdServiceInfo.java +++ b/packages/ConnectivityT/framework-t/src/android/net/nsd/NsdServiceInfo.java diff --git a/packages/Nsd/framework/Android.bp b/packages/ConnectivityT/service/Android.bp index 2363a9f8d4a3..7b8817692b74 100644 --- a/packages/Nsd/framework/Android.bp +++ b/packages/ConnectivityT/service/Android.bp @@ -19,11 +19,13 @@ package { default_applicable_licenses: ["Android-Apache-2.0"], } +// NetworkStats related libraries. + filegroup { - name: "framework-connectivity-nsd-internal-sources", + name: "services.connectivity-netstats-sources", srcs: [ - "src/**/*.java", - "src/**/*.aidl", + "src/com/android/server/net/NetworkIdentity*.java", + "src/com/android/server/net/NetworkStats*.java", ], path: "src", visibility: [ @@ -31,24 +33,43 @@ filegroup { ], } +// Nsd related libraries. + filegroup { - name: "framework-connectivity-nsd-aidl-export-sources", + name: "services.connectivity-nsd-sources", srcs: [ - "aidl-export/**/*.aidl", + "src/com/android/server/INativeDaemon*.java", + "src/com/android/server/NativeDaemon*.java", + "src/com/android/server/Nsd*.java", ], - path: "aidl-export", + path: "src", visibility: [ "//visibility:private", ], } +// IpSec related libraries. + filegroup { - name: "framework-connectivity-nsd-sources", + name: "services.connectivity-ipsec-sources", srcs: [ - ":framework-connectivity-nsd-internal-sources", - ":framework-connectivity-nsd-aidl-export-sources", + "src/com/android/server/IpSecService.java", ], + path: "src", visibility: [ - "//frameworks/base", + "//visibility:private", ], } + +// Connectivity-T common libraries. + +filegroup { + name: "services.connectivity-tiramisu-sources", + srcs: [ + ":services.connectivity-ipsec-sources", + ":services.connectivity-netstats-sources", + ":services.connectivity-nsd-sources", + ], + path: "src", + visibility: ["//frameworks/base/services/core"], +} diff --git a/packages/Nsd/service/src/com/android/server/INativeDaemonConnectorCallbacks.java b/packages/ConnectivityT/service/src/com/android/server/INativeDaemonConnectorCallbacks.java index 0cf9dcde012d..0cf9dcde012d 100644 --- a/packages/Nsd/service/src/com/android/server/INativeDaemonConnectorCallbacks.java +++ b/packages/ConnectivityT/service/src/com/android/server/INativeDaemonConnectorCallbacks.java diff --git a/services/core/java/com/android/server/IpSecService.java b/packages/ConnectivityT/service/src/com/android/server/IpSecService.java index aeb814327e66..aeb814327e66 100644 --- a/services/core/java/com/android/server/IpSecService.java +++ b/packages/ConnectivityT/service/src/com/android/server/IpSecService.java diff --git a/packages/Nsd/service/src/com/android/server/NativeDaemonConnector.java b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonConnector.java index ec8d7798e17e..ec8d7798e17e 100644 --- a/packages/Nsd/service/src/com/android/server/NativeDaemonConnector.java +++ b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonConnector.java diff --git a/packages/Nsd/service/src/com/android/server/NativeDaemonConnectorException.java b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonConnectorException.java index 4d8881c68324..4d8881c68324 100644 --- a/packages/Nsd/service/src/com/android/server/NativeDaemonConnectorException.java +++ b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonConnectorException.java diff --git a/packages/Nsd/service/src/com/android/server/NativeDaemonEvent.java b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonEvent.java index 568369434629..568369434629 100644 --- a/packages/Nsd/service/src/com/android/server/NativeDaemonEvent.java +++ b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonEvent.java diff --git a/packages/Nsd/service/src/com/android/server/NativeDaemonTimeoutException.java b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonTimeoutException.java index 658f7d6264eb..658f7d6264eb 100644 --- a/packages/Nsd/service/src/com/android/server/NativeDaemonTimeoutException.java +++ b/packages/ConnectivityT/service/src/com/android/server/NativeDaemonTimeoutException.java diff --git a/packages/Nsd/service/src/com/android/server/NsdService.java b/packages/ConnectivityT/service/src/com/android/server/NsdService.java index 497107dbf989..497107dbf989 100644 --- a/packages/Nsd/service/src/com/android/server/NsdService.java +++ b/packages/ConnectivityT/service/src/com/android/server/NsdService.java diff --git a/services/core/java/com/android/server/net/NetworkStatsFactory.java b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsFactory.java index e6433db11d7b..e6433db11d7b 100644 --- a/services/core/java/com/android/server/net/NetworkStatsFactory.java +++ b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsFactory.java diff --git a/services/core/java/com/android/server/net/NetworkStatsManagerInternal.java b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsManagerInternal.java index 0e9a9da6804b..0e9a9da6804b 100644 --- a/services/core/java/com/android/server/net/NetworkStatsManagerInternal.java +++ b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsManagerInternal.java diff --git a/services/core/java/com/android/server/net/NetworkStatsObservers.java b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsObservers.java index 2564daeaa1c0..1a0866d2f9c5 100644 --- a/services/core/java/com/android/server/net/NetworkStatsObservers.java +++ b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsObservers.java @@ -22,7 +22,10 @@ import static com.android.internal.util.Preconditions.checkArgument; import android.app.usage.NetworkStatsManager; import android.net.DataUsageRequest; +import android.net.NetworkIdentitySet; import android.net.NetworkStats; +import android.net.NetworkStatsAccess; +import android.net.NetworkStatsCollection; import android.net.NetworkStatsHistory; import android.net.NetworkTemplate; import android.os.Bundle; diff --git a/services/core/java/com/android/server/net/NetworkStatsRecorder.java b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsRecorder.java index 978ae87d39d5..5e27c776ccb0 100644 --- a/services/core/java/com/android/server/net/NetworkStatsRecorder.java +++ b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsRecorder.java @@ -21,8 +21,11 @@ import static android.net.TrafficStats.KB_IN_BYTES; import static android.net.TrafficStats.MB_IN_BYTES; import static android.text.format.DateUtils.YEAR_IN_MILLIS; +import android.net.NetworkIdentitySet; import android.net.NetworkStats; import android.net.NetworkStats.NonMonotonicObserver; +import android.net.NetworkStatsAccess; +import android.net.NetworkStatsCollection; import android.net.NetworkStatsHistory; import android.net.NetworkTemplate; import android.net.TrafficStats; diff --git a/services/core/java/com/android/server/net/NetworkStatsService.java b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsService.java index c876d411fac1..2beca73ecd72 100644 --- a/services/core/java/com/android/server/net/NetworkStatsService.java +++ b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsService.java @@ -96,11 +96,14 @@ import android.net.INetworkStatsSession; import android.net.Network; import android.net.NetworkCapabilities; import android.net.NetworkIdentity; +import android.net.NetworkIdentitySet; import android.net.NetworkSpecifier; import android.net.NetworkStack; import android.net.NetworkStateSnapshot; import android.net.NetworkStats; import android.net.NetworkStats.NonMonotonicObserver; +import android.net.NetworkStatsAccess; +import android.net.NetworkStatsCollection; import android.net.NetworkStatsHistory; import android.net.NetworkTemplate; import android.net.TelephonyNetworkSpecifier; diff --git a/services/core/java/com/android/server/net/NetworkStatsSubscriptionsMonitor.java b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsSubscriptionsMonitor.java index 5646c752fc90..5646c752fc90 100644 --- a/services/core/java/com/android/server/net/NetworkStatsSubscriptionsMonitor.java +++ b/packages/ConnectivityT/service/src/com/android/server/net/NetworkStatsSubscriptionsMonitor.java diff --git a/packages/Nsd/tests/unit/java/com/android/server/NativeDaemonConnectorTest.java b/packages/ConnectivityT/tests/unit/java/com/android/server/NativeDaemonConnectorTest.java index e2253a2151b0..e2253a2151b0 100644 --- a/packages/Nsd/tests/unit/java/com/android/server/NativeDaemonConnectorTest.java +++ b/packages/ConnectivityT/tests/unit/java/com/android/server/NativeDaemonConnectorTest.java diff --git a/packages/Nsd/OWNERS b/packages/Nsd/OWNERS deleted file mode 100644 index 4862377852ac..000000000000 --- a/packages/Nsd/OWNERS +++ /dev/null @@ -1 +0,0 @@ -file:platform/packages/modules/Connectivity:master:/OWNERS_core_networking
\ No newline at end of file diff --git a/packages/Nsd/service/Android.bp b/packages/Nsd/service/Android.bp deleted file mode 100644 index 529f58d130ed..000000000000 --- a/packages/Nsd/service/Android.bp +++ /dev/null @@ -1,31 +0,0 @@ -// -// Copyright (C) 2021 The Android Open Source Project -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// - -package { - // See: http://go/android-license-faq - default_applicable_licenses: ["Android-Apache-2.0"], -} - -filegroup { - name: "services.connectivity-nsd-sources", - srcs: [ - "src/**/*.java", - ], - path: "src", - visibility: [ - "//frameworks/base/services/core", - ], -} diff --git a/packages/Shell/AndroidManifest.xml b/packages/Shell/AndroidManifest.xml index 87d50f29061f..1f1e24ac8b1e 100644 --- a/packages/Shell/AndroidManifest.xml +++ b/packages/Shell/AndroidManifest.xml @@ -165,6 +165,7 @@ <uses-permission android:name="com.android.permission.USE_INSTALLER_V2" /> <uses-permission android:name="android.permission.INSTALL_TEST_ONLY_PACKAGE" /> <uses-permission android:name="com.android.permission.USE_SYSTEM_DATA_LOADERS" /> + <uses-permission android:name="android.permission.PACKAGE_VERIFICATION_AGENT" /> <uses-permission android:name="android.permission.MOVE_PACKAGE" /> <uses-permission android:name="android.permission.KEEP_UNINSTALLED_PACKAGES" /> <uses-permission android:name="android.permission.CLEAR_APP_USER_DATA" /> diff --git a/packages/SystemUI/tests/AndroidTest.xml b/packages/SystemUI/tests/AndroidTest.xml index fc353a1945a6..5ffd3008c6cd 100644 --- a/packages/SystemUI/tests/AndroidTest.xml +++ b/packages/SystemUI/tests/AndroidTest.xml @@ -18,12 +18,17 @@ <option name="test-file-name" value="SystemUITests.apk" /> </target_preparer> + <target_preparer class="com.android.tradefed.targetprep.RootTargetPreparer"> + <option name="force-root" value="true" /> + </target_preparer> + <option name="test-suite-tag" value="apct" /> <option name="test-suite-tag" value="framework-base-presubmit" /> <option name="test-tag" value="SystemUITests" /> <test class="com.android.tradefed.testtype.AndroidJUnitTest" > <option name="package" value="com.android.systemui.tests" /> <option name="runner" value="android.testing.TestableInstrumentation" /> + <option name="test-filter-dir" value="/data/data/com.android.systemui.tests" /> <option name="hidden-api-checks" value="false"/> </test> </configuration> diff --git a/services/core/Android.bp b/services/core/Android.bp index d65969c11357..1dda14ca0db5 100644 --- a/services/core/Android.bp +++ b/services/core/Android.bp @@ -111,7 +111,7 @@ java_library_static { "java/com/android/server/am/EventLogTags.logtags", "java/com/android/server/wm/EventLogTags.logtags", "java/com/android/server/policy/EventLogTags.logtags", - ":services.connectivity-nsd-sources", + ":services.connectivity-tiramisu-sources", ], libs: [ diff --git a/services/core/java/com/android/server/BluetoothAirplaneModeListener.java b/services/core/java/com/android/server/BluetoothAirplaneModeListener.java index 263ff189a288..380b1f37b981 100644 --- a/services/core/java/com/android/server/BluetoothAirplaneModeListener.java +++ b/services/core/java/com/android/server/BluetoothAirplaneModeListener.java @@ -112,9 +112,9 @@ class BluetoothAirplaneModeListener { void handleAirplaneModeChange() { if (shouldSkipAirplaneModeChange()) { Log.i(TAG, "Ignore airplane mode change"); - // We have to store Bluetooth state here, so if user turns off Bluetooth - // after airplane mode is turned on, we don't forget to turn on Bluetooth - // when airplane mode turns off. + // Airplane mode enabled when Bluetooth is being used for audio/headering aid. + // Bluetooth is not disabled in such case, only state is changed to + // BLUETOOTH_ON_AIRPLANE mode. mAirplaneHelper.setSettingsInt(Settings.Global.BLUETOOTH_ON, BluetoothManagerService.BLUETOOTH_ON_AIRPLANE); if (shouldPopToast()) { diff --git a/services/core/java/com/android/server/OWNERS b/services/core/java/com/android/server/OWNERS index b6413773046f..71b463a4db8c 100644 --- a/services/core/java/com/android/server/OWNERS +++ b/services/core/java/com/android/server/OWNERS @@ -25,13 +25,14 @@ per-file *Battery* = file:/BATTERY_STATS_OWNERS per-file *Binder* = file:/core/java/com/android/internal/os/BINDER_OWNERS per-file *Bluetooth* = file:/core/java/android/bluetooth/OWNERS per-file *Gnss* = file:/services/core/java/com/android/server/location/OWNERS +per-file **IpSec* = file:/services/core/java/com/android/server/net/OWNERS +per-file **IpSec* = file:/services/core/java/com/android/server/vcn/OWNERS per-file *Location* = file:/services/core/java/com/android/server/location/OWNERS per-file *Network* = file:/services/core/java/com/android/server/net/OWNERS per-file *Storage* = file:/core/java/android/os/storage/OWNERS per-file *TimeUpdate* = file:/core/java/android/app/timezone/OWNERS per-file DynamicSystemService.java = file:/packages/DynamicSystemInstallationService/OWNERS per-file GestureLauncherService.java = file:platform/packages/apps/EmergencyInfo:/OWNERS -per-file IpSecService.java = file:/services/core/java/com/android/server/net/OWNERS per-file MmsServiceBroker.java = file:/telephony/OWNERS per-file NetIdManager.java = file:/services/core/java/com/android/server/net/OWNERS per-file PackageWatchdog.java, RescueParty.java = file:/services/core/java/com/android/server/rollback/OWNERS diff --git a/services/core/java/com/android/server/SystemServiceManager.java b/services/core/java/com/android/server/SystemServiceManager.java index cb6e73af56ac..3cc8e7672557 100644 --- a/services/core/java/com/android/server/SystemServiceManager.java +++ b/services/core/java/com/android/server/SystemServiceManager.java @@ -21,18 +21,16 @@ import android.annotation.Nullable; import android.annotation.UserIdInt; import android.content.Context; import android.content.pm.UserInfo; -import android.os.Build; import android.os.Environment; import android.os.SystemClock; import android.os.Trace; -import android.util.ArrayMap; import android.util.EventLog; import android.util.IndentingPrintWriter; import android.util.Slog; import android.util.SparseArray; import com.android.internal.annotations.GuardedBy; -import com.android.internal.os.ClassLoaderFactory; +import com.android.internal.os.SystemServerClassLoaderFactory; import com.android.internal.util.Preconditions; import com.android.server.SystemService.TargetUser; import com.android.server.am.EventLogTags; @@ -77,9 +75,6 @@ public final class SystemServiceManager implements Dumpable { // Services that should receive lifecycle events. private final ArrayList<SystemService> mServices = new ArrayList<SystemService>(); - // Map of paths to PathClassLoader, so we don't load the same path multiple times. - private final ArrayMap<String, PathClassLoader> mLoadedPaths = new ArrayMap<>(); - private int mCurrentPhase = -1; private UserManagerInternal mUserManagerInternal; @@ -119,16 +114,8 @@ public final class SystemServiceManager implements Dumpable { * @return The service instance. */ public SystemService startServiceFromJar(String className, String path) { - PathClassLoader pathClassLoader = mLoadedPaths.get(path); - if (pathClassLoader == null) { - // NB: the parent class loader should always be the system server class loader. - // Changing it has implications that require discussion with the mainline team. - pathClassLoader = (PathClassLoader) ClassLoaderFactory.createClassLoader( - path, null /* librarySearchPath */, null /* libraryPermittedPath */, - this.getClass().getClassLoader(), Build.VERSION.SDK_INT, - true /* isNamespaceShared */, null /* classLoaderName */); - mLoadedPaths.put(path, pathClassLoader); - } + PathClassLoader pathClassLoader = SystemServerClassLoaderFactory.getOrCreateClassLoader( + path, this.getClass().getClassLoader()); final Class<SystemService> serviceClass = loadClassFromLoader(className, pathClassLoader); return startService(serviceClass); } diff --git a/services/core/java/com/android/server/am/ProcessList.java b/services/core/java/com/android/server/am/ProcessList.java index b77270f5963b..6c84ca4d9251 100644 --- a/services/core/java/com/android/server/am/ProcessList.java +++ b/services/core/java/com/android/server/am/ProcessList.java @@ -374,6 +374,16 @@ public final class ProcessList { private static final long NATIVE_HEAP_POINTER_TAGGING = 135754954; // This is a bug id. /** + * Native heap allocations in AppZygote process and its descendants will now have a + * non-zero tag in the most significant byte. + * @see <a href="https://source.android.com/devices/tech/debug/tagged-pointers">Tagged + * Pointers</a> + */ + @ChangeId + @EnabledAfter(targetSdkVersion = Build.VERSION_CODES.S) + private static final long NATIVE_HEAP_POINTER_TAGGING_APP_ZYGOTE = 207557677; + + /** * Enable asynchronous (ASYNC) memory tag checking in this process. This * flag will only have an effect on hardware supporting the ARM Memory * Tagging Extension (MTE). @@ -1738,6 +1748,16 @@ public final class ProcessList { return level; } + private int decideTaggingLevelForAppZygote(ProcessRecord app) { + int level = decideTaggingLevel(app); + // TBI ("fake" pointer tagging) in AppZygote is controlled by a separate compat feature. + if (!mPlatformCompat.isChangeEnabled(NATIVE_HEAP_POINTER_TAGGING_APP_ZYGOTE, app.info) + && level == Zygote.MEMORY_TAG_LEVEL_TBI) { + level = Zygote.MEMORY_TAG_LEVEL_NONE; + } + return level; + } + private int decideGwpAsanLevel(ProcessRecord app) { // Look at the process attribute first. if (app.processInfo != null @@ -2238,7 +2258,8 @@ public final class ProcessList { // not the calling one. appInfo.packageName = app.getHostingRecord().getDefiningPackageName(); appInfo.uid = uid; - appZygote = new AppZygote(appInfo, uid, firstUid, lastUid); + int runtimeFlags = decideTaggingLevelForAppZygote(app); + appZygote = new AppZygote(appInfo, uid, firstUid, lastUid, runtimeFlags); mAppZygotes.put(app.info.processName, uid, appZygote); zygoteProcessList = new ArrayList<ProcessRecord>(); mAppZygoteProcesses.put(appZygote, zygoteProcessList); diff --git a/services/core/java/com/android/server/biometrics/OWNERS b/services/core/java/com/android/server/biometrics/OWNERS index 4eac97286880..f05f40353e30 100644 --- a/services/core/java/com/android/server/biometrics/OWNERS +++ b/services/core/java/com/android/server/biometrics/OWNERS @@ -6,3 +6,4 @@ curtislb@google.com ilyamaty@google.com joshmccloskey@google.com jbolinger@google.com +graciecheng@google.com diff --git a/services/core/java/com/android/server/vcn/routeselection/NetworkPriorityClassifier.java b/services/core/java/com/android/server/vcn/routeselection/NetworkPriorityClassifier.java index 7b26fe0370c9..45769575111f 100644 --- a/services/core/java/com/android/server/vcn/routeselection/NetworkPriorityClassifier.java +++ b/services/core/java/com/android/server/vcn/routeselection/NetworkPriorityClassifier.java @@ -226,9 +226,9 @@ class NetworkPriorityClassifier { .getSystemService(TelephonyManager.class) .createForSubscriptionId(subId); - if (!networkPriority.getAllowedPlmnIds().isEmpty()) { + if (!networkPriority.getAllowedOperatorPlmnIds().isEmpty()) { final String plmnId = subIdSpecificTelephonyMgr.getNetworkOperator(); - if (!networkPriority.getAllowedPlmnIds().contains(plmnId)) { + if (!networkPriority.getAllowedOperatorPlmnIds().contains(plmnId)) { return false; } } diff --git a/services/tests/servicestests/src/com/android/server/biometrics/OWNERS b/services/tests/servicestests/src/com/android/server/biometrics/OWNERS index 8765c9a64b77..6a2192a2c7fb 100644 --- a/services/tests/servicestests/src/com/android/server/biometrics/OWNERS +++ b/services/tests/servicestests/src/com/android/server/biometrics/OWNERS @@ -1,7 +1 @@ -set noparent - -kchyn@google.com -jaggies@google.com -curtislb@google.com -ilyamaty@google.com -joshmccloskey@google.com +include /services/core/java/com/android/server/biometrics/OWNERS diff --git a/telecomm/java/android/telecom/Connection.java b/telecomm/java/android/telecom/Connection.java index d06fe45a104c..2b855e92c549 100644 --- a/telecomm/java/android/telecom/Connection.java +++ b/telecomm/java/android/telecom/Connection.java @@ -822,6 +822,17 @@ public abstract class Connection extends Conferenceable { "android.telecom.extra.AUDIO_CODEC_BANDWIDTH_KHZ"; /** + * Last known cell identity key to be used to fill geo location header in case of an emergency + * call. This entry will not be filled if call is not identified as an emergency call. + * {@link Connection}. Only provided to the {@link ConnectionService} for the purpose + * of placing an emergency call; will not be present in the {@link InCallService} layer. + * The {@link ConnectionService}'s implementation will be logged for fine location access + * when an outgoing call is placed in this case. + */ + public static final String EXTRA_LAST_KNOWN_CELL_IDENTITY = + "android.telecom.extra.LAST_KNOWN_CELL_IDENTITY"; + + /** * Boolean connection extra key used to indicate whether device to device communication is * available for the current call. * @hide diff --git a/telephony/common/com/android/internal/telephony/TelephonyPermissions.java b/telephony/common/com/android/internal/telephony/TelephonyPermissions.java index ce4363f66d1c..fcc23a924d85 100644 --- a/telephony/common/com/android/internal/telephony/TelephonyPermissions.java +++ b/telephony/common/com/android/internal/telephony/TelephonyPermissions.java @@ -565,6 +565,17 @@ public final class TelephonyPermissions { } /** + * Check if the caller (or self, if not processing an IPC) has ACCESS_LAST_KNOWN_CELL_ID + * permission + * + * @return true if caller has ACCESS_LAST_KNOWN_CELL_ID permission else false. + */ + public static boolean checkLastKnownCellIdAccessPermission(Context context) { + return context.checkCallingOrSelfPermission("android.permission.ACCESS_LAST_KNOWN_CELL_ID") + == PackageManager.PERMISSION_GRANTED; + } + + /** * Ensure the caller (or self, if not processing an IPC) has * {@link android.Manifest.permission#READ_PHONE_STATE} or carrier privileges. * diff --git a/telephony/java/android/telephony/CarrierConfigManager.java b/telephony/java/android/telephony/CarrierConfigManager.java index 5ffe45f8c489..d3fc033e1b1d 100644 --- a/telephony/java/android/telephony/CarrierConfigManager.java +++ b/telephony/java/android/telephony/CarrierConfigManager.java @@ -5821,6 +5821,7 @@ public class CarrierConfigManager { sDefaults.putInt( KEY_OPPORTUNISTIC_TIME_TO_SCAN_AFTER_CAPABILITY_SWITCH_TO_PRIMARY_LONG, 120000); + sDefaults.putAll(ImsServiceEntitlement.getDefaults()); sDefaults.putAll(Gps.getDefaults()); sDefaults.putIntArray(KEY_CDMA_ENHANCED_ROAMING_INDICATOR_FOR_HOME_NETWORK_INT_ARRAY, new int[] { diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java index 453547c49498..a2efc962ed9c 100644 --- a/telephony/java/android/telephony/TelephonyManager.java +++ b/telephony/java/android/telephony/TelephonyManager.java @@ -15805,4 +15805,31 @@ public class TelephonyManager { ex.rethrowAsRuntimeException(); } } + + /** + * Get last known cell identity. + * Require {@link android.Manifest.permission#ACCESS_FINE_LOCATION} and + * com.android.phone.permission.ACCESS_LAST_KNOWN_CELL_ID, otherwise throws SecurityException. + * If there is current registered network this value will be same as the registered cell + * identity. If the device goes out of service the previous cell identity is cached and + * will be returned. If the cache age of the Cell identity is more than 24 hours + * it will be cleared and null will be returned. + * @return last known cell identity {@CellIdentity}. + * @hide + */ + @RequiresPermission(allOf = {Manifest.permission.ACCESS_FINE_LOCATION, + "com.android.phone.permission.ACCESS_LAST_KNOWN_CELL_ID"}) + public @Nullable CellIdentity getLastKnownCellIdentity() { + try { + ITelephony telephony = getITelephony(); + if (telephony == null) { + throw new IllegalStateException("telephony service is null."); + } + return telephony.getLastKnownCellIdentity(getSubId(), getOpPackageName(), + getAttributionTag()); + } catch (RemoteException ex) { + ex.rethrowAsRuntimeException(); + } + return null; + } } diff --git a/telephony/java/android/telephony/ims/DelegateRegistrationState.java b/telephony/java/android/telephony/ims/DelegateRegistrationState.java index c00c741a0d60..c2c9497cef3d 100644 --- a/telephony/java/android/telephony/ims/DelegateRegistrationState.java +++ b/telephony/java/android/telephony/ims/DelegateRegistrationState.java @@ -97,7 +97,24 @@ public final class DelegateRegistrationState implements Parcelable { */ public static final int DEREGISTERING_REASON_DESTROY_PENDING = 6; - /** @hide */ + /** + * This feature tag is deregistering because the PDN that the IMS registration is on + * is being torn down. + * <p> + * All open SIP Dialogs associated with this feature tag must be closed + * using {@link SipDelegateConnection#cleanupSession(String)} before this operation can proceed. + */ + public static final int DEREGISTERING_REASON_LOSING_PDN = 7; + + /** + * This feature tag is deregistering because of an unspecified reason. + * <p> + * All open SIP Dialogs associated with this feature tag must be closed + * using {@link SipDelegateConnection#cleanupSession(String)} before this operation can proceed. + */ + public static final int DEREGISTERING_REASON_UNSPECIFIED = 8; + +/** @hide */ @Retention(RetentionPolicy.SOURCE) @IntDef(prefix = "DEREGISTERED_REASON_", value = { DEREGISTERED_REASON_UNKNOWN, @@ -113,10 +130,13 @@ public final class DelegateRegistrationState implements Parcelable { DEREGISTERING_REASON_PDN_CHANGE, DEREGISTERING_REASON_PROVISIONING_CHANGE, DEREGISTERING_REASON_FEATURE_TAGS_CHANGING, - DEREGISTERING_REASON_DESTROY_PENDING + DEREGISTERING_REASON_DESTROY_PENDING, + DEREGISTERING_REASON_LOSING_PDN, + DEREGISTERING_REASON_UNSPECIFIED }) public @interface DeregisteringReason {} + private ArraySet<String> mRegisteringTags = new ArraySet<>(); private ArraySet<String> mRegisteredTags = new ArraySet<>(); private final ArraySet<FeatureTagState> mDeregisteringTags = new ArraySet<>(); private final ArraySet<FeatureTagState> mDeregisteredTags = new ArraySet<>(); @@ -134,6 +154,20 @@ public final class DelegateRegistrationState implements Parcelable { } /** + * Add the set of feature tags that are associated with this SipDelegate and + * the IMS stack is actively trying to register on the carrier network. + * + * The feature tags will either move to the registered or deregistered state + * depending on the result of the registration. + * @param featureTags The IMS media feature tags that are in the progress of registering. + * @return The in-progress Builder instance for RegistrationState. ] + */ + public @NonNull Builder addRegisteringFeatureTags(@NonNull Set<String> featureTags) { + mState.mRegisteringTags.addAll(featureTags); + return this; + } + + /** * Add a feature tag that is currently included in the current network IMS Registration. * @param featureTag The IMS media feature tag included in the current IMS registration. * @return The in-progress Builder instance for RegistrationState. @@ -209,6 +243,17 @@ public final class DelegateRegistrationState implements Parcelable { mRegisteredTags = (ArraySet<String>) source.readArraySet(null); readStateFromParcel(source, mDeregisteringTags); readStateFromParcel(source, mDeregisteredTags); + mRegisteringTags = (ArraySet<String>) source.readArraySet(null); + } + + /** + * Get the feature tags that are associated with this SipDelegate that the IMS stack is actively + * trying to register on the carrier network. + * @return A Set of feature tags associated with this SipDelegate that the IMS service is + * currently trying to register on the carrier network. + */ + public @NonNull Set<String> getRegisteringFeatureTags() { + return new ArraySet<>(mRegisteringTags); } /** @@ -286,6 +331,7 @@ public final class DelegateRegistrationState implements Parcelable { dest.writeArraySet(mRegisteredTags); writeStateToParcel(dest, mDeregisteringTags); writeStateToParcel(dest, mDeregisteredTags); + dest.writeArraySet(mRegisteringTags); } private void writeStateToParcel(Parcel dest, Set<FeatureTagState> state) { @@ -311,19 +357,22 @@ public final class DelegateRegistrationState implements Parcelable { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; DelegateRegistrationState that = (DelegateRegistrationState) o; - return mRegisteredTags.equals(that.mRegisteredTags) + return mRegisteringTags.equals(that.mRegisteringTags) + && mRegisteredTags.equals(that.mRegisteredTags) && mDeregisteringTags.equals(that.mDeregisteringTags) && mDeregisteredTags.equals(that.mDeregisteredTags); } @Override public int hashCode() { - return Objects.hash(mRegisteredTags, mDeregisteringTags, mDeregisteredTags); + return Objects.hash(mRegisteringTags, mRegisteredTags, + mDeregisteringTags, mDeregisteredTags); } @Override public String toString() { return "DelegateRegistrationState{ registered={" + mRegisteredTags + + "}, registering={" + mRegisteringTags + "}, deregistering={" + mDeregisteringTags + "}, deregistered={" + mDeregisteredTags + "}}"; } diff --git a/telephony/java/com/android/internal/telephony/ITelephony.aidl b/telephony/java/com/android/internal/telephony/ITelephony.aidl index 6b33a6894365..2df5f53147bc 100644 --- a/telephony/java/com/android/internal/telephony/ITelephony.aidl +++ b/telephony/java/com/android/internal/telephony/ITelephony.aidl @@ -2509,4 +2509,13 @@ interface ITelephony { * Unregister an IMS connection state callback */ void unregisterImsStateCallback(in IImsStateCallback cb); + + /** + * return last known cell identity + * @param subId user preferred subId. + * @param callingPackage the name of the package making the call. + * @param callingFeatureId The feature in the package. + */ + CellIdentity getLastKnownCellIdentity(int subId, String callingPackage, + String callingFeatureId); } diff --git a/tests/vcn/java/android/net/vcn/VcnCellUnderlyingNetworkPriorityTest.java b/tests/vcn/java/android/net/vcn/VcnCellUnderlyingNetworkPriorityTest.java index f7d3697029d6..476be44ee759 100644 --- a/tests/vcn/java/android/net/vcn/VcnCellUnderlyingNetworkPriorityTest.java +++ b/tests/vcn/java/android/net/vcn/VcnCellUnderlyingNetworkPriorityTest.java @@ -36,7 +36,7 @@ public class VcnCellUnderlyingNetworkPriorityTest { return new VcnCellUnderlyingNetworkPriority.Builder() .setNetworkQuality(NETWORK_QUALITY_OK) .setAllowMetered(true /* allowMetered */) - .setAllowedPlmnIds(ALLOWED_PLMN_IDS) + .setAllowedOperatorPlmnIds(ALLOWED_PLMN_IDS) .setAllowedSpecificCarrierIds(ALLOWED_CARRIER_IDS) .setAllowRoaming(true /* allowRoaming */) .setRequireOpportunistic(true /* requireOpportunistic */) @@ -48,7 +48,7 @@ public class VcnCellUnderlyingNetworkPriorityTest { final VcnCellUnderlyingNetworkPriority networkPriority = getTestNetworkPriority(); assertEquals(NETWORK_QUALITY_OK, networkPriority.getNetworkQuality()); assertTrue(networkPriority.allowMetered()); - assertEquals(ALLOWED_PLMN_IDS, networkPriority.getAllowedPlmnIds()); + assertEquals(ALLOWED_PLMN_IDS, networkPriority.getAllowedOperatorPlmnIds()); assertEquals(ALLOWED_CARRIER_IDS, networkPriority.getAllowedSpecificCarrierIds()); assertTrue(networkPriority.allowRoaming()); assertTrue(networkPriority.requireOpportunistic()); @@ -60,7 +60,7 @@ public class VcnCellUnderlyingNetworkPriorityTest { new VcnCellUnderlyingNetworkPriority.Builder().build(); assertEquals(NETWORK_QUALITY_ANY, networkPriority.getNetworkQuality()); assertFalse(networkPriority.allowMetered()); - assertEquals(new HashSet<String>(), networkPriority.getAllowedPlmnIds()); + assertEquals(new HashSet<String>(), networkPriority.getAllowedOperatorPlmnIds()); assertEquals(new HashSet<Integer>(), networkPriority.getAllowedSpecificCarrierIds()); assertFalse(networkPriority.allowRoaming()); assertFalse(networkPriority.requireOpportunistic()); diff --git a/tests/vcn/java/android/net/vcn/VcnGatewayConnectionConfigTest.java b/tests/vcn/java/android/net/vcn/VcnGatewayConnectionConfigTest.java index 724c33ffb354..377f526a9825 100644 --- a/tests/vcn/java/android/net/vcn/VcnGatewayConnectionConfigTest.java +++ b/tests/vcn/java/android/net/vcn/VcnGatewayConnectionConfigTest.java @@ -17,6 +17,8 @@ package android.net.vcn; import static android.net.ipsec.ike.IkeSessionParams.IKE_OPTION_MOBIKE; +import static android.net.vcn.VcnGatewayConnectionConfig.DEFAULT_UNDERLYING_NETWORK_PRIORITIES; +import static android.net.vcn.VcnGatewayConnectionConfig.UNDERLYING_NETWORK_PRIORITIES_KEY; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -30,6 +32,7 @@ import android.net.ipsec.ike.IkeSessionParams; import android.net.ipsec.ike.IkeTunnelConnectionParams; import android.net.vcn.persistablebundleutils.IkeSessionParamsUtilsTest; import android.net.vcn.persistablebundleutils.TunnelConnectionParamsUtilsTest; +import android.os.PersistableBundle; import androidx.test.filters.SmallTest; import androidx.test.runner.AndroidJUnit4; @@ -230,6 +233,16 @@ public class VcnGatewayConnectionConfigTest { assertEquals(config, new VcnGatewayConnectionConfig(config.toPersistableBundle())); } + @Test + public void testParsePersistableBundleWithoutVcnUnderlyingNetworkPriorities() { + PersistableBundle configBundle = buildTestConfig().toPersistableBundle(); + configBundle.putPersistableBundle(UNDERLYING_NETWORK_PRIORITIES_KEY, null); + + final VcnGatewayConnectionConfig config = new VcnGatewayConnectionConfig(configBundle); + assertEquals( + DEFAULT_UNDERLYING_NETWORK_PRIORITIES, config.getVcnUnderlyingNetworkPriorities()); + } + private static IkeTunnelConnectionParams buildTunnelConnectionParams(String ikePsk) { final IkeSessionParams ikeParams = IkeSessionParamsUtilsTest.createBuilderMinimum() @@ -271,4 +284,40 @@ public class VcnGatewayConnectionConfigTest { assertNotEquals(tunnelParams, anotherTunnelParams); assertNotEquals(config, anotherConfig); } + + private static VcnGatewayConnectionConfig buildTestConfigWithVcnUnderlyingNetworkPriorities( + LinkedHashSet<VcnUnderlyingNetworkPriority> networkPriorities) { + return buildTestConfigWithExposedCaps( + new VcnGatewayConnectionConfig.Builder( + "buildTestConfigWithVcnUnderlyingNetworkPriorities", + TUNNEL_CONNECTION_PARAMS) + .setVcnUnderlyingNetworkPriorities(networkPriorities), + EXPOSED_CAPS); + } + + @Test + public void testVcnUnderlyingNetworkPrioritiesEquality() throws Exception { + final VcnGatewayConnectionConfig config = + buildTestConfigWithVcnUnderlyingNetworkPriorities(UNDERLYING_NETWORK_PRIORITIES); + + final LinkedHashSet<VcnUnderlyingNetworkPriority> networkPrioritiesEqual = + new LinkedHashSet(); + networkPrioritiesEqual.add(VcnCellUnderlyingNetworkPriorityTest.getTestNetworkPriority()); + networkPrioritiesEqual.add(VcnWifiUnderlyingNetworkPriorityTest.getTestNetworkPriority()); + final VcnGatewayConnectionConfig configEqual = + buildTestConfigWithVcnUnderlyingNetworkPriorities(networkPrioritiesEqual); + + final LinkedHashSet<VcnUnderlyingNetworkPriority> networkPrioritiesNotEqual = + new LinkedHashSet(); + networkPrioritiesNotEqual.add( + VcnWifiUnderlyingNetworkPriorityTest.getTestNetworkPriority()); + final VcnGatewayConnectionConfig configNotEqual = + buildTestConfigWithVcnUnderlyingNetworkPriorities(networkPrioritiesNotEqual); + + assertEquals(UNDERLYING_NETWORK_PRIORITIES, networkPrioritiesEqual); + assertEquals(config, configEqual); + + assertNotEquals(UNDERLYING_NETWORK_PRIORITIES, networkPrioritiesNotEqual); + assertNotEquals(config, configNotEqual); + } } diff --git a/tests/vcn/java/com/android/server/vcn/routeselection/NetworkPriorityClassifierTest.java b/tests/vcn/java/com/android/server/vcn/routeselection/NetworkPriorityClassifierTest.java index 2e1aab60152d..46a614f60ae7 100644 --- a/tests/vcn/java/com/android/server/vcn/routeselection/NetworkPriorityClassifierTest.java +++ b/tests/vcn/java/com/android/server/vcn/routeselection/NetworkPriorityClassifierTest.java @@ -279,7 +279,7 @@ public class NetworkPriorityClassifierTest { final String networkPriorityPlmnId = useMatchedPlmnId ? PLMN_ID : PLMN_ID_OTHER; final VcnCellUnderlyingNetworkPriority networkPriority = getCellNetworkPriorityBuilder() - .setAllowedPlmnIds(Set.of(networkPriorityPlmnId)) + .setAllowedOperatorPlmnIds(Set.of(networkPriorityPlmnId)) .build(); assertEquals( diff --git a/tools/locked_region_code_injection/Android.bp b/tools/locked_region_code_injection/Android.bp index 98c0e69cbf8e..3e1297190622 100644 --- a/tools/locked_region_code_injection/Android.bp +++ b/tools/locked_region_code_injection/Android.bp @@ -12,10 +12,10 @@ java_binary_host { manifest: "manifest.txt", srcs: ["src/**/*.java"], static_libs: [ - "asm-6.0", - "asm-commons-6.0", - "asm-tree-6.0", - "asm-analysis-6.0", + "asm-7.0", + "asm-commons-7.0", + "asm-tree-7.0", + "asm-analysis-7.0", "guava-21.0", ], } diff --git a/tools/locked_region_code_injection/src/lockedregioncodeinjection/LockTargetStateAnalysis.java b/tools/locked_region_code_injection/src/lockedregioncodeinjection/LockTargetStateAnalysis.java index 1002c88e9281..335b3f82c533 100644 --- a/tools/locked_region_code_injection/src/lockedregioncodeinjection/LockTargetStateAnalysis.java +++ b/tools/locked_region_code_injection/src/lockedregioncodeinjection/LockTargetStateAnalysis.java @@ -13,8 +13,6 @@ */ package lockedregioncodeinjection; -import java.util.ArrayList; -import java.util.List; import org.objectweb.asm.Type; import org.objectweb.asm.tree.AbstractInsnNode; import org.objectweb.asm.tree.MethodInsnNode; @@ -22,6 +20,9 @@ import org.objectweb.asm.tree.analysis.AnalyzerException; import org.objectweb.asm.tree.analysis.BasicInterpreter; import org.objectweb.asm.tree.analysis.BasicValue; +import java.util.ArrayList; +import java.util.List; + /** * A simple dataflow analysis to determine if the operands on the stack must be one of target lock * class type. @@ -31,6 +32,7 @@ public class LockTargetStateAnalysis extends BasicInterpreter { private final List<LockTarget> targetLocks; public LockTargetStateAnalysis(List<LockTarget> targetLocks) { + super(Utils.ASM_VERSION); this.targetLocks = targetLocks; } diff --git a/tools/locked_region_code_injection/src/lockedregioncodeinjection/Utils.java b/tools/locked_region_code_injection/src/lockedregioncodeinjection/Utils.java index 219c2b3a2fec..f1e84b1d8a33 100644 --- a/tools/locked_region_code_injection/src/lockedregioncodeinjection/Utils.java +++ b/tools/locked_region_code_injection/src/lockedregioncodeinjection/Utils.java @@ -13,13 +13,14 @@ */ package lockedregioncodeinjection; +import org.objectweb.asm.Opcodes; + import java.util.ArrayList; import java.util.List; -import org.objectweb.asm.Opcodes; public class Utils { - public static final int ASM_VERSION = Opcodes.ASM6; + public static final int ASM_VERSION = Opcodes.ASM7; /** * Reads a comma separated configuration similar to the Jack definition. diff --git a/tools/locked_region_code_injection/test/lockedregioncodeinjection/TestMain.java b/tools/locked_region_code_injection/test/lockedregioncodeinjection/TestMain.java index c408b9e99c32..31fa0bf63416 100644 --- a/tools/locked_region_code_injection/test/lockedregioncodeinjection/TestMain.java +++ b/tools/locked_region_code_injection/test/lockedregioncodeinjection/TestMain.java @@ -30,7 +30,7 @@ import org.junit.Test; * rm -fr out/* * * # Make booster - * javac -cp lib/asm-6.0_BETA.jar:lib/asm-commons-6.0_BETA.jar:lib/asm-tree-6.0_BETA.jar:lib/asm-analysis-6.0_BETA.jar:lib/guava-21.0.jar src/*/*.java -d out/ + * javac -cp lib/asm-7.0_BETA.jar:lib/asm-commons-7.0_BETA.jar:lib/asm-tree-7.0_BETA.jar:lib/asm-analysis-7.0_BETA.jar:lib/guava-21.0.jar src/*/*.java -d out/ * pushd out * jar cfe lockedregioncodeinjection.jar lockedregioncodeinjection.Main */*.class * popd @@ -43,7 +43,7 @@ import org.junit.Test; * popd * * # Run tool on unit tests. - * java -ea -cp lib/asm-6.0_BETA.jar:lib/asm-commons-6.0_BETA.jar:lib/asm-tree-6.0_BETA.jar:lib/asm-analysis-6.0_BETA.jar:lib/guava-21.0.jar:out/lockedregioncodeinjection.jar \ + * java -ea -cp lib/asm-7.0_BETA.jar:lib/asm-commons-7.0_BETA.jar:lib/asm-tree-7.0_BETA.jar:lib/asm-analysis-7.0_BETA.jar:lib/guava-21.0.jar:out/lockedregioncodeinjection.jar \ * lockedregioncodeinjection.Main \ * -i out/test_input.jar -o out/test_output.jar \ * --targets 'Llockedregioncodeinjection/TestTarget;' \ |