diff options
author | Marcin Slusarz <marcin.slusarz@gmail.com> | 2010-05-16 17:27:03 +0200 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2010-05-18 16:19:27 +1000 |
commit | 1471ca9aa71cd37b6a7476bb6f06a3a8622ea1bd (patch) | |
tree | 3bf5ef9fea79b0b92220cfcc3842db7afb5cd63d /drivers/video/efifb.c | |
parent | 3da1f33e79a5922c1a31077e7b33aba1cec19b94 (diff) | |
download | kernel-common-1471ca9aa71cd37b6a7476bb6f06a3a8622ea1bd.tar.gz kernel-common-1471ca9aa71cd37b6a7476bb6f06a3a8622ea1bd.tar.bz2 kernel-common-1471ca9aa71cd37b6a7476bb6f06a3a8622ea1bd.zip |
fbdev: allow passing more than one aperture for handoff
It removes a hack from nouveau code which had to detect which
region to pass to kick vesafb/efifb.
Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Cc: Eric Anholt <eric@anholt.net>
Cc: Ben Skeggs <bskeggs@redhat.com>
Cc: Thomas Hellstrom <thellstrom@vmware.com>
Cc: Dave Airlie <airlied@redhat.com>
Cc: Peter Jones <pjones@redhat.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
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) { if (info->screen_base) iounmap(info->screen_base); - release_mem_region(info->aperture_base, info->aperture_size); + release_mem_region(info->apertures->ranges[0].base, info->apertures->ranges[0].size); framebuffer_release(info); } @@ -289,8 +289,13 @@ static int __devinit efifb_probe(struct platform_device *dev) info->pseudo_palette = info->par; info->par = NULL; - info->aperture_base = efifb_fix.smem_start; - info->aperture_size = size_remap; + info->apertures = alloc_apertures(1); + if (!info->apertures) { + err = -ENOMEM; + goto err_release_fb; + } + info->apertures->ranges[0].base = efifb_fix.smem_start; + info->apertures->ranges[0].size = size_remap; info->screen_base = ioremap(efifb_fix.smem_start, efifb_fix.smem_len); if (!info->screen_base) { |