Skip to content

Commit

Permalink
drivers: cavs: set budget for IPC task
Browse files Browse the repository at this point in the history
IPC task may be time consuming and has high priority,
what may make other tasks stall. To prevent this it should
have limited cycles budget per systick.

Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
  • Loading branch information
jajanusz committed Jul 21, 2020
1 parent e003afe commit e8dc076
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
7 changes: 7 additions & 0 deletions src/drivers/intel/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,13 @@ config INTEL_DMIC
Select this to enable Intel DMIC driver. The DMIC driver provides
as DAI the SoC direct attach digital microphones interface.

config INTEL_CAVS_IPC_TASK_BUDGET
int "Intel cycles budget for IPC task"
depends on CAVS
default 8000
help
Cycles budget for IPC task per systick (see config SYSTICK).

if INTEL_DMIC

choice
Expand Down
6 changes: 4 additions & 2 deletions src/drivers/intel/cavs/ipc.c
Original file line number Diff line number Diff line change
Expand Up @@ -295,8 +295,10 @@ int platform_ipc_init(struct ipc *ipc)
ipc_set_drvdata(ipc, NULL);

/* schedule */
schedule_task_init_edf(&ipc->ipc_task, SOF_UUID(ipc_task_uuid),
&ipc_task_ops, ipc, 0, 0);
schedule_task_init_edf_with_budget(&ipc->ipc_task,
SOF_UUID(ipc_task_uuid),
&ipc_task_ops, ipc, 0, 0,
CONFIG_INTEL_CAVS_IPC_TASK_BUDGET);

/* configure interrupt */
irq = interrupt_get_irq(PLATFORM_IPC_INTERRUPT,
Expand Down

0 comments on commit e8dc076

Please sign in to comment.