Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752749AbbK2Mrv (ORCPT ); Sun, 29 Nov 2015 07:47:51 -0500 Received: from mail-wm0-f46.google.com ([74.125.82.46]:36497 "EHLO mail-wm0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751993AbbK2Mrq (ORCPT ); Sun, 29 Nov 2015 07:47:46 -0500 Date: Sun, 29 Nov 2015 13:47:42 +0100 From: Daniel Vetter To: Ilia Mirkin Cc: Emil Velikov , Daniel Vetter , Andrew Morton , Greg Kroah-Hartman , Intel Graphics Development , LKML , DRI Development Subject: Re: [PATCH RESEND 2/2] drm/i915: prevent the vgacon from ever reloading Message-ID: <20151129124742.GA17050@phenom.ffwll.local> Mail-Followup-To: Ilia Mirkin , Emil Velikov , Andrew Morton , Greg Kroah-Hartman , Intel Graphics Development , LKML , DRI Development References: <1448637005-3847-1-git-send-email-daniel.vetter@ffwll.ch> <1448637005-3847-2-git-send-email-daniel.vetter@ffwll.ch> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: Linux phenom 4.1.0-2-amd64 User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2506 Lines: 54 On Fri, Nov 27, 2015 at 07:37:53PM -0500, Ilia Mirkin wrote: > On Fri, Nov 27, 2015 at 10:40 AM, Emil Velikov wrote: > > On 27 November 2015 at 15:10, Daniel Vetter wrote: > >> It only leads to bloodshed and tears - we don't bother to restore a > >> working legacy vga hw setup. > >> > >> On haswell with the new dynamic power well code this leads to even > >> more hilarity since for some configurations the hardware is simply no > >> longer there. > >> > >> The actual implementation is a bit a hack - we realy on fbcon to kick > >> out the vgacon. To make this also work with I915_FBDEV=n (or FBCON=n) > >> and VGA_CONSOLE=y i915 already unregisters the vga console manually > >> early in the driver load sequence. > >> > > Interesting... nv50 and later GPUs are in a roughly similar shame > > afaict. They lack the dedicated hardware and no one really bothered > > figuring out how to restore things to a working shape [1]. > > > > Then again, upon sequential load of the nouveau module the GPU gets > > initialised properly, where you can get X (weston?) up and running > > without issues. Am I thinking about a different thing ? > > > > I take it that you guys do less of the (re)initialisation dance, to > > ensure faster boot times ? > > > > Thanks, > > Emil > > > > [1] http://nouveau.freedesktop.org/wiki/KernelModeSetting/#deactivatingkmsandunloadingnouveau > > FWIW it's possible to unload nouveau, at which point your screen turns > off (because we can't restore the vga emulation junk... haven't the > faintest clue how it works), and then reload it, at which point fbcon > gets rebound and is completely happy. I can't tell what this patch is > doing, but for your own sanity, you should support unloading/reloading > i915 as well. We do of course support unloading/reloading. And we do the same "shut everything down" like nouveau seems to do. The problem though on some hw is that if vgacon then tries to access the registers the hw dies. So the problem we have with not restoring VGA functionality isn't that the screen is black when i915.ko is unloaded, but that the machine dies. This patch fixes that. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/