As has been reported a few times on the linux1394-devel
list, hotplugging firewire drives only sortof works. A
posting to the list rehashing the problems
reminded me of my old partial fix for this problem that was
sitting unfinished. So last night I polished it up,
bugs, and it is now working perfectly for me.
Without this patch, hotplugging firewire drives will
drives with the 1394 layers, but will not register them
SCSI subsystem. Unplugging firewire drives leaves the (now
absent) drives still registered with the SCSI
subsystem. As you
can imagine, the current situation sucks, and makes
firewire drives mostly useless. To make things behave
one needs to manually add/remove SBP-2 devices using a
pokes at /proc/scsi/scsi by scanning though all your
and then does things like
echo "scsi remove-single-device 0 0 0 0" >
for each and every SCSI device on your system. I don't
such things safe or desirable at all.
It seemed to me that since the kernel had all the
do the Right Thing(tm), it made sense to connect the
remove-single-device and add-single-device functionality of
/proc/scsi/scsi together with the sbp2 driver so the Right
Thing(tm) could happen automagically.
With my patch applied, one can now plug in firewire
they will all be automagically registered with the SCSI
subsystem. When one unplugs SBP-2 devices, they will be
automagically unregistered from the SCSI subsystem.
When I posted my earlier effort to the linux1394-devel
it was decided that the change to the SCSI subsystem
expose scsi_add_single_device() and
was not desirable. I'll leave the decision on that to
For the moment, this patch is works nicely for me and
firewire drives a much nicer experience.
Erik B. Andersen
--This message was written using 73% post-consumer