add -r to make resulting device read-only
authorRitesh Raj Sarraf <rrs@researchut.com>
Wed, 2 Feb 2011 14:21:46 +0000 (19:51 +0530)
committerChristophe Varoqui <christophe.varoqui@opensvc.com>
Wed, 2 Feb 2011 17:14:36 +0000 (18:14 +0100)
commit6c923aaaeb956a178f2545455faf0fec132e6e6e
tree5e8dabb7c582e9dea2319a08b3ec191ec5c3cfc2
parent035ea75c47302fc95d5742e854971f951419ec81
add -r to make resulting device read-only

This patch adds the ability to create targets which are read-only to
keep from accidentally modifying the newly created device.  In some cases,
mounting with -o ro still modifies the device (in the case of ext3
filesystems).  I created a small patch that will do this.  I have tested it
only to the point that using -a with or without -r produces the desired
effects.

Signed-off-by: Ritesh Raj Sarraf <rsarraf@netapp.com>
Signed-off-by: Wakko Warner <wakko@animx.eu.org>
kpartx/devmapper.c
kpartx/devmapper.h
kpartx/kpartx.c