* Ignore the block devices in case their mount points are symlinks.
This is common on devices where maintainers have chosen not to use
real partitions because of their size being too small to be useful
Also `continue` instead of `break`. Oops.
Change-Id: I3e27abe510219066ecacd81d099220ac8e119f9f
There are addon.d scripts that rely on the value of ADDOND_VERSION
to determine if they're being called from a-only vs a/b backuptool.
If they declare ADDOND_VERSION=3, they shall stop doing that;
otherwise offer them the same environment, that is unset ADDOND_VERSION
for a-only backuptool.
Change-Id: I1be21eda2e6ec9837b3080bb5e7fbe5241318eaa
* Also: add a lot of additional info for many of the numbers based on
the comments from the commit prior to this
Change-Id: I937637c8f002d193ed6b23ac60c1f350d7d2eec7
* The plan was to support odm & oem too, but it turned out
unnecessarily complicated due to their symlink setup,
while being most likely unused.
The partitions were removed from the list of supported ones
in a-only backuptool, but were forgotten in ab backuptool.
Change-Id: I58a01cdc3f5c4239048b204f3313f4bf697dd60a
For scripts declaring ADDOND_VERSION=3 automatically mount
vendor, product, system_ext and others (when they're dedicated partitions).
Also expose the get_output_path() function to get the path to where
a file is mounted in case it lives in a dedicated partition.
ab exapmles:
get_output_path "system/product/priv-app/MyApp.apk" = "/postinstall/product/priv-app/MyApk.apk"
get_output_path "system/app/MySystemApp.apk" = "/postinstall/system/app/MySystemApp.apk"
a-only examples:
get_output_path "/mnt/system/system/product/priv-app/MyApp.apk" = "/mnt/system/system/product/priv-app/MyApp.apk"
******************************************************************
Instead of cycling all scripts for each stage, run
pre-backup -> backup -> post-backup in quick succession
(and likewise for restore), to ensure backwards compatibility
with scripts that wrongly assumed their environment not to
change between steps.
This is needed because we want to undo any mounting done for V3
scripts when executing V2 scripts. If a V2 script did mounting in
pre-restore and expected things to still be mounted in restore,
we would break their (yes incorrect) assumption.
Change-Id: I73fbad6f45824fed99e4482128769435348588f5
FscryptSetDirectoryPolicy no longer tries to infer the action from the
filename. Well mostly; it still assumes top-level directories in /data
should be encrypted unless the mkdir arguments say otherwise, but
it warns.
Bug: 26641735
Test: boot, check log messages
Change-Id: Id6d2cea7fb856f17323897d85cf6190c981b443c
Adding "default" to the type list, will allow to connect to mobile internet via LTE again.
According to the user, even if enforcing LTE here, it won't work unless adding "default".
I couldn't find any official resources, just that this APN seems to relate to CDMA and other people fixed the issue by adding the APN manually:
https://help.ting.com/hc/en-us/community/posts/206433277/comments/216019607
Therefore trusting the reporter in the ticket below that default is enough:
https://gitlab.com/LineageOS/issues/android/-/issues/2819
Change-Id: I931f5355af74e197020032a1581dd11abf84f10c
In Q, we added a new bugreport API that asks for user consent before
showing the "Share" notification for the bugreport. We will be migrating
all bugreporting clients to use the API in R.
In the new API workflow we are moving away from broadcasts and using
callbacks to communicate with dumpstate. Finished bugreport notification
broadcast used to share the final path of the bugreport but API now uses
file descriptors instead. Hence, moving away from broadcasts.
The full bugreport in this case can be retrieved from dumpstate directory
using 'adb pull' or finding and attaching the file directly to gmail or
betterbug.
Remove outputfile flag since it's unused.
Bug: 135186519
Bug: 137825702
Test: Build and flash to the device. Create a bugreport using combo
keys, share notification does not pop up. Full bugreport created in
bugreports/ dir
Change-Id: I3c15123a6a4ed62ae9cb87f5dd07db60b1416dfc
Using cp instead of mv during the restore step resulted in double the
amount of free space and inodes being used.
For example, a nano arm64 opengapps install uses around 500M. But during
a backup/restore process when the Updater is used, it temporarily uses
1G on the other slot. That causes failed updates on devices that
don't have that much free space on the system partition.
Change-Id: I57ba2e0f52d328d4ff91d47a3db45f47bb8402af
Extracted from sony stock rom firmware 'H8266_Customized DE_1313-6279_52.1.A.3.49_R3C'
E-Plus got merged into O2
Synced the newest O2 changes
Change-Id: I67e6987769d0bcc271e58e7416468faa902a870b
* There is no reference to ANDROID_CACHE now, and
/persist does not exist on most devices, neither
can we write to it.
Change-Id: I91af1e6f571ced317d195e3a7901bf4c269486a1
Backup/restore functionality was broken in the
Ia1f4ae95c9e4dae4df844853e81c264bc838f177 change
because of incorrect check of the function's result.
check_prereq() function refactored to return 0 if
backuping/restoration is possible. Any work should be
performed only if check_prereq() succeeds.
Change-Id: Ic977dba675df58a228ef4b882b25beb66cc9d2c6
For non AB devices system partition should be unmounted
if check_prereq function fails.
This patch also refactors backuptool a bit for AB devices
in order to look same as backuptool for non AB devices.
Change-Id: Ia1f4ae95c9e4dae4df844853e81c264bc838f177
* This check was supposed to check whether the script
addon.d version was lower than backuptool's
* Given that the backuptool addon.d version is 1, this
isn't going to happen ever making this check completely
unuseful
Change-Id: I2464749b52bf4e8825e0b4ef42500ee7d3bbfa61
* For some odd reasons executing `cd /system/addon.d` makes the system
hang and unmount error:
umount: /system_root: Device or resource busy
* Don't change directory to not allow the system partition hang
Change-Id: I3d30bdc59c2f05d16823e99046c1dce2e1e6eb73
* If any of these two function gets run on a recovery mounting system
to /system, /system/addon.d won't exist while /system/system/addon.d will.
* Run the functions with $S as argument to make this work correctly
Change-Id: I02e7b91429a9e74d28bdb77e56955dad97ca75ac
* The path /postinstall exists only for A/B, causing:
grep: /postinstall/tmp/addon.d/*sh: No such file or directory
Change-Id: Ia07b3029e949c3e08302457cd08798a4dde00ef6
* Dynamically mount system to the path chosen by the recovery through backuptool
* This can be helpful because of the fragmentation that will happen with system mount in recovery after Q
Change-Id: I2d1e775efcf87e33319bc7790d1e54bca72116d3
* No longer used by any device and fw/base part is missing
Revert "Update boosted audio files 2/2"
This reverts commit 103c64a964.
Revert "Add volume boosted ringtones (1/2)"
This reverts commit a1c783fb28.
Change-Id: I384f44d515e2bcc237662184de0830836ba95b09
Add dun apn type to fix hotspot/tethering.
Also update according to https://www.ultramobile.com/data-settings/
BUGBASH-2371
Change-Id: I202cc7be26403d774e8694dd4386391d3576ea66
(cherry picked from commit 367ca28f8206a1e5be8655fb2f1c2e4972d7e8e3
For Example new devices need the new Sprint APNs, so add a new board flag for
them to set that will make the build system add the new APNs to
the APN config XML. If the flag is not set, continue to use the
old APNs.
To add or replace APNs, the custom_apns.py script has been
added. If CUSTOM_APNS_FILE is defined, custom_apns.py
is run and generates a new version of apns-conf.xml.
Change-Id: I7ff12a4342de2a7663b2b66fd627244214a8dc71
* LineageOS/android_system_sepolicy@0e3235f45d removed open, read,
and write for init to general sysfs types. As schedulers are
changed, the related directories gets dynamically torn-down and
rebuilt, but they lacks proper contexts. We need to make sure the
context is correct before init can write to these nodes.
Change-Id: Ic6f4567c173799bc56ecccc217040392f73aeaba
Bulgarian numbers: Most of these were directly sourced from Crisis or
Emergency centers' websites. At least half are from one of the leading
NGOs' detailed map that includes contact details for numerous hotlines,
centers, etc.
The non-Bulgarian numbers were sourced from https://116111.eu and
from the CM 14.1 sensitive_pn file.
Change-Id: I925b36ad7f616acf24c4c1e2109ea817a6de9338
(cherry picked from commit c88df996bea6f45093a6493d85c84b2df8a204d8)
Changes:
1. Rename "Internet" to "JIO 4G" per carrier request
2. Make IMS APN invisible per carrier request
3. Remove "carrier_enabled=true" to reduce
redundency as that's default value
Bug: 32935086
Change-Id: Ic7ce9978ed03aa24f116cad3b4fb049277864b89
This fixes BUGBASH-2328 for Portuguese carrier NOS (mcc="268"
mnc="03").
This is an ugly workaround since you can't edit the APN definition
anymore: if you try to save an APN with type dun, you get the error
message: "Carrier does not allow adding APNs of type dun." But it's
working.
Since the preinstalled APNs does not need to be edited and this
doesn't break anything else for this carrier, this is acceptable.
Thanx to tfae@xda.
Change-Id: Ic81a9549bf9610805e68b9be56c811b008cbdacb
* T-Mobile's domestic network is IPv6 only, and T-Mobile
support recommends setting IPv6 only for max compat
* T-Mobile support also recommends IPv4 only for roaming,
however compat issues have been discovered in the past
* Switching to IPv6 only domestically fixes an issue with
literal IPv4 addresses failing to resolve properly on ether
Change-Id: I7e394c6b7eebf9c106eaea5e000fe021adf421e6
* The LineageOS versions properties were removed from the build.prop,
which is resolved properly in commit:
"lineage: Keep LineageOS versions properties in build.prop"
Change-Id: I0060141c097b3d14c3710eee1e0caf7110634967
Change-Id: Ib11670474641d6fd14a00f8421e9fe8d1879bbc2
* The grep errorlevel output was not properly used by the if,
therefore allowing a device to upgrade with old addons
instead of aborting the backuptool steps
* The LineageOS versions properties were removed from the build.prop,
which is resolved properly in commit:
"lineage: Keep LineageOS versions properties in build.prop"
Change-Id: I0060141c097b3d14c3710eee1e0caf7110634967
* Introduced in the following commit:
"backuptool: Take into account new location for system default props"
Change-Id: I62046447876c2198a0c4f88a4f36f4723d417617
This reverts commit 1022cc7c50.
Change-Id: I7f5a3510f64f0ecabfe9d15b5dbc1a667b210eb8
Signed-off-by: Adrian DC <radian.dc@gmail.com>
* otasigcheck doesn't work on encrypted devices and makes
the zip installation fail since oreo.
* The build part of this was never ported to oreo.
This reverts commit aff5e54c4e.
Change-Id: I411f33c1db64844091c1692ef4706ae541925d4f
* Newer Sprint devices will only get LTE on the x.* variant of
the APN. Though, using this breaks all legacy Sprint devices
LTE connection. until we have a majority of post 8996 era
devices, default to the n.* variant of the APN.
Change-Id: I95a26a5d3175dbf6ebd4eb78e9f2720017c8c7e2
* Since A/B addon.d scripts are going to need to do things in a
specific way or things could go horribly wrong for a user, let's
introduce versioning so that scripts can claim to be compatible.
* A script can denote it is compatible with addon.d version 2 by
adding: "# ADDOND_VERSION=2" somewhere in its script.
* Only A/B will require version 2 scripts for now, and version 2
scripts will still run on non-A/B. Additionally if a script does
not explicitly denote its version, assume its version 1.
* Version 1: The same old scripts we've always used. We cannot assume
these will all work with A/B backuptools.
* Version 2: Scripts that denote they are compatible with version 2
must be aware of the fact that A/B devices will run this
script for a rom, during a seamless update, mounted at
/postinstall. The best way to ensure compatibility would
be to use the pre-designated functions found in the
backuptool[,_ab].functions scripts.
Change-Id: I5573018dabd21bb64c7c964e2081806072a75243
* A/B OTA devices wont run backuptools in recovery (because they don't
go in to recovery to do an OTA). In these cases let's use a modified
version to backup/restore from within android upon postinstall.
* Add backuptool_postinstall.sh which will be run prior to the normal
postinstall script in order to backup/restore via addon.d scripts.
* This needs to be done in such a manner because we need /postinstall
mounted rw instead of the ro with context= options which are used for
the normal postinstall (dexopt) script.
Change-Id: I51511870634dd1ec5388adafddb446f95cc5a950
* Due to both following commits, backuptool went permissive
and lineage properties got lost from the system on devices
that do not have BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED
"backuptool: Take into account new location for system default props"
Change-Id: I62046447876c2198a0c4f88a4f36f4723d417617
"lineage: Move to Google's method of defining system default props"
Change-Id: I6cb0e28a7599b010b389cc541015a37010a00f4b
* Once the properties issue is properly resolved in the sources,
a period of time is required for "most" of the users to upgrade
their system with fixed lineage properties before we break addons
by repairing the backuptool script globally
Change-Id: Iea8865ea9bb05eed56a8a0a7b95e3f04b01c4bae
- Add missing ims apn. Without this, pixel and nexus users were not
able to use ims features.
- Set the mtu value. This improves data connection reliability.
- These changes match with pixel's aosp apn.
Change-Id: I170de2c92cc916424c266dc972a6538599640b7c
Pixels will only establish a data connection to these carriers using
IPv6, so this fixes the reports of no cellular data and no mms.
Also, this matches with what aosp has.
Change-Id: I07768f817cf6bb4997dd737cc467fb146c959434
* System default props defined using PRODUCT_SYSTEM_DEFAULT_PROPERTIES
are stored into /system/etc/prop.default, so that's the location where
ro.lineage.version prop needs to be checked now. Although, fallback
to the old location to allow sucessful upgrades.
Change-Id: I62046447876c2198a0c4f88a4f36f4723d417617
* MMS doesn't need to have its own APN
* This matches https://support.t-mobile.com/docs/DOC-2090 and
was verified against a T-Mobile Galaxy Note 5 on stock
Change-Id: I254de82de012ea4b052d7751d4910f13692c970a
* Add support for bearer 18
* Update mmsc urls
* Remove bad dun apn
* Set approprite auth_types
* Set visibility
* Update max_conns
Change-Id: Ie9256f10899343242c64ae3896434b4c994f3dac
* Sort MCC orders
* Sort phone number orders
* Remove one duplicate phone number entry (116123 in GB)
* Add a note about maintaining this file
Change-Id: Ifcf392c1ca54c0daf37248a647d401d4a93dd355
Accordind to https://www.symamobile.com/parametrage-internet.html#8 the Syma APN should be symamobile.com not symacom.fr
I had to edit the APN manually to get it working
Change-Id: I62ccdc6bdcf8803e47c2f454a6ece622e06027d1
* http://www.mtel.ba/frend-plan
* Frend spoken "friend" is their voice & data plan
Change-Id: I014f7549d936c64abb3801596d940cee7703f790
Signed-off-by: Celoxocis <celox.ocis@gmail.com>
*) Put Lineage rc files in /system/etc/init instead of /init.lineage.rc
*) Split into function specific files (vibrator-specific stuff moved to
our custom vibrator HAL service)
Change-Id: I1d00950253fbf7fdd7a4b7bd52adbed971923575
GmsCore deletes the files in /data/ota_package/, including the files
downloaded by Updater. Create a new directory where Updater can store
its files not to have them disappear randomly.
Change-Id: Ifdfbc7f81eb5f2c4370d02f0634c869fdbb848b4
France has 7 MCC codes, but only include the 2 DOM (Overseas regions) codes here.
* Metropolitan France: 208
* Guadeloupe, Martinique, Guyane: 340
* La Réunion, Mayotte, TAAF (French Southern and Antarctic Lands): 647
The 4 others MCC codes aren't covered by those number as stated on their website.
* Saint-Pierre-et-Miquelon: 308
* Wallis-et-Futuba: 543
* Nouvelle-Calédonie: 546
* Polynésie française: 547
See:
* http://www.solidaritefemmes.org/appeler-le-3919
* http://www.allo119.gouv.fr/
Change-Id: If13e2c2cfa669b76178182f9aa2d0f19772a45a3
Notice: I am very likely the only one here having a Macau SIM card, so I am the only one who can confirm this change.
Please do not paste APN settings copied from other vendors or devices.
The exactly APN used in MIUI is not MMC455/MNC07 but MMC455/MNC02, maybe Xiaomi has done extra calculations to do so.
It is a waste of time to argue which APN is “BETTER”. This one works for China Telecom Macau LTE. I can confirm this. If you live out of Macau, you can't.
Screenshot: https://pics.mustu.cn/assets/52c546f9-e883-4335-a090-c9e66ec1c77e.png
CTWAP and CTNET are not discussed in this change.
CTNET is for 3G. There are still someone using 3G. You can add one if you are interested in this, or I will add one if I have a confirmed APN settings from China Telecom Macau staffs.
CTWAP is outdated. If you use CTWAP in China, most apps will tell you "CTWAP is deprecated, use CTNET instead.".
China is moving from 3G to 4G/LTE, and will soon be moving from 4G to 5G. If you live out of China, please simply +1 and merge it. If you live in China and having problem with this APN, we can discuss this with beer and snacks.
For now, there is NO APN settings for MMC455/MNC07, so this APN won't harm anyone else living out of Macau.
Merge this change, that's it.
Update:
Add CTNET for MMC455/MNC07
Screenshot: https://pics.mustu.cn/assets/bbd9e8ee-7af5-4d5e-af6d-3722de329ef0.png
Change-Id: I8600dbbb8d3ea567f04a516d7a296dbaaebc5216
Source: http://www.la-strada.org.ua :
Human Trafficking Counteraction: "0-800-500-22-5"
Domestic Violence Counteraction: "0-800-500-33-5" or "386"
Child Rights Protection: "0-800-500-33-5" or "386"
Gender And Human Rights: "0-800-500-33-5"
Source: http://www.la-strada.org.ua/ucp_mod_content_show_30_robota-garyachoyi-liniyi.html :
National Child Toll Free Hotline "0-800-500-22-5" or "772"
Change-Id: I63a02f34853b86914383d9d8666036cd684bc3b3
If /system is empty, /tmp/addon.d/ will not exist, "*sh" won't be
expanded, md5sum will not generate any output and the variable $s
will be empty. Therefore grep, which will receive only one arg, will
start to read the standard input and never exit, causing the
installation to never end. Fix this checking whether we have files
to read or not.
Change-Id: I656eab42e54b3f81da8c5ac81374b9deddcf8484