diff options
Diffstat (limited to 'drivers/video/efifb.c')
-rw-r--r-- | drivers/video/efifb.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/drivers/video/efifb.c b/drivers/video/efifb.c index 581d2dbf675a..3b986567111a 100644 --- a/drivers/video/efifb.c +++ b/drivers/video/efifb.c | |||
@@ -165,7 +165,7 @@ static void efifb_destroy(struct fb_info *info) | |||
165 | { | 165 | { |
166 | if (info->screen_base) | 166 | if (info->screen_base) |
167 | iounmap(info->screen_base); | 167 | iounmap(info->screen_base); |
168 | release_mem_region(info->aperture_base, info->aperture_size); | 168 | release_mem_region(info->apertures->ranges[0].base, info->apertures->ranges[0].size); |
169 | framebuffer_release(info); | 169 | framebuffer_release(info); |
170 | } | 170 | } |
171 | 171 | ||
@@ -289,8 +289,13 @@ static int __devinit efifb_probe(struct platform_device *dev) | |||
289 | info->pseudo_palette = info->par; | 289 | info->pseudo_palette = info->par; |
290 | info->par = NULL; | 290 | info->par = NULL; |
291 | 291 | ||
292 | info->aperture_base = efifb_fix.smem_start; | 292 | info->apertures = alloc_apertures(1); |
293 | info->aperture_size = size_remap; | 293 | if (!info->apertures) { |
294 | err = -ENOMEM; | ||
295 | goto err_release_fb; | ||
296 | } | ||
297 | info->apertures->ranges[0].base = efifb_fix.smem_start; | ||
298 | info->apertures->ranges[0].size = size_remap; | ||
294 | 299 | ||
295 | info->screen_base = ioremap(efifb_fix.smem_start, efifb_fix.smem_len); | 300 | info->screen_base = ioremap(efifb_fix.smem_start, efifb_fix.smem_len); |
296 | if (!info->screen_base) { | 301 | if (!info->screen_base) { |