diff options
Diffstat (limited to 'drivers/video/tgafb.c')
-rw-r--r-- | drivers/video/tgafb.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/video/tgafb.c b/drivers/video/tgafb.c index 680642c089c9..a86046ff60ad 100644 --- a/drivers/video/tgafb.c +++ b/drivers/video/tgafb.c | |||
@@ -1663,7 +1663,7 @@ tgafb_register(struct device *dev) | |||
1663 | if (register_framebuffer(info) < 0) { | 1663 | if (register_framebuffer(info) < 0) { |
1664 | printk(KERN_ERR "tgafb: Could not register framebuffer\n"); | 1664 | printk(KERN_ERR "tgafb: Could not register framebuffer\n"); |
1665 | ret = -EINVAL; | 1665 | ret = -EINVAL; |
1666 | goto err1; | 1666 | goto err2; |
1667 | } | 1667 | } |
1668 | 1668 | ||
1669 | if (tga_bus_pci) { | 1669 | if (tga_bus_pci) { |
@@ -1682,6 +1682,8 @@ tgafb_register(struct device *dev) | |||
1682 | 1682 | ||
1683 | return 0; | 1683 | return 0; |
1684 | 1684 | ||
1685 | err2: | ||
1686 | fb_dealloc_cmap(&info->cmap); | ||
1685 | err1: | 1687 | err1: |
1686 | if (mem_base) | 1688 | if (mem_base) |
1687 | iounmap(mem_base); | 1689 | iounmap(mem_base); |