All of lore.kernel.org
 help / color / mirror / Atom feed
From: Valdis.Kletnieks@vt.edu
To: Steven Rostedt <rostedt@goodmis.org>
Cc: Ingo Molnar <mingo@elte.hu>, LKML <linux-kernel@vger.kernel.org>
Subject: Re: 2.6.10-rc3-mm1-V0.7.33-03 and NVidia wierdness, with workaround...
Date: Fri, 17 Dec 2004 13:10:26 -0500	[thread overview]
Message-ID: <200412171810.iBHIAQP3026387@turing-police.cc.vt.edu> (raw)
In-Reply-To: Your message of "Fri, 17 Dec 2004 12:03:31 EST." <1103303011.12664.58.camel@localhost.localdomain>


[-- Attachment #1.1: Type: text/plain, Size: 1852 bytes --]

On Fri, 17 Dec 2004 12:03:31 EST, Steven Rostedt said:

> Update: I just tried some of my fixes to the rc3-mm1 kernel, and that
> worked without a problem.  But I still didn't get by the sleep problem
> in Ingo's RT patch.  Did you get further, and did you make fixes to both
> the nvidia module as well as the kernel?

I have to admit I haven't *hit* a sleep problem specific to Ingo's code, unless
you have a different config/hardware and my BKL wierdness and your sleep are
2 different manifestations of the same problem.  Or maybe they're 2 different
bugs... ;)

I'm running Ingo's patch and the nvidia 6629 drivers as I'm typing this. Given
you had to fool with pgd_offset_k and friends, you're probably trying an older
driver (6111?) and should upgrade - the 6629 picked up a *bunch* of 2.6-related
fixes.  Maybe 6629 fixed your sleep issue?

I needed to make 1 small patch to the nvidia code to support the 4-level
page table code in -mm, and one small kernel patch from Zander at NVidia to work
around another issue.  Both attached.  You apparently already have the GPL-export
fix.  If you're not running Ingo's patch, you'll need the non-NVidia-related
patch to fix the ioctl-cleanup.patch breakage (Ingo rolled that one into -RT),
but if you got it to come up at all in -rc3-mm1, you have that one too (but those
of you playing along at home will need it)...

Modulo those patches, the only thing I've hit since 2.6.10-rc1-mm1 or so is
this BKL strangeness, and that only bites me in -RT with one configuration...

YMMV, binary modules are evil, Works For Me with 6629 on my Dell laptop, and
all that. If this isn't enough to get it working for you, your best bet is
probably to wander over to

http://www.nvnews.net/vbulletin/forumdisplay.php?s=&forumid=14

and see if Zander has new words of wisdom (that's where I found the VM-IO patch).


[-- Attachment #1.2: VM_IO.diff --]
[-- Type: text/plain , Size: 479 bytes --]

--- linux-2.6.10-rc2-mm2/mm/mmap.c.nvidia	2004-11-18 22:10:39.259326934 -0500
+++ linux-2.6.10-rc2-mm2/mm/mmap.c	2004-11-18 22:22:46.877972513 -0500
@@ -1026,7 +1026,8 @@ out:	
 	__vm_stat_account(mm, vm_flags, file, len >> PAGE_SHIFT);
 	if (vm_flags & VM_LOCKED) {
 		mm->locked_vm += len >> PAGE_SHIFT;
-		make_pages_present(addr, addr + len);
+		if (!(vm_flags & VM_IO))
+			make_pages_present(addr, addr + len);
 	}
 	if (flags & MAP_POPULATE) {
 		up_write(&mm->mmap_sem);

[-- Attachment #1.3: nv.diff --]
[-- Type: text/plain , Size: 1033 bytes --]

diff -upr NVIDIA-Linux-x86-1.0-6629-pkg1/usr/src/nv/nv.c ../src/NVIDIA-Linux-x86-1.0-6629-pkg1/usr/src/nv/nv.c
--- NVIDIA-Linux-x86-1.0-6629-pkg1/usr/src/nv/nv.c	2004-11-03 16:53:00.000000000 -0500
+++ ../src/NVIDIA-Linux-x86-1.0-6629-pkg1/usr/src/nv/nv.c	2004-11-10 16:18:29.000000000 -0500
@@ -2492,6 +2492,7 @@ _get_phys_address(
 )
 {
     struct mm_struct *mm;
+    pml4_t *pg_l4_dir;
     pgd_t *pg_dir;
     pmd_t *pg_mid_dir;
     pte_t *pte;
@@ -2500,10 +2501,15 @@ _get_phys_address(
     mm = (kern) ? &init_mm : current->mm;
     spin_lock(&mm->page_table_lock);
 
-    if (kern) pg_dir = pgd_offset_k(address);
-    else pg_dir = pgd_offset(mm, address);
+    if (kern) pg_l4_dir = pml4_offset_k(address);
+    else pg_l4_dir = pml4_offset(mm, address);
 
-    if (!pg_dir || pgd_none(*pg_dir))
+    if (!pg_l4_dir || pml4_none(*pg_l4_dir))
+        goto failed;
+
+    pg_dir = pml4_pgd_offset_k(pg_l4_dir,address);
+
+    if (pgd_none(*pg_dir))
         goto failed;
 
     NV_PMD_OFFSET(address, pg_dir, pg_mid_dir);

[-- Attachment #2: Type: application/pgp-signature, Size: 226 bytes --]

  reply	other threads:[~2004-12-17 18:14 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-16 16:26 2.6.10-rc3-mm1-V0.7.33-03 and NVidia wierdness, with workaround Valdis.Kletnieks
2004-12-17 16:19 ` Steven Rostedt
2004-12-17 17:03   ` Steven Rostedt
2004-12-17 18:10     ` Valdis.Kletnieks [this message]
2004-12-17 20:04       ` Steven Rostedt
2004-12-17 21:49         ` Valdis.Kletnieks
2004-12-17 21:55           ` Steven Rostedt
2004-12-17 21:52         ` Steven Rostedt
2004-12-17 22:42           ` Valdis.Kletnieks
2004-12-19 16:20             ` Steven Rostedt
2004-12-20  2:46               ` Joe
2004-12-20  4:22                 ` Steven Rostedt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200412171810.iBHIAQP3026387@turing-police.cc.vt.edu \
    --to=valdis.kletnieks@vt.edu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=rostedt@goodmis.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.