diff options
author | Karel Zak <kzak@redhat.com> | 2008-08-21 11:17:55 +0200 |
---|---|---|
committer | Karel Zak <kzak@redhat.com> | 2008-08-21 11:17:55 +0200 |
commit | 2482d7dd247d33ff224f330eba0874df2895d9a6 (patch) | |
tree | 7aa05d34c74218ada0c550183729dd3aa7c5d667 /mount/lomount.c | |
parent | 6bfa5f756f38211270f8eb0c2902dc68d808fe1e (diff) | |
download | util-linux-old-2482d7dd247d33ff224f330eba0874df2895d9a6.tar.gz |
losetup: remove unnecessary minor number check
The latest kernel supports partitioned loop devices (kernel commit
476a4813cfddf7cf159956cc0e2d3c830c1507e3). Unfortunately, this change
makes minor numbers useless, because mirror number does not match with
loop device name (loop<N>).
Fortunately, losetup code does not depend on minor numbers.
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'mount/lomount.c')
-rw-r--r-- | mount/lomount.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/mount/lomount.c b/mount/lomount.c index b9a83c6b..d47f3dd9 100644 --- a/mount/lomount.c +++ b/mount/lomount.c @@ -317,8 +317,7 @@ looplist_next(struct looplist *ll) ret = stat(ll->name, &st); if (ret == 0 && S_ISBLK(st.st_mode) && - major(st.st_rdev) == LOOPMAJOR && - minor(st.st_rdev) >= NLOOPS_DEFAULT) { + major(st.st_rdev) == LOOPMAJOR) { ll->ct_succ++; fd = open(ll->name, O_RDONLY); |