diff options
author | Jesse Barnes <jbarnes@virtuousgeek.org> | 2010-02-05 15:42:41 -0500 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2010-02-22 11:46:57 -0500 |
commit | b5e50c3f56ee4aa0d0168eab5ece413ac5df76aa (patch) | |
tree | eb6ee1777dc52a00d3981e4a7a208bbe6a136263 /drivers/gpu/drm/i915/i915_dma.c | |
parent | 357b13c3e498bb658f511f91a9e4f09c9553be6e (diff) |
drm/i915: provide FBC status in debugfs
Tools like powertop want to check the current FBC status and report it
to the user. So add a debugfs file indicating whether FBC is enabled,
and if not, why.
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Eric Anholt <eric@anholt.net>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_dma.c')
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 3afe361ec552..47805a41395e 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c | |||
@@ -1249,6 +1249,7 @@ static void i915_setup_compression(struct drm_device *dev, int size) | |||
1249 | /* Leave 1M for line length buffer & misc. */ | 1249 | /* Leave 1M for line length buffer & misc. */ |
1250 | compressed_fb = drm_mm_search_free(&dev_priv->vram, size, 4096, 0); | 1250 | compressed_fb = drm_mm_search_free(&dev_priv->vram, size, 4096, 0); |
1251 | if (!compressed_fb) { | 1251 | if (!compressed_fb) { |
1252 | dev_priv->no_fbc_reason = FBC_STOLEN_TOO_SMALL; | ||
1252 | i915_warn_stolen(dev); | 1253 | i915_warn_stolen(dev); |
1253 | return; | 1254 | return; |
1254 | } | 1255 | } |
@@ -1256,6 +1257,7 @@ static void i915_setup_compression(struct drm_device *dev, int size) | |||
1256 | compressed_fb = drm_mm_get_block(compressed_fb, size, 4096); | 1257 | compressed_fb = drm_mm_get_block(compressed_fb, size, 4096); |
1257 | if (!compressed_fb) { | 1258 | if (!compressed_fb) { |
1258 | i915_warn_stolen(dev); | 1259 | i915_warn_stolen(dev); |
1260 | dev_priv->no_fbc_reason = FBC_STOLEN_TOO_SMALL; | ||
1259 | return; | 1261 | return; |
1260 | } | 1262 | } |
1261 | 1263 | ||