Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 07 Sep 2024 12:45:29 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 255072] boot (legacy): no progress beyond 'BIOS DRIVE D: is disk1'
Message-ID:  <bug-255072-227-Dr6HdjDQDs@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-255072-227@https.bugs.freebsd.org/bugzilla/>
References:  <bug-255072-227@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D255072

--- Comment #50 from spell@itl.ua ---
(In reply to Toomas Soome from comment #45)

> Unfortunately, with those legacy cases, we really can not fix it just by=
=20
> reading and changing the code -- we need to understand under which condit=
ions
> the problem is appearing and then figure how to fix it. Meaning, debug=20
> printouts need to be inserted and it is long cycle of tests.... and=20
> unfortunately, those tests need to be performed on that specific hardware.

BTW, I had done this investigation already, with all those printouts, long
cycle of tests and finally locating the exact point and conditions when boot
fails.
The issue is obviously in BIOS code and has stochastic behavior as it occurs
due to (seems) some race condition.
My comprehensive tests had shown that in no way the FreeBSD loader code cau=
ses
the failure (I've tested 11.2-RELEASE and 12.3-RELEASE).
The failure occurs exclusively inside of bd_edd_io() or bd_int13probe(), th=
ough
far not every call of these functions. This conclusion is based on result of
debug printf()'s: right before these calls and right after of them. Sometim=
es
(randomly) these functions do not return (no exit debug message), approxima=
tely
once per several tens of calls (proved by print()'s with incrementing number
after each such call, and this number is always random one), without any
regularity, so it is like some race condition.
bd_edd_io() and bd_int13probe() call BIOS INT 13H, so it appears to be the
cause of the failure.
The reason why 11.2 loader seems to not having this issue (it boots normall=
y)
is just the fact it calls INT 13H just several times (about 6 or so) and al=
most
always the race condition does not occur and boot goes normally (proved by
incrementing count of bd_int13probe() calls - boot fails).
Contrarily, 12.3 loader, due to zfs probing, has over hundred of INT 13H ca=
lls
so earlier or sooner INT 13H runs into the race condition and boot fails.

Just to remember, the failure occurs when three conditions are met:
1) Legacy boot
2) AHCI mode
3) USB flash drive inserted
In these conditions, boot fails regardless of the device from which boot is
preformed, whether it is USB Drive or HDD. So conclusion is: BIOS 13H handl=
er
incorrectly handles HDD+FlashDrive combination in AHCI mode.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-255072-227-Dr6HdjDQDs>