event/cnxk: create and free timer adapter
authorShijith Thotton <sthotton@marvell.com>
Tue, 4 May 2021 00:27:14 +0000 (05:57 +0530)
committerJerin Jacob <jerinj@marvell.com>
Tue, 4 May 2021 05:27:59 +0000 (07:27 +0200)
commit0e792433d051efb6c68100383241f2c29c060e6d
tree29ddb535c2aa5a578579f548900471483c0ed725
parentdd519f83dd9691c10c5d192ab9dba2d6b45ff19c
event/cnxk: create and free timer adapter

When the application calls timer adapter create the following is used:
- Allocate a TIM LF based on number of LF's provisioned.
- Verify the config parameters supplied.
- Allocate memory required for
* Buckets based on min and max timeout supplied.
* Allocate the chunk pool based on the number of timers.

On Free:
- Free the allocated bucket and chunk memory.
- Free the TIM lf allocated.

Signed-off-by: Shijith Thotton <sthotton@marvell.com>
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
drivers/event/cnxk/cnxk_tim_evdev.c
drivers/event/cnxk/cnxk_tim_evdev.h