]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/video/gbefb.c
[MTD] Basic NAND driver for AMD/NatSemi CS5535/CS5536 Geode companion chip
[linux-2.6-omap-h63xx.git] / drivers / video / gbefb.c
index d744c51807b73af9420abaea6397f5f96afc7af3..5e25b98601967722df5e6014fbfb35d97abedcb7 100644 (file)
@@ -656,12 +656,15 @@ static int gbefb_set_par(struct fb_info *info)
        switch (bytesPerPixel) {
        case 1:
                SET_GBE_FIELD(WID, TYP, val, GBE_CMODE_I8);
+               info->fix.visual = FB_VISUAL_PSEUDOCOLOR;
                break;
        case 2:
                SET_GBE_FIELD(WID, TYP, val, GBE_CMODE_ARGB5);
+               info->fix.visual = FB_VISUAL_TRUECOLOR;
                break;
        case 4:
                SET_GBE_FIELD(WID, TYP, val, GBE_CMODE_RGB8);
+               info->fix.visual = FB_VISUAL_TRUECOLOR;
                break;
        }
        SET_GBE_FIELD(WID, BUF, val, GBE_BMODE_BOTH);
@@ -979,7 +982,7 @@ static int gbefb_check_var(struct fb_var_screeninfo *var, struct fb_info *info)
        return 0;
 }
 
-static int gbefb_mmap(struct fb_info *info, struct file *file,
+static int gbefb_mmap(struct fb_info *info,
                        struct vm_area_struct *vma)
 {
        unsigned long size = vma->vm_end - vma->vm_start;
@@ -1000,7 +1003,6 @@ static int gbefb_mmap(struct fb_info *info, struct file *file,
                pgprot_fb(pgprot_val(vma->vm_page_prot));
 
        vma->vm_flags |= VM_IO | VM_RESERVED;
-       vma->vm_file = file;
 
        /* look for the starting tile */
        tile = &gbe_tiles.cpu[offset >> TILE_SHIFT];
@@ -1244,7 +1246,7 @@ static int __devexit gbefb_remove(struct platform_device* p_dev)
                          (void *)gbe_tiles.cpu, gbe_tiles.dma);
        release_mem_region(GBE_BASE, sizeof(struct sgi_gbe));
        iounmap(gbe);
-       gbefb_remove_sysfs(dev);
+       gbefb_remove_sysfs(&p_dev->dev);
        framebuffer_release(info);
 
        return 0;