I am using the latest kernel on a Dell LAtitude E4310 with 8Gbyte RAM

2.6.38-10-generic #44-Ubuntu SMP Thu Jun 2 21:32:22 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux

At boot I get the following message

[drm] MTRR allocation failed.  Graphics performance may suffer.

and indeed my /proc/mtrr looks strange

reg00: base=0x000000000 (    0MB), size= 8192MB, count=1: write-back
reg01: base=0x200000000 ( 8192MB), size=  512MB, count=1: write-back
reg02: base=0x0e0000000 ( 3584MB), size=  512MB, count=1: uncachable
reg03: base=0x0dc000000 ( 3520MB), size=   64MB, count=1: uncachable
reg04: base=0x0db400000 ( 3508MB), size=    4MB, count=1: uncachable
reg05: base=0x21c000000 ( 8640MB), size=   64MB, count=1: uncachable

I tried mtrr-uncover but it does not work:

Initial MTRR configuration:
 0  0x000000000-0x1ffffffff write-back
         4  0x0db400000-0x0db7fffff uncachable
         3  0x0dc000000-0x0dfffffff uncachable
         2  0x0e0000000-0x0ffffffff uncachable
 1  0x200000000-0x21fffffff write-back
         5  0x21c000000-0x21fffffff uncachable
./mtrr-uncover: 9 MTRRs needed but only 8 in architecture.

Does anybody know how to properly set the mtrr in my architecture?

here the relevant output of lspci -v

00:02.0 VGA compatible controller: Intel Corporation Core Processor Integrated Graphics Controller (rev 02) (prog-if 00 [VGA controller])
    Subsystem: Dell Device 0410
    Flags: bus master, fast devsel, latency 0, IRQ 42
    Memory at f0000000 (64-bit, non-prefetchable) [size=4M]
    Memory at e0000000 (64-bit, prefetchable) [size=256M]
    I/O ports at 60b0 [size=8]
    Expansion ROM at <unassigned> [disabled]
    Capabilities: <access denied>
    Kernel driver in use: i915
    Kernel modules: i915
  • I believe that the mtrr over e0000000 is the AGP gart, therefore you already have an mtrr over the region drm is trying to change. I suspect if you remove and replace that with a WC it may work. The rules for overlapping them are very complex and prone to error though.
    – Andy
    Jul 26 '11 at 7:37

There is a simple solution for this. Just use kernel boot parameter enable_mtrr_cleanup.

Edit /etc/default/grub config file:

$ sudo nano /etc/default/grub

find a line containing GRUB_CMDLINE_LINUX_DEFAULT and you'll probably see these default params:


So to use enable_mtrr_cleanup you'll add it like this:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash enable_mtrr_cleanup"

Then you must update your grub configuration with this command:

$ sudo update-grub2

And reboot:

$ sudo reboot

Then the message will dissappear and you'll see the system has found proper values for MTRR.

  • didn't work for me on debian wheezy Mar 18 '15 at 10:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.