1050 Commits

Author SHA1 Message Date
Yu-Han Yang
ef7bdefa61 Fix serialization bug in GpsNavigationMessage
Bug: 196970023
Test: presubmits passing.
Change-Id: I69f51eb2faac0cf2ee9f7a5f94f7100925f7221c
2021-09-22 01:46:44 +00:00
TreeHugger Robot
a5117ca3b4 Merge "Allow negative value for CorrelationVector#samplingStartM" into sc-dev 2021-08-12 07:17:47 +00:00
TreeHugger Robot
b42181c3be Merge "Fix Location equals()" into sc-dev 2021-08-11 01:52:31 +00:00
Soonil Nagarkar
271b907bab Fix Location equals()
Should handle extras in a better manner.

Bug: 196075248
Test: presubmits + manual
Change-Id: I89e45c289b26ea97486c5a72feb0a805c8c1a950
2021-08-10 14:25:39 -07:00
Soonil Nagarkar
309ab3bb49 Log locations received by default and add javadocs
Logging received locations was originally removed over fears it would be
too spammy, but it is proving too difficult to debug without at least
some logs here.

Bug: 196053011
Test: manual
Change-Id: Ie18baa26daca9ad761125ad07a734f27fabfd89e
2021-08-10 09:58:31 -07:00
Shinru Han
e19a11cf6f Allow negative value for CorrelationVector#samplingStartM
Bug: 195934893
Test: atest ctsLocationPrivilegedTestCases
Change-Id: I255e118cabf274811b57e88a35faf8c9e697d8ae
2021-08-10 10:36:53 +00:00
Soonil Nagarkar
e58fea5a45 Add ADAS GNSS bypass functionality
ADAS applications on automotive device require a way to access GNSS
sensors even when the master location toggle is off, so that they can
provide automotive safety services.

Bug: 156688086
Test: atest LocationProviderManagerTest
Change-Id: I438a781b2202c488da97f7ea732f87403d1068e4
2021-06-23 11:11:50 -07:00
Yu-Han Yang
cfd524f1b6 Merge "Fix ADR half cycle ambiguity doc (frameworks/base)" into sc-dev 2021-06-22 19:07:51 +00:00
TreeHugger Robot
d0595d18d1 Merge "Replace "satellite" with "satellite signal" in doc" into sc-dev 2021-06-18 16:02:27 +00:00
Sasha Kuznetsov
3e4cfb9ac7 Fix ADR half cycle ambiguity doc (frameworks/base)
Bug: 190846015
Test: N/A
Change-Id: Ib954ac948f7e2ac4684bcc02b553bb2a3c61e853
2021-06-17 09:53:24 -07:00
Yu-Han Yang
327919c2dc Replace "satellite" with "satellite signal" in doc
Bug: 190263418
Test: doc update only
Change-Id: I0bec883c5b64d3e9fb2b7e3436aef3cc58a7e53a
2021-06-16 14:34:28 -07:00
Soonil Nagarkar
a244ceeb2e Merge "Fix bugs in LocationManagerService and AppOpsPolicy" into sc-dev 2021-06-16 15:37:32 +00:00
Soonil Nagarkar
4aa42bdb17 Fix bugs in LocationManagerService and AppOpsPolicy
LocationManagerService was overwriting location source appops tag
information whenever a location provider changed state. Since multiple
location providers can correspond to the same uid/app id, this could
lead to loss of tags. This is fixed by recalculating the set of tag for
an entire app id any time a uid changes.

AppOpsPolicy had a bug where tag lists coming from different uids under
the same appid would inappropriately overwrite each other. This is fixed
by modifying the internal/external APIs to work in terms of appid rather
than uid, so that it is someone else's responsibility to ensure the
result is valid for the app id as a whole.

Also fixes a bug where LMS assumes tag listeners are added prior to any
providers. If listeners are added after some providers they will miss
updates. Fixed by always updating the listener on registration.

Bug: 190073375
Test: manual
Change-Id: Ib52d752d857b6ac3b6683186a8d1bbcb814fb798
2021-06-15 08:45:44 -07:00
Soonil Nagarkar
08cb5412af Minor eventlog and LocationProviderBase cleanups
Change eventlog behavior solely based on logging properties, not the
debug build. This allows for reduced logging even on debug builds. Minor
updates to LocationProviderBase.

Bug: 190609486
Test: manual
Change-Id: I1efb28663de7ddd4224b01afe195baf3ff78ddb0
2021-06-09 17:29:11 -07:00
Soonil Nagarkar
59b24345c9 Revert implict min update interval to 1/6 of interval
Keeps same behavior from previous releases.

Bug: 190427917
Test: none
Change-Id: I5f80bbe202ce1137c702e90f2b54a285a7628c94
2021-06-07 14:57:29 -07:00
Colin Cross
fe09091214 Set dist_group: "android" for frameworks/base java_sdk_libraries
dist_group replaces owner and the default is going to change, set it
to the current default "android" for frameworks/base java_sdk_libraries.

Bug: 186723288
Test: m checkbuild
Change-Id: I1526853951bcffbe5c5aec6fbc6ba8e0dbea95ad
2021-06-02 13:49:22 -07:00
Jeff Sharkey
725a2ea256 Clean up "Deprecated at Birth" APIs.
When APIs are refactored mid-release, they can often be left marked
as @Deprecated with the intention of eventually removing them before
the SDK is finalized.

Well, the time has come to finalize the SDK, so let's clean them up.

Bug: 189325658
Test: manual
Change-Id: I48e3e1c1306fbaf071e4acfd9e8107e6ad564ffe
2021-05-26 13:09:00 -06:00
Joe Huang
9d78bec9fa Merge "SatellitePvt API council review" into sc-dev 2021-05-22 04:46:24 +00:00
Joe Huang
8945fbb3a1 SatellitePvt API council review
Remove getFlags/setFlags, determining the flag in Java side

Bug: 188798284
Test: atest CtsLocationPrivilegedTestCases, also try setting different flags in HAL to see if CTS can be passed.
Change-Id: I231148b62404ee4873da60546eebb75d83fae9a7
2021-05-22 02:02:53 +08:00
Soonil Nagarkar
1ea818347e Update location bypass allowlist
Create a new DeviceConfig entry to replace the prior Settings entry on
which the location ignore settings allowlist is based. This allows us to
allowlist based on attribution tag, and eliminate holes for large
applications.

Test: manual + CTS + GTS
Bug: 187421886
Change-Id: I31e61db79b93e202bd8c66efae1bb5aaf0c88ff5
2021-05-21 09:25:47 -07:00
Joe Huang
ce10acd0af Add valid satellite PVT fields in JNI & framework
Bug: 187145250
Bug: 188225075
Test: atest CtsLocationPrivilegedTestCases, also try setting different flags in HAL to see if CTS can be passed.

Change-Id: Ie5e11ebd5516dffcf80373805a7b37668f7db8a0
2021-05-15 04:23:17 +00:00
Joe Huang
88385cc1f0 Merge "Add additional doc for SatellitePvt" into sc-dev 2021-05-10 17:07:40 +00:00
Yu-Han Yang
83a305a089 Merge "Revert "Remove dynamic location settings footer"" into sc-dev 2021-05-08 15:58:10 +00:00
Yu-Han Yang
7b1f58ce2d Revert "Remove dynamic location settings footer"
Revert "Remove dynamic location settings footer"

Revert submission 13809184-location_footer

Reason for revert: b/187211885

Reverted Changes:
Iaf14044e0:Remove dynamic location settings footer
Ifa6468b11:Remove dynamic location settings footer
If3ab49241:Remove dynamic location settings footer

Bug: 187211885

Change-Id: Ib53c42b3583fd93c87d21feb9882f3431b133d40
2021-05-08 15:57:26 +00:00
Joe Huang
027bb813be Add additional doc for SatellitePvt
Bug: 183239007
Test: atest CtsLocationPrivilegedTestCases
Change-Id: I30a0ff67c2523ab08505c2761594b64f48c23a21
2021-05-08 04:51:52 +00:00
TreeHugger Robot
bc8bb62683 Merge "Fix cache by userId bugs" into sc-dev 2021-05-03 18:40:52 +00:00
Soonil Nagarkar
da4d1c3639 Fix cache by userId bugs
Three bugs were present here:

1) isLocationEnabled() will return incorrect results for USER_CURRENT
and USER_CURRENT_OR_SELF
2) Disabling the location enabled cache does not work properly in the
system process, we only disable the cache for a single instance of
LocationManager.
3) isLocationEnabled() was not respecting the user as defined by the
context used to create the LocationManager.

Bug: 185401689
Test: atest CtsLocationFineTestCases
Change-Id: I84bff02604a4b2d84494a0e099e172c4ffb400a2
2021-04-29 12:44:03 -07:00
TreeHugger Robot
d582f3d1c3 Merge "Clarify ISB sign in Javadoc" into sc-dev 2021-04-28 02:24:54 +00:00
Yu-Han Yang
331748aa07 Clarify ISB sign in Javadoc
Bug: 162508535
Test: doc update only
Change-Id: I3267a8b02d47e780cf1124a0882a26958383dd5f
2021-04-27 09:36:40 -07:00
Soonil Nagarkar
ad53af1fa7 Update Geocoder docs to strengthen warnings
Bug: 177616061
Test: none
Change-Id: I81bcd4530fd7064ade8be00e0ad6d126cb9ab6f6
2021-04-22 19:05:50 -07:00
Soonil Nagarkar
1cfbcfef5c Update location time docs
Updates various docs around location time, and also fixes up some
deprecated method usage.

Bug: 184726840
Test: presubmits
Change-Id: I79365e2a3608c8eaeba954b7c193775e98fb2a91
2021-04-15 11:12:57 -07:00
Treehugger Robot
9864e155a8 Merge "[LSC] Add LOCAL_LICENSE_KINDS to frameworks/base" am: 7226ad3729 am: a087245e03 am: 3dd40d172b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1661581

Change-Id: I99cb5fd94c4ee02688709ad00e3ffbc3e2f388e7
2021-04-01 13:47:07 +00:00
Treehugger Robot
3dd40d172b Merge "[LSC] Add LOCAL_LICENSE_KINDS to frameworks/base" am: 7226ad3729 am: a087245e03
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1661581

Change-Id: I70994b32bd4a68bb3d3062d349cc833ba2edf5a0
2021-04-01 13:02:13 +00:00
Bob Badour
de423b7a58 [LSC] Add LOCAL_LICENSE_KINDS to frameworks/base
Added SPDX-license-identifier-Apache-2.0 to:
  drm/java/Android.bp
  graphics/java/Android.bp
  identity/Android.bp
  identity/java/Android.bp
  keystore/java/Android.bp
  location/java/Android.bp
  location/tests/Android.bp
  lowpan/java/Android.bp
  media/mca/effect/java/Android.bp
  media/mca/filterfw/java/Android.bp
  media/mca/filterpacks/java/Android.bp
  mime/java/Android.bp
  mms/java/Android.bp
  opengl/java/Android.bp
  rs/java/Android.bp
  sax/java/Android.bp
  services/tests/servicestests/test-apps/PackageParsingTestManifests/Android.bp
  telecomm/java/Android.bp
  telephony/common/Android.bp
  tests/FlickerTests/test-apps/Android.bp

Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD to:
  telephony/java/Android.bp

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all

Exempt-From-Owner-Approval: janitorial work
Change-Id: I2ee0af9ce8f74de2172b359b41d2c52a8b8f7e6c
2021-03-31 19:55:25 -07:00
Anton Hansson
5013902a24 Merge changes I97086e30,Ic55df4cf,I81a08c29 am: 4199ef90b9 am: 4bc578052d am: ec1f981309
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1655736

Change-Id: I5d242cf5b18c4b556105cfcfe78df2ac18a8544e
2021-03-31 18:01:32 +00:00
Anton Hansson
ec1f981309 Merge changes I97086e30,Ic55df4cf,I81a08c29 am: 4199ef90b9 am: 4bc578052d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1655736

Change-Id: Ib8d66e1fb8845f3b47fd6e81091c0286ca6c8c9c
2021-03-31 17:32:14 +00:00
Anton Hansson
9b2c4a650b Move framework java filegroups into subdirectories
All the java code used to build the framework jar and run metalava
was previously defined in the toplevel Android.bp files. Move these
into the subdirs where the source actually lives.

This simplifies the rules themselves (no path and needless prefix) and
declutters the top level Android.bp.

Test: m
Change-Id: I97086e309eacb879d16facb8497d9940fa5ddaf6
2021-03-30 12:26:55 +01:00
Shinru Han
c247fad24e Merge "Add docs to SatellitePvt class" into sc-dev 2021-03-26 09:59:31 +00:00
Soonil Nagarkar
2b8a31a838 Merge "Remove dynamic location settings footer" into sc-dev 2021-03-25 21:08:32 +00:00
Shinru Han
25474af18c Add docs to SatellitePvt class
Bug: 183670215
Test: comment only
Change-Id: Ie9cef6f22d8a9b020ce081ca18e02f43eb259188
2021-03-25 14:46:52 +08:00
Soonil Nagarkar
1f731d7bb1 Merge "Make Location.setMock() public" into sc-dev 2021-03-25 01:19:47 +00:00
Soonil Nagarkar
ed28be3633 Make Location.setMock() public
Also renames *FromMockProvider to *Mock for clarity.

Bug: 183632564
Test: atest CtsLocationFineTestCases
Change-Id: Ic3b2cc2ec69d6a632e347868e7cc53e56e7400b0
2021-03-24 12:26:00 -07:00
Shinru Han
2bd6304749 Add capability bit for Bluesky driving
Bug: 182304682
Test: on cuttlefish
Change-Id: Ic4655c5002712f7872c5a090986da5565ab63278
2021-03-24 11:17:32 +08:00
Soonil Nagarkar
c257baefb5 Refactor ServiceWatcher
Split it up into more generic and useable components that are not as
location specific.

Bug: 182491144
Bug: 181665909
Test: presubmits
Change-Id: I2d6d5e70328657a7430e170531402cb3acbed028
2021-03-22 20:27:31 -07:00
Soonil Nagarkar
1dc7b05ca3 Fix logging bugs
Adds additional logging around user switches, and fixes a bug where
location toggle changes were not logged correctly.

Bug: 183409327
Test: manual
Change-Id: I36fdef5c3eddd3db70d7c18506f82bb687677120
2021-03-22 15:00:51 -07:00
Yu-Han Yang
1bdbcffaa1 Merge "Update Javadoc of getData() for IRNSS" into sc-dev 2021-03-17 17:47:47 +00:00
Shinru Han
473ebd77d5 Add comment for getMagnitude in CorrelationVector
Bug: 179389247
Test: comment only
Change-Id: I826e7a34940267a32e37ed57074e17c0c17b1515
2021-03-17 11:32:06 +08:00
Yu-Han Yang
67738c9a38 Update Javadoc of getData() for IRNSS
Bug: 182848571
Test: javadoc only
Change-Id: Ia72f8c4cb2bd78ea4b399d3d4bfff6107fa3875b
2021-03-15 18:40:26 -07:00
Soonil Nagarkar
a157bb3399 Remove dynamic location settings footer
Replace with plain text.

Bug: 182210346
Test: manual
Change-Id: Iaf14044e08ca8f4e09f38a96bbe4d2c66a100b13
2021-03-08 15:23:40 -08:00
TreeHugger Robot
2d98e149eb Merge "Fix the return type of getFrequencyOffsetMetersPerSecond" into sc-dev 2021-03-08 18:10:51 +00:00