mirage / mirage-block

Block implementations for mirage
ISC License
2 stars 10 forks source link

Add a `READ_ONLY` interface which allows us to manipulate the block device outside `lwt` #55

Open dinosaure opened 1 year ago

dinosaure commented 1 year ago

As discussed into our MirageOS meeting, I would like to add this new interface (and I will add a new type into mirage/mirage) to allow the manipulation of a block-device as a read-only filesystem. It fixes #53.

More precisely, this implementation is not a mmap implementation, it's just a referentially transparent read operation which can be outside lwt because we don't need to deal (with such view) with side-effects (like write).

hannesm commented 1 year ago

This looks nice, but shouldn't we move all READ_ONLY operations to outside the lwt monad? And eventually drop the disconnect, or do you see any use thereof in a concrete implementation?