Commit graph

76 commits

Author SHA1 Message Date
Xin Li
11da9e6792 Merge Android R (rvc-dev-plus-aosp-without-vendor@6692709)
Bug: 166295507
Merged-In: I6d0b1be1a46288fff42c3689dbef2f7443efebcc
Change-Id: I133180d20457b9f805f3da0915e2cf6e48229132
2020-08-29 01:45:24 -07:00
Jeff Sharkey
a0e7a6da28 Update language to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for reference

Bug: 161896447
Change-Id: I0caf39b349c48e44123775d98c52a773b0b504ff
2020-07-31 12:28:11 -06:00
Tao Bao
6131110763 Ignore the denial due to vendor_misc_writer reading DT fstab. am: ab38d7073e am: 086085b8ad
Change-Id: I0d9fbabdd5402a0ea3d25b8137fd11d89fc08e24
2020-03-30 14:35:31 +00:00
Tao Bao
086085b8ad Ignore the denial due to vendor_misc_writer reading DT fstab. am: ab38d7073e
Change-Id: I33416cf74bab1bd45fb7eec879391976943c9b00
2020-03-30 14:19:01 +00:00
Tao Bao
ff229fc4b8 Ignore the denial due to vendor_misc_writer reading DT fstab. am: ab38d7073e
Change-Id: I5522be992b05e51d6af245eebb728a57691a56c5
2020-03-30 14:18:56 +00:00
Tao Bao
ab38d7073e Ignore the denial due to vendor_misc_writer reading DT fstab.
This CL addresses the following denial, when vendor_misc_writer tries to
read DT fstab (i.e. device tree fstab) for /misc entry.

avc: denied { search } for comm="misc_writer" name="android" dev="sysfs" ino=17456 scontext=u:r:vendor_misc_writer:s0 tcontext=u:object_r:sysfs_dt_firmware_android:s0 tclass=dir

DT fstab was used for devices shipped prior to Q, for early-mounting
partitions (e.g. /system, /vendor, /product), which has been disallowed
for Q launch devices. vendor_misc_writer is a new module added since Q,
so it doesn't need to worry about the legacy code path; in practice
there's no benefit of putting /misc entry into DT fstab either.

Bug: 134122603
Bug: 152718206
Test: Build and flash taimen with the change that enables
      vendor_misc_writer. Check that it no longer gives the above denial
      during boot.
Change-Id: Id2fb206706f7cd19a4cde2701e4155bfc03f01b4
2020-03-30 11:49:35 +02:00
Steven Thomas
1454af74a3 Allow access to the "refresh_rate_switching" system property
Bug: 147233255
Bug: 136592946
Bug: 138261472

Test: Ran with the patch applied, confirmed surface flinger can access
the system property.

Change-Id: I259a488399c5e698de384322852ea81ea1a96e7d
Merged-In: I259a488399c5e698de384322852ea81ea1a96e7d
Exempt-From-Owner-Approval: Approved internally
2020-03-23 16:01:38 -07:00
Steven Thomas
4ee8089356 Allow access to the "refresh_rate_switching" system property
Bug: 147233255
Bug: 136592946
Bug: 138261472

Test: Ran with the patch applied, confirmed surface flinger can access
the system property.

Change-Id: I259a488399c5e698de384322852ea81ea1a96e7d
Merged-In: I259a488399c5e698de384322852ea81ea1a96e7d
Exempt-From-Owner-Approval: Approved internally
2020-03-20 22:32:15 -07:00
Treehugger Robot
282735ec15 Merge "Allow XML file paths to be customized with sysprop" am: fa4a015fa1 am: e899ee1913
Change-Id: I1a0a851f5a70bc347c981a348eab5e34cf5551aa
2020-03-18 23:26:12 +00:00
Treehugger Robot
9a61042ffe Merge "Allow XML file paths to be customized with sysprop" am: fa4a015fa1 am: e899ee1913
Change-Id: I2ba3cb14676e2e76fe24951812b9a83b225f1e84
2020-03-18 23:26:01 +00:00
Pawin Vongmasa
76d7cf961e Allow XML file paths to be customized with sysprop
Three properties are declared as vendor-init-settable:
ro.media.xml_variant.codecs
ro.media.xml_variant.codecs_performance
ro.media.xml_variant.profiles

media_codecs.xml can now be named
media_codecs${ro.media.xml_variant.codecs}.xml

media_codecs_performance.xml can now be named
media_codecs_performance${ro.media.xml_variant.codecs_performance}.xml

media_profiles_V1_0 can now be named
media_profiles${ro.media.xml_variant.profiles}.xml

Test: Rename "media_codecs.xml" to "media_codecs_test.xml",
set ro.media.xml_variant.codecs to "_test", then
call "stagefright -i".

Test: Rename "media_codecs_performance.xml" to
"media_codecs_performance_test.xml",
set ro.media.xml_variant.codecs_performance to "_test", then
run android.media.cts.VideoDecoderPerfTest.

Test: Rename "media_profiles_V1_0.xml" to "media_profiles_test.xml",
set ro.media.xml_variant.profiles to "_test", then
run vts_mediaProfiles_validate_test.

Bug: 142102953
Change-Id: I407a0a327fcc8e799bb4079b11048a497565be48
2020-03-18 06:02:55 -07:00
Jaegeuk Kim
2f5e44eb49 sepolicy: introduce boottime props in public
Bug: 146053177
Bug: 146053658
Bug: 149844577
Change-Id: Iddfefedc4538044c6abcc2eea29b86e3f038aee0
Merged-In: Iddfefedc4538044c6abcc2eea29b86e3f038aee0
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
2020-03-08 03:31:10 +00:00
Jaegeuk Kim
9a8ba7f64b sepolicy: introduce boottime props in public
Bug: 146053177
Bug: 146053658
Bug: 149844577
Change-Id: Iddfefedc4538044c6abcc2eea29b86e3f038aee0
Merged-In: Iddfefedc4538044c6abcc2eea29b86e3f038aee0
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
(cherry picked from commit 19df15400e)
2020-03-06 16:48:29 +00:00
Automerger Merge Worker
7ab65fadb7 Add property contexts for dex2oat cpu-set properties am: 23098ec3bb
Change-Id: Ifebf2c5b2780da8175f73135d8c534ce669473b4
2020-03-06 16:19:26 +00:00
Automerger Merge Worker
39aacfaf27 Add property contexts for dex2oat cpu-set properties am: 23098ec3bb
Change-Id: I0efdff9c0d1a911d6b9abd345169b1bb745de7cf
2020-03-06 09:05:39 +00:00
Orion Hodson
23098ec3bb Add property contexts for dex2oat cpu-set properties
New properties are:

 dalvik.vm.dex2oat-cpu-set [default compiler thread affinity]
 dalvik.vm.boot-dex2oat-cpu-set [compiler thread affinity for boot]
 dalvik.vm.image-dex2oat-cpu-set [thread affinity recompiling the boot image]

Bug: 141446571
Bug: 149395059
Test: Run installd tests with new properties defined in target mk file.
Change-Id: Idcbb1332aa9c18f6082b827eae0334d063644a41
(cherry picked from commit 7b2ee48cd2)
2020-03-05 08:48:53 +00:00
Jaegeuk Kim
028f2c3453 Merge "block: allow init.rc to tune max discard size" into qt-qpr1-dev 2020-02-01 01:49:24 +00:00
Jaegeuk Kim
2b1e595e8f block: allow init.rc to tune max discard size
Init.rc requires to limit max discard to avoid long latencies.

Bug: 148209614
Change-Id: Idf3b295ac15efd5edf979ca896fdf826b9fc3c99
Merged-In: Idf3b295ac15efd5edf979ca896fdf826b9fc3c99
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
2020-01-23 20:02:58 +00:00
Automerger Merge Worker
b354eba19c Merge "Allow adb start/stop mdnsd via ctl.start/stop" into qt-qpr1-dev am: 2192ec6223
Change-Id: I1bafff0ae8087a3c72209eb2a6edcaddc1e5d463
2020-01-17 18:44:15 +00:00
Changyeon Jo
60c4276c15 Allow adb start/stop mdnsd via ctl.start/stop
Bug: 128345139
Test: make selinux_policy
Change-Id: I477d6d94c16974f23f703d5f334ef108279ab3bb
Signed-off-by: Changyeon Jo <changyeon@google.com>
(cherry picked from commit cfeaa1c664)
2020-01-16 08:26:51 -08:00
Automerger Merge Worker
c188e2deca Merge "Create new system property type for Factory OTA could write system property" am: a75fa8058c am: 150bdab002
Change-Id: I092b89446bf37e9fa23163519835491c5e4cb07c
2019-12-15 19:38:22 +00:00
Treehugger Robot
a75fa8058c Merge "Create new system property type for Factory OTA could write system property" 2019-12-15 19:26:39 +00:00
Henry Tung
6d57b494c0 Create new system property type for Factory OTA could write system property
Due to Factory OTA client install in product partition but it also declare coredomian in
its sepolicy setting. That will let Factory OTA unable to find a property type could write system property.
But now Factory OTA have a restore NFC wake function need to write system property for communicate with bootloader.
So we need to create a new property type in system framework which could allow Factory OTA client to write system property.

Bug: 145178094
Test: Manual
Change-Id: Ic549cc939893ec67a46bf28a23ebeb9f9b81bd0b
2019-12-13 09:39:19 +00:00
Automerger Merge Worker
2225c5ea6e Allow vendor_init to modify pm.dexopt.disable_bg_dexopt am: 4c06707b5e
Change-Id: I7cded22281ade995b060641209ae84d37c55a583
2019-12-11 21:55:50 +00:00
Eric Jeong
4c06707b5e Allow vendor_init to modify pm.dexopt.disable_bg_dexopt
- Android Auto has disabled background dexopt (b/142753051).
- The modification is in car_base.mk which is included by vendor device
file.
- So, vendor_init needs to be able to modify
pm.dexopt.disable_bg_dexopt property.

Bug: 145348176
Test: Check pm.dexopt.disable_bg_dexopt is set to true in Android Auto
device.

Cherry-Picked-From: 03b1992d0bf363e438b0fd7efca1e2a1d7249320
Change-Id: I84d19ea62f1abe1bf9206a60ca103614616e312b
2019-12-06 10:40:12 -08:00
Jaegeuk Kim
a47abdbe16 block: allow init.rc to tune max discard size
Init.rc requires to limit max discard to avoid long latencies.

Change-Id: Idf3b295ac15efd5edf979ca896fdf826b9fc3c99
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
2019-12-04 12:26:19 -08:00
Xin Li
7883f6b3c1 DO NOT MERGE - Merge QD1A.190821.011 into stage-aosp-master
Bug: 141248619
Change-Id: I3186316d366cc7c9fee29cef5d2cd6ef37ff3926
2019-10-14 22:53:21 +00:00
Paul Crowley
fa2cc0539e Merge "Export vold FDE algorithm properties"
am: 8cb6460058

Change-Id: I912cca35978e934dfc1458cee946f0f0c24760f5
2019-09-25 10:02:47 -07:00
yuguoxu
a894a1aa66 Export vold FDE algorithm properties
ro.crypto.fde_algorithm
ro.crypto.fde_sector_size
ro.crypto.volume.contents_mode

These properties were not added to sepolicy export2vold. vold can't access
crypto algorithm type when flashing a GSI image and when the properties are in
/vendor/build.prop. This prevents FDE from working.

Bug: 141518844
Change-Id: I234bda439f6be7a2211a194856baf75800396232
Signed-off-by: yuguoxu <yuguoxu@allwinnertech.corp-partner.google.com>
2019-09-25 16:29:54 +00:00
Paul Crowley
859f9211d8 Allow toolbox to rm -rf /data/per_boot
Bug: 140882488
Test: create files and dirs in /data/per_boot, check they're removed.
Cherry-Picked-From: 2367ba358f
Merged-In: Idf0ba09cbe51cbff6a7b2a464c4651a1f7fcf343
Change-Id: Idf0ba09cbe51cbff6a7b2a464c4651a1f7fcf343
2019-09-17 18:44:13 +00:00
Xin Li
36edee480d Merge qt-r1-dev-plus-aosp-without-vendor (5817612) into stage-aosp-master
Bug: 135460123
Change-Id: Ie43761a96540ce489b65d9ba467ebdfa2dfe6066
Merged-In: I87a1ce741a77f5bd3a4ea81f1c519f7c1955a3c6
2019-09-08 13:07:03 -07:00
Paul Lawrence
31e6fa2075 Merge "Fix ext4/metadata/udc problem"
am: 4d40aefa4b

Change-Id: I6d445070b533d3353a714fb043102c0be00cc883
2019-08-27 08:44:48 -07:00
Daniel Solomon
3248182855 selinux: Update Q sepolicy prebuilt
Tag gpu_service as app_api_service. This is the corresponding api 29.0
change to the public service.te from commit aosp/1105058
(I30a951cd712b0ae4aacd2c4d6d42e74fac5c0707).

Bug: 139685237
Test: m selinux_policy
Change-Id: Ia23cdd5f59b40a3e99cae424d9cf41d5e7442631
2019-08-21 17:10:37 -07:00
Paul Lawrence
37739146b6 Fix ext4/metadata/udc problem
Test: Cannot currently test since no device supports this combo
Bug: 137924328
Change-Id: Ie59e6c37e293c983e99618eacda9fd09c2ce01ed
2019-08-08 08:55:29 -07:00
Ady Abraham
f8aebbaa5d Merge "Add ro.surface_flinger.set_display_power_timer_ms to sepolicy" into qt-r1-dev
am: 74395f1ff4

Change-Id: I2abb139843bc425d276145d27d00c0f3acf5d30a
2019-07-16 15:54:52 -07:00
Ady Abraham
40909f65a6 Add ro.surface_flinger.set_display_power_timer_ms to sepolicy
Bug: 135550670
Test: Boot with SELinux enforcing
Change-Id: I61c30abc39909a263a2c402a5c0eb1de570748bb
2019-07-12 12:43:25 -07:00
Thierry Strudel
b8c28bdc96 Merge "SF: enable device-specific dataspace for color space agnostic surfaces" into qt-r1-dev
am: d519b1ca7c

Change-Id: I65664b9072278b2dd6d43ad564670a03defdaed7
2019-07-08 17:34:13 -07:00
Yichi Chen
39efa50184 SF: enable device-specific dataspace for color space agnostic surfaces
To reduce the DPU loading in color conversion, we enable device-specific
dataspace for color space agnostic surfaces. Since the type of surfaces
usually provide gray-level surfaces to users, it can be acceptable to
ignore the color conversion on them.

Bug: 134783740
Bug: 135140940
Test: Check ScreenDecorOverlays in expected dataspace
Test: Play HDR video on C2 and check dataspace
Change-Id: Ief32f0ff3867b2e154fecd6c9ebd6610b0e6ed11
2019-07-03 20:24:42 +08:00
Oliver Nguyen
bf513525a4 Merge "In native coverage builds, allow all domains to access /data/misc/trace" into qt-dev am: 72a75ffe19
am: 75f2c87c8a

Change-Id: Iae83e01bc56d5bc0c631251be18f7395a6d1bd87
2019-06-20 16:17:04 -07:00
Oliver Nguyen
0012d6574c Merge "In native coverage builds, allow all domains to access /data/misc/trace" into qt-dev
am: 72a75ffe19

Change-Id: I93de590b94ce57c8ad87361ddb3b6188552854c7
2019-06-20 15:42:32 -07:00
Oliver Nguyen
72a75ffe19 Merge "In native coverage builds, allow all domains to access /data/misc/trace" into qt-dev 2019-06-20 19:07:41 +00:00
Kevin Chyn
741f8214cb Add rules to dump hal traces am: 6d976f4d5d
am: 20ca587019

Change-Id: Ia6bd656a5cfaf4f408178352a5c164e979ad4c74
2019-06-19 19:59:58 -07:00
Kevin Chyn
15ff564438 Add rules to dump hal traces
am: 6d976f4d5d

Change-Id: Ia0e7b39d215b9306b724135f7d888593f3c76aae
2019-06-19 19:06:04 -07:00
Pirama Arumuga Nainar
b65824642b In native coverage builds, allow all domains to access /data/misc/trace
Bug: http://b/135139675

Coverage files are written to /data/misc/trace (governed by the
method_trace_data_file selinux type).  Allow all domains to access
(create directories, access files) this directory when native coverage
is enabled (by setting NATIVE_COVERAGE to true) in an userdebug or eng
build.

Also relax neverallow constraints to allow access to
method_trace_data_file for native coverage builds.

Test: Build 32-bit cuttlefish with coverage:
          m NATIVE_COVERAGE=true COVERAGE_PATHS="*"
      and verify that there are no selinux denials in kernel log and
      logcat.

Change-Id: I3fe7c77612854b9de7de7a0ddd5cbf44a2f5c21e
(cherry picked from commit ce9c0c5a5f)
2019-06-19 16:27:17 -07:00
Kevin Chyn
6d976f4d5d Add rules to dump hal traces
Test: manual
Bug: 126802513

Change-Id: If037483f305e161a158e30f6322d5e25b7770952
2019-06-19 19:55:14 +00:00
Tao Bao
1520895967 Merge "Add persist.sys.theme." into qt-dev
am: 890dba4999

Change-Id: Ia747bf55b5275a8b05a3dbb971c82747b4292807
2019-06-18 20:25:32 -07:00
Tao Bao
a999e39423 Add persist.sys.theme.
This property will be set by system_server (to indicate the currently
selected theme for device), and can be accessed by vendor init.rc.

avc:  denied  { read } for property=persist.sys.theme pid=0 uid=0 gid=0 scontext=u:r:vendor_init:s0 tcontext=u:object_r:theme_prop:s0 tclass=file

Bug: 113028175
Test: Set a vendor init trigger that waits on `persist.sys.theme`. Check
      that the trigger fires without denial.
Change-Id: Ia85b1a8dfc118efdbb9337ca017c8fb7958dc386
Merged-In: Ibb4e392d5059b76059f36f7d11ba82cd65cbe970
(cherry picked from commit 75182a1ea6)
2019-06-18 17:36:21 -07:00
Tao Bao
890dba4999 Merge "Add persist.sys.theme." into qt-dev 2019-06-19 00:36:03 +00:00
Hridya Valsaraju
351f85a4ee Add permission required by libdm_test
am: 9bb71537ac

Change-Id: I18326abc7713f95ee027e476a96ce32905a9525f
2019-06-17 21:15:34 -07:00
Hridya Valsaraju
9bb71537ac Add permission required by libdm_test
This CL fixes the following denials during libdm_test
that is part of VTS.

avc: denied { read } for comm="loop1" path=2F6D656D66643A66696C655F32202864656C6574656429
dev="tmpfs" ino=97742 scontext=u:r:kernel:s0 tcontext=u:object_r:appdomain_tmpfs:s0
tclass=file permissive=0
W loop1   : type=1400 audit(0.0:371): avc: denied { read } for
path=2F6D656D66643A66696C655F32202864656C6574656429 dev="tmpfs" ino=97742 scontext=u:r:kernel:s0
tcontext=u:object_r:appdomain_tmpfs:s0 tclass=file permissive=0

Bug: 135004816
Test: adb shell libdm_test
Change-Id: Ifb6d58ee6f032cdf3952a05667aa8696d6e2a2fa
2019-06-17 22:46:03 +00:00