linux-mips-fnet
[Top] [All Lists]

Re: mmap() frame buffer causes bus error on MIPS ...

To: Jun Sun <jsun@mvista.com>, linux-fbdev@vuser.vu.union.edu, linux-mips@oss.sgi.com, linux-mips@fnet.fr
Subject: Re: mmap() frame buffer causes bus error on MIPS ...
From: Ralf Baechle <ralf@oss.sgi.com>
Date: Thu, 7 Sep 2000 11:58:49 +0200
In-reply-to: <20000907112013.A6259@bacchus.dhis.org>; from ralf@oss.sgi.com on Thu, Sep 07, 2000 at 11:20:13AM +0200
References: <39B5BD14.A8D2F467@mvista.com> <39B5DABB.7FB85B09@mvista.com> <39B6B75D.2501654E@mvista.com> <20000907112013.A6259@bacchus.dhis.org>
On Thu, Sep 07, 2000 at 11:20:13AM +0200, Ralf Baechle wrote:

> The definition should be:
> 
> extern inline pte_t mk_pte_phys(unsigned long physpage, pgprot_t pgprot)
> {
>       return __pte(physpage) | pgprot_val(pgprot);
> }
> 
> Masking with PAGE_MASK also seemed to be useless.
> 
> It's really surprising why it never has been caught.  Probably people
> feed it with the addresses that are tweaked such that sich just work.
> 
> I'll cook up a patch for this bug.

This one has a interesting history in CVS:

revision 1.21
date: 1999/07/26 19:42:43;  author: harald;  state: Exp;  lines: +84 -82
The remaining R3000 changes. From now on the CVS will be R3000 aware. R3000
Indigo anyone? :-)

which re-establishes a bug which was fixed by:

revision 1.16
date: 1998/08/28 23:24:03;  author: tsbogend;  state: Exp;  lines: +2 -2
fixed MAP_NR() second try:-(

which I introduced in:

revision 1.15
date: 1998/08/25 09:21:59;  author: ralf;  state: Exp;  lines: +148 -70
 o Merge with Linux 2.1.116.
 o New Newport console code.
 o New G364 console code.

which got fixed by:

revision 1.13
date: 1998/07/13 23:28:18;  author: tsbogend;  state: Exp;  lines: +1 -1
fixed physical mapping

So the original bug is probably as old as the MIPS port itself ...

Ouch.

  Ralf

<Prev in Thread] Current Thread [Next in Thread>