Make this compile in the userland-regression testsuite again.

This commit is contained in:
phk 2002-03-17 18:57:49 +00:00
parent 460894ff2e
commit 963527831a

View File

@ -88,24 +88,11 @@ g_bsd_start(struct bio *bp)
struct g_geom *gp;
struct g_bsd_softc *ms;
struct g_slicer *gsp;
struct partinfo pi;
struct g_ioctl *gio;
gp = bp->bio_to->geom;
gsp = gp->softc;
ms = gsp->softc;
#if 0
if (g_haveattr(bp, "IOCTL::DIOCGDINFO",
&ms->inram,
sizeof ms->inram))
return (1);
else if (!strcmp(bp->bio_attribute, "IOCTL::DIOCGPART")) {
pi.disklab = &ms->inram;
pi.part = &ms->inram.d_partitions[bp->bio_to->index];
if (g_haveattr(bp, "IOCTL::DIOCGPART", &pi, sizeof pi))
return (1);
}
#endif
if (strcmp(bp->bio_attribute, "GEOM::ioctl"))
return(0);
else if (bp->bio_length != sizeof *gio)
@ -117,7 +104,9 @@ g_bsd_start(struct bio *bp)
g_io_deliver(bp);
return (1);
}
#ifdef _KERNEL
if (gio->cmd == DIOCGPART) {
struct partinfo pi;
pi.disklab = &ms->inram;
pi.part = &ms->inram.d_partitions[bp->bio_to->index];
bcopy(&pi, gio->data, sizeof pi);
@ -125,6 +114,7 @@ g_bsd_start(struct bio *bp)
g_io_deliver(bp);
return (1);
}
#endif
return (0);
}