firewire: add kernel API to access packet structure in request structure for AR context
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>
Tue, 5 Apr 2022 07:22:21 +0000 (16:22 +0900)
committerTakashi Iwai <tiwai@suse.de>
Tue, 5 Apr 2022 16:23:05 +0000 (18:23 +0200)
commitb2405aa948b95afc5246fa56fc05c3512cd6185c
tree4ea5a7f693605e2a267f65adef545282b332b60b
parentbaa914cd81f51f4e4f3bae5bb59764b32ad8c353
firewire: add kernel API to access packet structure in request structure for AR context

In 1394 OHCI specification, descriptor of Asynchronous Receive DMA context
has timeStamp field in its trailer quadlet. The field is written by
the host controller for the time to receive asynchronous request
subaction in isochronous cycle time.

In Linux FireWire subsystem, the value of field is stored to fw_packet
structure and copied to fw_request structure as the part. The fw_request
structure is hidden from unit driver and passed as opaque pointer when
calling registered handler. It's inconvenient to the unit driver which
needs timestamp of packet.

This commit adds kernel API to pick up timestamp from opaque pointer to
fw_request structure.

Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Link: https://lore.kernel.org/r/20220405072221.226217-4-o-takashi@sakamocchi.jp
Signed-off-by: Takashi Iwai <tiwai@suse.de>
drivers/firewire/core-transaction.c
include/linux/firewire.h