Re: 2.5.74-mm2 + nvidia (and others)

From: Christian Axelsson (smiler@lanil.mine.nu)
Date: Tue Jul 08 2003 - 06:40:35 EST


On Tue, 2003-07-08 at 09:03, Martin Schlemmer wrote:
> On Mon, 2003-07-07 at 21:30, Andrew Morton wrote:
>
> > Well that will explode if someone enables highpmd and has highmem.
> > This would be better:
> >
> > --- nv.c.orig 2003-07-05 22:55:10.000000000 -0700
> > +++ nv.c 2003-07-05 22:55:58.000000000 -0700
> > @@ -2105,11 +2105,14 @@
> > if (pgd_none(*pg_dir))
> > goto failed;
> >
> > - pg_mid_dir = pmd_offset(pg_dir, address);
> > - if (pmd_none(*pg_mid_dir))
> > + pg_mid_dir = pmd_offset_map(pg_dir, address);
> > + if (pmd_none(*pg_mid_dir)) {
> > + pmd_unmap(pg_mid_dir);
> > goto failed;
> > + }
> >
> > NV_PTE_OFFSET(address, pg_mid_dir, pte);
> > + pmd_unmap(pg_mid_dir);
> >
> > if (!pte_present(pte))
> > goto failed;
> >
> > -
>
> Bit too specific to -mm2, what about the the attached?

Compiles nicely, havent but I havent reloaded it yet.

-- 
Christian Axelsson
smiler@lanil.mine.nu


- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Tue Jul 15 2003 - 22:00:27 EST