Reduce the GEOM verbosity under bootverbose to something more sufferable.
This is not quite the set of information I would want, but the tree where I have the "correct" version is messed up with conflicts. Sponsored by: DARPA & NAI Labs.
This commit is contained in:
parent
6de4b3c6cb
commit
3d5500fc51
@ -235,6 +235,8 @@ g_disk_create(void *arg)
|
||||
pp->mediasize = dev->si_disk->d_mediasize;
|
||||
pp->sectorsize = dev->si_disk->d_sectorsize;
|
||||
g_error_provider(pp, 0);
|
||||
if (bootverbose)
|
||||
printf("GEOM: new disk %s\n", gp->name);
|
||||
}
|
||||
|
||||
|
||||
|
@ -149,8 +149,6 @@ void
|
||||
g_init(void)
|
||||
{
|
||||
printf("Initializing GEOMetry subsystem\n");
|
||||
if (bootverbose)
|
||||
g_debugflags |= G_T_TOPOLOGY;
|
||||
sx_init(&topology_lock, "GEOM topology");
|
||||
g_io_init();
|
||||
g_event_init();
|
||||
|
@ -155,13 +155,11 @@ static void
|
||||
g_mbr_print(int i __unused, struct dos_partition *dp __unused)
|
||||
{
|
||||
|
||||
#if 0
|
||||
g_hexdump(dp, sizeof(dp[0]));
|
||||
printf("[%d] f:%02x typ:%d", i, dp->dp_flag, dp->dp_typ);
|
||||
printf(" s(CHS):%d/%d/%d", dp->dp_scyl, dp->dp_shd, dp->dp_ssect);
|
||||
printf(" e(CHS):%d/%d/%d", dp->dp_ecyl, dp->dp_ehd, dp->dp_esect);
|
||||
printf(" s:%d l:%d\n", dp->dp_start, dp->dp_size);
|
||||
#endif
|
||||
}
|
||||
|
||||
static struct g_geom *
|
||||
@ -235,7 +233,10 @@ g_mbr_taste(struct g_class *mp, struct g_provider *pp, int insist)
|
||||
continue;
|
||||
if (dp[i].dp_size == 0)
|
||||
continue;
|
||||
g_mbr_print(i, dp + i);
|
||||
if (bootverbose) {
|
||||
printf("Slice %d:\n", i + 1);
|
||||
g_mbr_print(i, dp + i);
|
||||
}
|
||||
npart++;
|
||||
ms->type[i] = dp[i].dp_typ;
|
||||
g_topology_lock();
|
||||
|
@ -141,7 +141,6 @@ g_pc98_taste(struct g_class *mp, struct g_provider *pp, int flags)
|
||||
buf[6] != 'L' || buf[7] != '1')
|
||||
break;
|
||||
|
||||
|
||||
for (i = 0; i < 16; i++) {
|
||||
v = g_dec_le2(buf + 512 + 10 + i * 32);
|
||||
u = g_dec_le2(buf + 512 + 14 + i * 32);
|
||||
|
@ -258,21 +258,32 @@ g_slice_config(struct g_geom *gp, int index, int how, off_t offset, off_t length
|
||||
gsl->length = length;
|
||||
gsl->offset = offset;
|
||||
gsl->sectorsize = sectorsize;
|
||||
if (length != 0 && pp != NULL)
|
||||
return (0);
|
||||
if (length == 0 && pp == NULL)
|
||||
return (0);
|
||||
if (length == 0 && pp != NULL) {
|
||||
if (length == 0) {
|
||||
if (pp == NULL)
|
||||
return (0);
|
||||
if (bootverbose)
|
||||
printf("GEOM: Deconfigure %s\n", pp->name);
|
||||
g_orphan_provider(pp, ENXIO);
|
||||
gsl->provider = NULL;
|
||||
gsp->nprovider--;
|
||||
return (0);
|
||||
}
|
||||
if (pp != NULL) {
|
||||
if (bootverbose)
|
||||
printf("GEOM: Reconfigure %s, start %jd length %jd end %jd\n",
|
||||
pp->name, (intmax_t)offset, (intmax_t)length,
|
||||
(intmax_t)(offset + length - 1));
|
||||
return (0);
|
||||
}
|
||||
va_start(ap, fmt);
|
||||
sb = sbuf_new(NULL, NULL, 0, SBUF_AUTOEXTEND);
|
||||
sbuf_vprintf(sb, fmt, ap);
|
||||
sbuf_finish(sb);
|
||||
pp = g_new_providerf(gp, sbuf_data(sb));
|
||||
if (bootverbose)
|
||||
printf("GEOM: Configure %s, start %jd length %jd end %jd\n",
|
||||
pp->name, (intmax_t)offset, (intmax_t)length,
|
||||
(intmax_t)(offset + length - 1));
|
||||
pp->index = index;
|
||||
pp->mediasize = gsl->length;
|
||||
pp->sectorsize = gsl->sectorsize;
|
||||
@ -308,6 +319,10 @@ g_slice_addslice(struct g_geom *gp, int index, off_t offset, off_t length, u_int
|
||||
pp->mediasize = gsp->slices[index].length;
|
||||
pp->sectorsize = gsp->slices[index].sectorsize;
|
||||
sbuf_delete(sb);
|
||||
if (bootverbose)
|
||||
printf("GEOM: Add %s, start %jd length %jd end %jd\n",
|
||||
pp->name, (intmax_t)offset, (intmax_t)length,
|
||||
(intmax_t)(offset + length - 1));
|
||||
return(pp);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user