diff options
author | Karel Zak | 2010-05-18 14:31:28 +0200 |
---|---|---|
committer | Karel Zak | 2010-05-18 15:26:03 +0200 |
commit | 508e438b5604206108c9ba03f5323df49805f89c (patch) | |
tree | f80e3e687c223af9bba79f7d677b46b06a5bde57 /shlibs/blkid/src/probe.c | |
parent | libblkid: cleanup superblocks_safeprobe() (diff) | |
download | kernel-qcow2-util-linux-508e438b5604206108c9ba03f5323df49805f89c.tar.gz kernel-qcow2-util-linux-508e438b5604206108c9ba03f5323df49805f89c.tar.xz kernel-qcow2-util-linux-508e438b5604206108c9ba03f5323df49805f89c.zip |
libblkid: probe for (non-linux) RAIDs on whole devices only
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'shlibs/blkid/src/probe.c')
-rw-r--r-- | shlibs/blkid/src/probe.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/shlibs/blkid/src/probe.c b/shlibs/blkid/src/probe.c index 370ef1335..200a52c5e 100644 --- a/shlibs/blkid/src/probe.c +++ b/shlibs/blkid/src/probe.c @@ -652,9 +652,6 @@ int blkid_probe_set_device(blkid_probe pr, int fd, pr->size -= pr->off; } - DBG(DEBUG_LOWPROBE, printf("ready for low-probing, offset=%jd, size=%jd\n", - pr->off, pr->size)); - if (pr->size <= 1440 * 1024 && !S_ISCHR(sb.st_mode)) pr->flags |= BLKID_TINY_DEV; @@ -662,6 +659,13 @@ int blkid_probe_set_device(blkid_probe pr, int fd, if (S_ISBLK(sb.st_mode) && ioctl(fd, CDROM_GET_CAPABILITY, NULL) >= 0) pr->flags |= BLKID_CDROM_DEV; #endif + + DBG(DEBUG_LOWPROBE, printf("ready for low-probing, offset=%jd, size=%jd\n", + pr->off, pr->size)); + DBG(DEBUG_LOWPROBE, printf("whole-disk: %s, regfile: %s\n", + blkid_probe_is_wholedisk(pr) ?"YES" : "NO", + S_ISREG(pr->mode) ? "YES" : "NO")); + return 0; err: DBG(DEBUG_LOWPROBE, |