drivers: ethernet: Convert DEVICE_AND_API_INIT to DEVICE_DEFINE

Convert driver(s) to DEVICE_DEFINE instead of DEVICE_AND_API_INIT
so we can deprecate DEVICE_AND_API_INIT in the future.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
Kumar Gala 2020-12-18 08:53:15 -06:00 committed by Anas Nashif
commit ce6088380f
3 changed files with 8 additions and 7 deletions

View file

@ -2449,8 +2449,8 @@ static int ptp_gmac_init(const struct device *port)
return 0;
}
DEVICE_AND_API_INIT(gmac_ptp_clock_0, PTP_CLOCK_NAME, ptp_gmac_init,
&ptp_gmac_0_context, NULL, POST_KERNEL,
CONFIG_APPLICATION_INIT_PRIORITY, &ptp_api);
DEVICE_DEFINE(gmac_ptp_clock_0, PTP_CLOCK_NAME, ptp_gmac_init,
device_pm_control_nop, &ptp_gmac_0_context, NULL, POST_KERNEL,
CONFIG_APPLICATION_INIT_PRIORITY, &ptp_api);
#endif /* CONFIG_PTP_CLOCK_SAM_GMAC */