Commit 9e87b63e authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull fbdev fixes from Helge Deller:
 "Most notable is a fix for a null-ptr-deref in fbcon's soft_cursor
  function which was found by syzbot.

   - Fix null-ptr-deref in soft_cursor

   - various remove callback conversions

   - error path fixes in imsttfb"

* tag 'fbdev-for-6.4-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/linux-fbdev:
  fbdev: bw2: Convert to platform remove callback returning void
  fbdev: broadsheetfb: Convert to platform remove callback returning void
  fbdev: au1200fb: Convert to platform remove callback returning void
  fbdev: au1100fb: Convert to platform remove callback returning void
  fbdev: arcfb: Convert to platform remove callback returning void
  fbdev: au1100fb: Drop if with an always false condition
  fbcon: Fix null-ptr-deref in soft_cursor
  fbdev: imsttfb: Fix error path of imsttfb_probe()
  fbdev: imsttfb: Release framebuffer and dealloc cmap on error path
  fbdev: matroxfb ssd1307fb: Switch i2c drivers back to use .probe()
parents b0e78154 d19663ed
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -590,7 +590,7 @@ static int arcfb_probe(struct platform_device *dev)
	return retval;
}

static int arcfb_remove(struct platform_device *dev)
static void arcfb_remove(struct platform_device *dev)
{
	struct fb_info *info = platform_get_drvdata(dev);

@@ -601,12 +601,11 @@ static int arcfb_remove(struct platform_device *dev)
		vfree((void __force *)info->screen_base);
		framebuffer_release(info);
	}
	return 0;
}

static struct platform_driver arcfb_driver = {
	.probe	= arcfb_probe,
	.remove = arcfb_remove,
	.remove_new = arcfb_remove,
	.driver	= {
		.name	= "arcfb",
	},
+3 −8
Original line number Diff line number Diff line
@@ -520,13 +520,10 @@ static int au1100fb_drv_probe(struct platform_device *dev)
	return -ENODEV;
}

int au1100fb_drv_remove(struct platform_device *dev)
void au1100fb_drv_remove(struct platform_device *dev)
{
	struct au1100fb_device *fbdev = NULL;

	if (!dev)
		return -ENODEV;

	fbdev = platform_get_drvdata(dev);

#if !defined(CONFIG_FRAMEBUFFER_CONSOLE) && defined(CONFIG_LOGO)
@@ -543,8 +540,6 @@ int au1100fb_drv_remove(struct platform_device *dev)
		clk_disable_unprepare(fbdev->lcdclk);
		clk_put(fbdev->lcdclk);
	}

	return 0;
}

#ifdef CONFIG_PM
@@ -593,7 +588,7 @@ static struct platform_driver au1100fb_driver = {
		.name		= "au1100-lcd",
	},
	.probe		= au1100fb_drv_probe,
        .remove		= au1100fb_drv_remove,
	.remove_new	= au1100fb_drv_remove,
	.suspend	= au1100fb_drv_suspend,
	.resume		= au1100fb_drv_resume,
};
+2 −4
Original line number Diff line number Diff line
@@ -1765,7 +1765,7 @@ static int au1200fb_drv_probe(struct platform_device *dev)
	return ret;
}

static int au1200fb_drv_remove(struct platform_device *dev)
static void au1200fb_drv_remove(struct platform_device *dev)
{
	struct au1200fb_platdata *pd = platform_get_drvdata(dev);
	struct fb_info *fbi;
@@ -1788,8 +1788,6 @@ static int au1200fb_drv_remove(struct platform_device *dev)
	}

	free_irq(platform_get_irq(dev, 0), (void *)dev);

	return 0;
}

#ifdef CONFIG_PM
@@ -1840,7 +1838,7 @@ static struct platform_driver au1200fb_driver = {
		.pm	= AU1200FB_PMOPS,
	},
	.probe		= au1200fb_drv_probe,
	.remove		= au1200fb_drv_remove,
	.remove_new	= au1200fb_drv_remove,
};
module_platform_driver(au1200fb_driver);

+2 −3
Original line number Diff line number Diff line
@@ -1193,7 +1193,7 @@ static int broadsheetfb_probe(struct platform_device *dev)

}

static int broadsheetfb_remove(struct platform_device *dev)
static void broadsheetfb_remove(struct platform_device *dev)
{
	struct fb_info *info = platform_get_drvdata(dev);

@@ -1209,12 +1209,11 @@ static int broadsheetfb_remove(struct platform_device *dev)
		module_put(par->board->owner);
		framebuffer_release(info);
	}
	return 0;
}

static struct platform_driver broadsheetfb_driver = {
	.probe	= broadsheetfb_probe,
	.remove = broadsheetfb_remove,
	.remove_new = broadsheetfb_remove,
	.driver	= {
		.name	= "broadsheetfb",
	},
+2 −4
Original line number Diff line number Diff line
@@ -352,7 +352,7 @@ static int bw2_probe(struct platform_device *op)
	return err;
}

static int bw2_remove(struct platform_device *op)
static void bw2_remove(struct platform_device *op)
{
	struct fb_info *info = dev_get_drvdata(&op->dev);
	struct bw2_par *par = info->par;
@@ -363,8 +363,6 @@ static int bw2_remove(struct platform_device *op)
	of_iounmap(&op->resource[0], info->screen_base, info->fix.smem_len);

	framebuffer_release(info);

	return 0;
}

static const struct of_device_id bw2_match[] = {
@@ -381,7 +379,7 @@ static struct platform_driver bw2_driver = {
		.of_match_table = bw2_match,
	},
	.probe		= bw2_probe,
	.remove		= bw2_remove,
	.remove_new	= bw2_remove,
};

static int __init bw2_init(void)
Loading