diff options
author | Hong Liu <hong.liu@intel.com> | 2008-05-19 17:06:38 +0800 |
---|---|---|
committer | Jesse Barnes <jbarnes@virtuousgeek.org> | 2008-05-22 10:34:08 -0700 |
commit | e8320a716d97504d91299d20d640b847c86e4b17 (patch) | |
tree | 6386d081752e0bd8c11c0a513187564e83583474 /shared-core/i915_init.c | |
parent | e4f29968f4860008c13635fa0891cb535e672b93 (diff) |
i915: init bo mm at driver init only when modeset=1
To avoid bo memory manager being inited twice, it will be called
at firstopen when modeset is not enabled.
Diffstat (limited to 'shared-core/i915_init.c')
-rw-r--r-- | shared-core/i915_init.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/shared-core/i915_init.c b/shared-core/i915_init.c index 98908a50..f5fe5ba4 100644 --- a/shared-core/i915_init.c +++ b/shared-core/i915_init.c @@ -353,16 +353,17 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) #endif #endif - /* - * Initialize the memory manager for local and AGP space - */ - ret = drm_bo_driver_init(dev); - if (ret) { - DRM_ERROR("fail to init memory manager for local & AGP space\n"); - goto out_rmmap; - } - if (drm_core_check_feature(dev, DRIVER_MODESET)) { + /* + * Initialize the memory manager for local and AGP space + */ + ret = drm_bo_driver_init(dev); + if (ret) { + DRM_ERROR("fail to init memory manager for " + "local & AGP space\n"); + goto out_rmmap; + } + ret = i915_load_modeset_init(dev); if (ret < 0) { DRM_ERROR("failed to init modeset\n"); |