[Intel-gfx] [PATCH] drm/agp: agp-intel/i915: trim stolen space to 16M

Jesse Barnes jbarnes at virtuousgeek.org
Tue Mar 23 19:34:56 CET 2010


On Tue, 23 Mar 2010 19:22:38 +0100
Lukas Hejtmanek <xhejtman at ics.muni.cz> wrote:

> On Tue, Mar 23, 2010 at 11:17:52AM -0700, Jesse Barnes wrote:
> > On Tue, 23 Mar 2010 19:13:49 +0100
> > Lukas Hejtmanek <xhejtman at ics.muni.cz> wrote:
> > 
> > > Hello,
> > > 
> > > On Tue, Mar 23, 2010 at 10:10:28AM -0700, Jesse Barnes wrote:
> > > > > Jesse, from Yakui's recent finding, the compressed fb size for Cantiga
> > > > > and Ironlake could be as large as 4096x2048 32bpc for 32MB, so some large
> > > > > fb size e.g 1900x1200 could be compressed. So max 16M for stolen may be
> > > > > too small?
> > > > > 
> > > > > I'll send out Yakui's patch later.
> > > > 
> > > > Yeah, if we need to bump the limit, that's fine.  We'd need to adjust
> > > > both the limit I added in AGP and the allocation size we try for in
> > > > i915_dma.c when we set up the compressed buffer.
> > > 
> > > is this somehow related?
> > > 
> > > [103307.780798] [drm:intel_update_fbc], framebuffer too large, disabling
> > > compression
> > > [103307.780800] [drm:intel_update_fbc], unsupported config, disabling FBC
> > > 
> > > I use 1680x1050 and I have i965GM. (I supose 8MB stolen memory.)
> > 
> > There should be a "set up XM of stolen memory" in your log somewhere as
> > well.  If you don't have enough, there's not much we can do.  If you do
> > have enough, but our compressed buffer is too small, that's something
> > we can fix.
> 
> there is:
> 
> agpgart-intel 0000:00:00.0: detected 7676K stolen memory
> [drm] set up 7M of stolen space
> 
> there is no chance to use non-stolen memory and/or adjust the stolen memory?

Not easily.  Stolen memory is supposed to be physically contiguous, so
if there's not enough for a compressed buffer, we'd have to throw away
the whole thing, allocate a new, larger chunk of physically contiguous
memory (which is impossible after a short amount of uptime) and update
the GTT map and the AGP and i915 drivers' view of it.

Sometimes there's a BIOS option to change the size though.

> anyway, FBC used to be enabled without KMS and seemed to work OK.

Yeah, the old UMS code didn't bother to check the size, so FBC might work
ok as long as the compressed bits fit in compressed buffer.  If they didn't,
the compressor would happily walk off the end and corrupt memory.  The KMS
code checks the size though, which is why it's now disabled on your platform.

-- 
Jesse Barnes, Intel Open Source Technology Center



More information about the Intel-gfx mailing list