Multiprotocol Service Layer workqueue

The Multiprotocol Service Layer (MPSL) workqueue library allows submitting tasks to the Multiprotocol Service Layer workqueue for processing. The MPSL workqueue is a workqueue running with a higher priority than the system workqueue.

Implementation

The MPSL workqueue is an instance of the Zephyr kernel workqueue which processes the MPSL low-priority signals.

Usage

The MPSL workqueue is intended to be used by callers of the low-priority MPSL API to process work in the same thread as the MPSL low-priority signals.

API documentation

Header file: include/mpsl/mpsl_work.h
Source files: subys/mpsl/
group mpsl_work

Internal MPSL workqueue.

Functions

static inline void mpsl_work_submit(struct k_work *work)

Submit a work item to the MPSL workqueue.

This routine submits work item work to be processed by the MPSL workqueue. If the work item is already pending in the MPSL workqueue or any other workqueue as a result of an earlier submission, this routine has no effect on the work item. If the work item has already been processed, or is currently being processed, its work is considered complete and the work item can be resubmitted.

Note

Work items submitted to the MPSL workqueue should avoid using handlers that block or yield since this may prevent the MPSL workqueue from processing other work items in a timely manner.

Note

Can be called by ISRs.

Parameters:
  • work – Address of work item.

static inline void mpsl_work_schedule(struct k_work_delayable *dwork, k_timeout_t delay)

Submit an idle work item to the MPSL workqueue after a delay.

Note

Can be called by ISRs.

Note

Work items submitted to the MPSL workqueue should avoid using handlers that block or yield since this may prevent the MPSL workqueue from processing other work items in a timely manner.

Note

This is a no-op if the work item is already scheduled or submitted, even if delay is K_NO_WAIT.

Parameters:
  • dwork – Address of delayable work item.

  • delay – the time to wait before submitting the work item. If K_NO_WAIT and the work is not pending this is equivalent to mpsl_work_submit().

Variables

struct k_work_q mpsl_work_q