From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chris Wilson Subject: Re: Switcheroo support in i915 Date: Mon, 8 Sep 2014 09:06:50 +0100 Message-ID: <20140908080650.GC19343@nuc-i3427.alporthouse.com> References: <17412193.9crM6G9hXq@tomac> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from fireflyinternet.com (mail.fireflyinternet.com [87.106.93.118]) by gabe.freedesktop.org (Postfix) with ESMTP id 76BBB89B67 for ; Mon, 8 Sep 2014 01:06:56 -0700 (PDT) Content-Disposition: inline In-Reply-To: <17412193.9crM6G9hXq@tomac> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" To: Tom Pitcher Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Sat, Sep 06, 2014 at 02:01:31PM +0100, Tom Pitcher wrote: > I've been attempting to solve a bug with i915 & switcheroo on many Macbook > Pros (some with nvidia discrete cards, others radeon), report here: > > https://bugs.freedesktop.org/show_bug.cgi?id=61115 > > Basically, after switching to i915 using switcheroo the display isn't > connected. It was mentioned that some kind of reprobing was needed, so I tried > the following: Right, I guess the output states do need to be repolled as well. But we need to effectively re-initialised the LVDS (and possibly all the other connectors, but it is likely to only be the panel connectors that are muxed). This will require some rejigging of intel_lvds_init(), though it should be safe enough to destroy and attempt to recreate it here: for_each_connector_safe() if (connector->type == DRM_MODE_CONNECOR_LVDS) drm_connector_destroy(connector); for_each_encoder_safe() if (encoder->type == DRM_MODE_ENCODER_LVDS) drm_encoder_destroy(encoder); intel_lvds_init(); -Chris -- Chris Wilson, Intel Open Source Technology Centre