Skip to content

Commit

Permalink
Annotate geom_md with MODULE_VERSION
Browse files Browse the repository at this point in the history
This was missed in 74d6c13 where other geom modules were annotated
with MODULE_VERSION.  Again, the problem is the same: we can't detect
that geom_md is loaded into the kernel without it.

This was noticed in release builds on the cluster; mdconfig attempts to
load geom_md because it can't detect it in the kernel, but the cluster
config includes md(4) and does not build the kmod.  This problem would
have been masked on hosts with the kmod built, as the kmod attempts to
register the g_md module and fails.  With this commit, mdconfig would
not even try to load it again.

(cherry picked from commit b9c92d6)
  • Loading branch information
kevans91 committed Feb 12, 2022
1 parent 5ae48f9 commit 371633e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions sys/dev/md/md.c
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,7 @@ struct g_class g_md_class = {
};

DECLARE_GEOM_CLASS(g_md_class, g_md);
MODULE_VERSION(geom_md, 0);

static LIST_HEAD(, md_s) md_softc_list = LIST_HEAD_INITIALIZER(md_softc_list);

Expand Down

0 comments on commit 371633e

Please sign in to comment.