On Sun, 10 Feb 2013, Scott McEachern wrote:
> Moving this to tech.
>
> I tested the patch found at
> http://marc.info/?l=openbsd-tech&m=133513662106783&w=2 and can give you
> some results.
As you've already discovered, that diff is broken. BIOCVOL does not behave how
the diff assumes - it will return the volume specified by the bv_volid field
in the bioc_vol struct. Since this is never initialised you'll effectively
get a random volume returned (based on stack garbage). This is arguably a
design flaw in bio(4), which softraid could work around (basically we want to
identify the volume whose device we opened, not the softraid controller).
--
"Reason is not automatic. Those who deny it cannot be conquered by it.
Do not count on them. Leave them alone." -- Ayn Rand