samples: drivers: counter: Add supprt for RZ/G3S-SMARC

Add support for RZ/G3S-SMARC to Counter driver sample

Signed-off-by: Hieu Nguyen <hieu.nguyen.ym@bp.renesas.com>
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
This commit is contained in:
Hieu Nguyen 2024-12-16 13:43:28 +07:00 committed by Benjamin Cabé
parent 2e76631bae
commit 26548fc4a5
2 changed files with 13 additions and 0 deletions

View File

@ -0,0 +1,11 @@
/*
* Copyright (c) 2024 Renesas Electronics Corporation
*
* SPDX-License-Identifier: Apache-2.0
*/
&gtm0 {
counter {
status = "okay";
};
};

View File

@ -59,6 +59,8 @@ struct counter_alarm_cfg alarm_cfg;
#define TIMER DT_NODELABEL(counter0)
#elif defined(CONFIG_COUNTER_RA_AGT)
#define TIMER DT_NODELABEL(counter0)
#elif defined(CONFIG_COUNTER_RENESAS_RZ_GTM)
#define TIMER DT_INST(0, renesas_rz_gtm_counter)
#else
#error Unable to find a counter device node in devicetree
#endif