Skip providers with not defined sector size.
Reported by: kuriyama
This commit is contained in:
parent
db68d2a6b7
commit
29c78ab315
@ -545,6 +545,9 @@ g_concat_taste(struct g_class *mp, struct g_provider *pp, int flags __unused)
|
||||
g_topology_assert();
|
||||
|
||||
G_CONCAT_DEBUG(3, "Tasting %s.", pp->name);
|
||||
/* Skip providers with 0 sectorsize. */
|
||||
if (pp->sectorsize == 0)
|
||||
return (NULL);
|
||||
|
||||
gp = g_new_geomf(mp, "concat:taste");
|
||||
gp->start = g_concat_start;
|
||||
|
@ -201,6 +201,9 @@ g_label_taste(struct g_class *mp, struct g_provider *pp, int flags __unused)
|
||||
|
||||
G_LABEL_DEBUG(2, "Tasting %s.", pp->name);
|
||||
|
||||
/* Skip providers with 0 sectorsize. */
|
||||
if (pp->sectorsize == 0)
|
||||
return (NULL);
|
||||
if (strcmp(pp->geom->class->name, mp->name) == 0)
|
||||
return (NULL);
|
||||
|
||||
|
@ -2490,6 +2490,9 @@ g_mirror_taste(struct g_class *mp, struct g_provider *pp, int flags __unused)
|
||||
g_topology_assert();
|
||||
g_trace(G_T_TOPOLOGY, "%s(%s, %s)", __func__, mp->name, pp->name);
|
||||
G_MIRROR_DEBUG(2, "Tasting %s.", pp->name);
|
||||
/* Skip providers with 0 sectorsize. */
|
||||
if (pp->sectorsize == 0)
|
||||
return (NULL);
|
||||
|
||||
gp = g_new_geomf(mp, "mirror:taste");
|
||||
/*
|
||||
|
@ -2703,6 +2703,9 @@ g_raid3_taste(struct g_class *mp, struct g_provider *pp, int flags __unused)
|
||||
g_topology_assert();
|
||||
g_trace(G_T_TOPOLOGY, "%s(%s, %s)", __func__, mp->name, pp->name);
|
||||
G_RAID3_DEBUG(2, "Tasting %s.", pp->name);
|
||||
/* Skip providers with 0 sectorsize. */
|
||||
if (pp->sectorsize == 0)
|
||||
return (NULL);
|
||||
|
||||
gp = g_new_geomf(mp, "raid3:taste");
|
||||
/* This orphan function should be never called. */
|
||||
|
@ -876,6 +876,9 @@ g_stripe_taste(struct g_class *mp, struct g_provider *pp, int flags __unused)
|
||||
g_topology_assert();
|
||||
|
||||
G_STRIPE_DEBUG(3, "Tasting %s.", pp->name);
|
||||
/* Skip providers with 0 sectorsize. */
|
||||
if (pp->sectorsize == 0)
|
||||
return (NULL);
|
||||
|
||||
gp = g_new_geomf(mp, "stripe:taste");
|
||||
gp->start = g_stripe_start;
|
||||
|
Loading…
Reference in New Issue
Block a user