| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a first pass at spliting up the tests into different binaries.
Doing this involved a small change in the zmake framework to pass the
project name into CMake. Then, the root CMakeLists is able to add
the correct subdirectory to the common sources. This will add that
set of tests as a zephyr library.
BRANCH=none
BUG=none
TEST=zmake test test-drivers-isl923x
TEST=zmake test test-drivers-led_driver
Signed-off-by: Yuval Peress <peress@google.com>
Change-Id: Ida49ab5c4f1ec156365c854251f548eac00d2c5e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3724970
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The gitlab builder is running out of disk space. Add flags to build
fewer things, and to delete the intermediate files and only leave the
output files.
Before this change zmake build of all boards took 2.1G, and 81M
afterwards.
BRANCH=None
BUG=None
TEST=make clobber
TEST=zmake build --boards-only -c --delete-intermediates
TEST=du -s -h build
Change-Id: I507abff512ca1348681a1fd7431d5267efaf5d65
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3726959
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
common/system.c includes ec_version.h to access its definition
of CROS_FWID_MISSING_STR. However, this is just a constant placeholder
for cases when an actual version string is not available. It does not
need to placed into the auto-generated ec_version.h header.
* Remove the code that adds the CROS_FWID_MISSING_STR definition in
zmake
* Place the #define macro into cros_version.h, which is included by
common/system.c already.
* Update zmake unit tests
BRANCH=None
BUG=None
TEST=zmake test test-drivers
Signed-off-by: Tristan Honscheid <honscheid@google.com>
Change-Id: I8bb8406823e7860162157c1baaa21440608f3eea
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3656257
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Adjust configurations to fit SPI image generation
BUG=none
BRANCH=main
TEST=zmake testall
Signed-off-by: martin yan <martin.yan@microchip.corp-partner.google.com>
Change-Id: I06da9b78fd3b3f42855ef197a37a18bc11ec3711
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3686761
Reviewed-by: Al Semjonovs <asemjonovs@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change zmake -j default from 1 to 0, which makes the jobserver default
to the number of cores.
Pass -j1 to ninja instead of letting it use all the cpus, if we are
building more than one project.
BRANCH=None
BUG=b:178196029
TEST=Various zmake calls + emerge-brya-zephyr chromeos-zephyr
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I0dd8176f565871441fe6c005157d3e03f9317b56
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3636184
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Denis Brockus <dbrockus@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If you call zmake with the same project name multiple times, it would
actually build it multiple times, this is a big problem if you use zmake
-j.
Change _resolve_projects to return a set instead of a list.
BRANCH=None
BUG=b:178196029
TEST=zmake -j100 build -B build brya brya
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: Ib9bbabe4e96a186731a3c15256558b3e9a3923d6
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3636183
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Al Semjonovs <asemjonovs@google.com>
Reviewed-by: Al Semjonovs <asemjonovs@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
flake8 reports more errors than necessary on BUILD.py files because:
- They are out of the zmake tree, and therefore do not have the
correct .flake8 config file.
- flake8 is confused by undefined variables like "here" and
"register_project", which come from the execution context zmake
provides.
These are just config files anyway, running flake8 on them is likely
overkill. Turn that off.
BUG=none
BRANCH=none
TEST=for f in $(git ls-files); do
zephyr/zmake/pre-upload.sh "$(realpath "${f}")"
done
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: Ia6eae025ec560d3f6dbdc5c8a4ce50d7b9b94459
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3630476
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 0ab6c10da0394f2887a26b1ac7c696baed801517.
Reason for revert: This is utilizing internal project & system paths
that are not guaranteed to be stable or be used by people.
Original change's description:
> zmake: Add .pylintrc and some fixes for pylint
>
> With this .pylintrc, and these tweaks, there are no errors reported by
> cros lint. Many warnings, but no errors.
>
> Added a pylint call to run_tests.sh. It only checks for errors, once we
> get the warnings cleaned up, we should change it to call cros lint
> instead.
>
> BRANCH=None
> BUG=b:217969201
> TEST=run_tests.sh
>
> Change-Id: I1ad75fda3d6f818f1d1c66654823bac97ce09942
> Signed-off-by: Jeremy Bettis <jbettis@google.com>
> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3449124
> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
> Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
> Tested-by: Jeremy Bettis <jbettis@chromium.org>
Bug: b:217969201
Change-Id: I6e4115e8e3649e345dc01c4d898c7f718feac66f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3612962
Tested-by: Mike Frysinger <vapier@chromium.org>
Commit-Queue: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
At the end of zmake configure or test (or all methods that delegate to
one of those), if any projects failed log them.
BRANCH=None
BUG=None
TEST=Ran unit tests, also zmake testall with some failures
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I52d9c66ecc4787b78c5c3451eac70de94995622f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3598176
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 08cb9cb318ecae05c45cebfab9a318276f9610cb.
Reason for revert: Causes CQ failures in ebuild
Example:
https://ci.chromium.org/ui/p/chromeos/builders/postsubmit/brya-zephyr-postsubmit/3995
BUG=none
TEST="emerge-brya-zephyr chromeos-zephyr" succeeds
Original change's description:
> zmake: Pass -j1 to ninja, and set default jobs
>
> Change zmake -j default from 1 to 0, which makes the jobserver default
> to the number of cores.
>
> Pass -j1 to ninja instead of letting it use all the cpus, if we are
> building more than one project.
>
> BRANCH=None
> BUG=b:178196029
> TEST=Various zmake calls
>
> Signed-off-by: Jeremy Bettis <jbettis@google.com>
> Change-Id: Ibe83159e085592c95c69ade493392454003336a2
> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3598175
> Tested-by: Jeremy Bettis <jbettis@chromium.org>
> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
> Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Bug: b:178196029
Change-Id: I888bd4a63fe401089c6a23c360b65b4f441fe1be
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3606145
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Tested-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Piotr Pawliczek <pawliczek@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change zmake -j default from 1 to 0, which makes the jobserver default
to the number of cores.
Pass -j1 to ninja instead of letting it use all the cpus, if we are
building more than one project.
BRANCH=None
BUG=b:178196029
TEST=Various zmake calls
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: Ibe83159e085592c95c69ade493392454003336a2
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3598175
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For tests, provide a mechanism to pass extra arguments on the command
line to the test binary. A temporary directory is provided to place
temp files.
The purpose of doing so can be seen in the modified BUILD.py for the
drivers test: the drivers test has been littering a `flash.bin` file
in the working directory, and we'd like to stop that if we can.
BUG=b:230107609
BRANCH=none
TEST=zmake test test-drivers -> no flash.bin litter
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: I52e9ed68489eea46b109e0e553bd6cf26c23a64a
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3602223
Reviewed-by: Abe Levkoy <alevkoy@chromium.org>
Reviewed-by: Aaron Massey <aaronmassey@google.com>
Commit-Queue: Aaron Massey <aaronmassey@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Perform same python file format checks as CQ checks.
BUG=b:228455007
BRANCH=NONE
TEST=Edit python files and check warnings are provided for
malformed formatting.
Change-Id: I169c5116f7fa08d26ae5c7a072aad75b92cf3d4b
Signed-off-by: Al Semjonovs <asemjonovs@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3602224
Reviewed-by: Abe Levkoy <alevkoy@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add MchpPacker to support SPI image generation
BUG=none
BRANCH=main
TEST=zmake testall and make buildall -j$(nproc)
verify "zmake build adlrvp_mchp" project locally
-- able to generate 512KB SPI image
-- image with expected header, RO/RW and FMAP information
-- RO can be loaded by EC Rom loader as POR or reboot
Signed-off-by: martin yan <martin.yan@microchip.corp-partner.google.com>
Change-Id: I55f188aa1ddf96ebc0f4b37990de01ff3f5a3bfb
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3583761
Reviewed-by: Denis Brockus <dbrockus@chromium.org>
Reviewed-by: Yuval Peress <peress@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added type hints in several places either to correct a warning or to
cause one. For example, if pylint can't tell the type of an inherited
method, it will report unused params, but if the params match exactly
the superclass, it will not. Some cases were because I tried to find all
references to a class or function, and the IDE couldn't find them.
Moved loose logging functions in multiproc into class methods of
LogWriter.
Refactored pack_firmware and _get_max_image_bytes to avoid problems with
the various packers taking different numbers of params and subclasses
not implemented abstract methods.
Stop disabling no-self-use and fix them instead.
Remove JobClient.run() because it's never called.
Remove JobServer, because it does nothing and is not used as a marker.
Fixed lots of small warnings also.
Disabled most of the too-many-* warnings in specific functions.
Fixed the imports in .pylintrc, as it was finding the emerged zmake, not
the local one.
Disabled wrong-import-order since isort and pylint don't agree.
BRANCH=None
BUG=b:217969201
TEST=zmake -j8 test -a
zephyr/zmake/run_tests.sh
find zephyr/zmake -name '*.py' -print0 | xargs -0 cros lint
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I4f1b3a9fa5881fe7bcc4a6065d326dd36701b5ef
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3583754
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixed all the cros lint warnings in the zmake tests.
BRANCH=None
BUG=b:217969201
TEST=zephyr/zmake/run_tests.sh && \
find zephyr/zmake/tests -name '*.py' -print0 | xargs -0 cros lint
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I01e06bdfbfca239db2092680635fa3bc72008647
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3582802
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These flags have been deprecated and are now being removed.
BUG=b:225379781
BRANCH=none
TEST=unit tests pass
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: Ib3dc35100df7946b0d48543eda6a17dfb3b56730
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3551651
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Zephyr build system supports passing extra CFLAGS via CMake, which
is useful for experimenting with compiler options. Add an option to zmake
which allows this to be passed through when configuring a build.
BUG=b:223044986
TEST=EXTRA_CFLAGS is set in generated cmake configurations when used
BRANCH=none
Signed-off-by: Peter Marheine <pmarheine@chromium.org>
Change-Id: I3fca24ada4cdcfe442d610c93ae7f60137764dfa
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3535542
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Hopefully we can get people to stop using these flags as we want to
remove them.
Let this land for a week or so then we can rip the band-aid.
BUG=b:225379781
BRANCH=none
TEST="zmake configure -b lazor" -> see warning
"zmake configure --test test-drivers" -> see warning
"zmake test test-drivers" -> no warning
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: Ia6e33f438237a5541cacb51b2479d8554197dbac
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3536609
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a BUILD.py syntax to copy another project and make simple
modifications.
BUG=b:224998797
BRANCH=none
TEST=provided unit test passes
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: I87f0fe6b0e02c3ac34bec6de09d38e620fc293e3
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3530957
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The correct values for iter_builds() is ro and rw, not build-ro and
build-rw.
BRANCH=None
BUG=None
TEST=run_tests.sh
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I1927f0dec54bf72ea5eef0e76d7063546c73a5fb
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3526178
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In order to capture the memory usage report in the link stage, write all
output from ninja to a build.log file in the build dir.
For example:
`zmake build herobrine` will create files in
`build/zephyr/herobrine/build-ro/build.log` and
`build/zephyr/herobrine/build-rw/build.log`
I intend to parse this file in firmware_builder.py
BRANCH=None
BUG=b:223846977
TEST=zmake build herobrine; \
tail build/zephyr/herobrine/build-*/build.log
Change-Id: I10e1e29e945f86bbc19adf62946ea7f3aab8fc6f
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3523395
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The warning detection in zmake consistently has false positives.
Remove it.
BRANCH=None
BUG=None
TEST=zmake test -a
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I8bd90801f7e188efc66227975387a9a281576e54
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3523203
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The posix flash simulator leaves a flash.bin file in the current
directory, so change zmake to run tests in the directory where the test
executable lives, so that any temporary files end up there.
BRANCH=None
BUG=b:214256453
TEST=zmake test -a
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I137c62976aaae59b07d5ad6d209dd2e8cdddf767
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3503400
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Keith Short <keithshort@chromium.org>
Commit-Queue: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In Zephyr test drivers CONFIG_NATIVE_UART_0_ON_STDINOUT is enabled to
print UART0 content to stdout. Log modules created by
LOG_MODULE_REGISTER print to UART0 by default.
It is necessary to pipe stdin in zmake to make test to work with UART0
redirected to stdin/stdout.
BUG=none
BRANCH=none
TEST=zmake -D configure --test test-drivers
Signed-off-by: Tomasz Michalec <tm@semihalf.com>
Change-Id: I5e577beee036a33b9ab1dfe7a25bdef0edb05aac
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3497740
Reviewed-by: Aaron Massey <aaronmassey@google.com>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Tomasz Michalec <tmichalec@google.com>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Tomasz Michalec <tmichalec@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added some tests to cover 100% of zmake/toolchains.py
BRANCH=None
BUG=b:219062927
TEST=Ran tests with coverage
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I420d3535cbe3433e87ab8f7cb86c17aefca3765e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3491406
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I was running the tests outside the chroot in python 3.9 and the path
mocking didn't work. Change test to mock pathlib.Path.stat instead.
Change test_zephyr to clear the env vars, in case the person running the
test has a ZEPHYR_SDK_INSTALL_DIR set.
BRANCH=None
BUG=b:219062927
TEST=Ran coverage report
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I371befc9217d8dd95bfbf3a83ea3742d7c9acd9a
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3491405
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Made changes for pylint.
BRANCH=None
BUG=None
TEST=black . && ./run_tests.sh && \
cros lint tests/test_toolchains.py zmake/toolchains.py
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I60eff964fdb619a5688c439e101f8f28c239585d
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3491407
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In zmake, don't remove any directories from the coverage reports.
In gitlab, add the exclusions back in so that we get the same finished
html report that we got before.
BRANCH=None
BUG=b:156895937
TEST=Ran firmware_builder.py, verified zephyr/test & zephyr/emul
Ran .gitlab-ci.yml commands for herobrine and verified that
build/herobrine/output/filtered_no_zephyr.info is unchanged.
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: Ie8fd1e787d8bb6e745f89d773113cccb6c335009
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3491416
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Aaron Massey <aaronmassey@google.com>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There should be no uses and no documentation of the coverage subcommand.
Remove it.
BRANCH=None
BUG=b:217788621
TEST=zmake test -a --coverage
Change-Id: I515af49c1468ac8db1d66833a6763b1a93442b46
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3488789
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For the files edited in the prior 2 cls in this chain, fix or suppress
all pylint warnings.
BRANCH=None
BUG=None
TEST=cros lint <filenames>
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I8332b80945814bdecc5f4c491818a3d4e172ce60
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3472821
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Calling self.executor.wait() from within a function that was added to
self.executor.append() will cause a deadlock. So don't do that anymore.
BRANCH=None
BUG=b:217788621
TEST=zmake testall; zmake -j8 testall
Change-Id: Id7a586bba0c05b78f49d9c70fed3560944564af8
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3488787
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add new commands to run zmake unit tests with coverage enabled.
BRANCH=None
BUG=b:219062927
TEST=Ran commands in docker
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: Ie7e8c0a33df8e92ff946e87bb787dd4a0aced2fa
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3472820
Reviewed-by: Simon Glass <sjg@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixed various bugs with running zmake tests outside of the chroot.
BRANCH=None
BUG=b:219062927
TEST=Ran commands in docker
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I942d4195b97384239869ac1d928c9eca47c70829
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3472687
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As described in go/zmake-cli-v2
Change zmake test to call zmake configure --test, unless the
--no-rebuild flag is used, in which case just run tests on existing
binaries. It is an error to use --no-rebuild, if you never did a zmake
build.
BRANCH=None
BUG=b:217788621
TEST=make clobber
zmake -j8 build herobrine test-drivers
zmake -j8 test --no-rebuild herobrine
zmake -j8 test --no-rebuild herobrine test-drivers
zmake -j8 test --no-rebuild herobrine test-drivers test-tasks
zmake -j8 build test-tasks
zmake -j8 test --no-rebuild herobrine test-drivers test-tasks
make clobber
zmake -j8 build --coverage herobrine test-drivers
zmake -j8 test --coverage --no-rebuild herobrine
zmake -j8 test --coverage --no-rebuild herobrine test-drivers
zmake -j8 test --coverage --no-rebuild herobrine test-drivers test-tasks
zmake -j8 build --coverage test-tasks
zmake -j8 test --coverage --no-rebuild herobrine test-drivers test-tasks
zmake -j8 test --coverage herobrine brya
zmake -j8 test --coverage --no-rebuild herobrine brya
zmake -j8 testall
zmake -j8 test --all
zmake -j8 test --all --no-rebuild
zmake -j8 test --host-tests-only
zmake -j8 test --host-tests-only --no-rebuild
zmake -j8 test --host-tests-only --coverage
zmake -j8 test --host-tests-only --coverage
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I90f23cd0061d97e42359e1d49f2331b71554e3a1
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3472683
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As described in go/zmake-cli-v2
Change zmake build to call zmake configure --build.
Updated docs to stop telling people to run both configure and build as
well as some other small documentation mistakes.
BRANCH=None
BUG=b:217788621
TEST=zmake -j8 build herobrine_npcx9
zmake -j8 build test-drivers
zmake -j8 build herobrine_npcx9 test-drivers
zmake -j8 build --all
zmake -j8 build --coverage herobrine_npcx9
zmake -j8 build --coverage test-drivers
zmake -j8 build --coverage herobrine_npcx9 test-drivers
zmake -j8 build --all --coverage
zmake test build/zephyr/test-drivers/
zmake test --coverage build/zephyr/test-drivers/
zmake -j8 configure --build herobrine_npcx9
zmake -j8 configure --build test-drivers
zmake -j8 configure --build herobrine_npcx9 test-drivers
zmake -j8 configure --build --all
zmake -j8 configure --build --coverage herobrine_npcx9
zmake -j8 configure --build --coverage test-drivers
zmake -j8 configure --build --coverage herobrine_npcx9 test-drivers
zmake -j8 configure --build --all --coverage
zmake -j8 configure --test herobrine_npcx9
zmake -j8 configure --test test-drivers
zmake -j8 configure --test herobrine_npcx9 test-drivers
zmake -j8 configure --test --all
zmake -j8 configure --test --coverage herobrine_npcx9
zmake -j8 configure --test --coverage test-drivers
zmake -j8 configure --test --coverage herobrine_npcx9 test-drivers
zmake -j8 configure --test --all --coverage
Cq-Depend: chromium:3470081
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: Iee939b92e39f0787e50234040a8b6b248ba6c831
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3462631
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change zmake configure to work as described in go/zmake-cli-v2.
BRANCH=None
BUG=b:217788621
TEST=Various zmake configure cmds.
Cq-Include-Trybots: luci.chromeos.cq:cq-orchestrator
Cq-Depend: chromium:3462900
Change-Id: I58fa4d8427efff64c5764eac6ba4752a71785127
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3445105
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some project references were not auto-completing in VSCode, so I added
type hints to help.
BRANCH=None
BUG=None
TEST=None
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I0819151f2053e0daf1012874beb72c112e7a80ef
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3462632
Reviewed-by: Abe Levkoy <alevkoy@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 59e9e0544ec4e449b11267053e5525d6de372a39.
With the CL in the CQ depend, this should now be safe to land.
Original change's description:
> Revert "zephyr: zmake: Drop support for building by project directory"
>
> This reverts commit 848a4a66b61a656d0bd0739526656f67213ee66e.
>
> Reason for revert: broke trogdor-zephyr
> https://ci.chromium.org/p/chromeos/builders/postsubmit/trogdor-zephyr-postsubmit
>
> Original change's description:
> > zephyr: zmake: Drop support for building by project directory
> >
> > This has been deprecated since November, and all code and
> > documentation has been updated to no longer mention building by
> > project directory path. Therefore, let's drop support for it.
> >
> > BUG=b:218868887
> > BRANCH=none
> > TEST=unit tests pass
> >
> > Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
> > Change-Id: I4f0762df289a413007a8409c6a39026db8056937
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3452934
> > Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
>
> Bug: b:218868887
> Change-Id: I59f593aef0b9490a35b22c65d50bf5f978e56eb1
> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3454742
> Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
> Tested-by: Jack Rosenthal <jrosenth@chromium.org>
> Reviewed-by: Evan Benn <evanbenn@chromium.org>
> Tested-by: Evan Benn <evanbenn@chromium.org>
> Owners-Override: Evan Benn <evanbenn@chromium.org>
Change-Id: I6f6e5a7594225b18ddc00c922c34ee87ee709420
Cq-Depend: chromium:3452985
Bug: b:218868887
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3456705
Tested-by: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With this .pylintrc, and these tweaks, there are no errors reported by
cros lint. Many warnings, but no errors.
Added a pylint call to run_tests.sh. It only checks for errors, once we
get the warnings cleaned up, we should change it to call cros lint
instead.
BRANCH=None
BUG=b:217969201
TEST=run_tests.sh
Change-Id: I1ad75fda3d6f818f1d1c66654823bac97ce09942
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3449124
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a timeout for all tests run by ztest, defaulting to 2 minutes. The
timeout can be customized on a test by test basis by setting
test_timeout_secs in the test's BUILD.py
BRANCH=None
BUG=b:218493723
TEST=Set timeout to 2s, and ran zmake test on the drivers test.
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I48f56a7d67c91d482094e0dc123bdacb6ffa79df
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3449123
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 848a4a66b61a656d0bd0739526656f67213ee66e.
Reason for revert: broke trogdor-zephyr
https://ci.chromium.org/p/chromeos/builders/postsubmit/trogdor-zephyr-postsubmit
Original change's description:
> zephyr: zmake: Drop support for building by project directory
>
> This has been deprecated since November, and all code and
> documentation has been updated to no longer mention building by
> project directory path. Therefore, let's drop support for it.
>
> BUG=b:218868887
> BRANCH=none
> TEST=unit tests pass
>
> Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
> Change-Id: I4f0762df289a413007a8409c6a39026db8056937
> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3452934
> Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Bug: b:218868887
Change-Id: I59f593aef0b9490a35b22c65d50bf5f978e56eb1
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3454742
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Tested-by: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-by: Evan Benn <evanbenn@chromium.org>
Tested-by: Evan Benn <evanbenn@chromium.org>
Owners-Override: Evan Benn <evanbenn@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This has been deprecated since November, and all code and
documentation has been updated to no longer mention building by
project directory path. Therefore, let's drop support for it.
BUG=b:218868887
BRANCH=none
TEST=unit tests pass
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: I4f0762df289a413007a8409c6a39026db8056937
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3452934
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On zephyr upstream, NPCX series map code RAM to flash0. Zephyr uses
CONFIG_FLASH_SIZE for the code RAM size. However, this is overridden by
Kconfig. This removes CONFIG_FLASH_SIZE in the cros repo. For the
zmake, change to use CONFIG_FLASH_SIZE_BYTES for flash size check.
BUG=b:216385443
BRANCH=none
TEST=linker show the error for the code RAM size out of range
TEST="zmake testall --clobber"
Signed-off-by: Wealian Liao <whliao@nuvoton.corp-partner.google.com>
Change-Id: I0942f18bd3b145c4d35eb15a44169f217496a6a6
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3419936
Tested-by: CH Lin <chlin56@nuvoton.com>
Reviewed-by: Eric Yilun Lin <yllin@google.com>
Commit-Queue: Eric Yilun Lin <yllin@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When you zmake configure --test you get coverage output in
$build_dir/output/zephyr.info, but zmake configure --build didn't.
Change the latter to match.
Change CQ and gitlab builders to match this change.
BRANCH=None
BUG=b:156895937
TEST=Ran firmware_builder.py commands
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I38c71a6f711f05c89882084ac93fafdc1f8d0e9f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3436694
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add an optional argument to specify the build directory used by
"zmake testall".
BUG=none
BRANCH=none
TEST=Run "zmake testall". Verify artifacts created under ./build/zephyr
TEST=Run "zmake testall -B /tmp/zephyr-testall". Verify artifacts created
under /tmp/zephyr-testall
Signed-off-by: Keith Short <keithshort@chromium.org>
Change-Id: I676cf672b95b01b3fb595bf4666403c3011df023
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3441358
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In crrev/c/3433631, the logic was reversed. It should do a special
coverage build only for non-tests, not for tests. Changed to be normal
builds for tests, and special builds for non-tests.
BRANCH=None
BUG=None
TEST=Ran firmware_builder.py to verify it could catch the breakage and
the fix.
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: Ie970f5228d582d03f000948b3a2b5f7237dabff1
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3436692
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Sam Hurst <shurst@google.com>
Commit-Queue: Sam Hurst <shurst@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Running zmake configure --coverage --build on a non-test works great. It
builds all the libs, and runs lcov to get a 0 lines covered report as a
baseline. And the coverage enabled binary is too big to flash, so there
is no reason to finish the build. However for tests, you really want the
full binary, but there is no reason to run lcov until after you run the
test once.
Change configure --coverage --build to only do the partial build and
lcov on non-tests.
BRANCH=None
BUG=None
TEST=zmake configure --coverage --build zephyr/test/drivers && \
build/zephyr/test-drivers/output/zephyr.elf
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I0a4711da61d894ca39097a912de781e0f816be44
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3433631
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As discussed in the logging brainstorming meeting, traceback
suppression only makes it more difficult to fix bugs, determine the
cause of a failure, or make changes in zmake. This is to the point
that much of our documentation has been putting -D everywhere.
While there's much work to go to get rid of -D everywhere so that we
display the right logs when we need them, we can start at getting rid
of the traceback suppression feature and making -D just set
--log-level=DEBUG.
The two options are placed in a mutually-exclusive group such that
specifying --debug/-D and --log-level at the same time is not valid.
BUG=b:217423904
BRANCH=none
TEST=unit tests pass
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: I124b23c307b8b6e82edf4d5e43e2fcff82384a8e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3432911
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The test name is showing as "zephyr" no matter which test is run in the
coverage report. Instead of using the binary name, use the basename of
the build directory, which normally looks like "test-drivers".
BRANCH=None
BUG=None
TEST=Ran locally, grep TN: in zephyr.info
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I11e1701d0d0f8ae10de369e05af31a64fc9e7bdf
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3418119
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Aaron Massey <aaronmassey@google.com>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|