aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/radeon_fb.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_fb.c')
-rw-r--r--drivers/gpu/drm/radeon/radeon_fb.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_fb.c b/drivers/gpu/drm/radeon/radeon_fb.c
index d71e346e9ab5..cda112cc7a6c 100644
--- a/drivers/gpu/drm/radeon/radeon_fb.c
+++ b/drivers/gpu/drm/radeon/radeon_fb.c
@@ -148,7 +148,6 @@ int radeonfb_create(struct drm_device *dev,
148 unsigned long tmp; 148 unsigned long tmp;
149 bool fb_tiled = false; /* useful for testing */ 149 bool fb_tiled = false; /* useful for testing */
150 u32 tiling_flags = 0; 150 u32 tiling_flags = 0;
151 int crtc_count;
152 151
153 mode_cmd.width = surface_width; 152 mode_cmd.width = surface_width;
154 mode_cmd.height = surface_height; 153 mode_cmd.height = surface_height;
@@ -239,11 +238,7 @@ int radeonfb_create(struct drm_device *dev,
239 rfbdev = info->par; 238 rfbdev = info->par;
240 rfbdev->helper.funcs = &radeon_fb_helper_funcs; 239 rfbdev->helper.funcs = &radeon_fb_helper_funcs;
241 rfbdev->helper.dev = dev; 240 rfbdev->helper.dev = dev;
242 if (rdev->flags & RADEON_SINGLE_CRTC) 241 ret = drm_fb_helper_init_crtc_count(&rfbdev->helper, rdev->num_crtc,
243 crtc_count = 1;
244 else
245 crtc_count = 2;
246 ret = drm_fb_helper_init_crtc_count(&rfbdev->helper, crtc_count,
247 RADEONFB_CONN_LIMIT); 242 RADEONFB_CONN_LIMIT);
248 if (ret) 243 if (ret)
249 goto out_unref; 244 goto out_unref;
@@ -257,7 +252,7 @@ int radeonfb_create(struct drm_device *dev,
257 info->flags = FBINFO_DEFAULT; 252 info->flags = FBINFO_DEFAULT;
258 info->fbops = &radeonfb_ops; 253 info->fbops = &radeonfb_ops;
259 254
260 tmp = fb_gpuaddr - rdev->mc.vram_location; 255 tmp = fb_gpuaddr - rdev->mc.vram_start;
261 info->fix.smem_start = rdev->mc.aper_base + tmp; 256 info->fix.smem_start = rdev->mc.aper_base + tmp;
262 info->fix.smem_len = size; 257 info->fix.smem_len = size;
263 info->screen_base = fbptr; 258 info->screen_base = fbptr;