]> code.ossystems Code Review - openembedded-core.git/blob
12362fef5a099312b0bffcee441467fd712dc3af
[openembedded-core.git] /
1 From: Keith Packard <keithp@keithp.com>
2 Date: Wed, 30 Jul 2008 19:28:47 +0000 (-0700)
3 Subject: i915: remove settable use_mi_batchbuffer_start
4 X-Git-Tag: v2.6.12-rc2
5 X-Git-Url: http://gitweb.freedesktop.org/?p=users/anholt/anholt/linux-2.6.git;a=commitdiff;h=6fcd9a69a91c53d733870df20e095eea2b73620c
6
7 i915: remove settable use_mi_batchbuffer_start
8
9 The driver can know what hardware requires MI_BATCH_BUFFER vs
10 MI_BATCH_BUFFER_START; there's no reason to let user mode configure this.
11
12 Signed-off-by: Eric Anholt <eric@anholt.net>
13 ---
14
15 --- a/drivers/gpu/drm/i915/i915_dma.c
16 +++ b/drivers/gpu/drm/i915/i915_dma.c
17 @@ -159,13 +159,6 @@ static int i915_initialize(struct drm_de
18         dev_priv->current_page = 0;
19         dev_priv->sarea_priv->pf_current_page = dev_priv->current_page;
20  
21 -       /* We are using separate values as placeholders for mechanisms for
22 -        * private backbuffer/depthbuffer usage.
23 -        */
24 -       dev_priv->use_mi_batchbuffer_start = 0;
25 -       if (IS_I965G(dev)) /* 965 doesn't support older method */
26 -               dev_priv->use_mi_batchbuffer_start = 1;
27 -
28         /* Allow hardware batchbuffers unless told otherwise.
29          */
30         dev_priv->allow_batchbuffer = 1;
31 @@ -486,7 +479,7 @@ static int i915_dispatch_batchbuffer(str
32                                 return ret;
33                 }
34  
35 -               if (dev_priv->use_mi_batchbuffer_start) {
36 +               if (!IS_I830(dev) && !IS_845G(dev)) {
37                         BEGIN_LP_RING(2);
38                         if (IS_I965G(dev)) {
39                                 OUT_RING(MI_BATCH_BUFFER_START | (2 << 6) | MI_BATCH_NON_SECURE_I965);
40 @@ -697,8 +690,6 @@ static int i915_setparam(struct drm_devi
41  
42         switch (param->param) {
43         case I915_SETPARAM_USE_MI_BATCHBUFFER_START:
44 -               if (!IS_I965G(dev))
45 -                       dev_priv->use_mi_batchbuffer_start = param->value;
46                 break;
47         case I915_SETPARAM_TEX_LRU_LOG_GRANULARITY:
48                 dev_priv->tex_lru_log_granularity = param->value;
49 --- a/drivers/gpu/drm/i915/i915_drv.h
50 +++ b/drivers/gpu/drm/i915/i915_drv.h
51 @@ -99,7 +99,6 @@ typedef struct drm_i915_private {
52         int front_offset;
53         int current_page;
54         int page_flipping;
55 -       int use_mi_batchbuffer_start;
56  
57         wait_queue_head_t irq_queue;
58         atomic_t irq_received;
59