History log of /system/libvintf/RuntimeInfo.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
9893552f4395296e509ce0d006b32593cb748d69 16-Apr-2018 Yifan Hong <elsk@google.com> Compat if POLICYVERS <= security_policyvers()

POLICYVERS in the build system specifies the
policydb version that the policy is compiled with.
security_policyvers() specifies the maximum
policy version that the kernel is compatible with.
Allow POLICYVERS <= security_policyvers() to be considered
compatible.

This changes compatibility check logic for RuntimeInfo,
hence this does not affect OTA, except the following
case:

* device kernel reports 30
* new images are built with POLICYVERS=31
* fwk matrix has 31
* device do OTA with these images
* OTA will fail

Right now, since there are no plans to bump POLICYVERS
in build system (and it stays 30), OTA won't break.

Bug: 77886167
Test: vts_treble_vintf_test
Change-Id: I91fb631b291d17e26ad1a9befb669aac6b7ed654
Merged-In: I91fb631b291d17e26ad1a9befb669aac6b7ed654
/system/libvintf/RuntimeInfo.cpp
db6423e7f0d1d3d40aa84c81ccdee06db438c653 11-Sep-2017 Yifan Hong <elsk@google.com> Allow to disable certain checks in VintfObject::CheckCompatibility

Allow to disable AVB version checks.
Test: builds
Test: vintf_object_test
Test: libvintf_test

Bug: 38325029
Bug: 65270190
Change-Id: Iadc2408f635a5487a5af4e19f516147930f4bc4b
Merged-In: Iadc2408f635a5487a5af4e19f516147930f4bc4b
/system/libvintf/RuntimeInfo.cpp
d776d20386b03780f31856dcee687c5f3187aa3e 23-Aug-2017 Yifan Hong <elsk@google.com> Match /proc/config.gz with fwk comp mat <kernel> fragments

Multiple <kernel> elements with the same version can
exist. The <condition> element decides whether the <kernel>
element is actually used during matching.

Test: libvintf_test
Bug: 64124223

Change-Id: I0dd28b8b1bdfe06a4da61aaa81df91f4df5fcf26
Merged-In: I0dd28b8b1bdfe06a4da61aaa81df91f4df5fcf26
/system/libvintf/RuntimeInfo.cpp
630e5bdc42f4082ea6f1f31f141797ba7f0be13d 15-Aug-2017 Yifan Hong <elsk@google.com> Enable AVB version matching in Runtime

Test: `adb shell vintf` shows compatible
Test: boots
Bug: 38325029
Change-Id: I6857a391bfa2a6f8ef68a2ac0374c7e5c8f62e93
Merged-In: I6857a391bfa2a6f8ef68a2ac0374c7e5c8f62e93
/system/libvintf/RuntimeInfo.cpp
9d12b79715b80475221b88b1147482060668baf9 23-May-2017 Yifan Hong <elsk@google.com> Workaround to disable check for avb in fwk matrix

Until <avb> is injected to fwk matrix, disable the check against
runtime information. This is to allow new devices to still work.

Bug: 38325029
Test: on new devices, adb shell vintf | tail
Change-Id: I1efececf2e24ca4f3d68ac3c0ebbdb3f11dd4174
Merged-In: I1efececf2e24ca4f3d68ac3c0ebbdb3f11dd4174
/system/libvintf/RuntimeInfo.cpp
5cfbc92dbc3972c793e9c793b7dd4977a63f5faf 08-May-2017 Michael Schwartz <schwartzmi@google.com> Improve error message for AVB failures

Bug: 38131335
Test: `m -j libvintf_test` and run test.
Change-Id: I952da9d08cfb0e16855bf63167e6067716abe777
/system/libvintf/RuntimeInfo.cpp
3477f0479f1075d9812ac20188e096510f171db8 08-May-2017 Yifan Hong <elsk@google.com> Remove sepolicy files from libvintf.

CTS device info collects sepolicy files via
adb pull, not via libvintf.

Changes RuntimeInfo::fetchAllInformation
errors to warnings.

Bug: 38070361
Test: pass
Change-Id: I5157efcbe65940bc5e71f5df8b6e3f208368797c
Merged-In: I5157efcbe65940bc5e71f5df8b6e3f208368797c
/system/libvintf/RuntimeInfo.cpp
ab0e6e7cb76c6b3f9439d4f902b4a48c68e6ac92 26-Apr-2017 Yifan Hong <elsk@google.com> Add getters to RuntimeInfo

They are used by Java API.

Test: pass
Bug: 28656227
Change-Id: I612692b96a9df69dca5cf4d1b15fc6ec45c86ee7
/system/libvintf/RuntimeInfo.cpp
881a9e45aa1666dd0ef105e92cab5f73c1eb6f1e 28-Apr-2017 Yifan Hong <elsk@google.com> Renamed avb version variables in RuntimeInfo.

Old variable names are confusing.

Test: pass
Change-Id: I21d43b0615f52443fcda8c067507d2d7207ec3e7
/system/libvintf/RuntimeInfo.cpp
242eabff291dcd9f6213e250263aa4da6eead2f7 20-Apr-2017 Yifan Hong <elsk@google.com> Add /proc/cpuinfo to RuntimeInfo.

Test: adb shell vintf
Bug: 37513906
Change-Id: I94617cb2ca0ae961ec56b2d22b663ecafbcbed48
/system/libvintf/RuntimeInfo.cpp
f302930a51397aa422355644b5de31439056eb51 13-Apr-2017 Yifan Hong <elsk@google.com> Add avb.vbmeta-version to CompatibilityMatrix and RuntimeInfo

RuntimeInfo fetch avb vbmeta version by reading the following two sysprops:
- ro.boot.vbmeta.avb_version
- ro.boot.avb_version
If the sysprop does not exist, 0.0 is set.

Test: libvintf_test
Test: adb shell vintf (shows 0.0 because CLs
for sysprops are not merged yet)

Bug: 35322304
Change-Id: I345bc792d1a7ceb585d246ec657707814b42ceff
/system/libvintf/RuntimeInfo.cpp
fa2b18bda6b3f8611dc93ebb32209943578a6539 13-Apr-2017 Yifan Hong <elsk@google.com> RuntimeInfo::sepolicyFilePaths for sepolicy files.

Create an API to report sepolicy files. The file paths
are TBD. This is for device info reporting purposes.

Test: pass
Bug: 36456394
Change-Id: Ia769dbb951aa1056e679dbd16f0a7cab1670aaa6
/system/libvintf/RuntimeInfo.cpp
ba3bb68534dc56eb01cece15dd40a3936dd8bb72 13-Apr-2017 Yifan Hong <elsk@google.com> Removed unused clear().

Removed it from CompatibilityMatrix, HalManifest
and RuntimeInfo.

Test: pass
Bug: 34620633
Change-Id: Ie91717dae09cacf974e43827657154055841b39a
/system/libvintf/RuntimeInfo.cpp
25c1eed7f2afdfb0dcd0e23e16de1ab99b3c376c 07-Apr-2017 Yifan Hong <elsk@google.com> Remove libz-host dependency.

RuntimeInfo doesn't need to be retrieved on host.

Test: builds on mac

Bug: 36456394
Bug: 36983271
Bug: 36681384

Change-Id: Ide634663ecf6bf69cd618129b615a98333590866
Merged-In: Ide634663ecf6bf69cd618129b615a98333590866
/system/libvintf/RuntimeInfo.cpp
4d18bcc9a3de245edb20c2469718f8442c758d97 07-Apr-2017 Yifan Hong <elsk@google.com> Revert "Revert "Create assemble_vintf""

Test: builds on mac

This reverts commit dbb9a780e050221fbedbf5bfdf3286994511c07c.

Bug: 36456394
Bug: 36983271
Bug: 36681384

Change-Id: Id01227fd856f56890fdf13035d04054cd2446e75
Merged-In: Id01227fd856f56890fdf13035d04054cd2446e75
/system/libvintf/RuntimeInfo.cpp
43264ce1534c8a85112f89a1773cf268a68cec4d 07-Apr-2017 Yifan Hong <elsk@google.com> Revert "Create assemble_vintf"

Test: none

This reverts commit c371908350ae073a54193db14588fe43548aa3ed.

Change-Id: Ie3b727f69d76ebe519a4c598905a4e16e845c3a4
Merged-In: Ie3b727f69d76ebe519a4c598905a4e16e845c3a4
/system/libvintf/RuntimeInfo.cpp
d7092bae593a2d69adcc573bd438815501985180 05-Apr-2017 Yifan Hong <elsk@google.com> Create assemble_vintf

* Make libvintf available on host
* Created a small binary, assemble_vintf, that utilizes
the host-side libvintf to read the device manifest file
and fill in appropriate information (like sepolicy version)

Test: pass
Test: BORAD_SEPOLICY_VERS=25.0 assemble_vintf -i /path/to/manifest.xml
outputs manifest.sepolicy.version correctly.

Bug: 36456394
Bug: 36983271
Bug: 36681384

Change-Id: I5ea45353e380f9bf8d73f62d54094bef750c0a9d
Merged-In: I5ea45353e380f9bf8d73f62d54094bef750c0a9d
/system/libvintf/RuntimeInfo.cpp
7c7d7063d09e7a06339b6aa71a045990b50b5168 05-Apr-2017 Yifan Hong <elsk@google.com> Add manifest/compatibility-matrix.type attribute

to distinguish device and framework HAL manifest, and
device and framework compatibility matrix.

Add .device / .framework entries to HalManifest and
CompatibilityMatrix class for device-only / fwk-only
entries. Access to these fields should be guarded with
a check to mType.

Test: libvintf_test
Test: boots
Change-Id: Id9c93c1e6bb585234a9ae6d9296f5a10582ef58f
/system/libvintf/RuntimeInfo.cpp
e8b7d95b884d3c5c86f0b9c8c4cf7b1f13ed7cac 05-Apr-2017 Yifan Hong <elsk@google.com> Hide CompatibiilityMatrix::findKernel and getSepolicy

as part of the effort to minimize public API for libvintf.

Bug: 34620633
Test: pass
Change-Id: I0218c317ceae48be45f7c54d29ebf0c702c23150
/system/libvintf/RuntimeInfo.cpp
3daec8116236a720edf3349b59470e41dd6c1056 28-Feb-2017 Yifan Hong <elsk@google.com> Add VintfObject as the top level API.

VintfObject has:
GetDeviceHalManifest (replace HalManifest::Get)
GetRuntimeInfo (replace RuntimeInfo::Get)
GetFrameworkHalManifest

Test: vintf
Test: libvintf_test
Change-Id: I6c1f0e6af0ea323054102bf713667c23dbc10972
/system/libvintf/RuntimeInfo.cpp
a7201e77e0c5221ada625ba5fcf89b25af45c10a 17-Feb-2017 Yifan Hong <elsk@google.com> vintf: KernelInfo -> RuntimeInfo.

There are more runtime information to report to the
OTA server besides kernel information (like avb.meta-version).
Renaming this class to reflect this.

Test: mma
Test: libvintf_test

Change-Id: Ie5863508bdac7a1a378c00528c8fd9853c6c50aa
/system/libvintf/RuntimeInfo.cpp