Commit graph

19 commits

Author SHA1 Message Date
Jordan Yates
ca72fff802 tests: pm: device_power_domains: remove CONFIG_PM
This test is unrelated to system PM.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2023-12-06 09:16:12 +00:00
Jordan Yates
955bd413e1 tests: pm: device_power_domains: test multiple claim
Test claiming a device multiple times before releasing it, and validate
that the power domain returns to off.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2023-12-06 09:16:12 +00:00
Alberto Escolar Piedras
b39d7c2c3d tests/subsys/pm/*: Switch to native_sim
Enable all these tests which run in native_posix in native_sim,
Switch from native_posix to native_sim as default test platform
And switch native_posix overlays to native_sim.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2023-11-22 09:53:54 +01:00
Anas Nashif
345735d0a8 tests: remove CONFIG_ZTEST_NEW_API in all tests
Remove all usage of CONFIG_ZTEST_NEW_API from tests and sample as this
is now enabled by default.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2023-10-20 15:04:29 +02:00
Anas Nashif
d885048637 tests: pm: power_domains: rename testcase, demo is ambigous
Rename testcase and use native_posix for coverage.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2023-09-27 15:11:18 -04:00
Jordan Yates
40d693371f tests: pm: update power domain behaviour
Update the expected power domain behaviour in the tests in line with
the driver implementation changes.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2023-07-26 08:16:44 +00:00
Jordan Yates
b74efbe59e Revert "tests: pm: update power domain behaviour"
This reverts commit b82bbf5e31.
2023-07-25 14:17:11 +02:00
Jordan Yates
b82bbf5e31 tests: pm: update power domain behaviour
Update the expected power domain behaviour in the tests in line with
the driver implementation changes.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2023-07-25 09:13:16 +02:00
Jordan Yates
9eaf1f8b44 tests: pm: power domains: test supported device
Validate the powered state and transitions for an arbitrary device
hanging off a power domain.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2023-01-24 09:42:11 +01:00
Kumar Gala
d2326fe187 drivers: power_domain: Update drivers to use devicetree Kconfig symbol
Update power_domain drivers to use DT_HAS_<compat>_ENABLED Kconfig
symbol to expose the driver and enable it by default based on
devicetree.

We remove one reference in prj.conf that is no longer needed.

Signed-off-by: Kumar Gala <kumar.gala@intel.com>
2022-11-02 15:41:17 +09:00
Kumar Gala
4f0166088c tests: move to using CONFIG_MP_MAX_NUM_CPUS
For tests that set CONFIG_MP_NUM_CPUS, switch to using
CONFIG_MP_MAX_NUM_CPUS instead as we work to phase out
CONFIG_MP_NUM_CPUS.

Signed-off-by: Kumar Gala <kumar.gala@intel.com>
2022-10-20 22:04:10 +09:00
Gerard Marull-Paretas
a202341958 devices: constify device pointers initialized at compile time
Many device pointers are initialized at compile and never changed. This
means that the device pointer can be constified (immutable).

Automated using:

```
perl -i -pe 's/const struct device \*(?!const)(.*)= DEVICE/const struct
device *const $1= DEVICE/g' **/*.c
```

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2022-08-22 17:08:26 +02:00
Yinfang Wang
9021c96e95 tests: subsys: pm: move device_power_domains to new ztest API
move device_power_domains to new ztest API.

Signed-off-by: Yinfang Wang <yinfang.wang@intel.com>
2022-08-15 18:40:17 +00:00
Kumar Gala
6c67239bc9 tests: subsys: pm: Remove unneccessary devicetree label prop
Remove "label" properties that are not used from devicetree
overlay files.

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-08-04 16:46:20 -05:00
Fabio Baltieri
def230187b test: fix more legacy #include paths
Add a bunch of missing "zephyr/" prefixes to #include statements in
various test and test framework files.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2022-08-02 16:41:41 +01:00
Jordan Yates
8eff15bab2 tests: pm: device: test pm_device_is_powered
Add tests for the function that checks whether a device is currently
powered.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2022-06-08 12:43:00 +02:00
Gerard Marull-Paretas
ade7ccb918 tests: migrate includes to <zephyr/...>
In order to bring consistency in-tree, migrate all tests to the new
prefix <zephyr/...>. Note that the conversion has been scripted, refer
to #45388 for more details.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2022-05-06 20:02:14 +02:00
Anas Nashif
97af0c8c33 tests: remove subsys prefix from test identifier
No need for subsys, the subsystem is expected to be the first component
of the identifier.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2022-03-18 10:50:57 -04:00
Jordan Yates
00317ef53a tests: pm: power_domains: initial demo
Add an initial demonstration of a physical power domain running on the
`qemu_cortex_m3` platform.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2022-01-19 13:35:32 -05:00