[PATCH 0/2] firewire: core: allow unit drivers to schedule work item to process isochronous context

From: Takashi Sakamoto
Date: Sun Sep 08 2024 - 00:06:06 EST


Hi,

ALSA firewire stack uses packet-per-buffer mode for both isochronous
receive (IR) and transmit (IT) contexts of 1394 OHCI. To process time
stamp per packet (or per sample in some cases) steadily for media clock
recovery against unexpected transmission skips in the IR context, it uses
an IT context to operate all of isochronous contexts by calls of
fw_iso_context_flush_completions() in the bottom-half of hardIRQ for the
IT context.

Although it looks well to handle all of isochronous contexts in a single
bottom-half context, it relatively takes longer time to finish. In the
future code integration (not yet), it is possible to apply parallelism
method to process these context. In the case, it is useful to allow unit
drivers to schedule work items to process these isochronous contexts.

As a preparation, in this series of changes,
fw_iso_context_schedule_flush_completions() is exposed as a kernel API
available by unit drivers. It is a counter part of
fw_iso_context_flush_completions(). This series of changes also includes
documentation about these kernel APIs.

Takashi Sakamoto (2):
firewire: core: expose kernel API to schedule work item to process
isochronous context
firewire: core: fulfill documentation of
fw_iso_context_flush_completions()

Documentation/driver-api/firewire.rst | 2 ++
drivers/firewire/core-iso.c | 11 +++++++++++
drivers/firewire/core.h | 5 -----
drivers/firewire/ohci.c | 4 ++--
include/linux/firewire.h | 17 +++++++++++++++++
5 files changed, 32 insertions(+), 7 deletions(-)

--
2.43.0