mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-15 10:17:20 +00:00
Don't probe for a disk unless explicitly enabled by a tunable.
This allows boot to proceed on a real system until the issue of calling back into certain OpenFirmware calls (e.g. finddevice) in thread context is understood. (this commit only affects psim users, of which I think I am the only one...)
This commit is contained in:
parent
efd3a489a7
commit
b8e106eadd
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=139372
@ -73,6 +73,9 @@ struct g_class g_ofwd_class = {
|
||||
|
||||
DECLARE_GEOM_CLASS(g_ofwd_class, g_ofwd);
|
||||
|
||||
static int ofwd_enable = 0;
|
||||
TUNABLE_INT("kern.ofw.disk", &ofwd_enable);
|
||||
|
||||
static int
|
||||
ofwd_startio(struct ofwd_softc *sc, struct bio *bp)
|
||||
{
|
||||
@ -139,6 +142,9 @@ g_ofwd_init(struct g_class *mp __unused)
|
||||
ihandle_t ifd;
|
||||
int error;
|
||||
|
||||
if (ofwd_enable == 0)
|
||||
return;
|
||||
|
||||
ofd = OF_finddevice("ofwdisk");
|
||||
if (ofd == -1)
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user