summaryrefslogtreecommitdiffstats
path: root/parameter/ParameterMgrPlatformConnector.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Move element tree initialisation to load functionGuillaume Denneulin2015-01-291-6/+0
| | | | | | | | | | | | | | | | | | | | BZ: 207091 The parameter platform manager used to initialize the element tree. However, this is too early for plugins, since they need information from the core which have not been initialized yet. This patch delays the initialization of the element tree by adding it to the load() function of the ParameterMgr. Change-Id: I98e0e3a20ac0af2736eddc4c8349911eb1d1a691 Signed-off-by: Guillaume Denneulin <guillaume.denneulin@intel.com> Signed-off-by: Mattijs Korpershoek <mattijsx.korpershoek@intel.com> Reviewed-on: https://android.intel.com/215426 Reviewed-by: De Chivre, Renaud <renaud.de.chivre@intel.com> Reviewed-by: Benavoli, Patrick <patrick.benavoli@intel.com> Reviewed-by: Rocard, KevinX <kevinx.rocard@intel.com> Tested-by: Rocard, KevinX <kevinx.rocard@intel.com>
* ParameterMgr: add a method to forcefully disable the remote interfaceDavid Wagner2015-01-281-0/+10
| | | | | | | | | | | | | | | In some setup, users might not want to start the remote interface even if the toplevel configuration file allows it. The parameter-framework client can now override the remote interface starting policy. This was, until now, only dictated by the 'TuningAllowed' attribute in the toplevel configuration file and the presence of the libremote-processor library. This method is forwarded to the connectors and the bindings. Change-Id: Ib6dc272dfc7114125fdafd1a58642cde88847752 Signed-off-by: David Wagner <david.wagner@intel.com>
* Add {get,set}SchemaFolderLocation() to the public Pfw APIDavid Wagner2015-01-281-0/+10
| | | | | | | | | | It will allow users to tell the parameter-framework where the Schemas are instead of letting it guess. These methods are also added to both "Platform" and "Full" connectors. Change-Id: I7fe3b2fd2c6dba1d90d36de97e6db7d71b2c686f Signed-off-by: David Wagner <david.wagner@intel.com>
* Make ParameterMgrLogger templateDavid Wagner2015-01-221-1/+1
| | | | | | | | This will make it possible to have different kind of ParameterMgr connectors instead of hardcoding ParameterMgrPlatformConnector in ParameterMgrLogger. Change-Id: Ia78d9f56c8cc73321e1956856755a56a3569b517 Signed-off-by: David Wagner <david.wagner@intel.com>
* Remove using std::XXX from headersSebastien Gonzalve2014-09-111-0/+2
| | | | | This is a bad practice to have using in headers because it pollutes the namespace of any user of that header.
* Test-platform enable/disable xml validationMattijs Korpershoek2014-06-251-0/+18
| | | | | | | | | | | | | | | | | | | | | | BZ: 184054 test-platform has no way to tell to the parameter framework that it wants the parameter framework to validate xmls on loading. New command added to test-platform executable. setValidateSchemasOnStart true|false If set to true, the parameter framework will try to validate the .xmls with the .xsds located next to them. If set to false, it will never attempt to validate. SetValidateSchemas is false by default to allow backward compatibility. Note(a): This assumes that the script is able to find the .xsd files (which should be in /tmp/Schemas/). Change-Id: I7a5b0bc09d31e6647d8c631380d31503666e7e7b Signed-off-by: Mattijs Korpershoek <mattijsx.korpershoek@intel.com>
* Change the license to 3-clause BSDDavid Wagner2014-02-131-23/+28
| | | | | | | Add license header in all source files and Makefiles, Add a "COPYING" file containing the license text. Signed-off-by: David Wagner <david.wagner@intel.com>
* Add an option to continue on failed setting loadKevin Rocard2014-02-121-0/+18
| | | | | | | | | | | | | | | | | BZ: 122982 When the PFW starts it loads the configurable domains, if the load fails, it used to abort the parameterMgr global load. Add an option to continue on failed setting load, as if there were none. Change-Id: Ifd3cd859ad0eaef266be4c9245ebd28c9e9c0a74 Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com> Reviewed-on: http://android.intel.com:8080/119924 Reviewed-by: Centelles, Sylvain <sylvain.centelles@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: cactus <cactus@intel.com> Tested-by: cactus <cactus@intel.com>
* Add missing subsystem policyKevin Rocard2014-02-121-3/+21
| | | | | | | | | | | | | | | | | | BZ: 122982 When the PFW starts it loads subsystems using there corresponding plugin. If the requested plugin is not found, the start fails. This is a problem, as for host, the plugins are not compiled. Add a command in the public API to ignore missing subsystem. Change-Id: I7597e3fef33466638191ff70b76e7faa9f979418 Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com> Reviewed-on: http://android.intel.com:8080/118039 Reviewed-by: Centelles, Sylvain <sylvain.centelles@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: cactus <cactus@intel.com> Tested-by: cactus <cactus@intel.com>
* PFW: Do not stop on hard sync errorsKevin Rocard2014-02-121-4/+5
| | | | | | | | | | | | | | | | BZ: 76263 When synchronization fails, the parameter-framework should log a warning and continue synchronization instead of stopping Change-Id: Ic12d8798ea25584db714ee26e644fac793c28881 Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com> Reviewed-on: http://android.intel.com:8080/81825 Reviewed-by: Centelles, Sylvain <sylvain.centelles@intel.com> Reviewed-by: Denneulin, Guillaume <guillaume.denneulin@intel.com> Tested-by: Dixon, CharlesX <charlesx.dixon@intel.com> Reviewed-by: cactus <cactus@intel.com> Tested-by: cactus <cactus@intel.com>
* PFW: Remove names from PFW license headerKevin Rocard2014-02-121-7/+1
| | | | | | | | | | | | | | | BZ: 47701 As parameter framework code is proprietary, it should not be signed (patrick Benavoli name inside the header). Change-Id: I198f2851ee2a6cffed64a552fa399b072a0cbd3e orig-Change-Id: I335ecce2fa22ad11d6fa24f57c7cbbae3423bf1e Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com> Reviewed-on: http://android.intel.com:8080/59560 Reviewed-by: Mendi, EduardoX <eduardox.mendi@intel.com> Tested-by: Mendi, EduardoX <eduardox.mendi@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com>
* HAL code to be used on tablet -> enforce null pointer protectionFrancois Gaffie2014-02-121-0/+6
| | | | | | | | | | | | | | | | | | | BZ:26933 Audio HAL code is supposed to be also used on tablet. If parameter FW cannot be started, must not bailing out. This patch add a new API to ensure PF is started before calling another API of the PF. Change-Id: I2f9059acf79370fc1cfbae27256060f872fe4ad7 Signed-off-by: Francois Gaffie <francoisx.gaffie@intel.com> Reviewed-on: http://android.intel.com:8080/38892 Reviewed-by: De Chivre, RenaudX <renaudx.de.chivre@intel.com> Reviewed-by: Continente, Christophe <christophe.continente@intel.com> Reviewed-by: Wood, Brian J <brian.j.wood@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com>
* PFW: Type safe dynamic parameter accessPatrick Benavoli2014-02-101-6/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | BZ: 15065 Replaced high level string based parameter access interface with typed ones. Now hosting platforms that want to control parameters must instantiate a CParameterHandle object out of the desired parameter path. CParameterHandle object may be used to access any kind of parameters, whatever its internal type, whether it's an array or not. Note that non rogue parameters offer a read access only. Any attempt to write them will fail. CParameterHandle objects offer the following kind of parameter accessing interfaces: - Boolean - Integer (signed or unsigned) - Double - String Note that those interfaces are available for scalar as well as for array parameters. Not all parameter types support all access kinds. Naturally, array parameters are only accessed via array interfaces while scalar parameters are managed through scalar interfaces. Here's a list of parameter types that may be controlled through each kind of access interface: - Boolean access: boolean, bit (bit size must be one); - Integer access: integer (sign must match), boolean (unsigned access only, value <= 1), enumerations; - Double access: for now only fixed points (soon integers will support them also through platform adaptation objects) - String access: all parameter types In addition, cleaned up parameter access related code so as to make it more generic and reusable. Changed version to 2.0.0 Change-Id: Ib80868cdb773e90962e48f1f38d2ff0029189815 Signed-off-by: Patrick Benavoli <patrickx.benavoli@intel.com> Reviewed-on: http://android.intel.com:8080/25406 Reviewed-by: Barthes, FabienX <fabienx.barthes@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com>
* PFW: file organizationPatrick Benavoli2014-02-101-8/+2
| | | | | | | | | | | | | | | | | | | | | | | | BZ: 12888, 12925, 13285, 13289 - Removed hard coded paths from source files - Separated test related resources and programs into a test subfolder - Schemas folder at root containing the schemas, a symbolic link to that folder might be a good way to enable schema aware editing - Now global configuration file path is passed from the hosting platform instead of the class name. - Global configuration path contains only the relevant class related descriptions (plugin paths, structure, settings) - .user environment file eclipsed through git-ignore (and removed from projects) - Removed system class configuration obsolete files Change-Id: I99b783ba22bca05238a760b2127939a91e976be8 Signed-off-by: Patrick Benavoli <patrickx.benavoli@intel.com> Reviewed-on: http://android.intel.com:8080/25404 Reviewed-by: Barthes, FabienX <fabienx.barthes@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com>
* PFW: Dynamic parameter accessPatrick Benavoli2014-02-101-1/+12
| | | | | | | | | | | | | | | | | | | | BZ: 13272 Added dynamic parameter setting / getting interface for hosting platforms This new API allows: - getting any parameter - setting any parameter as long as it is rogue (attached to no domains) Passed parameter values are in the form of strings. Change-Id: I01a34597fcb4dafb225519cbc01dfffb22b5d52a Signed-off-by: Patrick Benavoli <patrickx.benavoli@intel.com> Reviewed-on: http://android.intel.com:8080/22629 Reviewed-by: Centelles, Sylvain <sylvain.centelles@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com> Reviewed-on: http://android.intel.com:8080/26781 Reviewed-by: Barthes, FabienX <fabienx.barthes@intel.com>
* parameter-framework: SequencePatrick Benavoli2014-02-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | BZ: 13152 - Introduced sequence notion in configurations: Sequences are configuration specific and are controlled from the Settings related XML files (order of settings appearance) as well as from the tuning interface (new commands available to set and get the sequence (setElementSequence / getElementSequence). Notes: - sequences will only matter for domains which new "SequenceAware" attribute is set to true (false by default). This attribute is also controlable through the tuning interface (setSequenceAware / getSequenceAware commands). - sequence unaware domain configurations will be applied before sequence aware ones. To allow for such functionality, the XML for settings format had to be reworked, leading to an unfortunate compatibility break. However, one benefit is that now a clear Settings section appears at the bottom of the domain description, which is easier to maintain than the previous structure where the settings appeared as sub-nodes of associated elements. Change-Id: Ic93552fd510ed8847f9c8e7d9d6164f7ea3c8c45 Signed-off-by: Patrick Benavoli <patrickx.benavoli@intel.com> Reviewed-on: http://android.intel.com:8080/22558 Reviewed-by: Centelles, Sylvain <sylvain.centelles@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com> Reviewed-on: http://android.intel.com:8080/26780 Reviewed-by: Barthes, FabienX <fabienx.barthes@intel.com>
* parameter-framework: Added string parametersPatrick Benavoli2014-02-101-1/+1
| | | | | | | | | | | | | | | | | | | | | BZ: 12819 String parameters are specified in the XML structure with a MaxLength attribute. MaxLength corresponds to the maximum amount of characters the string parameter can handle. String parameters are expressend in the form of tokens, that is they don't contain any sort of space characters. For now, string parameter arrays are not supported. Change-Id: Ifbb006e3d2e3077535c32c0fd579cc04872a82b0 Signed-off-by: Patrick Benavoli <patrickx.benavoli@intel.com> Reviewed-on: http://android.intel.com:8080/22319 Reviewed-by: Centelles, Sylvain <sylvain.centelles@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com> Reviewed-on: http://android.intel.com:8080/26778 Reviewed-by: Barthes, FabienX <fabienx.barthes@intel.com>
* parameter-framework: Changed criterion interfacePatrick Benavoli2014-02-101-3/+20
| | | | | | | | | | | | | | | | | BZ: 9561 - separated selection criterion change event indication form configuration application requests in different APIs - added a way to retrieve selection criterion from its name - updated version number 0.2.1 Change-Id: Icf4560fe67001655a171401f106296b9aa09afb3 Orig-Change-Id: I8dfb05ba1e704888c5c1ff9268a2a2e9a46af9bb Signed-off-by: Patrick Benavoli <patrickx.benavoli@intel.com> Reviewed-on: http://android.intel.com:8080/20208 Reviewed-by: Barthes, FabienX <fabienx.barthes@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com>
* parameter-framework: initial commitPatrick Benavoli2011-09-081-0/+101
BZ: 6081 Parameter-framework is still-under-development, Intel proprietary, multi-platform (standard C++, for now only linux, no dependency on Android) software that allows system-wide parameter management. It relies on a number of configurations files, from which it knows how / when to hand out settings towards the hardware (subsystems) at runtime. 3 kinds of configuration files are used: - Structure description files indicating the actual parameter structure, types, min/max values, data representation. - Configurable domain description file containing the actual distribution of parameters over different domains, that is, different set of configurations, each of which being dynamically activated based on selection criteria rules that are themselves configurable. Configurable domains file contain the tuned settings along the tuning process, that is during the period where the system is being tuned. - Binary settings file used to store the settings when the tuning process is complete. Changing any of those files causes no recompilation of the framework. This project is based on a open plugin architecture allowing any kind of subsystems to be handled, whatever their respective Endianness. It fully relies on the platform SW to provide it with with the kowledge of exisitng selection criteria (selected device, current mode), as well as change events that occuring on them, thus triggering the application of corresponding configuration settings wherever appropriate. It supports handling mutliple parameter classes (Audio, Energy management) through TCP/IP interface. For now tuning commands can be sent to parameter-framework instances through a command-line utility, via adb over USB or via ethernet/WIFI. Change-Id: If7709c464db118f367f953e0824f49cce9fd0402 Orig-Change-Id: I7842e8808a4cfc0c615e0365e6d02101971ae2dc Signed-off-by: Patrick Benavoli <patrickx.benavoli@intel.com> Reviewed-on: http://android.intel.com:8080/16877 Reviewed-by: Mahe, Erwan <erwan.mahe@intel.com> Tested-by: Barthes, FabienX <fabienx.barthes@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com>