Commit Graph

414 Commits

Author SHA1 Message Date
John Stultz
b31e6addda
msm8974-common: Disable nonblocking_ffs to avoid recent crashes with adbd
Recent changes to adbd have enabled nonblocking_ffs by default.

These have seeminly uncovered some bad memory corruption in the
kernel ffs gadget driver on every kernel I've tried so far.

Unfortunately I've not been able to diagnose what is going wrong,
so for now, lets disable the nonblocking_ffs.

We still need to root cause the issue as its a problem even with
the mainline kernel on HiKey, so its likely a generic kernel issue.

Change-Id: I7a0797cc9e8e5f263e533beea23642f768c0f017
Signed-off-by: John Stultz <john.stultz@linaro.org>
2020-04-18 10:55:03 -06:00
Katz Yamada
3138fafbcd
msm8974-common: gps: Fix for buffer overrun crash at copying nmea string
Add zero clearing of allocated nmea buffer to ensure
the nmea string is null terminated.

Change-Id: Ie36010a7d3eca16dabb3067ae891a94e4b63b10c
CRs-Fixed: 2041933
2020-04-18 10:55:03 -06:00
Suren Baghdasaryan
2efdd808f9
msm8974-common: gps: Add libprocessgroup dependency to set_sched_policy users
Add libprocessgroup dependency required for set_sched_policy function.
Include sched_policy_ctrl.h header which now contains set_sched_policy
definition.

Bug: 111307099
Test: builds, boots

Merged-In: I3b93555d4be0a8b3040235b2ab872a6a3238505e
Change-Id: I3b93555d4be0a8b3040235b2ab872a6a3238505e
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
2020-04-18 10:55:03 -06:00
LuK1337
c0ea446532
msm8974-common: init: Override everything ^.^
Change-Id: If09eed5bf254a386631327ea19e21d42366fb08f
2020-04-18 10:55:02 -06:00
Kevin F. Haggerty
0fd0cb6ade
msm8974-common: Convert libinit_helpers_sam8974 to blueprint
Change-Id: I990a4d2c68cd51f0043390408c3b128c4bb20900
2020-04-18 10:55:02 -06:00
Kevin F. Haggerty
992ae3c4fe
msm8974-common: Drop vestiges of old libinit_msm8974
Change-Id: I40b11ebb48ff71a0a81e4f248fcc9bb42d6db792
2020-04-13 06:31:52 -06:00
Kevin F. Haggerty
080bf8a0ec
msm8974-common: libinit: Convert extension into simple helper library
* This will contain functions used by the actual extensions at the
  device level, it will not be a full-fledged libinit extension on
  its own.

Change-Id: I2752dbf7d0b0fb439765fa99b61c82ec10a6c3d2
2020-04-06 09:31:49 -06:00
Paul Keith
5006db0ec0 msm8974-common: Remove unnecessary keylayout files
* Nothing uses these keylayout files

Change-Id: I477445fd226f5fc77125fa5706e42cd8e0fe8b02
2020-03-31 19:23:55 +02:00
Paul Keith
11997658fb msm8974-common: Enforce inclusion of samsung_qcom-common/BoardConfigCommon.mk
* This should always be present in the souce tree

Change-Id: I32397f245580be8174f22af6096dcbeee2bedcd8
2020-03-30 15:51:10 +02:00
Paul Keith
95faaa3643 msm8974-common: Migrate all properties system.prop
* We already set props via system.prop, so let's not mix
  and match between that and PRODUCT_PROPERTY_OVERRIDES.

Change-Id: I92c6863b8393640e2239decd7f089ee890b3c7f7
2020-03-26 17:46:41 +02:00
Kevin F. Haggerty
1d1a7f182c
msm8974-common: libinit: Commonize {cdma,gsm}_properties functions
* It doesn't make sense to maintain these in the numerous device-
  specific trees. It especially doesn't make sense for those to be
  subtly-different.

Change-Id: I4e82c0f6b5b835ac4c742a5d5663a8f3498aaf7b
2020-03-02 06:37:33 -07:00
Kevin F. Haggerty
a1be441339
msm8974-common: libinit: Drop unnecessary includes
Change-Id: I678c39f2dbdf91916a97b3ac07b467de7b14e503
2020-02-29 12:44:02 -07:00
Paul Keith
eea2c37a49 Revert "msm8974-common: Don't mess with APN or CDMA CarrierConfig options"
* It turns out, this is now necessary for Sprint

This reverts commit b1352d7bec.

Change-Id: Ifaa71b0cfc0879d881a8ab9d1cb54aa8255a74d2
2020-02-15 02:49:23 +01:00
Paul Keith
50045fa46e msm8974-common: Transition to consumerir HIDL hal
Change-Id: I85950a46eebec0e9a4b34681b2042467231b33b3
2020-01-31 15:08:24 +01:00
Nolen Johnson
24300422f6 msm8974-common: Set TARGET_RECOVERY_DEVICE_DIRS
* In the previous commit, I failed to note that TWRP
  also needs the AIO property set, so append local path
  to TARGET_RECOVERY_DEVICE_DIRS to make both Lineage
  Recovery and TWRP happy.

Change-Id: Ie1d8dfa252dad02787544a73e9d4ee1d44d30dbf
2019-08-06 06:30:09 +00:00
Nolen Johnson
4a85372d41 msm8974-common: Set sys.usb.ffs.aio_compat in recovery as well
Change-Id: I36d76f74ceae3029f49c3cb564cd876bbb6b5b81
2019-08-06 05:27:58 +02:00
jrior001
881a6b9fff
msm8974-common: Disable network scan via TelephonyManager
Change-Id: I07ac2eee478d6edbc266447ef3209403a14285f1
2019-08-03 08:32:27 -06:00
LuK1337
756a4e4063
msm8974-common: hal_lineage_livedisplay_default -> hal_lineage_livedisplay_sysfs
Change-Id: If8954290c41913b7453a1cba4d67f7a63d08d2dd
2019-06-16 09:01:58 -06:00
maxwen
1ea634bce2
msm8974-common: Update overlay to hide sRGB toggle
* Now expected as an array in Settings package

Change-Id: I92a56abb0fc1379e4482d1889d04d8db6a14ea2b
2019-05-23 20:12:35 -06:00
dianlujitao
464acd06e1
msm8974-common: Hide sRGB toggle in developer options
* This is only available on Nexus/Pixel devices and we don't even
   support such color space.

Change-Id: I8343e4986d7dd8413bd8d36dfad0309a4c08026e
2019-05-23 20:12:35 -06:00
Kevin F. Haggerty
66b282da2e
msm8974-common: Build Samsung LiveDisplay service
Change-Id: I74d38aa0df3179bb00b942135e8ff055aa8a5658
2019-05-07 07:20:49 -06:00
Paul Keith
c036f18fe2
msm8974-common: Build vendor.lineage.touch HAL from hardware/samsung
Change-Id: I6eca1e9875cb5793a3a45c6e77bc201946ebd897
2019-04-10 06:45:59 -06:00
Bruno Martins
67de8e7484
msm8974-common: Enable B-services aging propagation
Change-Id: I4ac0525933bb421f7d025c5e4c6a1de0f083c46e
2019-02-25 20:55:33 -07:00
Joey
021211d1ea
msm8974-common: Build Trust HAL
Change-Id: I2a426b2c2dda70f41e3c3ea6f85905b0daf65f0d
Signed-off-by: Joey <joey@lineageos.org>
2019-02-24 06:57:36 -07:00
Michael Bestas
88778ca52a
msm8974-common: manifest: Add health HAL
Change-Id: Ib934ab27f49bd27ba0285db505d2b5fa198522ef
2019-02-23 08:20:37 -07:00
elektroschmock
ccee55ca25
msm8974-common: manifest: Add OMX media HAL
Change-Id: Iebb280cc1a3f456662a1f4a0a8e95d2a3099b397
2019-02-20 00:02:30 -07:00
Paras Nagda
c21e12c074
msm8974-common: manifest: Add CAS HAL
Change-Id: I3d26b3c8c57425d2ee596f8efecaa2722b39551c
2019-02-19 22:50:37 -07:00
Michael Bestas
a88e2e277a
msm8974-common: Move media configs to vendor
Change-Id: Iffa5bfcac6e363ddd320ef3af5ccdc8c55f7942f
2019-02-19 07:58:26 -07:00
Ethan Chen
6ac0af40b5
msm8974-common: Drop custom display flags
* TARGET_USES_OVERLAY and USE_OPENGL_RENDERER are largely deprecated
* Don't set triple buffering, it introduces latency
* Don't use custom VSYNC offsets

Change-Id: If2892c83726c3558a96b28a8404f49982ebb9ba0
[haggertk: Only triple offset aspect of this change is relevant to
 this device family]
2019-02-19 07:42:09 -07:00
Kevin F. Haggerty
4b086d485b
Revert "msm8974-common: sepolicy: Label sysfs_net, resolve denials"
This reverts commit 97ff0e6d32.

Change-Id: Ib609a1a9987598be26e2fe32cc77ea9f57c9c63d
2019-02-19 07:42:09 -07:00
Kevin F. Haggerty
9aa32ce3c9
msm8974-common: sepolicy: Adapt to global sepolicy merges
* Several items merged globally caused duplicate definition of paths
  that were previously labeled here.

This reverts commit 27afbf1dc6.
This reverts commit 7fb5a8c6cb.
This partially reverts commit bb196ad94b.
This partially reverts commit c39a735ab5.

Change-Id: I901e5aa78058e1a465f110cde31fb7d76eaf3d51
2019-01-21 16:59:40 -07:00
Bruno Martins
99b3981287
msm8974-common: Allow media UID process to access CameraServiceProxy
* This fixes the following error on camera-in-mediaserver devices:

   E CameraService_proxy: Calling UID: 1013 doesn't match expected  camera service UID!

Change-Id: I185e34e8983b286436bfc0fe36cfdf260ef78170
2018-12-31 15:22:36 -07:00
Kevin F. Haggerty
f823b51508
msm8974-common: sepolicy: Eliminate qemu_hw_mainkeys_prop entries
* Specific definition of this is dropped from qcom/sepolicy-legacy

Change-Id: I429abf7dddd2de4443349366b932149f30b87206
2018-12-31 15:21:52 -07:00
Kevin F. Haggerty
a6b73c4ef2
Revert "msm8974-common: Set TARGET_NEEDS_LEGACY_CAMERA_HAL1_DYN_NATIVE_HANDLE"
* This is not necessary for P

This reverts commit 55cf3f11c6.

Change-Id: Ie6527cd691f07f024cfb7cf3ff021da6eb77c8a5
2018-12-26 18:45:45 -07:00
Kevin F. Haggerty
afa0af84d6 msm8974-common: sepolicy: Clean up
* Group policy statements better
* Nuke unneeded allows

Change-Id: Ibc1fd4debe8c95005a6dd54e1428d6365248bd80
2018-12-26 22:06:35 +01:00
Wayne Lin
cb2941d541
Changing SUPL_ES=1 for SUPL end point control
SUPL_ES=1 ensures the GnssLocationProvider and related framework code
accepts incoming SMS SUPL_INIT messages with ES-bit=1
(which allow redirection of the ESLP
end-point e.g. to the current local emergency services provider when
you are travelling) only during an emergency call

Bug: 115331218
Bug: 112159033
Test: Build pass
Change-Id: I5075f7887a184ce18bb1815b35a2ce7acd8bca10
2018-12-16 07:59:22 -07:00
Kevin F. Haggerty
7e3f9a566d
msm8974-common: sepolicy: Resolve init denials
* avc: denied { write } for name="enable_adaptive_lmk" dev="sysfs"
  ino=6724 scontext=u:r:init:s0
  tcontext=u:object_r:sysfs_lowmemorykiller:s0 tclass=file permissive=1
* avc: denied { open } for name="enable_adaptive_lmk" dev="sysfs"
  ino=6724 scontext=u:r:init:s0
  tcontext=u:object_r:sysfs_lowmemorykiller:s0 tclass=file
  permissive=1
* avc: denied { setattr } for name="firmware_path" dev="sysfs"
  ino=6423 scontext=u:r:init:s0
  tcontext=u:object_r:sysfs_wifi_writeable:s0 tclass=file
  permissive=1
* avc: denied { write } for name="l2" dev="sysfs" ino=29063
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_msm_power:s0
  tclass=file permissive=1
* avc: denied { open } for name="l2" dev="sysfs" ino=29063
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_msm_power:s0
  tclass=file permissive=1
* avc: denied { write } for name="enabled" dev="sysfs" ino=29716
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_thermal:s0
  tclass=file permissive=1
* avc: denied { write } for name="online" dev="sysfs" ino=5871
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_devices_system_cpu:s0
  tclass=file permissive=1
* avc: denied { write } for name="boost_ms" dev="sysfs" ino=6652
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_cpu_boost:s0
  tclass=file permissive=1
* avc: denied { open } for name="boost_ms" dev="sysfs" ino=6652
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_cpu_boost:s0
  tclass=file permissive=1
* avc: denied { setattr } for name="min_pwrlevel" dev="sysfs"
  ino=19546 scontext=u:r:init:s0 tcontext=u:object_r:sysfs_kgsl:s0
  tclass=file permissive=0
* avc: denied { setattr } for name="enabled" dev="sysfs" ino=23417
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_hal_pwr:s0
  tclass=file permissive=1
* avc: denied { setattr } for name="rear_camfw" dev="sysfs" ino=24404
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_camera:s0
  tclass=file permissive=1
* avc: denied { check_context } for scontext=u:r:init:s0
  tcontext=u:object_r:kernel:s0 tclass=security permissive=0

Change-Id: Id7f78abedea2209f84527b1b83259574d06a0900
2018-11-30 14:29:49 -07:00
Kevin F. Haggerty
7fb5a8c6cb
msm8974-common: sepolicy: Label sysfs_usb_storage_gadget, resolve denials
* avc: denied { setattr } for name="file" dev="sysfs" ino=23591
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_usb_storage_gadget:s0
  tclass=file permissive=1

Change-Id: Ia96e3634cbe1a85bb7da3f24ecfa3fbaaa55baad
2018-11-30 14:14:59 -07:00
Kevin F. Haggerty
58cf5da15e
msm8974-common: sepolicy: Label sysfs_usb_otg, resolve denials
* avc: denied { setattr } for name="booster" dev="sysfs" ino=23129
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_usb_otg:s0
  tclass=file permissive=1

Change-Id: Iffb33bd7647026107473fb63e82d942ad027f9f9
2018-11-30 14:10:55 -07:00
Kevin F. Haggerty
a0c32871a9
msm8974-common: sepolicy: Broaden sysfs_bluetooth_writable, resolve denials
Change-Id: Iff3645e36ece2126f3697bb0389394415be16529
2018-11-29 21:58:43 -07:00
Kevin F. Haggerty
5c15bb5833
msm8974-common: sepolicy: Label sysfs_msmuart_file, resolve denials
* avc: denied { setattr } for name="clock" dev="sysfs" ino=18914
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_msmuart_file:s0
  tclass=file permissive=1

Change-Id: Iaf5fe6791344dcf419242599eb6c9272c61cd707
2018-11-29 21:58:43 -07:00
Kevin F. Haggerty
5d817ed103
msm8974-common: sepolicy: Label sysfs_mmc_host, resolve denials
* avc: denied { write } for name="control" dev="sysfs" ino=25383
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_mmc_host:s0
  tclass=file permissive=1
* avc: denied { open } for name="control" dev="sysfs" ino=25383
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_mmc_host:s0
  tclass=file permissive=1

Change-Id: I876d025db9cf1fe67faeccca830ffd53dbf92904
2018-11-29 21:58:43 -07:00
Kevin F. Haggerty
6189adadd4
msm8974-common: sepolicy: Label sysfs_socinfo, resolve denials
* avc: denied { setattr } for name="soc_iddq" dev="sysfs" ino=5543
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_socinfo:s0 tclass=file
  permissive=0

Change-Id: Ife248a9cccea19b09b931525606cf4c34344fd9f
2018-11-29 21:58:42 -07:00
Kevin F. Haggerty
b98cef71f1
msm8974-common: sepolicy: Label additional sysfs_io_sched_tuneable node
Change-Id: I2b416123c7d925443df20f518cb2a0bd02935229
2018-11-29 21:58:42 -07:00
Kevin F. Haggerty
dbcc41c888
msm8974-common: sepolicy: Resolve additional sensors HAL denials
* avc: denied { search } for name="sec-thermistor" dev="sysfs"
  ino=5485 scontext=u:r:hal_sensors_default:s0
  tcontext=u:object_r:sysfs_sec_thermistor:s0 tclass=dir permissive=0

Change-Id: I4d77e87b2662bca081cc5b934161347fed6a157d
2018-11-29 21:58:42 -07:00
Kevin F. Haggerty
1f52307ccb
msm8974-common: sepolicy: Label sysfs_sensors, resolve denials
* avc: denied { read } for name="ssp_sensor" dev="sysfs" ino=27809
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_sensors:s0
  tclass=lnk_file permissive=1
* avc: denied { setattr } for name="temperature" dev="sysfs" ino=10861
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs_sensors:s0
  tclass=file permissive=0

Change-Id: I2e4a436704ed019af153da880d7becbde4b0ab11
2018-11-29 21:57:48 -07:00
Kevin F. Haggerty
c39a735ab5
msm8974-common: sepolicy: Label sysfs_msm_perf, resolve denials
* avc: denied { write } for name="suspend_enabled" dev="sysfs"
  ino=10567 scontext=u:r:init:s0 tcontext=u:object_r:sysfs_msm_perf:s0
  tclass=file permissive=1
* avc: denied { open } for name="suspend_enabled" dev="sysfs"
  ino=10567 scontext=u:r:init:s0 tcontext=u:object_r:sysfs_msm_perf:s0
  tclass=file permissive=1

Change-Id: I23d69f0442d126b2a6ac3aaeda5032856a4483f2
2018-11-29 19:17:53 -07:00
Kevin F. Haggerty
27afbf1dc6
msm8974-common: sepolicy: Label sysfs_disk_stat nodes
* avc: denied { read } for name="stat" dev="sysfs" ino=26461
  scontext=u:r:storaged:s0 tcontext=u:object_r:sysfs:s0 tclass=file
  permissive=1

Change-Id: I4b7258d069801f542da8c7f5ca8242ea32f12bca
2018-11-29 19:17:52 -07:00
Kevin F. Haggerty
97ff0e6d32
msm8974-common: sepolicy: Label sysfs_net, resolve denials
* avc: denied { getattr } for path="/sys/devices/msm_sdcc.2/mmc_host/
  mmc0/mmc0:0001/mmc0:0001:2/net/wlan0/phy80211" dev="sysfs"
  ino=29873 scontext=u:r:hal_wifi_hostapd_default:s0
  tcontext=u:object_r:sysfs_net:s0 tclass=lnk_file permissive=0
* avc: denied { read } for name="phy80211" dev="sysfs" ino=29823
  scontext=u:r:hal_wifi_hostapd_default:s0
  tcontext=u:object_r:sysfs_net:s0 tclass=lnk_file permissive=0

Change-Id: I6f40b8bdac2537b7000c02af6fac8277acb2a718
2018-11-29 19:17:52 -07:00
Kevin F. Haggerty
a7c4bcc98e
msm8974-common: sepolicy: Label our custom sensors service
Change-Id: I331abeac851cd92b32990ff797dff506dd67e503
2018-11-27 08:12:35 -07:00