MTRRs not working in 2.6 linux kernels?

Jonathan Thambidurai jonthambi at comcast.net
Mon Oct 4 07:49:22 PDT 2004


On Mon, 4 Oct 2004 12:07:01 +0200
Felix Kühling <fxkuehl at gmx.de> wrote:

> On Sun, 3 Oct 2004 22:33:28 -0400
> Jonathan Thambidurai <jonthambi at comcast.net> wrote:
> 
> > When I try to use the application tvtime under Xorg 6.8.1 with Linux
> > kernel 2.6.7, I get very choppy framerates; tvtime indicates that it is
> > only getting about 50 MB/s for blitting to the screen.  With the same
> > version of Xorg and Linux kernel 2.4.22, I get smooth play, and tvtime
> > indicates that it gets about 150 MB/s for blitting to screen.  I made
> > sure DRI wasn't playing a role in this by rmmod'ing the agpgart module
> > before starting X.  
> > 
> > Of note is the difference in /proc/mtrr between 2.6 and 2.4
> > kernels:
> > 
> > in 2.4, it contains only
> > 
> > reg00: base=0x00000000 (   0MB), size= 256MB: write-back, count=1
> > reg01: base=0x0ff80000 ( 255MB), size= 512KB: uncachable, count=1
> > 
> > while in 2.6 it contains
> > 
> > reg00: base=0x00000000 (   0MB), size= 256MB: write-back, count=1
> > reg01: base=0x0ff80000 ( 255MB), size= 512KB: uncachable, count=1
> > reg02: base=0xe8000000 (3712MB), size=   2MB: write-combining, count=1
> > 
> > Lastly, in the X.org log when running a 2.6 kernel the following line is
> > displayed:
> > 
> > (WW) RADEON(0): Failed to set up write-combining range (0xe8000000,0x1000000)
> > 
> > while under 2.4 the following line is displayed:
> > 
> > (==) RADEON(0): Write-combining range (0xe8000000,0x1000000)
> 
> This fails because someone else set up write combining for the same
> start address but only 2MB long. Usually that would be a kernel frame
> buffer driver that doesn't detect the correct frame buffer size
> (vesafb?). I think there an option "nomtrr" you can pass to the
> radeonfb/vesafb driver.
> 
> HTH,
>   Felix

I found that doing 

echo "disable=2" > /proc/mtrr 

disables the conflicting range and allows xorg to set it up correctly.

Thanks for the reply,
Jonathan Thambidurai

> 
> > 
> > I am running a P4 at 1.8 Ghz Laptop with an AGP 4x Radeon 7500 and 16 MB
> > of VRAM; it has 256 MB of system memory, which makes the third line of 
> > /proc/mtrr in the 2.6 kernels look wrong to my untrained eyes.
> > 
> > I just tried this on kernel 2.6.9-rc2 with the same results
> > as 2.6.7 and saw that dmesg complained about some mtrr overlapping with 
> > something else; if this is important, I can report the exact message.
> > 
> > Perhaps this is a kernel issue and should be posted to the kernel list? 
> > Any help would be appreciated.
> > 
> > --Jonathan Thambidurai
> 
> | Felix Kühling <fxkuehl at gmx.de>                     http://fxk.de.vu |
> | PGP Fingerprint: 6A3C 9566 5B30 DDED 73C3  B152 151C 5CC1 D888 E595 |



More information about the xorg mailing list