when a disk or a cdrom reports that it has 0 sectors
devsd won't let you write to the control file. it gives
write error: media or partition has changed.
this is because sdinitpart increments the partition vers
each time it is called and it's called in many places when
the number of sectors is zero.
there are a couple of senerios where this is a pain.
first, if you have a blank cdrom in the tray, you can't
echo dma on>/dev/sdXX/ctl
worse, if i have a drive that sometimes needs to be reset
manually. (some sata drives have loopy firmware.) i can't
echo reset>/dev/sdE5/ctl
to fix it. (one could abuse /dev/sdctl to do this, but then
you've reinvented the problem of figuring out which
device is the intended target of the request.)
am i missing something here or is this a real devsd
problem? without knowing a whole lot about devsd,
i would think that the devsd should allow writes to
the control file even when sectors == 0. perhaps
letting -1 sectors be the sentinal value would be enough.
- erik