Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[OIS] CI improvments and stabilization #25866

Merged
merged 15 commits into from
May 16, 2023

Conversation

ATmobica
Copy link
Contributor

Sets of OIS platform improvements that allow re-enabling CI testing and results stabilization.

@github-actions
Copy link

github-actions bot commented May 9, 2023

PR #25866: Size comparison from 7b5ecb2 to b1ddf30

Full report (1 build for cc32xx)
platform target config section 7b5ecb2 b1ddf30 change % change
cc32xx lock CC3235SF_LAUNCHXL 0 0 0 0.0
(read only) 605002 605002 0 0.0
(read/write) 204164 204164 0 0.0
.ARM.attributes 44 44 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 197576 197576 0 0.0
.comment 206 206 0 0.0
.data 1468 1468 0 0.0
.debug_abbrev 957619 957619 0 0.0
.debug_aranges 101232 101232 0 0.0
.debug_frame 342080 342080 0 0.0
.debug_info 19674627 19674627 0 0.0
.debug_line 2671903 2671903 0 0.0
.debug_line_str 513 513 0 0.0
.debug_loc 33340 33340 0 0.0
.debug_loclists 1491139 1491139 0 0.0
.debug_ranges 4984 4984 0 0.0
.debug_rnglists 94412 94412 0 0.0
.debug_str 3131828 3131828 0 0.0
.ramVecs 780 780 0 0.0
.resetVecs 64 64 0 0.0
.rodata 104314 104314 0 0.0
.shstrtab 265 265 0 0.0
.stack 2048 2048 0 0.0
.strtab 483089 483089 0 0.0
.symtab 287232 287232 0 0.0
.text 498564 498564 0 0.0

@ATmobica ATmobica force-pushed the upstream/ois-ci-impr branch 2 times, most recently from 5693f91 to 4c7b9c9 Compare May 10, 2023 07:10
@github-actions
Copy link

PR #25866: Size comparison from 4f081a5 to 4c7b9c9

Increases (1 build for cc32xx)
platform target config section 4f081a5 4c7b9c9 change % change
cc32xx lock CC3235SF_LAUNCHXL .debug_info 19674626 19674627 1 0.0
Full report (1 build for cc32xx)
platform target config section 4f081a5 4c7b9c9 change % change
cc32xx lock CC3235SF_LAUNCHXL 0 0 0 0.0
(read only) 605002 605002 0 0.0
(read/write) 204164 204164 0 0.0
.ARM.attributes 44 44 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 197576 197576 0 0.0
.comment 206 206 0 0.0
.data 1468 1468 0 0.0
.debug_abbrev 957619 957619 0 0.0
.debug_aranges 101232 101232 0 0.0
.debug_frame 342080 342080 0 0.0
.debug_info 19674626 19674627 1 0.0
.debug_line 2671903 2671903 0 0.0
.debug_line_str 513 513 0 0.0
.debug_loc 33340 33340 0 0.0
.debug_loclists 1491139 1491139 0 0.0
.debug_ranges 4984 4984 0 0.0
.debug_rnglists 94412 94412 0 0.0
.debug_str 3131828 3131828 0 0.0
.ramVecs 780 780 0 0.0
.resetVecs 64 64 0 0.0
.rodata 104314 104314 0 0.0
.shstrtab 265 265 0 0.0
.stack 2048 2048 0 0.0
.strtab 483089 483089 0 0.0
.symtab 287232 287232 0 0.0
.text 498564 498564 0 0.0

@ATmobica ATmobica force-pushed the upstream/ois-ci-impr branch 4 times, most recently from c1b1196 to 5158134 Compare May 10, 2023 12:56
@ATmobica ATmobica marked this pull request as draft May 10, 2023 14:31
@ATmobica ATmobica force-pushed the upstream/ois-ci-impr branch from 5158134 to 9c35234 Compare May 11, 2023 11:57
@ATmobica ATmobica marked this pull request as ready for review May 11, 2023 14:06
ATmobica and others added 15 commits May 15, 2023 08:10
Improve CHIP stack initialization in PlatformManager - add
stack initialization flag.
Check initialization stack state in event loop functions.
Initialize the CHIP stack in timer starting and event posting.
Dispatch all events in queue.

Signed-off-by: ATmobica <[email protected]>
Remove CHIP stack initialization in unit-tests application main.
Restore CHIP stack init and shutdown in unit tests context.
Skip TestEventLogging due to lack of real-time clock support.
Skip TestTLVPacketBufferBackingStore due to LwIP buffers usage
in SystemPacketBuffer.

Signed-off-by: ATmobica <[email protected]>
Zero-initialization of ip6_addr_t structure in TestInetAddress.
That protects against error that may occur when the memory is aligned
to multiples of 4 and LWIP_IPV6_SCOPES is enabled. In this case,
 the ip6_addr_t contains 16 bytes array of address and 1 byte of zone
but the structure length is 20. If we don't set the initial value
for ip_addr_1 and ip_addr_2  the memcmp returns mismatch.

Signed-off-by: ATmobica <[email protected]>
Add sleep after stopping event loop task.
In OIS platform implementations the event loop thread  is self-terminating.
We need time to process the stopping event inside event loop.

Signed-off-by: ATmobica <[email protected]>
Update Matter Python builder.
Check if FVP process run properly and wait for the
connection port log. Validate if FVP starts properly.
Wait for the FVP stop.
Move Pigweed env activation to a common point.
Create supported apps list and use it.
Fixing the optimization issue for mcu-driver-hal target
in the non-debug build.

Signed-off-by: ATmobica <[email protected]>
Use target name from function argument instead of
APP_TARGET variable in linker.cmake and sdk.cmake.
Add custom command to sign the TF-M non-secure image.

Signed-off-by: ATmobica <[email protected]>
Common:
Improve commissioning function to return commission error.
Check if FVP process run properly and wait for the connection port log.
Set verbose for  wait_for_output() function. The default value is
false - not print waiting log.
Fix telnet connection readline function, buffering output date and
processes only entire lines (ending with "\n").
Increase wait for lock-app application run timeout.
Increase wait for setup QR code timeout.
Add "verbose" state setting in the device class.
Improve read/write ZCL attributes and send ZCL command functions.
Improve controller device - add controllerConfig fixture, the
dictionary with settings, remove persistent storage file at the end,
change fixture scope to session.

Lock test:
Apply common changes.

Shell test:
Change the shell prompt to "Enter command:\r\n". It should be
terminated by a newline character.
Add waiting for the prompt before sending the shell command.
Update file header.

Signed-off-by: ATmobica <[email protected]>
For unit-test applications, 1MB ISRAM0 is not enough.
Extend it by adding ISRAM1, then 2MB of memory is available.
Change TF-M linker script and AN552 target configuration.

Signed-off-by: ATmobica <[email protected]>
Adapt unit-tests project to TF-M support.
Change unit-tests debug Vscode task.
Increase application run timeout for unit-tests integration test.

Signed-off-by: ATmobica <[email protected]>
Create unit-tests Python integration test that checks
and control time execution of OIS unit-tests.
Change run script to only run single test on FVP.
Add testing of unit-test apps to test script and Vscode
tasks and CI.

Signed-off-by: ATmobica <[email protected]>
Open IoT SDK version udpate.
Move LwIP opts settings to sdk.cmake. As default the
config/openiotsdk/lwip/user_lwipopts.h file is used.
You can provide your settings with define LWIP_PROJECT_OPTS_DIR
with path to custom file.
Add CONFIG_CHIP_OPEN_IOT_SDK_LWIP_DEBUG variable to
enable LwIP debug logs. It's disabled by default.
Add LwIP debug logs option to build script and VScode tasks.
Create common LwIP options for examples and unit-tests.

Signed-off-by: ATmobica <[email protected]>
Enable TFM fault trace support - application hangs instead of reset
in case of fault.

Force secure partition isolation to level 1 - this speed up
processing which allows slow Github runners to pass the tests.

Signed-off-by: Vincent Coubard <[email protected]>
Add startup library

This library setup the C runtime:
- Initialize stdio
- Start the kernel
- Create an run the main thread

The main thread setups TFM and the locks used by the libc before
entering main.

Additionaly, lock support has been added to malloc/free, operator
new and delete have been overriden to print errors and sbrk is
overriden to print heap segment overallocation.

The startup also rework stdio:

- Override iotsdk-serial-retarget
- Lock stream at the libc level
- Buffer bytes on the RX path

Add option to set serial baud rate from Cmake level.
Decrease serial baudrate for shell examples to 9600.
Create ois_logging_init() function and move setting log filter
for non-debug mode to it.

Co-authored-by: ATmobica <[email protected]>
Signed-off-by: Vincent Coubard <[email protected]>
Add correct condition for nullptr string argument.

Signed-off-by: ATmobica <[email protected]>
Adjust timeouts for job and steps.

Signed-off-by: ATmobica <[email protected]>
@ATmobica ATmobica force-pushed the upstream/ois-ci-impr branch from 9c35234 to 9b809ad Compare May 15, 2023 08:10
@yufengwangca yufengwangca merged commit 58699c8 into project-chip:master May 16, 2023
@ATmobica ATmobica deleted the upstream/ois-ci-impr branch May 19, 2023 07:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants