From patchwork Thu Oct 30 18:54:02 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jesse Barnes X-Patchwork-Id: 5199921 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 6A1839F349 for ; Thu, 30 Oct 2014 18:54:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9C1102021B for ; Thu, 30 Oct 2014 18:54:20 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id C958320225 for ; Thu, 30 Oct 2014 18:54:19 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id F37066E57F; Thu, 30 Oct 2014 11:54:18 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-pa0-f45.google.com (mail-pa0-f45.google.com [209.85.220.45]) by gabe.freedesktop.org (Postfix) with ESMTP id BB11F6E0D8 for ; Thu, 30 Oct 2014 11:54:17 -0700 (PDT) Received: by mail-pa0-f45.google.com with SMTP id lf10so6014266pab.18 for ; Thu, 30 Oct 2014 11:54:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=oi4KuMsAqVG5paPPzMUlyhpglfJugHCQ83aSxMhn+vw=; b=bxMdrG103T+tTHSVd+HlJbuUeQNcPYYuqKf44VrCa/plSnSakOOg4nOVlZbxADLTb7 6vNUIiBWxWg+tcyfyqn8UyRf9ROuDGzIX7gp75FvzrOrjUNctCVIcmo+mqb2ZMqTU3ni SrSc7HIOfusv93H18o7QD+seNZqr/rXUKdNc4Nk137fDKvb7UGdlFu+J2gmY7ldETBv2 qdTKy5ZpKBhTcDQjvmDUKEccoCHBESUG8+q6058j6HnRo1UpGGl5y8hj4KhUL04ZQiY+ 9xzLW2+7dcmXwvkARW9D6hfZNtyjTIEosE8QDJgS527HjCERnhLODDQ3Z/gxlca8H0Vv 6lcA== X-Received: by 10.66.226.235 with SMTP id rv11mr19013160pac.41.1414695257529; Thu, 30 Oct 2014 11:54:17 -0700 (PDT) Received: from jbarnes-t420.intel.com (c-67-161-37-189.hsd1.ca.comcast.net. [67.161.37.189]) by mx.google.com with ESMTPSA id k9sm7828118pdj.41.2014.10.30.11.54.16 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 30 Oct 2014 11:54:17 -0700 (PDT) From: Jesse Barnes To: intel-gfx@lists.freedesktop.org Date: Thu, 30 Oct 2014 11:54:02 -0700 Message-Id: <1414695244-14159-4-git-send-email-jbarnes@virtuousgeek.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1414695244-14159-1-git-send-email-jbarnes@virtuousgeek.org> References: <1414695244-14159-1-git-send-email-jbarnes@virtuousgeek.org> Cc: shuang.he@linux.intel.com Subject: [Intel-gfx] [PATCH 4/6] drm/i915: check for audio and infoframe changes across mode sets X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP If these change (e.g. after a modeset following a fastboot), we need to do a full mode set. Signed-off-by: Jesse Barnes --- drivers/gpu/drm/i915/intel_display.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 0f1952e..2199a9a 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -11482,6 +11482,16 @@ static int intel_crtc_set_config(struct drm_mode_set *set) if (ret) goto fail; + if (to_intel_crtc(set->crtc)->new_config->has_audio != + to_intel_crtc(set->crtc)->config.has_audio) + config->mode_changed = true; + + /* Force mode sets for any infoframe stuff */ + if (to_intel_crtc(set->crtc)->new_config->has_infoframe || + to_intel_crtc(set->crtc)->config.has_infoframe) + config->mode_changed = true; + + if (config->mode_changed) { ret = intel_set_mode_pipes(set->crtc, set->mode, set->x, set->y, set->fb,