1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-10-31 07:51:08 +03:00

volume_id: move some debug to info level

This commit is contained in:
Kay Sievers 2006-04-08 05:04:35 +02:00
parent 03149e13c2
commit f7dd3a57a4
28 changed files with 32 additions and 30 deletions

View File

@ -45,7 +45,7 @@ int volume_id_probe_cramfs(struct volume_id *id, uint64_t off)
{
struct cramfs_super *cs;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
cs = (struct cramfs_super *) volume_id_get_buffer(id, off, 0x200);
if (cs == NULL)

View File

@ -75,7 +75,7 @@ int volume_id_probe_ext(struct volume_id *id, uint64_t off)
struct ext2_super_block *es;
size_t bsize;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
es = (struct ext2_super_block *) volume_id_get_buffer(id, off + EXT_SUPERBLOCK_OFFSET, 0x200);
if (es == NULL)

View File

@ -147,7 +147,7 @@ int volume_id_probe_vfat(struct volume_id *id, uint64_t off)
uint32_t next;
int maxloop;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
vs = (struct vfat_super_block *) volume_id_get_buffer(id, off, 0x200);
if (vs == NULL)

View File

@ -160,7 +160,7 @@ int volume_id_probe_hfs_hfsplus(struct volume_id *id, uint64_t off)
struct hfsplus_extent extents[HFSPLUS_EXTENT_COUNT];
const uint8_t *buf;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
buf = volume_id_get_buffer(id, off + HFS_SUPERBLOCK_OFFSET, 0x200);
if (buf == NULL)

View File

@ -49,7 +49,7 @@ int volume_id_probe_highpoint_37x_raid(struct volume_id *id, uint64_t off)
struct hpt37x_meta *hpt;
uint32_t magic;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
buf = volume_id_get_buffer(id, off + HPT37X_CONFIG_OFF, 0x200);
if (buf == NULL)

View File

@ -38,7 +38,7 @@ int volume_id_probe_hpfs(struct volume_id *id, uint64_t off)
{
struct hpfs_super *hs;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
hs = (struct hpfs_super *) volume_id_get_buffer(id, off + HPFS_SUPERBLOCK_OFFSET, 0x200);
if (hs == NULL)

View File

@ -59,7 +59,7 @@ int volume_id_probe_iso9660(struct volume_id *id, uint64_t off)
struct iso_volume_descriptor *is;
struct high_sierra_volume_descriptor *hs;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
buf = volume_id_get_buffer(id, off + ISO_SUPERBLOCK_OFFSET, 0x200);
if (buf == NULL)

View File

@ -43,7 +43,7 @@ int volume_id_probe_intel_software_raid(struct volume_id *id, uint64_t off, uint
uint64_t meta_off;
struct isw_meta *isw;
dbg("probing at offset 0x%llx, size 0x%llx",
info("probing at offset 0x%llx, size 0x%llx",
(unsigned long long) off, (unsigned long long) size);
if (size < 0x10000)

View File

@ -45,7 +45,7 @@ int volume_id_probe_jfs(struct volume_id *id, uint64_t off)
{
struct jfs_super_block *js;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
js = (struct jfs_super_block *) volume_id_get_buffer(id, off + JFS_SUPERBLOCK_OFFSET, 0x200);
if (js == NULL)

View File

@ -54,7 +54,7 @@ int volume_id_probe_linux_raid(struct volume_id *id, uint64_t off, uint64_t size
uint64_t sboff;
uint8_t uuid[16];
dbg("probing at offset 0x%llx, size 0x%llx",
info("probing at offset 0x%llx, size 0x%llx",
(unsigned long long) off, (unsigned long long) size);
if (size < 0x10000)

View File

@ -42,7 +42,7 @@ int volume_id_probe_linux_swap(struct volume_id *id, uint64_t off)
const uint8_t *buf;
unsigned int page;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
/* the swap signature is at the end of the PAGE_SIZE */
for (page = 0x1000; page <= LARGEST_PAGESIZE; page <<= 1) {

View File

@ -38,7 +38,7 @@ int volume_id_probe_lsi_mega_raid(struct volume_id *id, uint64_t off, uint64_t s
uint64_t meta_off;
struct lsi_meta *lsi;
dbg("probing at offset 0x%llx, size 0x%llx",
info("probing at offset 0x%llx, size 0x%llx",
(unsigned long long) off, (unsigned long long) size);
if (size < 0x10000)

View File

@ -46,7 +46,7 @@ int volume_id_probe_lvm1(struct volume_id *id, uint64_t off)
const uint8_t *buf;
struct lvm1_super_block *lvm;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
buf = volume_id_get_buffer(id, off + LVM1_SB_OFF, 0x800);
if (buf == NULL)

View File

@ -46,7 +46,7 @@ int volume_id_probe_minix(struct volume_id *id, uint64_t off)
{
struct minix_super_block *ms;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
ms = (struct minix_super_block *) volume_id_get_buffer(id, off + MINIX_SUPERBLOCK_OFFSET, 0x200);
if (ms == NULL)

View File

@ -105,7 +105,7 @@ int volume_id_probe_ntfs(struct volume_id *id, uint64_t off)
const uint8_t *buf;
const uint8_t *val;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
ns = (struct ntfs_super_block *) volume_id_get_buffer(id, off, 0x200);
if (ns == NULL)

View File

@ -41,7 +41,7 @@ int volume_id_probe_nvidia_raid(struct volume_id *id, uint64_t off, uint64_t siz
uint64_t meta_off;
struct nvidia_meta *nv;
dbg("probing at offset 0x%llx, size 0x%llx",
info("probing at offset 0x%llx, size 0x%llx",
(unsigned long long) off, (unsigned long long) size);
if (size < 0x10000)

View File

@ -132,6 +132,8 @@ int volume_id_probe_ocfs1(struct volume_id *id, uint64_t off)
struct ocfs1_super_block_header *osh;
struct ocfs1_super_block_label *osl;
info("probing at offset 0x%llx", (unsigned long long) off);
buf = volume_id_get_buffer(id, off, 0x200);
if (buf == NULL)
return -1;
@ -168,7 +170,7 @@ int volume_id_probe_ocfs2(struct volume_id *id, uint64_t off)
struct ocfs2_super_block *os;
size_t blksize;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
for (blksize = 0x200; blksize <= OCFS2_MAX_BLOCKSIZE; blksize <<= 1) {
buf = volume_id_get_buffer(id, off + OCFS2_SUPER_BLOCK_BLKNO * blksize, 0x200);

View File

@ -42,7 +42,7 @@ int volume_id_probe_promise_fasttrack_raid(struct volume_id *id, uint64_t off, u
63, 255, 256, 16, 399, 0
};
dbg("probing at offset 0x%llx, size 0x%llx",
info("probing at offset 0x%llx, size 0x%llx",
(unsigned long long) off, (unsigned long long) size);
if (size < 0x40000)

View File

@ -60,7 +60,7 @@ int volume_id_probe_reiserfs(struct volume_id *id, uint64_t off)
struct reiser4_super_block *rs4;
uint8_t *buf;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
buf = volume_id_get_buffer(id, off + REISERFS_SUPERBLOCK_OFFSET, 0x200);
if (buf == NULL)

View File

@ -37,7 +37,7 @@ int volume_id_probe_romfs(struct volume_id *id, uint64_t off)
{
struct romfs_super *rfs;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
rfs = (struct romfs_super *) volume_id_get_buffer(id, off, 0x200);
if (rfs == NULL)

View File

@ -53,7 +53,7 @@ int volume_id_probe_silicon_medley_raid(struct volume_id *id, uint64_t off, uint
uint64_t meta_off;
struct silicon_meta *sil;
dbg("probing at offset 0x%llx, size 0x%llx",
info("probing at offset 0x%llx, size 0x%llx",
(unsigned long long) off, (unsigned long long) size);
if (size < 0x10000)

View File

@ -36,7 +36,7 @@ int volume_id_probe_squashfs(struct volume_id *id, uint64_t off)
{
struct squashfs_super *sqs;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
sqs = (struct squashfs_super *) volume_id_get_buffer(id, off + 0x200, 0x200);
if (sqs == NULL)

View File

@ -95,7 +95,7 @@ int volume_id_probe_sysv(struct volume_id *id, uint64_t off)
struct xenix_super *xs;
unsigned int boff;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
for (boff = 0x200; boff <= SYSV_MAX_BLOCKSIZE; boff <<= 1) {
vs = (struct sysv_super *)

View File

@ -72,7 +72,7 @@ int volume_id_probe_udf(struct volume_id *id, uint64_t off)
unsigned int loc;
unsigned int clen;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
vsd = (struct volume_structure_descriptor *) volume_id_get_buffer(id, off + UDF_VSD_OFFSET, 0x200);
if (vsd == NULL)

View File

@ -175,7 +175,7 @@ int volume_id_probe_ufs(struct volume_id *id, uint64_t off)
struct ufs_super_block *ufs;
int offsets[] = {0, 8, 64, 256, -1};
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
for (i = 0; offsets[i] >= 0; i++) {
ufs = (struct ufs_super_block *) volume_id_get_buffer(id, off + (offsets[i] * 0x400), 0x800);

View File

@ -180,7 +180,7 @@ uint8_t *volume_id_get_buffer(struct volume_id *id, uint64_t off, size_t len)
{
ssize_t buf_len;
dbg("get buffer off 0x%llx(%llu), len 0x%zx", (unsigned long long) off, (unsigned long long) off, len);
info("get buffer off 0x%llx(%llu), len 0x%zx", (unsigned long long) off, (unsigned long long) off, len);
/* check if requested area fits in superblock buffer */
if (off + len <= SB_BUFFER_SIZE) {
if (id->sbbuf == NULL) {
@ -193,7 +193,7 @@ uint8_t *volume_id_get_buffer(struct volume_id *id, uint64_t off, size_t len)
/* check if we need to read */
if ((off + len) > id->sbbuf_len) {
dbg("read sbbuf len:0x%llx", (unsigned long long) (off + len));
info("read sbbuf len:0x%llx", (unsigned long long) (off + len));
if (lseek(id->fd, 0, SEEK_SET) < 0) {
dbg("lseek failed (%s)", strerror(errno));
return NULL;
@ -229,7 +229,7 @@ uint8_t *volume_id_get_buffer(struct volume_id *id, uint64_t off, size_t len)
/* check if we need to read */
if ((off < id->seekbuf_off) || ((off + len) > (id->seekbuf_off + id->seekbuf_len))) {
dbg("read seekbuf off:0x%llx len:0x%zx", (unsigned long long) off, len);
info("read seekbuf off:0x%llx len:0x%zx", (unsigned long long) off, len);
if (lseek(id->fd, off, SEEK_SET) < 0) {
dbg("lseek failed (%s)", strerror(errno));
return NULL;

View File

@ -37,7 +37,7 @@ int volume_id_probe_vxfs(struct volume_id *id, uint64_t off)
{
struct vxfs_super *vxs;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
vxs = (struct vxfs_super *) volume_id_get_buffer(id, off + 0x200, 0x200);
if (vxs == NULL)

View File

@ -45,7 +45,7 @@ int volume_id_probe_xfs(struct volume_id *id, uint64_t off)
{
struct xfs_super_block *xs;
dbg("probing at offset 0x%llx", (unsigned long long) off);
info("probing at offset 0x%llx", (unsigned long long) off);
xs = (struct xfs_super_block *) volume_id_get_buffer(id, off, 0x200);
if (xs == NULL)