Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d609f60a authored by Maarten Lankhorst's avatar Maarten Lankhorst
Browse files

Merge branch 'topic/remove-fbcon-notifiers' into drm-misc-next



topic/remove-fbcon-notifiers:
- remove fbdev notifier usage for fbcon, as prep work to clean up the fbcon locking
- assorted locking checks in vt/console code
- assorted notifier and cleanups in fbdev and backlight code

This is the pull request that was sent out, plus the compile fix for
sh4 reported by kbuild.

Acked-by: default avatarBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Signed-off-by: default avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
parents bcb7416e 24430914
Loading
Loading
Loading
Loading
+11 −2
Original line number Diff line number Diff line
@@ -347,8 +347,17 @@ int __init am200_init(void)
{
	int ret;

	/* before anything else, we request notification for any fb
	 * creation events */
	/*
	 * Before anything else, we request notification for any fb
	 * creation events.
	 *
	 * FIXME: This is terrible and needs to be nuked. The notifier is used
	 * to get at the fb base address from the boot splash fb driver, which
	 * is then passed to metronomefb. Instaed of metronomfb or this board
	 * support file here figuring this out on their own.
	 *
	 * See also the #ifdef in fbmem.c.
	 */
	fb_register_client(&am200_fb_notif);

	pxa2xx_mfp_config(ARRAY_AND_SIZE(am200_pin_config));
+3 −8
Original line number Diff line number Diff line
@@ -35,6 +35,7 @@
#include <linux/debugfs.h>
#include <linux/fb.h>
#include <linux/fs.h>
#include <linux/fbcon.h>
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/pm_domain.h>
@@ -734,14 +735,8 @@ static int vga_switchto_stage2(struct vga_switcheroo_client *new_client)
	if (!active->driver_power_control)
		set_audio_state(active->id, VGA_SWITCHEROO_OFF);

	if (new_client->fb_info) {
		struct fb_event event;

		console_lock();
		event.info = new_client->fb_info;
		fb_notifier_call_chain(FB_EVENT_REMAP_ALL_CONSOLE, &event);
		console_unlock();
	}
	if (new_client->fb_info)
		fbcon_remap_all(new_client->fb_info);

	mutex_lock(&vgasr_priv.mux_hw_lock);
	ret = vgasr_priv.handler->switchto(new_client->id);
+1 −5
Original line number Diff line number Diff line
@@ -1246,11 +1246,7 @@ static int ivtvfb_callback_cleanup(struct device *dev, void *p)
	struct osd_info *oi = itv->osd_info;

	if (itv->v4l2_cap & V4L2_CAP_VIDEO_OUTPUT) {
		if (unregister_framebuffer(&itv->osd_info->ivtvfb_info)) {
			IVTVFB_WARN("Framebuffer %d is in use, cannot unload\n",
				       itv->instance);
			return 0;
		}
		unregister_framebuffer(&itv->osd_info->ivtvfb_info);
		IVTVFB_INFO("Unregister framebuffer %d\n", itv->instance);
		itv->ivtvfb_restore = NULL;
		ivtvfb_blank(FB_BLANK_VSYNC_SUSPEND, &oi->ivtvfb_info);
+3 −1
Original line number Diff line number Diff line
@@ -891,7 +891,9 @@ int fbtft_unregister_framebuffer(struct fb_info *fb_info)
	if (par->fbtftops.unregister_backlight)
		par->fbtftops.unregister_backlight(par);
	fbtft_sysfs_exit(par);
	return unregister_framebuffer(fb_info);
	unregister_framebuffer(fb_info);

	return 0;
}
EXPORT_SYMBOL(fbtft_unregister_framebuffer);

+7 −0
Original line number Diff line number Diff line
TODO:
	- complete rewrite:
	  1. The underlying fbdev drivers need to be converted into drm kernel
	     modesetting drivers.
	  2. The dcon low-power display mode can then be integrated using the
	     drm damage tracking and self-refresh helpers.
	  This bolted-on self-refresh support that digs around in fbdev
	  internals, but isn't properly integrated, is not the correct solution.
	- see if vx855 gpio API can be made similar enough to cs5535 so we can
	  share more code
	- convert all uses of the old GPIO API from <linux/gpio.h> to the
Loading