18.1/19.1/20.0: January ASB picks

Signed-off-by: Tavi <tavi@divested.dev>
This commit is contained in:
Tavi 2024-01-06 16:46:38 -05:00
parent 533749cffd
commit 4020f2cbaa
No known key found for this signature in database
GPG Key ID: E599F62ECBAEAF2E
11 changed files with 49 additions and 44 deletions

View File

@ -10,10 +10,10 @@ requiring the READ_PHONE_STATE permission.
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index f8aaa4e5a31e..ce034892f379 100644
index 234b23a99626..6f52225a9c5a 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -5285,12 +5285,7 @@ public class ActivityManagerService extends IActivityManager.Stub
@@ -5284,12 +5284,7 @@ public class ActivityManagerService extends IActivityManager.Stub
}
}

View File

@ -10,7 +10,7 @@ requiring the READ_PHONE_STATE permission.
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index ffa290649580..fc14d5dd247e 100644
index 9a9c05060a4c..7185fac975e6 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -4526,12 +4526,7 @@ public class ActivityManagerService extends IActivityManager.Stub

View File

@ -10,7 +10,7 @@ requiring the READ_PHONE_STATE permission.
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index 46f62b83d669..035af8bde9d8 100644
index 70bef605b567..7605d05d6287 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -4866,12 +4866,7 @@ public class ActivityManagerService extends IActivityManager.Stub

View File

@ -109,10 +109,10 @@ index 749c67abf389..39f08b6a0f15 100644
// classpath. If found, create a PathClassLoader and use it for applicationInit.
ClassLoader classLoader = null;
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index 035af8bde9d8..b31d139877dd 100644
index 7605d05d6287..38d2b15520be 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -18633,4 +18633,10 @@ public class ActivityManagerService extends IActivityManager.Stub
@@ -18646,4 +18646,10 @@ public class ActivityManagerService extends IActivityManager.Stub
Trace.traceBegin(traceTag, methodName + subInfo);
}
}

View File

@ -9,10 +9,10 @@ Change-Id: I26dc2942736cf0cfe4e7b92ddfdd04b9d74dbae5
1 file changed, 2 insertions(+), 9 deletions(-)
diff --git a/app/src/main/java/org/lineageos/updater/misc/Utils.java b/app/src/main/java/org/lineageos/updater/misc/Utils.java
index b7ba720..f3d334b 100644
index f2cab10..13179a1 100644
--- a/app/src/main/java/org/lineageos/updater/misc/Utils.java
+++ b/app/src/main/java/org/lineageos/updater/misc/Utils.java
@@ -155,16 +155,9 @@ public class Utils {
@@ -144,16 +144,9 @@ public class Utils {
String incrementalVersion = SystemProperties.get(Constants.PROP_BUILD_VERSION_INCREMENTAL);
String device = SystemProperties.get(Constants.PROP_NEXT_DEVICE,
SystemProperties.get(Constants.PROP_DEVICE));

View File

@ -18,10 +18,10 @@ Change-Id: Ibfe080c3d801af34fb64fda1b6b8f4f39a2b1ccf
10 files changed, 134 insertions(+), 5 deletions(-)
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index cc485f7..7cdfb93 100644
index 2abb833..6041740 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -13,6 +13,10 @@
@@ -18,6 +18,10 @@
<uses-permission android:name="android.permission.START_ACTIVITIES_FROM_BACKGROUND" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
@ -33,10 +33,10 @@ index cc485f7..7cdfb93 100644
android:allowBackup="false"
android:icon="@mipmap/ic_launcher"
diff --git a/app/src/main/java/org/lineageos/updater/UpdatesActivity.java b/app/src/main/java/org/lineageos/updater/UpdatesActivity.java
index 25ca0b8..4dbc077 100644
index a4eda73..387eea0 100644
--- a/app/src/main/java/org/lineageos/updater/UpdatesActivity.java
+++ b/app/src/main/java/org/lineageos/updater/UpdatesActivity.java
@@ -473,10 +473,14 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
@@ -462,10 +462,14 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
final DownloadClient downloadClient;
try {
@ -51,7 +51,7 @@ index 25ca0b8..4dbc077 100644
.build();
} catch (IOException exception) {
Log.e(TAG, "Could not build download client");
@@ -580,6 +584,7 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
@@ -569,6 +573,7 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
private void showPreferencesDialog() {
View view = LayoutInflater.from(this).inflate(R.layout.preferences_dialog, null);
Spinner autoCheckInterval = view.findViewById(R.id.preferences_auto_updates_check_interval);
@ -59,7 +59,7 @@ index 25ca0b8..4dbc077 100644
SwitchCompat autoDelete = view.findViewById(R.id.preferences_auto_delete_updates);
SwitchCompat meteredNetworkWarning = view.findViewById(
R.id.preferences_metered_network_warning);
@@ -592,6 +597,7 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
@@ -581,6 +586,7 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(this);
autoCheckInterval.setSelection(Utils.getUpdateCheckSetting(this));
@ -67,7 +67,7 @@ index 25ca0b8..4dbc077 100644
autoDelete.setChecked(prefs.getBoolean(Constants.PREF_AUTO_DELETE_UPDATES, false));
meteredNetworkWarning.setChecked(prefs.getBoolean(Constants.PREF_METERED_NETWORK_WARNING,
prefs.getBoolean(Constants.PREF_MOBILE_DATA_WARNING, true)));
@@ -632,6 +638,8 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
@@ -621,6 +627,8 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
prefs.edit()
.putInt(Constants.PREF_AUTO_UPDATES_CHECK_INTERVAL,
autoCheckInterval.getSelectedItemPosition())
@ -76,7 +76,7 @@ index 25ca0b8..4dbc077 100644
.putBoolean(Constants.PREF_AUTO_DELETE_UPDATES, autoDelete.isChecked())
.putBoolean(Constants.PREF_METERED_NETWORK_WARNING,
meteredNetworkWarning.isChecked())
@@ -645,6 +653,10 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
@@ -634,6 +642,10 @@ public class UpdatesActivity extends UpdatesListActivity implements UpdateImport
UpdatesCheckReceiver.cancelUpdatesCheck(this);
}
@ -88,10 +88,10 @@ index 25ca0b8..4dbc077 100644
boolean enableABPerfMode = abPerfMode.isChecked();
mUpdaterService.getUpdaterController().setPerformanceMode(enableABPerfMode);
diff --git a/app/src/main/java/org/lineageos/updater/UpdatesCheckReceiver.java b/app/src/main/java/org/lineageos/updater/UpdatesCheckReceiver.java
index 9f45423..382fbd4 100644
index b065ed0..5767bfb 100644
--- a/app/src/main/java/org/lineageos/updater/UpdatesCheckReceiver.java
+++ b/app/src/main/java/org/lineageos/updater/UpdatesCheckReceiver.java
@@ -110,10 +110,14 @@ public class UpdatesCheckReceiver extends BroadcastReceiver {
@@ -99,10 +99,14 @@ public class UpdatesCheckReceiver extends BroadcastReceiver {
};
try {
@ -107,10 +107,10 @@ index 9f45423..382fbd4 100644
downloadClient.start();
} catch (IOException e) {
diff --git a/app/src/main/java/org/lineageos/updater/controller/UpdaterController.java b/app/src/main/java/org/lineageos/updater/controller/UpdaterController.java
index daa710c..1e51c5b 100644
index 691012c..4dbab2c 100644
--- a/app/src/main/java/org/lineageos/updater/controller/UpdaterController.java
+++ b/app/src/main/java/org/lineageos/updater/controller/UpdaterController.java
@@ -374,12 +374,16 @@ public class UpdaterController {
@@ -363,12 +363,16 @@ public class UpdaterController {
update.setFile(destination);
DownloadClient downloadClient;
try {
@ -127,7 +127,7 @@ index daa710c..1e51c5b 100644
.build();
} catch (IOException exception) {
Log.e(TAG, "Could not build download client");
@@ -419,6 +423,9 @@ public class UpdaterController {
@@ -408,6 +412,9 @@ public class UpdaterController {
verifyUpdateAsync(downloadId);
notifyUpdateChange(downloadId);
} else {
@ -137,7 +137,7 @@ index daa710c..1e51c5b 100644
DownloadClient downloadClient;
try {
downloadClient = new DownloadClient.Builder()
@@ -427,6 +434,7 @@ public class UpdaterController {
@@ -416,6 +423,7 @@ public class UpdaterController {
.setDownloadCallback(getDownloadCallback(downloadId))
.setProgressListener(getProgressListener(downloadId))
.setUseDuplicateLinks(true)
@ -146,10 +146,10 @@ index daa710c..1e51c5b 100644
} catch (IOException exception) {
Log.e(TAG, "Could not build download client");
diff --git a/app/src/main/java/org/lineageos/updater/download/DownloadClient.java b/app/src/main/java/org/lineageos/updater/download/DownloadClient.java
index 3494947..7a7f7cf 100644
index 0623d4f..bfc037e 100644
--- a/app/src/main/java/org/lineageos/updater/download/DownloadClient.java
+++ b/app/src/main/java/org/lineageos/updater/download/DownloadClient.java
@@ -60,6 +60,7 @@ public interface DownloadClient {
@@ -49,6 +49,7 @@ public interface DownloadClient {
private DownloadClient.DownloadCallback mCallback;
private DownloadClient.ProgressListener mProgressListener;
private boolean mUseDuplicateLinks;
@ -157,7 +157,7 @@ index 3494947..7a7f7cf 100644
public DownloadClient build() throws IOException {
if (mUrl == null) {
@@ -70,7 +71,7 @@ public interface DownloadClient {
@@ -59,7 +60,7 @@ public interface DownloadClient {
throw new IllegalStateException("No download callback defined");
}
return new HttpURLConnectionClient(mUrl, mDestination, mProgressListener, mCallback,
@ -166,7 +166,7 @@ index 3494947..7a7f7cf 100644
}
public Builder setUrl(String url) {
@@ -97,5 +98,10 @@ public interface DownloadClient {
@@ -86,5 +87,10 @@ public interface DownloadClient {
mUseDuplicateLinks = useDuplicateLinks;
return this;
}
@ -178,10 +178,10 @@ index 3494947..7a7f7cf 100644
}
}
diff --git a/app/src/main/java/org/lineageos/updater/download/HttpURLConnectionClient.java b/app/src/main/java/org/lineageos/updater/download/HttpURLConnectionClient.java
index b9c4b5d..b94fff0 100644
index 4ce3dd0..d39de45 100644
--- a/app/src/main/java/org/lineageos/updater/download/HttpURLConnectionClient.java
+++ b/app/src/main/java/org/lineageos/updater/download/HttpURLConnectionClient.java
@@ -18,12 +18,16 @@ package org.lineageos.updater.download;
@@ -7,12 +7,16 @@ package org.lineageos.updater.download;
import android.os.SystemClock;
import android.util.Log;
@ -198,7 +198,7 @@ index b9c4b5d..b94fff0 100644
import java.net.URL;
import java.util.Comparator;
import java.util.List;
@@ -42,6 +46,7 @@ public class HttpURLConnectionClient implements DownloadClient {
@@ -31,6 +35,7 @@ public class HttpURLConnectionClient implements DownloadClient {
private final DownloadClient.ProgressListener mProgressListener;
private final DownloadClient.DownloadCallback mCallback;
private final boolean mUseDuplicateLinks;
@ -206,7 +206,7 @@ index b9c4b5d..b94fff0 100644
private DownloadThread mDownloadThread;
@@ -56,8 +61,14 @@ public class HttpURLConnectionClient implements DownloadClient {
@@ -45,8 +50,14 @@ public class HttpURLConnectionClient implements DownloadClient {
HttpURLConnectionClient(String url, File destination,
DownloadClient.ProgressListener progressListener,
DownloadClient.DownloadCallback callback,
@ -223,7 +223,7 @@ index b9c4b5d..b94fff0 100644
mDestination = destination;
mProgressListener = progressListener;
mCallback = callback;
@@ -177,7 +188,12 @@ public class HttpURLConnectionClient implements DownloadClient {
@@ -166,7 +177,12 @@ public class HttpURLConnectionClient implements DownloadClient {
private void changeClientUrl(URL newUrl) throws IOException {
String range = mClient.getRequestProperty("Range");
mClient.disconnect();
@ -237,7 +237,7 @@ index b9c4b5d..b94fff0 100644
if (range != null) {
mClient.setRequestProperty("Range", range);
}
@@ -232,7 +248,7 @@ public class HttpURLConnectionClient implements DownloadClient {
@@ -221,7 +237,7 @@ public class HttpURLConnectionClient implements DownloadClient {
}
Log.d(TAG, "Downloading from " + newUrl);
changeClientUrl(url);
@ -246,7 +246,7 @@ index b9c4b5d..b94fff0 100644
mClient.connect();
if (!isSuccessCode(mClient.getResponseCode())) {
throw new IOException("Server replied with " + mClient.getResponseCode());
@@ -257,6 +273,9 @@ public class HttpURLConnectionClient implements DownloadClient {
@@ -246,6 +262,9 @@ public class HttpURLConnectionClient implements DownloadClient {
public void run() {
boolean justResumed = false;
try {
@ -257,10 +257,10 @@ index b9c4b5d..b94fff0 100644
mClient.connect();
int responseCode = mClient.getResponseCode();
diff --git a/app/src/main/java/org/lineageos/updater/misc/Constants.java b/app/src/main/java/org/lineageos/updater/misc/Constants.java
index beb9423..a51ab15 100644
index a00dce1..825e1a0 100644
--- a/app/src/main/java/org/lineageos/updater/misc/Constants.java
+++ b/app/src/main/java/org/lineageos/updater/misc/Constants.java
@@ -30,6 +30,7 @@ public final class Constants {
@@ -19,6 +19,7 @@ public final class Constants {
public static final String PREF_LAST_UPDATE_CHECK = "last_update_check";
public static final String PREF_AUTO_UPDATES_CHECK_INTERVAL = "auto_updates_check_interval";
@ -269,10 +269,10 @@ index beb9423..a51ab15 100644
public static final String PREF_AB_PERF_MODE = "ab_perf_mode";
public static final String PREF_METERED_NETWORK_WARNING = "pref_metered_network_warning";
diff --git a/app/src/main/java/org/lineageos/updater/misc/Utils.java b/app/src/main/java/org/lineageos/updater/misc/Utils.java
index f3d334b..67ad386 100644
index 13179a1..3d4aab9 100644
--- a/app/src/main/java/org/lineageos/updater/misc/Utils.java
+++ b/app/src/main/java/org/lineageos/updater/misc/Utils.java
@@ -46,6 +46,7 @@ import java.io.BufferedReader;
@@ -35,6 +35,7 @@ import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.io.IOException;
@ -280,7 +280,7 @@ index f3d334b..67ad386 100644
import java.util.ArrayList;
import java.util.Enumeration;
import java.util.HashSet;
@@ -151,11 +152,75 @@ public class Utils {
@@ -140,11 +141,75 @@ public class Utils {
return updates;
}
@ -357,10 +357,10 @@ index f3d334b..67ad386 100644
return server + "?base=LineageOS&device=" + device + "&inc=" + incrementalVersion;
}
diff --git a/app/src/main/res/layout/preferences_dialog.xml b/app/src/main/res/layout/preferences_dialog.xml
index c1b4356..93f1bfc 100644
index 774d1be..8a01e3d 100644
--- a/app/src/main/res/layout/preferences_dialog.xml
+++ b/app/src/main/res/layout/preferences_dialog.xml
@@ -29,6 +29,14 @@
@@ -33,6 +33,14 @@
android:entries="@array/menu_auto_updates_check_interval_entries" />
</LinearLayout>
@ -376,10 +376,10 @@ index c1b4356..93f1bfc 100644
android:id="@+id/preferences_auto_delete_updates"
android:layout_width="match_parent"
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 02dda7f..3fbfbb5 100644
index 0748b23..ac159a8 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -70,6 +70,7 @@
@@ -59,6 +59,7 @@
<string name="menu_auto_updates_check_interval_weekly">Once a week</string>
<string name="menu_auto_updates_check_interval_monthly">Once a month</string>
<string name="menu_auto_updates_check_interval_never">Never</string>
@ -387,7 +387,7 @@ index 02dda7f..3fbfbb5 100644
<string name="menu_auto_delete_updates">Delete updates when installed</string>
<string name="menu_delete_update">Delete</string>
<string name="menu_copy_url">Copy URL</string>
@@ -87,6 +88,7 @@
@@ -76,6 +77,7 @@
<string name="snack_download_failed">The download failed. Please check your internet connection and try again later.</string>
<string name="snack_download_verification_failed">The update verification failed.</string>
<string name="snack_download_verified">Download completed.</string>

View File

@ -123,6 +123,7 @@ patchWorkspaceReal() {
repopick -fit msm8974-gps-r;
repopick -fit hh-vsync;
repopick -fi 311299; #ble: Workaround malformed HCI_BLE_VENDOR_CAP response
repopick -it R_asb_2024-01;
sh "$DOS_SCRIPTS/Patch.sh";
sh "$DOS_SCRIPTS_COMMON/Enable_Verity.sh";

View File

@ -96,6 +96,7 @@ sed -i '75i$(my_res_package): PRIVATE_AAPT_FLAGS += --auto-add-overlay' core/aap
awk -i inplace '!/updatable_apex.mk/' target/product/mainline_system.mk; #Disable APEX
sed -i 's/PLATFORM_MIN_SUPPORTED_TARGET_SDK_VERSION := 23/PLATFORM_MIN_SUPPORTED_TARGET_SDK_VERSION := 28/' core/version_defaults.mk; #Set the minimum supported target SDK to Pie (GrapheneOS)
#sed -i 's/PRODUCT_OTA_ENFORCE_VINTF_KERNEL_REQUIREMENTS := true/PRODUCT_OTA_ENFORCE_VINTF_KERNEL_REQUIREMENTS := false/' core/product_config.mk; #broken by hardenDefconfig
sed -i 's/2023-12-05/2024-01-05/' core/version_defaults.mk; #Bump Security String #R_asb_2024-01
fi;
if enterAndClear "build/soong"; then

View File

@ -66,9 +66,10 @@ patchWorkspaceReal() {
verifyAllPlatformTags;
gpgVerifyGitHead "$DOS_BUILD_BASE/external/chromium-webview";
#source build/envsetup.sh;
source build/envsetup.sh;
#repopick -ift twelve-bt-sbc-hd-dualchannel;
#repopick -it twelve-colors;
repopick -it S_asb_2024-01;
sh "$DOS_SCRIPTS/Patch.sh";
sh "$DOS_SCRIPTS_COMMON/Enable_Verity.sh";

View File

@ -98,6 +98,7 @@ sed -i '75i$(my_res_package): PRIVATE_AAPT_FLAGS += --auto-add-overlay' core/aap
awk -i inplace '!/updatable_apex.mk/' target/product/generic_system.mk; #Disable APEX
sed -i 's/PLATFORM_MIN_SUPPORTED_TARGET_SDK_VERSION := 23/PLATFORM_MIN_SUPPORTED_TARGET_SDK_VERSION := 28/' core/version_defaults.mk; #Set the minimum supported target SDK to Pie (GrapheneOS)
#sed -i 's/PRODUCT_OTA_ENFORCE_VINTF_KERNEL_REQUIREMENTS := true/PRODUCT_OTA_ENFORCE_VINTF_KERNEL_REQUIREMENTS := false/' core/product_config.mk; #broken by hardenDefconfig
sed -i 's/2023-12-05/2024-01-05/' core/version_defaults.mk; #Bump Security String #S_asb_2024-01
fi;
if enterAndClear "build/soong"; then

View File

@ -161,6 +161,7 @@ patchWorkspaceReal() {
source build/envsetup.sh;
repopick -i 361248; #Launcher3: Allow toggling monochrome icons for all apps
repopick -it T_asb_2024-01;
sh "$DOS_SCRIPTS/Patch.sh";
sh "$DOS_SCRIPTS_COMMON/Enable_Verity.sh";