Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED]vbox guest additions fail against 4.17
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Mon Jun 04, 2018 5:00 pm    Post subject: [SOLVED]vbox guest additions fail against 4.17 Reply with quote

Hello!
I installed the 4.17 kernel and I did an emerge @module-rebuild
I got the following errors https://paste.pound-python.org/show/KexmfktOESI6TSEohlQO/
Probably fedeliallalinea could see if there is a patch somewhere.
Thanks in advance


Last edited by pourpier on Fri Jun 22, 2018 9:28 pm; edited 1 time in total
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Mon Jun 04, 2018 5:32 pm    Post subject: Re: vbox guest additions fail against 4.17 Reply with quote

pourpier wrote:
Probably fedeliallalinea could see if there is a patch somewhere.


Feel free to use internet search all by yourself, I just did.

https://www.virtualbox.org/pipermail/vbox-dev/2018-April/015001.html
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Mon Jun 04, 2018 5:49 pm    Post subject: Re: vbox guest additions fail against 4.17 Reply with quote

Jaglover wrote:
pourpier wrote:
Probably fedeliallalinea could see if there is a patch somewhere.


Feel free to use internet search all by yourself, I just did.

https://www.virtualbox.org/pipermail/vbox-dev/2018-April/015001.html


Have you read the patch? It concerns the version 5.2.8 of VirtualBox and I am on 5.2.12. This has already been incorporated in the 5.2.12 if you read the changelogs on the web site of VirtualBox.
But here it concerns the functions ttm_tt_init and ttm_bo_init
So I need the help of fedeliallalinea who knows the issues with VBox quite well. He has helped me many times and I am sure he'll be able to write the sequence of commands to make it work on Gentoo.
Cheers
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30894
Location: here

PostPosted: Mon Jun 04, 2018 6:40 pm    Post subject: Re: vbox guest additions fail against 4.17 Reply with quote

pourpier wrote:
Have you read the patch? It concerns the version 5.2.8 of VirtualBox and I am on 5.2.12. This has already been incorporated in the 5.2.12 if you read the changelogs on the web site of VirtualBox.
But here it concerns the functions ttm_tt_init and ttm_bo_init

I don't think it's a attitude to have with those who want to help you

pourpier wrote:
So I need the help of fedeliallalinea who knows the issues with VBox quite well.

No simple I seach if there is a open bug in virtualbox [urlhttps://www.virtualbox.org/wiki/Bugtracker]bug tracker[/url]....

pourpier wrote:
He has helped me many times and I am sure he'll be able to write the sequence of commands to make it work on Gentoo.

... but unfortunately in this case does not exists, the problem is the changed api on ttm_tt_init function but I don't kwon how resolve issue.
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Mon Jun 04, 2018 7:07 pm    Post subject: Re: vbox guest additions fail against 4.17 Reply with quote

[quote="fedeliallalinea"]
pourpier wrote:
Have you read the patch? It concerns the version 5.2.8 of VirtualBox and I am on 5.2.12. This has already been incorporated in the 5.2.12 if you read the changelogs on the web site of VirtualBox.
But here it concerns the functions ttm_tt_init and ttm_bo_init

I don't think it's a attitude to have with those who want to help you

If I have offended Jaglover I offer my apologies. I didn't mean to be harsh to him. I should develop assertiveness.
I had already checked your previous patch for the kernel 4.16 but I saw that the functions giving the errors were not the same. I can wait a little as I still have the 4.16.13 kernel. Either 5.2.14 will fix the issue or hopefully you'll be able to find a patch on Fedora or OpenSUSE.
Thanks for your quick reply.
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30894
Location: here

PostPosted: Mon Jun 04, 2018 7:30 pm    Post subject: Reply with quote

And you tried kernel module instead of app-emulation/virtualbox-guest-additions?
Code:
Device Drivers  --->
    [*] Virtualization drivers  --->
        <M>   Virtual Box Guest integration support

Device Drivers  --->
    [*] Staging drivers  --->
        <M>   Virtual Box Graphics Card

_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Mon Jun 04, 2018 7:42 pm    Post subject: Reply with quote

fedeliallalinea wrote:
And you tried kernel module instead of app-emulation/virtualbox-guest-additions?
Code:
Device Drivers  --->
    [*] Virtualization drivers  --->
        <M>   Virtual Box Guest integration support

Device Drivers  --->
    [*] Staging drivers  --->
        <M>   Virtual Box Graphics Card


I did it already with the kernel 4.16 but unfortunately the support for the guest additions in the kernel is quite limited as this didn't do anything the last time but I'll try it on another VM to see if it changes anything.
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Tue Jun 05, 2018 4:58 am    Post subject: Reply with quote

fedeliallalinea wrote:
And you tried kernel module instead of app-emulation/virtualbox-guest-additions?
Code:
Device Drivers  --->
    [*] Virtualization drivers  --->
        <M>   Virtual Box Guest integration support

Device Drivers  --->
    [*] Staging drivers  --->
        <M>   Virtual Box Graphics Card


I tried this in a VM with Xfce. The situation is worse. I can launch applications but once the window is open I can't minimize, maximize or close the window and I was unable to shut the VM down within the guest. I was forced to shut the machine down through one of the options of the menu of VirtualBox.
Do you think I need to file a bug to VirtualBox?
Best regards
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30894
Location: here

PostPosted: Tue Jun 05, 2018 6:12 am    Post subject: Reply with quote

pourpier wrote:
Do you think I need to file a bug to VirtualBox?

You have better chance to have a response
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Tue Jun 05, 2018 9:01 am    Post subject: Reply with quote

fedeliallalinea wrote:
pourpier wrote:
Do you think I need to file a bug to VirtualBox?

You have better chance to have a response


I did it and it is the ticket 17801 on the Bugtracker of VirtualBox.
Best regards
Back to top
View user's profile Send private message
yzg
Guru
Guru


Joined: 18 Jun 2005
Posts: 493

PostPosted: Tue Jun 05, 2018 9:26 am    Post subject: Reply with quote

bug report https://bugs.gentoo.org/657380
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Fri Jun 22, 2018 11:17 am    Post subject: Reply with quote

fedeliallalinea wrote:
pourpier wrote:
Do you think I need to file a bug to VirtualBox?

You have better chance to have a response


Do you think you can do something with this? https://www.virtualbox.org/changeset/72641/vbox
Cheers.
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30894
Location: here

PostPosted: Fri Jun 22, 2018 12:16 pm    Post subject: Reply with quote

I created the patch for virtualbox-guest-additions-5.2.12 but you should, as usual, manually patch
Code:
# ebuild /usr/portage/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.2.12.ebuild clean prepare
# cd /var/tmp/portage/app-emulation/virtualbox-guest-additions-5.2.12/work
# patch -p1 < /path/to/patch/virtualbox-guest-addition-kernel-4.17.patch
# ebuild /usr/portage/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.2.12.ebuild clean prepare
# ebuild /usr/portage/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.2.12.ebuild merge

_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Cuong Nguyen
Apprentice
Apprentice


Joined: 18 Jan 2018
Posts: 152

PostPosted: Fri Jun 22, 2018 5:00 pm    Post subject: Reply with quote

fedeliallalinea wrote:
I created the patch for virtualbox-guest-additions-5.2.12 but you should, as usual, manually patch


Thanks for the patch, but there is a misplaced line, I've corrected and successfully emerge after apply a manual patch.
Your patch:
Code:
@@ -394,9 +403,13 @@
        acc_size = ttm_bo_dma_acc_size(&vbox->ttm.bdev, size,
                                       sizeof(struct vbox_bo));

+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 17, 0)
        ret = ttm_bo_init(&vbox->ttm.bdev, &vboxbo->bo, size,
                          ttm_bo_type_device, &vboxbo->placement,
                          align >> PAGE_SHIFT, false, NULL, acc_size,
+#else
+                          align >> PAGE_SHIFT, false, acc_size,
+#endif
 #if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 18, 0) || defined(RHEL_73)
                          NULL,
 #endif


Corrected:
Code:
@@ -396,7 +405,11 @@

        ret = ttm_bo_init(&vbox->ttm.bdev, &vboxbo->bo, size,
                          ttm_bo_type_device, &vboxbo->placement,
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 17, 0)
                          align >> PAGE_SHIFT, false, NULL, acc_size,
+#else
+                          align >> PAGE_SHIFT, false, acc_size,
+#endif
 #if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 18, 0) || defined(RHEL_73)
                          NULL,
 #endif
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30894
Location: here

PostPosted: Fri Jun 22, 2018 5:27 pm    Post subject: Reply with quote

Ops sorry.
Cuong Nguyen thank you, I have corrected also on my github.
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Fri Jun 22, 2018 8:55 pm    Post subject: Reply with quote

fedeliallalinea wrote:
Ops sorry.
Cuong Nguyen thank you, I have corrected also on my github.


When I apply the sequence of commands I get for the first command this message:
Code:
shell-init : erreur de détermination du répertoire actuel : getcwd : ne peut accéder aux répertoires parents : Aucun fichier ou dossier de ce type

But the source is prepared.
When I execute the command patch -p1 < /path/to/the/patch I get:
Code:
can't find file to patch at input line 4
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff -Naru vboxvideo.orig/vbox_ttm.c vboxvideo/vbox_ttm.c
|--- a/vboxvideo.orig/vbox_ttm.c   2018-06-22 13:56:45.070112812 +0200
|+++ b/vboxvideo/vbox_ttm.c   2018-06-22 14:00:56.320114099 +0200
--------------------------
File to patch:

I tried to clean it several times but I always get the same message.
What should I need to do?

[Moderator edit: added [code] tags to preserve output layout. -Hu]
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Fri Jun 22, 2018 9:07 pm    Post subject: Reply with quote

fedeliallalinea wrote:
Ops sorry.
Cuong Nguyen thank you, I have corrected also on my github.


I found a workaround. I did emerge @module-rebuild which failed then I cd /var/tmp/portage/app-emulation/virtualbox-guest-additions-5.2.12/work followed by patch -p1 < /path/to/patch followed by ebuild /usr/portage/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.2.12.ebuild install qmerge and this succeeded.
Thanks a lot for your help to both of you.
Best regards,
pourpier
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Fri Jun 22, 2018 9:13 pm    Post subject: Reply with quote

fedeliallalinea wrote:
Ops sorry.
Cuong Nguyen thank you, I have corrected also on my github.


The virtualbox-guest-additions compiled correctly but there is another problem now. I can open each application but then I can't use the mouse to click. I can't minimize, maximize and exit.
I lose the focus.

I found a workaround. I created a file blacklist.conf under /etc/modprobe.d/ and I put this line in it:
blacklist vboxguest
Cheers
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21607

PostPosted: Sat Jun 23, 2018 12:26 am    Post subject: Reply with quote

pourpier wrote:
When I apply the sequence of commands I get for the first command this message:
Code:
shell-init : erreur de détermination du répertoire actuel : getcwd : ne peut accéder aux répertoires parents : Aucun fichier ou dossier de ce type
When you need help with errors, please run the failed command under LC_MESSAGES=C so that untranslated output is produced. Based on the general structure, I think this is telling you that you are in a directory that does not exist. That will almost certainly lead to other problems.
pourpier wrote:
But the source is prepared.
After that failure, what is the output if you run pwd ; ls -la ; ls -la $(pwd)?
Back to top
View user's profile Send private message
Cuong Nguyen
Apprentice
Apprentice


Joined: 18 Jan 2018
Posts: 152

PostPosted: Sat Jun 23, 2018 1:51 am    Post subject: Reply with quote

pourpier wrote:

The virtualbox-guest-additions compiled correctly but there is another problem now. I can open each application but then I can't use the mouse to click. I can't minimize, maximize and exit.
I lose the focus.

It hit me too, I even didn't notice, because I mostly run VirtualBox Gentoo in console mode.

Now as Kernel includes vboxvideo modules, do you think to break virtualbox-guest-additions into several sub pkgs like virtualbox-guest-modules, virtualbox-guest-utils and somehow splitting as per kernel versions. If I run several kernel versions, I have builtd virtualbox-guest for every version.
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Sat Jun 23, 2018 5:46 am    Post subject: Reply with quote

Hu wrote:
When you need help with errors, please run the failed command under LC_MESSAGES=C so that untranslated output is produced. Based on the general structure, I think this is telling you that you are in a directory that does not exist. That will almost certainly lead to other problems. After that failure, what is the output if you run pwd ; ls -la ; ls -la $(pwd)?

You are right. As the sequence of commands implied that I had to change directory into /var/tmp/portage/app-emulation/virtualbox-guest-additions-5.2.12/work When it failed I was there and I started again from that directory.
What I don't understand is why is the output in French for the clean prepare command and in English for the output of the patch -p1 command!
Best regards.
Back to top
View user's profile Send private message
pourpier
Apprentice
Apprentice


Joined: 27 Sep 2017
Posts: 166

PostPosted: Sat Jun 23, 2018 5:50 am    Post subject: Reply with quote

Cuong Nguyen wrote:

It hit me too, I even didn't notice, because I mostly run VirtualBox Gentoo in console mode.

Now as Kernel includes vboxvideo modules, do you think to break virtualbox-guest-additions into several sub pkgs like virtualbox-guest-modules, virtualbox-guest-utils and somehow splitting as per kernel versions. If I run several kernel versions, I have builtd virtualbox-guest for every version.


I am too new in Gentoo to be able to answer your question. Perhaps fedeliallalinea or Hu might help you.
Best regards.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21607

PostPosted: Sat Jun 23, 2018 3:49 pm    Post subject: Reply with quote

From looking at the source of =sys-devel/patch-2.7.6-r1, it does not appear to support localization. Therefore, that error message will always be in English.
Back to top
View user's profile Send private message
Cuong Nguyen
Apprentice
Apprentice


Joined: 18 Jan 2018
Posts: 152

PostPosted: Wed Jul 04, 2018 4:26 am    Post subject: [Solved] virtualbox-guest-additions-5.2.14 kernel-4.17.4 Reply with quote

Compiled without any extra patches.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum