stacked bdev driver, howto? locking of lower level block device

Lars Ellenberg (l.g.e@web.de)
Mon, 5 Aug 2002 22:16:52 +0200


Hi there, I'm new on this list.

I do some happy hacking with drbd, which is "distributed replicated
block device", a stacked block device driver by Phillipp Reisner,
aiming towards network raid, GFS, this stuff.

I'd like to implement some kind of locking of the lower level
block device, so nobody can mount it/modify it underneath the drbd
driver.

I know drivers/md/md.c does this somehow. I tried to understand
and adapt, but it does not work.

Hopefully my questions are trivial to some of you. Please put me
on the right track.

- How does block device locking work?
- In which mode do I have to open it?
- Which flags have to be set?
- What else am I missing?

TIA
Lars-Gunnar
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/