Commit Graph

721 Commits

Author SHA1 Message Date
Kevin F. Haggerty 933059f487
klte-common: sepolicy: Label sysfs_fingerprint, resolve denials
* avc: denied { setattr } for name="type_check" dev="sysfs" ino=28060
  scontext=u:r:init:s0 tcontext=u:object_r:sysfs:s0 tclass=file
  permissive=0

Change-Id: Ide1be660eaa005a7268161a4ab8d301b793ba062
2018-11-29 07:01:06 -07:00
Kevin F. Haggerty b5bfa3d797
klte-common: sepolicy: Label sysfs_audio nodes
Change-Id: I46a0067241a3ce4567992c7437336f4a9c4bab8e
2018-11-25 08:10:41 -07:00
Kevin F. Haggerty dd67265c98
klte-common: restorecon I/O scheduler tunables before touching them
* early-init is before the global restorecon of /sys gets run, so
  we need to set a context on these before changing attributes

Change-Id: I493a9bb0c1bd2ea83a815e07169b8b689cf76a5d
2018-11-17 11:03:19 -07:00
Kevin F. Haggerty 06b36697e1
klte-common: Move change of ownership of ES705 UART later
* Samsung loads the firmware through the front door. Pie init
  runs faster than previously, so we need to wait to change
  the ownership until some point later, after the firmware has
  time to load, else the load gets blocked by a dac_override.

Change-Id: I37be9e22b49735388ce1f5b922132dbfd20e2dc3
2018-11-15 21:17:29 -07:00
Kevin F. Haggerty 1075fc17bb
klte-common: sepolicy: Resolve fingerprint HAL denials
* avc: denied { write } for name=fpdata dev=mmcblk0p26 ino=106076
  scontext=u:r:hal_fingerprint_default:s0
  tcontext=u:object_r:fingerprintd_data_file:s0 tclass=dir
  permissive=1

Change-Id: I624acde27d157daa473179980af30abd82b51131
2018-11-15 21:17:28 -07:00
Cal Archer 01be0409e2 fix USB audio support
fw/b changes in Oreo cause some USB audio devices
which were previously recognized as AUDIO_DEVICE_OUT_USB_DEVICE
or AUDIO_DEVICE_OUT_USB_ACCESSORY now to be recognized as
AUDIO_DEVICE_OUT_USB_HEADSET (0x4000000), causing this error:

AudioPolicyManagerCustom: setDeviceConnectionState() could not find HW module for device 04000000

BUGBASH-2398

Change-Id: If1f6c760e28a2daeb3855c86fc561c7e5e85f0bf
(cherry picked from commit 36fb5d9d181a7e0ae8dd5f2e93a1f5f1a70d1302)
2018-11-05 05:34:46 +02:00
jrior001 a33190af8a
klte-common: nfc: remove unsupported MAX_RF_DATA_CREDITS config
Change-Id: I63eb31cfd62d135b63d04f3dafcd08de7319346d
2018-10-08 19:12:18 -06:00
Andre Eisenbach 8b0c1bcc23
klte-common: Rename libnfc-brcm.conf -> libnfc-nci.conf
Test: manual
Merged-In: I9655a14e021024540cf342022cb817e1f8d0f9ad
Change-Id: I9655a14e021024540cf342022cb817e1f8d0f9ad
2018-10-08 19:12:18 -06:00
nx111 2e8f6982f1
klte-common: Set SDK API level for rild
* P made changes to pthread_mutex_init() that are incompatible
  with our libsec-ril libraries. In order for rild to even see a
  radio as being availble we need the legacy behavior.
* Even though our libsec-ril libraries are from 5.0, which is API
  level 21, we do not appear to require any of the other behaviors
  from API levels earlier than 27.

Change-Id: I3b3d0160236df09bdae95c5d9f10a61bf91ebc72
2018-10-08 19:12:18 -06:00
Kevin F. Haggerty 7d0ac47ff7 klte-common: proprietary-files: Update source package note
* G900FXXU1CRH1_G900FOXA1CRH1_BTU

Change-Id: I0748584777ce61a4a10566d372dc6b6498ef6bb7
(cherry picked from commit 630ee7fda60d183721790187d4b2297046157dd7)
2018-10-08 15:25:39 +02:00
Kevin F. Haggerty 14c7605df9
klte-common: Stop building sensors.msm8974
* msm8974-common has moved to hwbinder mode for sensors, with the
  multihal statically linked into the impl. We don't need this
  version of the multihal anymore.

Change-Id: Id9e9103bb03351cef2a7cb0e81800057898fe862
2018-09-22 10:04:42 -06:00
Kevin F. Haggerty 787f55dbbd
klte-common: Set SDK API level for required executables
* This singularly handles both text relocation (M) and mutex (P)
  linker restrictions
* mediaserver - Needs text relocations
* mm-qcamera-daemon - Needs both text relocations and mutex restrictions
  relaxed

Change-Id: I97a79fb57aaadf5cf62894489522b2de6d8c2e36
2018-09-22 10:04:36 -06:00
Kevin F. Haggerty e0733f9f48
klte-common: Commonize camera packages and manifest entries
Change-Id: Ie8b564606e5c8e99d76bcc73d8fa020001b75337
2018-09-15 12:02:15 -06:00
Lucas Dupin b9ba70686a
klte-common: Renamed config_dozeAfterScreenOff
New name is config_dozeAfterScreenOffByDefault
Bug: 73178121

Change-Id: Ie3d1ea5a2cc480655592bf6e49b37f5ea07f3f58
2018-09-07 13:18:01 -06:00
Kevin F. Haggerty bb32b1c672
klte-common: Remove irrelevant BOARD_HAVE_NEW_QCOM_CSDCLIENT flag
* This only exists in audio-caf/msm8960. It's not for us.

Change-Id: I5ddbbb6b45f42bd485ddb09619e918c74fb82369
2018-09-07 13:18:00 -06:00
Bruno Martins 2b748f4635 klte-common: Update prefixes for audio system properties
* All vendor-specific properties are required to have vendor prefixes

Change-Id: I562639e93b8eca4914473575c13da958224181f8
2018-09-07 21:00:37 +02:00
Glen Kuhne 0439e056e6 klte-common: Add p2p_no_group_iface=1 to p2p_supplicant_overlay
Configures wpa_supplicant to use p2p0 mgmt iface instead of dynamically
created p2p-p2p0-XYZ virtual interfaces for P2P group.

Bug: 65524423
Test: CtsVerifier WifiDirect
Test: Manual verification
Change-Id: I70582f114ab69684424aac41fbeb78fa7cc04847
Merged-In: Id9add59aa122adb7f39c80252061a8f5d3cc55cd
2018-09-07 20:59:28 +02:00
Roshan Pius 2edb480242 klte-common: wpa_supplicant(hidl): Add support for starting HAL lazily
Bug: 72394251
Test: Able to start supplicant from framework using
ISupplicant.getService()
Change-Id: I19b8434e7241b9028e7dc86316ec9d5512affcca
2018-09-07 20:59:02 +02:00
Roshan Pius 3a27833cd6 klte-common: Don't start supplicant with interfaces
Framework will now add interface to supplicant (via HIDL) when it
needs to control an interface, so don't specify them in the startup
params.

Bug: 69426063
Test: Device boots up and able to connect to wifi.
Change-Id: I817d28093f8b982e3806c212babd888c0f5eb7c0
2018-09-07 20:58:21 +02:00
Jeff Vander Stoep db257250cf klte-common: wpa_supplicant: Move control sockets to /data/vendor
Treble compliance.

Bug: 70228425
Bug: 70393317
Test: complete wifi test in b/70393317
Test: verify sockets exist in /data/vendor/wifi/wpa/sockets

Change-Id: I0bfc3a351419f0a03498e79664949f353369bf1b
2018-08-21 21:46:29 -06:00
Jeff Vander Stoep 3a48b9c130 klte-common: wifi_supplicant: deprecate entropy.bin
Wpa_supplicant's random pool is not necessary on Android. Randomness
is already provided by the entropymixer service which ensures
sufficient entropy is maintained across reboots. Commit b410eb1913
'Initialize /dev/urandom earlier in boot' seeds /dev/urandom with
that entropy before either wpa_supplicant or hostapd are run.

Bug: 34980020
Test: Use wifi and wifi tethering on 8974 targets
Change-Id: Iaa2a8a42e4e3fd941c5be0f8fa691245cdb429e9
2018-08-21 21:46:29 -06:00
Jeff Johnson 41fbb27e8a klte-common: wlan: Update supplicant services for new calling sequence
Change-Id: I9a2b5b2c27c8fd0e7b13e78cf02985c1c19db1b6
2018-08-21 21:46:29 -06:00
Jerry Zhang 9589d29127 klte-common: Set sys.usb.ffs.aio_compat
The kernel does not support aio with ffs.
Set the property so adb/mtp know to use the compatible
functions, and the same while in recovery.

Bug: 37916658
Test: Use adb / use adb in recovery
Change-Id: Id35a05fcb9952dcf7239bd15a61cc620537419bc
2018-08-21 21:46:29 -06:00
Steve Kondik b7220270dc klte-common: Increase heap start size to 16m to minimize GC with larger bitmaps
Change-Id: I89af5e94c9aafdc6007c84d3fce60e4db349e967
2018-08-21 21:46:29 -06:00
Bruno Martins 98e211ff8c klte-common: Import stock Dalvik heap overrides
Change-Id: Ifac6650a874cf982a6e767da92599d4b6230a637
2018-08-21 21:46:29 -06:00
Michael Bestas 142d84b85b klte-common: Move wpa_supplicant overlays to vendor
Change-Id: I42e8994585615c15fb069166a79b86488e8acb25
2018-08-21 21:46:29 -06:00
Kevin F. Haggerty 452e013f50 klte-common: Use TARGET_COPY_OUT_VENDOR instead of explicit path
Change-Id: I5835a05b7f357cfe666090907a1a4a89781a68dc
2018-08-20 06:33:17 -06:00
T H 8a4570cb82 klte-common: Use sensors MultiHAL
Change-Id: I527e72e2e0419931ba21137826774f5b65299f92
2018-08-04 02:08:10 +02:00
Danny Baumann ed5ede4467 klte-common: Update call recording overlay.
Change-Id: I3428fa6e47318b195a8dc46731e0aabc14a9a8e7
2018-07-23 19:53:45 -06:00
Kevin F. Haggerty 67f1192cd0 klte-common: Remove hwui properties
Change-Id: Id5f75dd39c0d385f30e6e8efe7dbe92ad017a688
2018-06-28 15:32:59 +02:00
Paul Keith dd53dc40b1 klte-common: Add support for klteactivexx
Change-Id: I2414653ab03dc45209dc4908166bc4c9d7de0e4d
2018-06-27 16:20:37 +02:00
Paul Keith 005ba34fb8 klte-common: Reorder tetherable connection types
* In O, the default setting for mobile data always active was
  changed from off to on, meaning that when non-WiFi tethering
  is being attempted, more than one connection can be active
* Since the first active connection type in this overlay is used,
  reorder the values to get WiFi connections first, and then
  any type of mobile data connection, instead of vice versa

Change-Id: I41f31ba1a2793e209ff439c9ba28a390fecdeecb
2018-06-23 08:49:32 -06:00
Nolen Johnson 873171b878 klte-common: Define Vendor security patch level
* This is needed for Trust, as we don't have a Vendor image that sets a
  valid vendor security patch level.

* Taken from the G900FXXU1CRA2_G900FOXA1CRA2_BTU Factory Image.

Change-Id: I105cc7e464e581683c6784e3aef8f7297b90aea0
2018-06-23 07:15:41 -06:00
Kevin F. Haggerty 89f2e08531 klte-common: Drop libshim_cutils_atomic
* We have included the appropriate android_atomic methods in libril,
  so the symbols are loaded into the process space and the libsec-ril*
  dependencies for all builds are handled.

Change-Id: I93289af789df7e263488e1db29bdbde0d0964e97
2018-06-15 15:12:48 -06:00
Kevin F. Haggerty f3442d4a1b klte-common: Rework shims
* Recent binder changes caused our approach of shimming libcutils to
  re-add the non-inlined android_atomic* methods to start getting
  slapped, at least with NDK apps. This looks oddly similar to the
  heads-up we received in 7.0, so no clue why it let us do it in 8.*
  prior to now.
* See: https://developer.android.com/about/versions/nougat/android-7.0-changes#ndk
* We did this because all of the libsec-ril* blobs and libuiblur
  needed it and doing each and every libsec-ril seemed fragile and
  fraught with the potential for error, but "fragile and fraught with
  the potential for error" is better than "phone breaking". And blur
  doesn't seem to ever be coming back.
* We'll leave the "standard" libsec-ril.so here and let the
  individual devices handle anything specific if they have variant-
  specific blobs

Change-Id: Ib11048e4924f34ade20f44b707f0106e139f2f82
2018-06-14 06:28:11 -06:00
Paul Keith 4cab6270ec klte-common: Stop abusing global contexts for fingerprint
* vcs_device is used to label /dev/vcs*, which are virtual consoles
* Create and use our own label for /dev/vfsspi so our fingerprint
  hal can access it, and rename vcs_data_file while we're at it

Change-Id: I01f0e8c4924d3847383319ce59dbbf802f89a36b
2018-05-15 14:02:21 +02:00
Kevin F. Haggerty 12e09aa4d8 Revert "klte-common: Enable legacy mediaserver"
This reverts commit aee12a34df.

* No Samsung msm8974 device is going to develop an OSS camera HAL
  at this point. Move this common stuff to msm8974-common.

Change-Id: Ib0bb18fe819e2ebbb39c9b278ccf687444f65488
2018-04-23 22:37:03 -06:00
Paul Keith d6249aa5b2 klte-common: Use passthrough manifest for all NFC chips
* And make a common nfc board stub while we're at it

Change-Id: I4ef9c69ebbff539924ba4dc10c8035521dbf5424
2018-04-11 01:44:00 +02:00
Paul Keith aadb44c0dc klte-common: Use sdfat for exfat and vfat
Change-Id: I660c5b3008636a651a2812fe1739ff8a2ea845cb
2018-03-28 14:06:25 -06:00
Michael Bestas 31947756a3 klte-common: Get rid of recovery-only fstab
* Mounting /system partition is handled in kernel now,
   however removing the entry from fstab caused issues building
   the OTA. The workaround was to have a separate fstab, but turns out
   that simply setting the recoveryonly flag does the trick because
   those are then ignored during a normal Android boot.

Change-Id: I2944384d0a1c41bc9f9f51e2e29daff2bed0a0f4
2018-03-27 21:44:24 -06:00
Cal Archer d091dbd3db klte-common: camera: add video HDR, phase-af and DRC
Note video HDR setting in Snap is only available
in Snap advanced settings at the very bottom of the menu.

Change-Id: Ia2d907aa5b20be6134bc3594684a423cf199f925
2018-03-05 21:23:23 -07:00
Cal Archer 4c4b746349 klte-common: fix camera ISO setting in Snap
Change-Id: I95ee3e06078ea1910d6bc11d9269313d43d59cdb
2018-03-05 21:23:23 -07:00
Cal Archer 8b8ab824ca klte-common: fix camera hal shim
* fixes binary garbage in CameraParams
* fixes HDR

Change-Id: Ia33924414b3616682c6eeab6b732ee55df8bb2ce
2018-03-05 21:23:23 -07:00
Kevin F. Haggerty 9d1c38d6ab klte-common: sepolicy: Label sysfs nodes for power HAL
Change-Id: I0fa2297ebb219421ad59a49836b9a39ece0843af
2018-03-01 04:42:08 +00:00
Kevin F. Haggerty 30d27eb628 Revert "klte-common: Enable legacy f_adb interface support"
This reverts commit 2a20e4cfc5.

* blek fixed it

Change-Id: Id40a86d92d17b9fd2a5f5cf1f590038616b8b343
2018-02-28 21:21:52 -07:00
Paul Keith 435b4ae064 klte-common: Update kernel exfat flag
Change-Id: Ic182471b28ec91340b13cdc6cad64a64772f4641
2018-02-24 14:43:48 +00:00
Paul Keith 74f7c031d8 klte-common: Set proper permissions for mDNIe nodes
Change-Id: Ib5d2825bb50c90b6743157bd624e7156c6d5ad01
2018-02-22 20:13:06 -07:00
Paul Keith c8d45dba1c klte-common: Transition to TARGET_LD_SHIM_LIBS
* Limits security exposure from shims

Change-Id: I877192422062f3e59c81a7130ad1a2b4be5d1647
2018-02-16 16:44:53 +01:00
Kevin F. Haggerty 9da1285c16 klte-common: init: restorecon .wifiver.info on boot
* We're messing with ownership and permissions here, so let's go
  ahead and fix the context of this near worthless thing.
* The kernel will create it, we also write it here which will create
  if it doesn't exist, so this is more manageable than chasing the
  type_transition path
* The file is already labeled as a wifi_data_file, so fix this to
  eliminate the below denial

avc: denied { read } for name=".wifiver.info" dev="mmcblk0p26"
  ino=12 scontext=u:r:hal_wifi_default:s0
  tcontext=u:object_r:system_data_file:s0 tclass=file permissive=0

Change-Id: Ie736b68f7d4d8559237b5cce072c6bf26f7ac4e7
2018-02-16 07:21:09 -07:00
Kevin F. Haggerty 01ebfad97a klte-common: sepolicy: Allow FP HAL more privs for vcs_data_file
avc: denied { read } for name="validity" dev="mmcblk0p26"
  ino=219889 scontext=u:r:hal_fingerprint_default:s0
  tcontext=u:object_r:vcs_data_file:s0 tclass=dir permissive=0
avc: denied { write } for name="validity" dev="mmcblk0p26"
  ino=219889 scontext=u:r:hal_fingerprint_default:s0
  tcontext=u:object_r:vcs_data_file:s0 tclass=dir permissive=0
avc: denied { create } for name="finger.db"
  scontext=u:r:hal_fingerprint_default:s0
  tcontext=u:object_r:vcs_data_file:s0 tclass=file permissive=0

Change-Id: I2e0caa8b3763b8cdcd19b40d174f1a8fc3dc332e
2018-02-15 21:45:17 -07:00