Game Driver: Add a Settings.Global property for sphal libraries

This change add the GAME_DRIVER_SPHAL_LIBRARIES property to save the
list of sphal libraries assessible to Game Driver.

Bug: 124448366
Test: Build, flash and boot.
Change-Id: I7cb06df80f19d87f5fd13d7df3c991ceb5bdfb06
Merged-In: I7cb06df80f19d87f5fd13d7df3c991ceb5bdfb06
Exempt-From-Owner-Approval: Change in CoreSettingsObserver.java is too
minor
This commit is contained in:
Yiwei Zhang
2019-02-14 10:43:42 -08:00
parent db98f35743
commit eb8d7cc3cd
5 changed files with 15 additions and 0 deletions

View File

@@ -11488,6 +11488,14 @@ public final class Settings {
*/
public static final String GAME_DRIVER_WHITELIST = "game_driver_whitelist";
/**
* List of libraries in sphal accessible by Game Driver
* The string is a list of library names, separated by colon.
* i.e. <lib1>:<lib2>:...:<libN>
* @hide
*/
public static final String GAME_DRIVER_SPHAL_LIBRARIES = "game_driver_sphal_libraries";
/**
* Ordered GPU debug layer list
* i.e. <layer1>:<layer2>:...:<layerN>

View File

@@ -402,6 +402,8 @@ message GlobalSettingsProto {
// Game Driver - List of blacklists, each blacklist is a blacklist for
// a specific Game Driver version
optional SettingProto game_driver_blacklists = 14;
// Game Driver - List of libraries in sphal accessible by Game Driver
optional SettingProto game_driver_sphal_libraries = 16;
}
optional Gpu gpu = 59;

View File

@@ -450,6 +450,7 @@ public class SettingsBackupTest {
Settings.Global.GAME_DRIVER_BLACKLISTS,
Settings.Global.GAME_DRIVER_BLACKLIST,
Settings.Global.GAME_DRIVER_WHITELIST,
Settings.Global.GAME_DRIVER_SPHAL_LIBRARIES,
Settings.Global.ENABLE_GNSS_RAW_MEAS_FULL_TRACKING,
Settings.Global.INSTALL_CARRIER_APP_NOTIFICATION_PERSISTENT,
Settings.Global.INSTALL_CARRIER_APP_NOTIFICATION_SLEEP_MILLIS,

View File

@@ -665,6 +665,9 @@ class SettingsProtoDumpUtil {
dumpSetting(s, p,
Settings.Global.GAME_DRIVER_BLACKLISTS,
GlobalSettingsProto.Gpu.GAME_DRIVER_BLACKLISTS);
dumpSetting(s, p,
Settings.Global.GAME_DRIVER_SPHAL_LIBRARIES,
GlobalSettingsProto.Gpu.GAME_DRIVER_SPHAL_LIBRARIES);
p.end(gpuToken);
final long hdmiToken = p.start(GlobalSettingsProto.HDMI);

View File

@@ -61,6 +61,7 @@ final class CoreSettingsObserver extends ContentObserver {
sGlobalSettingToTypeMap.put(Settings.Global.GAME_DRIVER_BLACKLIST, String.class);
sGlobalSettingToTypeMap.put(Settings.Global.GAME_DRIVER_WHITELIST, String.class);
sGlobalSettingToTypeMap.put(Settings.Global.GAME_DRIVER_BLACKLISTS, String.class);
sGlobalSettingToTypeMap.put(Settings.Global.GAME_DRIVER_SPHAL_LIBRARIES, String.class);
// add other global settings here...
}