To Do

From IEEE 1394 FireWire Wiki
(Difference between revisions)
Jump to: navigation, search
(FireWire kernel subsystem: transaction timeout changed in 2.6.38, workqueue changes in 3.0, firedtv housekeeping in 2.6.39)
m (markup fixlet)
Line 65: Line 65:
 
=== firewire-sbp2 ===
 
=== firewire-sbp2 ===
  
* <s>[http://lwn.net/Articles/370150/ Concurrency-managed workqueues] have been [http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=3b7433b8a8a83c87972065b1852b7dcae691e464 merged] into the mainline.  Make use of them so that login, inquiry, and reconnects of different targets (or even different logical units?) are parallelized.  The present single-threaded workqueue of firewire-sbp2 is only a compromise to avoid the creation of lots of kernel threads that are idle most of the time.  If parallelism of management requests to different logical units on the same target work with multi-LUN devices that are available for testing, then firewire-sbp2 should simply queue everything into system_nrt_wq.</s>  &amp;  Done, merged in Linux 3.0.
+
* <s>[http://lwn.net/Articles/370150/ Concurrency-managed workqueues] have been [http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=3b7433b8a8a83c87972065b1852b7dcae691e464 merged] into the mainline.  Make use of them so that login, inquiry, and reconnects of different targets (or even different logical units?) are parallelized.  The present single-threaded workqueue of firewire-sbp2 is only a compromise to avoid the creation of lots of kernel threads that are idle most of the time.  If parallelism of management requests to different logical units on the same target work with multi-LUN devices that are available for testing, then firewire-sbp2 should simply queue everything into system_nrt_wq.</s>  &mdash;  Done, merged in Linux 3.0.
 
* Change the bus reset handling thus that scsi_block_requests/scsi_unblock_requests is no longer needed, as this is a fragile mechanism and requires nontrivial state tracking.  Instead, let a SCSI transaction overlap a bus reset and either let it time out (so that the SCSI subsystem retries it) or retry it in firewire-sbp2 itself after the reset and reconnect/re-login.
 
* Change the bus reset handling thus that scsi_block_requests/scsi_unblock_requests is no longer needed, as this is a fragile mechanism and requires nontrivial state tracking.  Instead, let a SCSI transaction overlap a bus reset and either let it time out (so that the SCSI subsystem retries it) or retry it in firewire-sbp2 itself after the reset and reconnect/re-login.
 
* Implement dynamically appended ORB lists for performance improvement.  Note, the old sbp2 driver's implementation of ORB lists is very buggy (default: off) but nevertheless results in better throughput with [http://marc.info/?l=linux1394-devel&m=125071985218864 some hardware combinations].
 
* Implement dynamically appended ORB lists for performance improvement.  Note, the old sbp2 driver's implementation of ORB lists is very buggy (default: off) but nevertheless results in better throughput with [http://marc.info/?l=linux1394-devel&m=125071985218864 some hardware combinations].
Line 96: Line 96:
 
* Implement a V4L2 driver which exposes DV and HDV devices ([[Specifications#IEC_61883|IEC 61883-2...-4]] camcorders, tapes, analogue tuners, TV sets) as /dev/video* devices?  This has been [http://marc.info/?l=linux1394-devel&m=122488376116868 suggested] in order to offer an interface that is supported by a broad variety of multimedia application programs.
 
* Implement a V4L2 driver which exposes DV and HDV devices ([[Specifications#IEC_61883|IEC 61883-2...-4]] camcorders, tapes, analogue tuners, TV sets) as /dev/video* devices?  This has been [http://marc.info/?l=linux1394-devel&m=122488376116868 suggested] in order to offer an interface that is supported by a broad variety of multimedia application programs.
 
* Implement an SBP-2 target using the in-kernel SCSI target framework as an alternative to Endpoint (Oracle's SBP-2 target implementation in userspace).
 
* Implement an SBP-2 target using the in-kernel SCSI target framework as an alternative to Endpoint (Oracle's SBP-2 target implementation in userspace).
* <s>Reimplement [[Out-of-tree Kernel Drivers|liSight]] on top of firewire-core.</s> snd-isight driver by Clemens Ladisch has been merged in Linux 3.0
+
* <s>Reimplement [[Out-of-tree Kernel Drivers|liSight]] on top of firewire-core.</s> &mdash;  snd-isight driver by Clemens Ladisch has been merged in Linux 3.0.

Revision as of 23:42, 1 June 2011

Linux1394 Project TODO List

This page is targeted towards users (to see which things don't work yet) as well as to developers (to pick a project which caught their interest). People new to FireWire low-level development may find our lists of specifications and books useful. Almost all FireWire related specifications are open, some of them even gratis.

See also our list of bugs at bugzilla.kernel.org for a whole lot of TODO items. There are also bugs filed in distributors' bug trackers but they are not as easy to query.


Contents


Documentation

  • Userspace programming documentation (for "plumbing layer" and application layer programming):
    • Add linux/Documentation/ABI/stable/sysfs-bus-firewire with reference documentation of firewire-core's sysfs interface.
    • Add linux/Documentation/ABI/stable/dev-fw (or however it should be called) with a summary description of firewire-core's character device file interface and a pointer to <linux/firewire-cdev.h>'s inline documentation.
    • Write some overview documentation of firewire-core's character device file interface: How to use ioctl, read, (e)poll, mmap; how ioctls and read events are paired; relationship between various ioctls and events to single nodes or a single bus or all buses; how to perform a few common tasks...
  • Kernel programming documentation:
    • Finish kerneldoc comments of all exported functions and struct types that are part of the firewire-core APIs?
    • Add a template to linux/Documentation/DocBook to pull firewire-core's kerneldoc comments in? Ideally, arrange the documentation in chapters for the userspace API, high-level API, and low-level API.
  • Usage documentation:
    • Add documentation for individual drivers on this wiki? See Special:Wantedpages.
    • Derive documentation suitable for distribution with the mainline kernel sources, i.e. linux/Documentation/...?


Support in userspace

  • libraw1394:
    • Fix handling of device removal. Implement hand-over to different default ioctl fd and iso ioctl fd when necessary and possible.
    • Implement multichannel isochronous reception with firewire-core of kernel 2.6.36 and later, as present in the raw1394 backend.
    • As an optimization, raw1394_read could be tweaked to use the kernel's Configuration ROM cache whenever a client attempts to read somewhere in the Config ROM, by means of FW_CDEV_IOC_GET_INFO. This would not only eliminate bus traffic, it would also make all the userspace Config ROM reading code much more robust.
  • Add <linux/firewire-cdev.h> support in FFmpeg's libavformat?
  • Add <linux/firewire-cdev.h> support in libdc1394 v1?


FireWire kernel subsystem

firewire-core

  • Use the non-reentrant system workqueue system_nrt_wq (added in 2.6.36-rc1) instead of the default system workqueue for fw_device.work, fw_card.bm_work, and fw_card.br_work. — Switched to non-reentrant workqueue with rescuer in Linux 3.0.
  • Design and implement an FCP transactions serializing infrastructure? See this posting for requirements.
  • Transaction layer: The transaction timeout should be counted from the time when the request hit the bus, not from the time when the request was handed over from upper layers to fw-core. — Done, merged in Linux 2.6.38.
  • Bus management:
    • Fedora bug 633260: A 1394-1995 IRM implementation in Canon camcorders and our 1394a-2000 IRM implementation fight endlessly over who shall be IRM, causing a bus reset loop.
    • Set SPLIT_TIMEOUT to the same value on all nodes.
    • Initialize BUS_TIME to the same value on all nodes.
    • Set PRIORITY_BUDGET on all nodes.
    • Implement gap count optimization based on round-trip delay measurement alternatively to the present hop count table based gap count optimization. The latter cannot be used if 1394b repeater nodes are present. (The algorithm for this is patented and not included in the 1394 Patent Portfolio License.)
    • Power management: Clear the linkoff bit and/or send link_on to disabled nodes if there is enough power. (It is impossible to determine whether there is enough power since too many devices and PCs provide wrong power class information.)

firewire-net

  • Release isochronous reception context at ifdown.
  • Reduce CPU utilization.
  • Implement IPv6 support as per RFC 3146.

firewire-ohci

  • Move all (or as much as possible) of the isochronous receive and transmit context tasklets into the IRQ handler. This is most desirable for low latency as required for audio I/O. Note, such a change may also affect other drivers. It may for example be necessary to add a tasklet to firewire-net for ARP/ broadcast/ multicast reception.
  • Bug 10935: ALi controllers don't work yet.
  • Fedora bug 228073: Apple UniNorth v1 built-in controllers do not seem to fully work.
  • Bug 8828, Fedora bug 244576: Come up with a quirk fix for NForce2. The person to do so will most certainly require direct access to this hardware. Note, the NForce2 workaround in ohci1394 is unacceptable by today's standards as it involves busy-waiting in the interrupt handler. Either we find something better for firewire-ohci, or NForce2 remains unsupported in firewire-ohci.
  • Fedora bug 492718 comments 5 and 6: Implement a workaround for Texas Instruments' erratum SLLZ012, "Errata for the 1394 Physical Layer Devices"?
  • Fedora bug 608544: Handle IntEvent.regAccessFail at least in ohci_enable().

firewire-sbp2

  • Concurrency-managed workqueues have been merged into the mainline. Make use of them so that login, inquiry, and reconnects of different targets (or even different logical units?) are parallelized. The present single-threaded workqueue of firewire-sbp2 is only a compromise to avoid the creation of lots of kernel threads that are idle most of the time. If parallelism of management requests to different logical units on the same target work with multi-LUN devices that are available for testing, then firewire-sbp2 should simply queue everything into system_nrt_wq. — Done, merged in Linux 3.0.
  • Change the bus reset handling thus that scsi_block_requests/scsi_unblock_requests is no longer needed, as this is a fragile mechanism and requires nontrivial state tracking. Instead, let a SCSI transaction overlap a bus reset and either let it time out (so that the SCSI subsystem retries it) or retry it in firewire-sbp2 itself after the reset and reconnect/re-login.
  • Implement dynamically appended ORB lists for performance improvement. Note, the old sbp2 driver's implementation of ORB lists is very buggy (default: off) but nevertheless results in better throughput with some hardware combinations.
  • Implement SBP-3 FASTSTART protocol which is rumored to be supported by newer OxSemi bridges and INIC-2430. — None of my (Stefan R.'s) OxSemi 912/ 924/ 934/ 936 or Initio 2430 based devices' firmwares offer FASTSTART support. It seems too rare to justify to add it to the driver.
  • Implement operation without physical DMA.
  • Implement hand-over from OpenFirmware login. When an Apple PC boots from a FireWire disk, the OpenFirmware is already logged in but does apparently not log out after it loaded the kernel image. When then the kernel's firewire-sbp2 (or sbp2, for that matter) logs in, the target may deny access. This has been observed with Momobay CX-1. The old ieee1394 driver stack somehow overcomes this because of timing subtleties, but firewire-sbp2 ends up with failed login due to denied access.
  • Bug 3225: Integrate with scsi_wait_scan module?


Other kernel drivers

firedtv

  • Remove ieee1394 driver binding and I/O code which has become unused since 2.6.37. — Done, merged in Linux 2.6.39.
  • Use firewire-core's channel and bandwidth allocation function in firedtv for proper cooperation with non-FireDTV AV/C devices on the same bus.

init_ohci1394_dma

  • Add support for more architectures besides x86-64.
  • Add interrupt handling to re-enable physical DMA after bus reset.
  • Add hand-over of interrupt handling from init_ohci1394_dma to firewire-ohci.

New drivers

  • Implement an audio i/o driver to enable FFADO to run smoother with less effort. Current and previous work, in reverse chronological order:
  • Implement a V4L2 driver which exposes DV and HDV devices (IEC 61883-2...-4 camcorders, tapes, analogue tuners, TV sets) as /dev/video* devices? This has been suggested in order to offer an interface that is supported by a broad variety of multimedia application programs.
  • Implement an SBP-2 target using the in-kernel SCSI target framework as an alternative to Endpoint (Oracle's SBP-2 target implementation in userspace).
  • Reimplement liSight on top of firewire-core. — snd-isight driver by Clemens Ladisch has been merged in Linux 3.0.
Personal tools