VirtualBox

#21446 closed defect (fixed)

Linux guest additions 7.0.6: vbox_drv.c compile error with (RH)EL 8.7 kernel: implicit declaration of function ‘vgacon_text_force’ => fixed in svn

Reported by: mareks Owned by:
Component: guest additions Version: VirtualBox-7.0.6
Keywords: Cc:
Guest type: Linux Host type: Windows

Description

Host:

Guest (as updated to latest 8.7):

  • RockyLinux 8.7
  • kernel: 4.18.0-425.10.1.el8_7.x86_64

Guest additions kernel module will fail to build on:

/tmp/vbox.0/vbox_drv.c: In function ‘vbox_init’:
/tmp/vbox.0/vbox_drv.c:54:34: error: implicit declaration of function ‘vgacon_text_force’ [-Werror=implicit-function-declaration]
 #  define VBOX_VIDEO_NOMODESET() vgacon_text_force() && vbox_modeset == -1
                                  ^~~~~~~~~~~~~~~~~

(see attached log)

Same build error w/ VBoxGuestAdditions_7.0.7-155247 (latest testing available)

I've seen in RHEL kernel changelog that nomodeset changes might have been backported into -425, not sure if this is the cause though?

* Fri Dec  9 13:00:00 2022 Jarod Wilson <jarod@redhat.com> [4.18.0-425.9.1.el8_7]
- Documentation/admin-guide: Document nomodeset kernel parameter (Jocelyn Falempe) [2145218 2143952]
- drm: Move nomodeset kernel parameter to the DRM subsystem (Jocelyn Falempe) [2145218 2143952]

Changing

#  define VBOX_VIDEO_NOMODESET() vgacon_text_force() && vbox_modeset == -1

to

#  define VBOX_VIDEO_NOMODESET() drm_firmware_drivers_only() && vbox_modeset == -1

seems to fix the build, although I have no idea whether this produces working driver module.

Attachments (1)

vboxadd-setup.log (10.8 KB ) - added by mareks 15 months ago.
vboxadd-setup build log

Download all attachments as: .zip

Change History (7)

by mareks, 15 months ago

Attachment: vboxadd-setup.log added

vboxadd-setup build log

comment:1 by galitsyn, 15 months ago

Summary: Linux guest additions 7.0.6: vbox_drv.c compile error with (RH)EL 8.7 kernel: implicit declaration of function ‘vgacon_text_force’Linux guest additions 7.0.6: vbox_drv.c compile error with (RH)EL 8.7 kernel: implicit declaration of function ‘vgacon_text_force’ => fixed in svn

Hi mareks,

This issue should be now fixed. Could you please try the latest "Development snapshot" from https://www.virtualbox.org/wiki/Testbuilds?

comment:2 by mareks, 15 months ago

rebuild of guest additions OK w/ VBoxGuestAdditions_7.0.7-155584.iso

[root@linux-hostname mnt]# uname -a
Linux linux-hostname 4.18.0-425.10.1.el8_7.x86_64 #1 SMP Thu Jan 12 16:32:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
[root@linux-hostname mnt]# cat /etc/redhat-release 
Rocky Linux release 8.7 (Green Obsidian)

[root@linux-hostname mnt]# ./VBoxLinuxAdditions.run 
Verifying archive integrity...  100%   MD5 checksums are OK. All good.
Uncompressing VirtualBox 7.0.7 Guest Additions for Linux  100%  
VirtualBox Guest Additions installer
Removing installed version 7.0.6 of VirtualBox Guest Additions...
VirtualBox Guest Additions: Starting.
VirtualBox Guest Additions: Setting up modules
VirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel 
modules.  This may take a while.
VirtualBox Guest Additions: To build modules for other installed kernels, run
VirtualBox Guest Additions:   /sbin/rcvboxadd quicksetup <version>
VirtualBox Guest Additions: or
VirtualBox Guest Additions:   /sbin/rcvboxadd quicksetup all
VirtualBox Guest Additions: Building the modules for kernel 
4.18.0-425.10.1.el8_7.x86_64.
VirtualBox Guest Additions: Running kernel modules will not be replaced until 
the system is restarted
[root@linux-hostname mnt]# 


thanks, will look forward for 7.0.7 :)

comment:3 by Guillermo Jano, 15 months ago

I am observing the same problem on Rocky Linux 9.1. Tested with https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_7.0.7-155584.iso:

Building the main Guest Additions 7.0.7 module for kernel 5.14.0-162.12.1.el9_1.0.1.x86_64.
Building the shared folder support module.
Building the graphics driver module.
Error building the module.  Build output follows.
[...]
/tmp/vbox.0/vbox_drv.c: In function ‘vbox_init’:
/tmp/vbox.0/vbox_drv.c:54:34: error: implicit declaration of function ‘vgacon_text_force’ [-Werror=implicit-function-declaration]
   54 | #  define VBOX_VIDEO_NOMODESET() vgacon_text_force() && vbox_modeset == -1
      |                                  ^~~~~~~~~~~~~~~~~
/tmp/vbox.0/vbox_drv.c:410:20: note: in expansion of macro ‘VBOX_VIDEO_NOMODESET’
  410 |                 printk("vboxvideo: please consider either to remove it or load driver\n");
      |                    ^~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:295: /tmp/vbox.0/vbox_drv.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[...]
make[1]: *** [Makefile:1915: /tmp/vbox.0] Error 2
make: *** [/tmp/vbox.0/Makefile-footer.gmk:133: vboxvideo] Error 2
$ uname -a
Linux localhost.localdomain 5.14.0-162.12.1.el9_1.0.1.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Jan 23 19:25:49 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

$ cat /etc/redhat-release
Rocky Linux release 9.1 (Blue Onyx)
Last edited 15 months ago by Guillermo Jano (previous) (diff)

comment:4 by galitsyn, 15 months ago

Both issues should now be fixed on development branch. Could you please give it a try to Guest Additions from "Development snapshots" on https://www.virtualbox.org/wiki/Testbuilds?

in reply to:  4 comment:5 by Guillermo Jano, 14 months ago

Replying to galitsyn:

Both issues should now be fixed on development branch. Could you please give it a try to Guest Additions from "Development snapshots" on https://www.virtualbox.org/wiki/Testbuilds?

Works for me on Rocky 9.1 with https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_7.0.97-155989.iso

comment:6 by galitsyn, 12 months ago

Resolution: fixed
Status: newclosed

Hi guys,

New VirtualBox versions 6.1.44 and 7.0.8 were just released and available at https://www.virtualbox.org/wiki/Downloads. This issue should be fixed there. Could you please give it a try?

Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use