Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp1082323ybl; Wed, 14 Aug 2019 10:24:30 -0700 (PDT) X-Google-Smtp-Source: APXvYqyV+mwAhd1EgZvHrv76Tz+0wqWpxaTZYMWA0hUBL3DUHVnxZ6ylq+eWJ5QGNY8zcyb1mAMC X-Received: by 2002:a62:be0c:: with SMTP id l12mr1063574pff.224.1565803470607; Wed, 14 Aug 2019 10:24:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565803470; cv=none; d=google.com; s=arc-20160816; b=h3hpyRtQpBVaKoX04S3pW8Ze77IOEHqsPQzbtQ/nXyAz/Y8hK0wd6yyOh9yEc2OcEq iv6xyOVTo3oXoqcTTwVL58RyznXcY63tpF+B/TArtcjE2ZS4VjsUbfWLihj5eIxpCiun pkzGUUVHnpZRZvjUcD/9P+O6laxY+I2Vuvs2mweGMjYr0B33+0HNITwu0LoxgdqDMGJ6 SBGhnhaBJiQd7e+mmj18Fi6F9hUh7Zj1NL2skjovgVp2NeOULy2m1b7JGejHwEM3jF/o VHCAUTTeZZNJxK9MpXjbQS7laU97FPv/P64Jc30iEyHpSBckteqn8M7kqV7FKzOrcKQc Xe/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=WEDZzf9Be70XAvC3JuHsPP2VIWgDfpyyUQnEAe6N76I=; b=kQEIBpj1n26rjsQhOupIihN//maTara42+iXRATvt41Ob+01GobxwFkBTuI9ZaoeDg 0R2G04Wi6QnMT+MURGemXsGQEw4xWQjV/Ro03buvNhfGzJNd9y4KUCsL8ragp2Dknhun 7fPaYC0IkDSfjw8YWF576HeHutm8XvDIXDwMBMwP7piiUv1H5i3JrPXZWB/JEYikZmdK jBLwG3SXbmvGTs+eD2zpWI3Ajt29M8gS9FZ6Zja1VtyDxQP2qAy3+qApdvbVp8CwMGz+ v/RDYa7pjBjubhOLCFxWVw7OG2h48kLUVqUffSzxzs5mcQrKTOBma5SuZ5KcbN/XpWTu zfug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=KT4qcTtK; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l10si167105pgp.411.2019.08.14.10.24.14; Wed, 14 Aug 2019 10:24:30 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=KT4qcTtK; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729117AbfHNRHR (ORCPT + 99 others); Wed, 14 Aug 2019 13:07:17 -0400 Received: from mail.kernel.org ([198.145.29.99]:56704 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729826AbfHNRHP (ORCPT ); Wed, 14 Aug 2019 13:07:15 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E23D221743; Wed, 14 Aug 2019 17:07:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1565802434; bh=HcpxKF/MCkxq4bpGnQg8NKwrDNeMif3vMtDdIL/Asro=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KT4qcTtKBKIZUVDErmTIG0iUXgtYNOs3UslhUTDe39FAooz2oztrK0j1Njahvu/Vq uy0xuvT+wdBZCAodnghcYxI0Czb8g+RuJtIWxR57z5Nzonkwk9KrPc5b9xBpaDaD6o PApNkS4aSqSSb1CwtBGI8bN+T+2fF0nfUQl99+0s= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Stanislav Lisovskiy , Vandita Kulkarni , Deepak M , Madhav Chauhan , Jani Nikula , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , intel-gfx@lists.freedesktop.org Subject: [PATCH 5.2 125/144] drm/i915: Fix wrong escape clock divisor init for GLK Date: Wed, 14 Aug 2019 19:01:21 +0200 Message-Id: <20190814165805.156518457@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190814165759.466811854@linuxfoundation.org> References: <20190814165759.466811854@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Stanislav Lisovskiy commit 73a0ff0b30af79bf0303d557eb82f1d1945bb6ee upstream. According to Bspec clock divisor registers in GeminiLake should be initialized by shifting 1(<<) to amount of correspondent divisor. While i915 was writing all this time that value as is. Surprisingly that it by accident worked, until we met some issues with Microtech Etab. v2: Added Fixes tag and cc v3: Added stable to cc as well. Signed-off-by: Stanislav Lisovskiy Reviewed-by: Vandita Kulkarni Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108826 Fixes: bcc657004841 ("drm/i915/glk: Program txesc clock divider for GLK") Cc: Deepak M Cc: Madhav Chauhan Cc: Jani Nikula Cc: Jani Nikula Cc: Joonas Lahtinen Cc: Rodrigo Vivi Cc: intel-gfx@lists.freedesktop.org Cc: stable@vger.kernel.org Signed-off-by: Jani Nikula Link: https://patchwork.freedesktop.org/patch/msgid/20190712081938.14185-1-stanislav.lisovskiy@intel.com (cherry picked from commit ce52ad5dd52cfaf3398058384e0ff94134bbd89c) Signed-off-by: Jani Nikula Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/i915/vlv_dsi_pll.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/gpu/drm/i915/vlv_dsi_pll.c +++ b/drivers/gpu/drm/i915/vlv_dsi_pll.c @@ -394,8 +394,8 @@ static void glk_dsi_program_esc_clock(st else txesc2_div = 10; - I915_WRITE(MIPIO_TXESC_CLK_DIV1, txesc1_div & GLK_TX_ESC_CLK_DIV1_MASK); - I915_WRITE(MIPIO_TXESC_CLK_DIV2, txesc2_div & GLK_TX_ESC_CLK_DIV2_MASK); + I915_WRITE(MIPIO_TXESC_CLK_DIV1, (1 << (txesc1_div - 1)) & GLK_TX_ESC_CLK_DIV1_MASK); + I915_WRITE(MIPIO_TXESC_CLK_DIV2, (1 << (txesc2_div - 1)) & GLK_TX_ESC_CLK_DIV2_MASK); } /* Program BXT Mipi clocks and dividers */