]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Fix loader detection of vbefb support on !amd64
authorDimitry Andric <dim@FreeBSD.org>
Wed, 27 Jan 2021 21:28:43 +0000 (22:28 +0100)
committerToomas Soome <tsoome@FreeBSD.org>
Tue, 23 Feb 2021 07:41:55 +0000 (09:41 +0200)
commit6daafec2083848e2da210bd2183e6fb598944bd2
tree045c31e970c82a0bbd1003ab2fd6138b6eec1b70
parentce132d4aab6762d7287eca1e0f0ade5cf4d7576e
Fix loader detection of vbefb support on !amd64

On i386, after 6c7a932d0b8baaaee16eca0ba061bfa6e0e57bfd, the vbefb vt
driver was no longer detected by the loader, if any kernel module was
loaded after the kernel itself.

This was caused by the parse_vt_drv_set() function being called multiple
times, resetting the detection flag. (It was called multiple times,
becuase i386 .ko files are shared objects like the kernel proper, while
this is not the case on amd64.)

Fix this by skipping the set_vt_drv_set lookup if vbefb was already
detected.

(cherry picked from commit 6e26189be406a9a3799074b16925e6cd63cc703b)

Reviewed by: tsoome
Approved by: re (gjb)
stand/common/load_elf.c