| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since a parameter-framework client may set a criterion before calling start(),
the logs may show changes to criteria before the coverage script knows the list
of criteria. It used to cause an unrecoverable error even with the "--force"
option.
This option now makes the coverage script ignore such errors. The script
already takes the initial values of criteria into account when the
parameter-framework starts, so there isn't any information loss.
However, if this error happens for any other error than described in the first
paragraph, you probably don't want to silence it.
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With a classic cmake install prefix '/usr',
bash completions were installed in
/usr/etc/bash_completion.d/
which even before bash-completion 1.9 was incorrect.
Since v1.9 all completions are to be installed in
/usr/share/bash-completion/completions
See:
http://anonscm.debian.org/cgit/bash-completion/bash-completion.git/tree/CHANGES#n324
Change the completions install path accordingly
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When an error occurs during input parsing,
the line number was incorrectly displayed.
In python, enumerating an iterable will yield
an pair of index and a value.
This index starts at 0: next(enumerate([""])) == (0, "")
This index was displayed as the line number.
Add one to the index to get the line number.
Signed-off-by: Kevin Rocard <kevin.rocard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some pfw bug induce empty criterion value,
when log it is dificult to see the the empty
value.
Add quotes around values.
before: Error in criterion
After : Error in criterion ""
Signed-off-by: Kevin Rocard <kevin.rocard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
32bit target names are postfixed with "_32". This was missed in the list
"required modules" for domainGenerator.py" which caused _PyPfw.so not being
compiled when needed.
Android only contains a 32bit version of prebuilt python.
Fix LOCAL_REQUIRED_MODULES for domainGenerator.py
Change-Id: Ieda460d0c4785bc2d1c2c14e38f5a73c66672497
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
|
|
| |
Allow optional arguments (initial settings, single domains, EDDs) to be passed
with an empty list of files.
This will make it a lot easier to write helper scripts.
Change-Id: I99527376b25d607616a3e73f6b62d556b79a90d2
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|\
| |
| | |
Iminleg rebase
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
During host domain generation, a port must be chosen before spawning a servers,
producing an error if someone else uses it before the server.
This race was workaround by retiring 10 times before failing.
This divided the failure probability by 10, but is no longer sufficient.
A correct implementation without this race is currently been developed
(without socket) but until then change the retry number from 10 to 1000.
Signed-off-by: Kevin Rocard <kevin.rocard@intel.com>
Tracked-On: https://jira01.devtools.intel.com/browse/IMINAN-17358
Change-Id: Ie80e4508952ef150eb999d9a6fa7e60b61825f35
Reviewed-on: https://android.intel.com:443/319856
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When working with the parameter-framework,
the remote-process command is very handy.
Nevertheless it has long commands and it is easy to make mistakes.
Add a bash completion script to complete:
- hostnames
- frequently used port
- commands and arguments based on the remote usage (help command)
Signed-off-by: Kevin Rocard <kevin.rocard@intel.com>
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The exportToXML was creating an minidom.Element using
it's constructor, which is forbidden in the documentation:
> Applications should not instantiate the classes themselves; they should use the creator functions available on the Document object.
http://docs.python.org/library/xml.dom.minidom.html
Since python 3.4 this method no longer works (private interface change)
thus the xml coverage generation was broken.
Fix by calling the recommended method Document.createElement.
See bug: http://bugs.python.org/issue15290
Signed-off-by: Kevin Rocard <kevin.rocard@intel.com>
|
|
|
|
|
|
|
| |
Document the new python xml generator and deprecate the old one.
Change-Id: I5bf9a8206c82678eda7b29b1fe88cbc0396b1f9d
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
The remote interface sometimes gets in the way of XML generation when the port
is already in use. A "retry" mechanism existed in the previous generator but
was unreliable.
In the new generator, we disable it altogether as we don't need it.
Change-Id: I0a1850058b688f5ea09b93959601d3c706d812b6
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
| |
Take advantage of the setLogger() method that was newly added to the bindings
to allow the parameter-framework to log during XML generation.
Change-Id: I71a43fae915756a7986a48a840306d454d071f17
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This new script (domainGenerator.py) uses both the newly-refactored
EddParser.py module as well as the new python bindings to generate XML Settings
through the parameter-framework interface.
This script can take the following data as input:
- the toplevel config file (mandatory)
- the 'criteria' file (mandatory)
- an initial settings file to be amended (optional)
- zero, one, or several 'domain' files (each containing a single domain)
- zero, one, or several files in the EDD syntax (aka ".pfw" files)
Call the script with the "--help" argument for detailed help.
It implements its own derived class of PfwBaseTranslator, calling the
parameter-framework python bindings. Any error happening within the binding or
below (e.g. the pfw core) is collected and forwarded to the user.
Change-Id: Id11123e083ed2a487800e737007a99541949a4bb
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
| |
Instead of calling this script from command line, we will need to use it from
another python script/module.
Change-Id: Ic3b1f55c0a73c4edff005687327cd19570ab7743
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The existing code is split in two parts:
- "EDD"-files parsing;
- parameter-framework remote commands generation
The first part is mostly kept as-is but the file is renamed to "EddParser.py";
the second part is refactored and an object presenting a "Translator" intreface
is passed to the parsed objects in order to generate the remote
parameter-framework commands. Later, another class implementing the Translator
interface will be implemented using the python bindings.
Some dead code is removed in the process.
Change-Id: I9725600ce34f36742c7e27ea7aee53892dd799b0
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This script is used to generate XML files through the parameter-framework's
remote interface. A "direct xml output" support was partially implemented to
generate the XML output without the involvement of the parameter-framework.
It has never been comletely implemented nor used by anyone, so we'd better
remove it.
Change-Id: I6ad166306585c55884482ed03934da9f3efc70df
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|\
| |
| | |
Update .pfw gedit syntax grammar
|
| |
| |
| |
| |
| |
| |
| | |
Add the new Extended Domain Description keywords to
gedit syntax grammar.
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
|
|\ \
| | |
| | | |
Remove flood debug trace on xml generation error
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The patch 0b3ff88 "Add log in case of failure"
added system process and network log on failure.
It was planed to be used to debug a tricky socket
error bug.
The bug was since fixed and the traces now only
flood build log, making xml generation
error root cause spotting a lot harder.
Remove extra debug message (netstat and ps invocation)
on error.
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
|
|\ \
| | |
| | | |
hostDomainGenerator: Fix the stripping of the temporary directory name
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We didn't properly remove the name of the temporary directory in the generated
files which caused two generation from identical sources result in different
generated files.
We know the full name of the temporary directory so we can simply completly
remove it from the generated file.
Issue: GMINL-1953
Change-Id: I1f360cea249328d30318a24643b524c87424475e
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|\ \
| | |
| | | |
Remove non ascii char
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Some comments representing a file tree were
using non ASCII characters.
They are not readable on many editors leading to
incoherent display.
Replace them by plain ASCII characters.
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
|
|/
|
|
|
|
|
| |
This seems to be mandatory.
Change-Id: Idba8c7a3ec9e2f05b28ee593d1d15a420a0bd9ed
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
| |
- More details in the root README.md file; add a nice diagram
- Add a lot of README files in subdirectories
Signed-off-by: David Wagner <david.wagner@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 207083
License headers were missing in CMake makefiles.
This patch adds the 3-clause BSD license header to each CMakeLists.txt.
Change-Id: Ia4da92e139e02d6348d655d0d88a16166d8431ca
Signed-off-by: Mattijs Korpershoek <mattijsx.korpershoek@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This tool can be used to validate a set of xml files against w3c
schemas.
It scans a directory recursively and checks for .xml files in it.
For each file, it extracts the current schema file based on a convention
(the corresponding schema file must have the same name as the root node)
which is used in the parameter-framework.
Change-Id: I27e32028e39a450ed18f86cb095348f73d59ade5
|
|
|
|
|
|
|
|
|
| |
When performing the tutorials, I wanted to use the
tools/xmlGenerator/hostDomainGenerator.sh script.
In order to do that, i had to copy manually my scripts files
to the pfwInstalledDir/bin directory.
This patchs completes the install target by copying the needed files
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 192861
When hostDomainGenerator.sh is called by the build system, it needs to
copy schema files to /tmp/tmp.XXXXXXX. This is because
parameter-framework needs to have the schema files next to the .xml
files in order to apply validation.
In order to do that, hostDomainGenerator.sh needs to know where he can
copy the .xsd files from.
Currently, the .xsd files are copied from
$HOST_OUT/etc/parameter-framework/Schemas via a dedicated makefile.
This used a phony package to group all the files that have to be copied.
The problem is that phony packages the phony package is not calling the
prebuildt rules we need. So the files we want to export to
/etc/parameter-framework/Schemas are not copied.
This patch removes the phony package in order to produce the expected
behaviour.
Change-Id: I96da56f85a8c3d512fcfb97244181dc6c1cb9401
Signed-off-by: Mattijs Korpershoek <mattijsx.korpershoek@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 188323
In order to validate xml files, we need the corresponding schemas to be
next to the xml files. Those are put by the script in /tmp.
This patch add the copying of the schema files to /tmp.
I also adds an optional command line argument to disable/enable validation.
This is useful for platform specific enabling/disabling validation.
It can be used by calling hostDomainGenerator.sh --validate.
Change-Id: I7da65f230e5abf5b1d18c5cd6cf11b67dae5ed76
Signed-off-by: Mattijs Korpershoek <mattijsx.korpershoek@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 189977
The hostDomainGenerator.sh script generates xml files a build time.
Sometimes it fails but the log information are no sufficient to found
the root cause.
Add some log information in order to be able to find it.
Change-Id: I505577ee30503dccf25375b0ea262461ec4cce14
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
Signed-off-by: Mattijs Korpershoek <mattijsx.korpershoek@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 177060
When the initial XML file for tuning is too big, the XML generation
fails with the message: "Argument list too long". This is because the
generation relies on the PFW command "setDomainsWithSettingsXML", which
takes XML data as string argument. There is a limitation concerning
the size of this string, leading to the current issue.
This patch replaces the call to "setDomainsWithSettingsXML" by
"importDomainsWithSettingsXML", which takes a file as argument instead
of a string. There is no limitation on the file size.
Change-Id: Ieb12e6ba1391545021cd3f1e867dee0d28425d19
Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 171573
If localhost is not bound to 127.0.0.1, socket creation fails in the
portAllocator.py script. This error is not well catched in the main
tool hostDomainGenerator.sh.
This patch updates portAllocator.py so that the IP address 127.0.0.1
is used instead of localhost. In addition, the potential error messages
raised by portAllocator.py are now correctly taken into account by
hostDomainGenerator.sh. HostDomainGenerator.sh has also been updated
to replace all instances of 'localhost' by '127.0.0.1'.
Change-Id: I7ed6ede7a1148360efac4bf38f49054066a50a29
Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com>
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 151780
The option --verbose must be provided in order to make hostDomainGenerator.sh
verbose. However, this option is very usefull when the generation fails during
a build, and it would be nice to have it enabled by default.
Make this option the default one, and add a nonverbose option instead.
Change-Id: I59195b7a28e25a5f18871d6baf2ae4f1310f49d7
Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 151780
When multiple process run hostDomainGenerator.sh, some race conditions
occur, despite current locking mechanism.
In consequence, the script has been modified in order to make sure that
available socket ports can be chosen for test-platform and PFW processes:
- portAllocator.py: python script which creates a new socket using a random
available port, and displays the port chosen. This port number is then
pushed to the end of the available ports list by the system.
- hostDomainGenerator.sh: uses portAllocator.py to get free ports for
test-platform and the PFW.
Fixed multiple issues as well:
- When an error occur, a cleanup function was called and sometimes would
kill concurrent processes. Now, only the test-platform and PFW instances
started by the current hostDomainGenerator.sh script will be stopped,
- Test-platform startup was not checked correctly,
- The creation of the symlink to libremote-processor.so sometimes failed,
leading to an early cleanup.
Change-Id: I33b4b2ad5a6c2bbc6f8283222eb2f16f05286734
Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 99956
XML scripts does not support empty tuning file.
This patches updates XML generation scripts to support empty
tuning file.
Change-Id: I2d3e11a950524c468c78e3b99cdebf3538b9e053
Signed-off-by: Francois Gaffie <francois.gaffie@intel.com>
Reviewed-on: http://android.intel.com:8080/138519
Reviewed-by: Quintero, Jorge <jorge.quintero@intel.com>
Reviewed-by: Centelles, Sylvain <sylvain.centelles@intel.com>
Reviewed-by: Rocard, KevinX <kevinx.rocard@intel.com>
Tested-by: Barthes, FabienX <fabienx.barthes@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 152121
As the hostDomainGenerator clean up function can be called after any
command, some clean commands were sometime irrelevant.
Clean commands should not fail.
Change-Id: I0e472919cd77abe393bca090a95d1c72cf77d58c
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 145379
As the lightRoutingUpdate.sh script is in private, it is not exported
for external release. As a result external clients can not use
lightRoutingUpdate to generate xml from .pfw.
Export lightRoutingUpdate to make it available in
$ANDROID_HOST_OUT/system/bin after compilation.
Change-Id: Id174ddb4dd0e31a7c5ede66e91b0db341745ff21
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 149851
The hostDomainGenerator.sh script uses a lockfile to protect some
operations from concurrent execution. This mechanism uses a file
that is created if it does not already exist. In this case, the file
permissions are too stricts, and other users are unable to run the script
anymore.
This patch changes the permission on the lockfile, allowing other
users to access it.
Change-Id: Iec250a4022cb8f97973fa92020b27dc0e83890c6
Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 148729
The script hostDomainGenerator.sh doesn't work fine on Ubuntu 13.04.
The processing is based on the external tool "ss" to monitor opened
sockets, in order to check if existing instances of test-platform
are currently started. It appears that the behavior of this tool
is different in the latest Ubuntu release: requests of opened sockets
always return multiple false results. In consequence, the script
cannot find any available port to start a new test-platform instance.
This patch updates the way opened sockets are checked, using "grep"
instead of the "ss" filter mechanism.
Change-Id: I2e1245c524d021d99389a0ec028105ed1f706666
Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 145938
XML generation is impossible when multiple instances of the script
hostDomainGeneration are run (this is typically the case with the
current Android Make process). This is because the way the ports
used to communicate with test-platform and parameter-framework are
chosen is not protected agains concurrent executions.
This patch protects the initialization of the test-platform and
parameter-framework agains concurrent executions using a flock.
In particular, it ensures that the ports chosen are reserved to
a specific process.
Change-Id: I3d8fee2b20313814c79f5390851ad57dc696cc28
Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 144262
Currently, the hostDomainGenerator script doesn't check if the port
used by the testPlatform is already used.
This patch adds this new check.
Change-Id: I323575f97f7437c01ce4e2d0b127aa658639af06
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
Reviewed-on: http://android.intel.com:8080/136085
Reviewed-by: Boisnard, FredericX <fredericx.boisnard@intel.com>
Reviewed-by: De Chivre, Renaud <renaud.de.chivre@intel.com>
Tested-by: Barthes, FabienX <fabienx.barthes@intel.com>
Reviewed-by: cactus <cactus@intel.com>
Tested-by: cactus <cactus@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 144262
Currently, the hostDomainGenrator doesn't handle well some relative
links.
This patch fixes the issue.
Change-Id: I7289b98c4e367a880ce0eac9238693f80c540a3c
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
Reviewed-on: http://android.intel.com:8080/135931
Reviewed-by: Boisnard, FredericX <fredericx.boisnard@intel.com>
Reviewed-by: Denneulin, Guillaume <guillaume.denneulin@intel.com>
Reviewed-by: Gaio, MiguelX <miguelx.gaio@intel.com>
Reviewed-by: De Chivre, Renaud <renaud.de.chivre@intel.com>
Tested-by: Barthes, FabienX <fabienx.barthes@intel.com>
Reviewed-by: cactus <cactus@intel.com>
Tested-by: cactus <cactus@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 122982
The build system does not preserve execution right in external prebuild
Add the execution rights witch chmod on executables.
Change-Id: Ieac44050e80df0e0f83e1a6b947edc432ef00260
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
Reviewed-on: http://android.intel.com:8080/134359
Reviewed-by: Gonzalve, Sebastien <sebastien.gonzalve@intel.com>
Tested-by: Barthes, FabienX <fabienx.barthes@intel.com>
Reviewed-by: cactus <cactus@intel.com>
Tested-by: cactus <cactus@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 122982
In order to generate the xml at build time, make has to launch an
executable (bash script here) that will take care of all the process.
This patch adds this script and the corresponding makefile.
Change-Id: Ifb2a6374afd4c73283e3d2371548b069c1fa72a6
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
Reviewed-on: http://android.intel.com:8080/119957
Reviewed-by: Gonzalve, Sebastien <sebastien.gonzalve@intel.com>
Tested-by: Barthes, FabienX <fabienx.barthes@intel.com>
Reviewed-by: cactus <cactus@intel.com>
Tested-by: cactus <cactus@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BZ: 122982
In order to generate the xml at build time, pfw configuration file must
be formated for simulation.
This patch adds this script and the corresponding makefile.
Change-Id: Ice404ec151b379dfd34d3a5c0b8a57f27d017356
Signed-off-by: Kevin Rocard <kevinx.rocard@intel.com>
Reviewed-on: http://android.intel.com:8080/132851
Reviewed-by: Denneulin, Guillaume <guillaume.denneulin@intel.com>
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>
|