
CVSID:$Id: TODO,v 1.23 2004/05/07 17:41:33 joe Exp $
 
This document is the TODO list for the HAL project. Feel free to add/remove
entries if you get an idea or implement one of these.

 -  Add support for removal of class devices - we should probably remove
    the properties merged and send out a d-bus signal; see comments in 
    hald/linux/osspec.c:remove_class_device(). This can now easily be tested
    with modprobe and rmmod on the sg kernel module

 -  Persistent device store
    Device should be persistent (e.g. saved in a file) so i) we don't need
    to check fdi files each and every time we start up; and ii) device 
    properties are persistent across time

    - How this should be implemented should probably be discussed on the
      mailing list; one way is to use a binary format (performance), another
      way is to use a human-readable file (maybe even, ugh, xml). I personally
      opt the the binary format

    - There should be a commandline tool for the administrator to easily
      purge the database

    - We still need to scan all devices at startup; most of the logic is
      already implemented but it's a bit tricky to figure out.

 -  Support for more bus-devices and class-devices

 -  Testing framework; probably only feasible for non-os specific code, e.g.
    the whole device and device store framework

 -  Support for more filesystem sniffing and volume label extraction
    (see hald/linux/block_class_device.c:detect_fs). Only cdfs and udf
    seems to be missing

 -  Caching in libhal; the API is ready for it. Remember you cannot use
    glib or other dependencies; we can only depend on libc and dbus!

 -  Property access control and per-user properties
    Non-root users should only have read-access to the devices except
    in properties where the key starts with 'user.'. Also properties
    starting with 'user.' should be per-user (and per-box, e.g. don't
    save them in a dotfile or dotdirectory in the users homedir; see TODO
    item for persistent device store)

 -  Support for signed fdi files
    One way to implement this is using an existing PKI framework.
    There should be an easy way to sign an .fdi file e.g. a hal-sign-fdi 
    tool. There should also be a directory where vendors can easily 
    drop the public key. 
    Also, we should probably consider emitting a dbus-signal or setting
    a property so desktop environments can figure display an appropriate
    dialog with the .fdi file is unsigned. Probably needs discussion on the
    mailling list.

 -  Callouts are currently called in order, so if a callout hangs then
    no others will be called.  There should be a timeout which kills the
    callout after a certain period of time.  (5 seconds?  10?  15?)

 -  Don't remove a device before all the children are removed

 -  Clean shutdown
    The daemon should listen for SIGTERM, SIGQUIT and SIGINT and shut
    itself down cleanly.  This includes removing all devices from the GDL
    so that callouts can clean up any state on disk.

Issues with Linux kernel 2.6.*:

 -  The ide%d, parent of IDE devices, are no under /sys/bus or /sys/class.
    In HAL we call it ide_host

 -  16-bit PCMCIA devices (e.g. not CardBus) is not in sysfs

 -  It would be nice if the kernel could poll for media by itself; right
    now we poll for media in hald/linux/block_class_device.c:detect_media

 -  The ide_cs driver for PCMCIA card readers has a bug where it removes
    and inserts the block device when we do a simple readonly open on the
    top block device (to poll for media)

