[PATCH 00/11] firewire: deliver hardware time stamp for asynchronous transaction

From: Takashi Sakamoto
Date: Wed Jan 25 2023 - 07:03:19 EST


Hi,

1394 OHCI hardware supports hardware time stamp for asynchronous
communication at 8,000 Hz resolution (= isochronous cycle), while
current implementation of FireWire subsystem does not deliver the time
stamp to both unit driver and user space application when operating the
asynchronous communication. It is inconvenient to a kind of application
which attempts to synchronize data from multiple sources by the (coarse)
time stamp.

This patchset changes the subsystem so that the unit driver and the user
space application to receive the time stamp, therefore it affects kernel
service for asynchronous transaction, kernel API for unit driver, and UAPI
for user space application. It is based on the kernel tree to which the
other patches are applied[1]. It is also available in my remote repository
in github.com[2] for backporting purpose to kernel v5.19 or later.
Additionally, a test result is reported in README in the repository.


Well, in recent few years, I have requested the maintainer of sound
subsystem to apply small fixes to FireWire subsystem since upstream of
FireWire subsystem has been inactive[3]. Nevertheless, this patchset should
be enough large and beyond his courtesy[4]. At present, it's unclear that
who reviews them and who sends them to mainline. It matters to me... I'm
pleased that any one has an idea to solve the upstream problem.

(Iwai-san supposed the best would be that I would step up as a maintainer
for FireWire stack, but it is the last resort.)

[1] [PATCH 0/3] firewire: use single object for user space listeners to
dispatch request to IEC 61883-1 FCP region
https://lore.kernel.org/lkml/20230120090344.296451-1-o-takashi@xxxxxxxxxxxxx/
[2] https://github.com/takaswie/linux-firewire-dkms/tree/topic/firewire/async-context-tstamp
[3] https://lore.kernel.org/alsa-devel/s5htub52zz1.wl-tiwai@xxxxxxx/
[4] https://lore.kernel.org/lkml/873581r76s.wl-tiwai@xxxxxxx/


Regards

Takashi Sakamoto (11):
firewire: cdev: add new version of ABI to notify time stamp at
request/response subaction of transaction
firewire: cdev: add new event to notify request subaction with time
stamp
firewire: cdev: implement new event to notify request subaction with
time stamp
firewire: core: use union for callback of transaction completion
firewire: core: implement variations to send request and wait for
response with time stamp
firewire: cdev: code refactoring to operate event of response
firewire: cdev: add new event to notify response subaction with time
stamp
firewire: cdev: implement new event to notify response subaction with
time stamp
firewire: cdev: code refactoring to dispatch event for phy packet
firewire: cdev: add new event to notify phy packet with time stamp
firewire: cdev: implement new event relevant to phy packet with time
stamp

drivers/firewire/core-cdev.c | 252 +++++++++++++++++++++-------
drivers/firewire/core-transaction.c | 93 +++++++---
drivers/firewire/core.h | 7 +
drivers/firewire/ohci.c | 17 +-
include/linux/firewire.h | 82 ++++++++-
include/uapi/linux/firewire-cdev.h | 180 +++++++++++++++++---
6 files changed, 515 insertions(+), 116 deletions(-)

--
2.37.2