Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 241794 - nvidia-drivers - wrong PARAVIRT check on gentoo-sources-2.6.27
Summary: nvidia-drivers - wrong PARAVIRT check on gentoo-sources-2.6.27
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Ricardo Mendoza (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-13 16:30 UTC by Olav K. Smørholm
Modified: 2009-08-03 03:29 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch to ebuild to check for PARAVIRT_GUEST (nvidia-paravirt-check.patch,822 bytes, patch)
2008-10-13 16:40 UTC, Calvin Walton
Details | Diff
nvidia-drivers 177.82 custom ebuild remove paravirt check (mutant-nvidia-drivers-177.82.ebuild,18.88 KB, text/plain)
2008-12-17 08:21 UTC, Tom Goren
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Olav K. Smørholm 2008-10-13 16:30:30 UTC
# CONFIG_PARAVIRT_GUEST is not set
CONFIG_PARAVIRT=y

The former option enables the latter, no way to have CONFIG_PARAVIRT=n
Manually editing kernel config to change, results in make changeing it back.

Reproducible: Always

Steps to Reproduce:
1. gentoo-sources-2.6.27 ~amd64
2. nvidia-drivers
3.

Actual Results:  
ERROR: setup
Please disable PARAVIRT in your kernel config, found at:

  Processor type and features
    [*] Paravirtualized guest support

or XEN support

and recompile your kernel ..

ERROR: x11-drivers/nvidia-drivers-177.80 failed.
Call stack:
                     ebuild.sh, line   49:  Called pkg_setup
  nvidia-drivers-177.80.ebuild, line  151:  Called paravirt_check
  nvidia-drivers-177.80.ebuild, line  131:  Called die
The specific snippet of code:
                die "PARAVIRT support detected!"
 The die message:
  PARAVIRT support detected!


Expected Results:  
emerge fails
Comment 1 Calvin Walton 2008-10-13 16:40:36 UTC
Created attachment 168306 [details, diff]
Patch to ebuild to check for PARAVIRT_GUEST

I've attached a patch to the ebuild with some minimal changes that should allow this to work.
These changes should be safe to kernels back to 2.6.25, at least.
Comment 2 Patrizio Bassi 2008-10-13 16:57:47 UTC
actually there was an old bug in bugzilla, now the check should be totally useless and should just be removed.
Comment 3 Miguel A. Liebana 2008-10-23 17:06:38 UTC
gentoo-sources-2.6.27-r1 include a patch that solves the problem (I think it's part of the linux patches included inside 2.6.27.3). With this version of the sources, the nvidia-drivers can be installed with CONFIG_PARAVIRT=y
Comment 4 Tom Goren 2008-12-17 08:14:20 UTC
running 2008.0 ~x86 with kernel 2.6.27-r6 - happened to me too with nvidia-drivers 177.82

i solved it by commenting out the paravirt_check() function in the ebuild:

1. vi /usr/portage/x11-drivers/nvidia-drivers/nvidia-drivers-177.82.ebuild

     (comment out the function and the call to the function in 'if use kernel_linux; then' (the row named paravirt_check))

2. save the file

3. run ebuild /usr/portage/x11-drivers/nvidia-drivers/nvidia-drivers-177.82.ebuild manifest (otherwise you will get filesize error / checksum when trying to emerge the package).

4. emerge - pbbly some errors and red stars, but it worked fine for me!

5. the other alternative is getting the package from nvidia and running it, however that has it's own set of problems.

i will attach my ebuild for reference.
Comment 5 Tom Goren 2008-12-17 08:21:40 UTC
Created attachment 175576 [details]
nvidia-drivers 177.82 custom ebuild remove paravirt check

probably good idea to save the original ebiuld, rename this one to the REAL name (pbbly /usr/portage/x11-drivers/nvidia-drivers/nvidia-drivers-177.82.ebuild) and then run ebuild /usr/portage/x11-drivers/nvidia-drivers/nvidia-drivers-177.82.ebuild manifest - which will make it 'legitimate' in portage's eyes)
Comment 6 Doug Goldstein (RETIRED) gentoo-dev 2008-12-18 20:14:30 UTC
So basically what you guys are saying is that with kernel 2.6.27 and newer, NVIDIA drivers will work unpatched when PARAVIRT and PARAVIRT_GUEST is on?
Comment 7 Olav K. Smørholm 2008-12-18 20:32:01 UTC
Both paravirt options needs to be enabled for it to be enabled in the kernel as i understand it.
the second option which is checked for is on by default but commented out.

I just edit /usr/src/linux/.config as a temporary fix and change it and save.

# CONFIG_PARAVIRT_GUEST is not set
CONFIG_PARAVIRT=y
# CONFIG_PARAVIRT_DEBUG is not set

On my system, there doesnt seem to be a way to config the kernel in any way so that:
CONFIG_PARAVIRT=n
Comment 8 Olav K. Smørholm 2008-12-18 20:33:59 UTC
(In reply to comment #7)
> On my system, there doesnt seem to be a way to config the kernel in any way so
> that:
> CONFIG_PARAVIRT=n

Oh, and changing the value to 'n' fixes the problem.
It compiles and works here at least.
Comment 9 Patrizio Bassi 2008-12-19 18:39:03 UTC
i think the check should just be removed. this was an old problem in my understand it's ok.

i'm running since 2 years and never hit a single problem.
Comment 10 Jonas Bernoulli 2008-12-28 03:31:16 UTC
(In reply to comment #9)

Unfortunately this doesn't seem to be the case. After enabling paravirt and emerging nvidia-drivers with the paravirt check removed starting X fails for me.

The classical "can not open display" error. As a side-note: enabling paravirt also caused (built-in) alsa to fail.

Comment 11 Lars 2009-04-04 11:08:28 UTC
i removed the check from the ebuild
in the pkg_setup() function:
#               paravirt_check
and everything works fine for me

Linux deepthought 2.6.27-gentoo-r4de #7 SMP Thu Apr 2 20:58:53 CEST 2009 x86_64 AMD Turion(tm) 64 X2 Mobile Technology TL-64 AuthenticAMD GNU/Linux

x11-drivers/nvidia-drivers-180.29

my alsa also works just fine. i would say: degrade it to a warning.
Comment 12 Doug Goldstein (RETIRED) gentoo-dev 2009-08-03 03:29:48 UTC
Fixed in tree.