samples/net: Adding relevant parts to test PM on echo server

Just to get something to test for PM, via frdm_k64f board. So only this
board will get PM enabled.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
This commit is contained in:
Tomasz Bursztyka 2020-02-28 15:03:55 +01:00 committed by Jukka Rissanen
commit df368e8094
2 changed files with 7 additions and 0 deletions

View file

@ -198,6 +198,11 @@ static int eth_mcux_device_pm_control(struct device *dev, u32_t command,
if (*(u32_t *)context == DEVICE_PM_SUSPEND_STATE) {
LOG_DBG("Suspending");
ret = net_if_suspend(eth_ctx->iface);
if (ret == -EBUSY) {
goto out;
}
eth_mcux_phy_enter_reset(eth_ctx);
eth_mcux_phy_stop(eth_ctx);

View file

@ -0,0 +1,2 @@
CONFIG_SYS_POWER_MANAGEMENT=y
CONFIG_DEVICE_POWER_MANAGEMENT=y