From patchwork Mon Feb 20 08:02:22 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Zhong X-Patchwork-Id: 9582127 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C93826047C for ; Mon, 20 Feb 2017 08:06:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B9826287FB for ; Mon, 20 Feb 2017 08:06:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AE5E928832; Mon, 20 Feb 2017 08:06:39 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 71C5F287FB for ; Mon, 20 Feb 2017 08:06:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=SQrYY/Ik0LtSAQ3fPk4KYyn2lGhN97OrvnEZHywgdBY=; b=OKmbRYrQEF6V0tLmSI4KovCRfN 8zMcwhn6iI7JAc0g8JEPEFn1PRZ5SRN1R+seCYUXRTpXlDqpwZe/eHfUet+fkJd3mrRlt8Ytxbes2 b8651BnXe5qMqXrjNm/NPJThkVeu6i1rtv1+WIJNKxB3jXqEJzg4I9Bra3u3eFll+ZgL7a1gyMnK0 Um3B18f3VMfAKWHXzRjvscFRrmKgG6NUVRceX51YCMx/sfsiXc/jASywrSsc5DCsU/QGLgg05xsuA +Wj44QVKWgDsn6nLc7jAtU+h6ZNSOtIGtFMZsZ+eBo1iL0W2u+6UBVo/xVGkDLkYlw9WDhvI1Hr1C MALa/V3g==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cfizW-0003CY-NK; Mon, 20 Feb 2017 08:06:38 +0000 Received: from mail-pf0-f196.google.com ([209.85.192.196]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cfiwE-0000C9-LY; Mon, 20 Feb 2017 08:03:17 +0000 Received: by mail-pf0-f196.google.com with SMTP id o64so8552799pfb.1; Mon, 20 Feb 2017 00:02:57 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=O2eb/NVQl2N4BfPpZaKgFjaKaFzNrD11xWbrVErevoU=; b=t3gQwAuPfiO1eLNdU8QPR+XUG3pJw6YYrpkabIiuvHg6dmA5nRpA8XQ1HeF0Gq7cTJ NHMiS7pPBgZKgaTmKnOCXTnq3HbTKCWc8qA8KOZ57+NZsgwPSQg2N4Z+0zrsJsq8kSlr rNDRvJxy4qO7OaLpLjsy98AcJXt3DTrspQjiCnwilredC9GTN7z/pMhq2QKIsPeQ9y6B LzijTJ0ZcB8WRx3QVZcJmaHNYYIopD6u+o07Nx0yKgUopCkT/HSrKEx98tUVe/kXpyJY KiEFXqV7RboPT8sjpEnUTvDjiSYB8NIetoHpp6DdQY/nlKDtMe/3EEpVn4W4yMHZrE92 xlhg== X-Gm-Message-State: AMke39m+3qbr/TAlzSQp+AHq0dDJzDuxuWSnVVSujYCTGukPrdwoIEP9kUe2c3nylne4og== X-Received: by 10.84.197.69 with SMTP id m63mr30296011pld.19.1487577777284; Mon, 20 Feb 2017 00:02:57 -0800 (PST) Received: from localhost.localdomain ([103.29.142.67]) by smtp.gmail.com with ESMTPSA id j127sm9998784pfg.89.2017.02.20.00.02.53 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 20 Feb 2017 00:02:56 -0800 (PST) From: Chris Zhong To: john@metanate.com, dianders@chromium.org, tfiga@chromium.org, heiko@sntech.de, yzq@rock-chips.com, mark.rutland@arm.com, devicetree@vger.kernel.org, robh+dt@kernel.org, galak@codeaurora.org, pawel.moll@arm.com, seanpaul@chromium.org Subject: [RESEND PATCH v7 6/7] drm/rockchip/dsi: fix insufficient bandwidth of some panel Date: Mon, 20 Feb 2017 16:02:22 +0800 Message-Id: <1487577744-2855-7-git-send-email-zyw@rock-chips.com> X-Mailer: git-send-email 2.6.3 In-Reply-To: <1487577744-2855-1-git-send-email-zyw@rock-chips.com> References: <1487577744-2855-1-git-send-email-zyw@rock-chips.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170220_000314_861565_66813828 X-CRM114-Status: UNSURE ( 9.72 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: David Airlie , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-rockchip@lists.infradead.org, Chris Zhong , linux-arm-kernel@lists.infradead.org, Mark Yao MIME-Version: 1.0 Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Set the lanes bps to 1 / 0.9 times of pclk, the margin is not enough for some panel, it will cause the screen display is not normal, so increases the badnwidth to 1 / 0.8. Signed-off-by: Chris Zhong Reviewed-by: Sean Paul --- Changes in v6: None Changes in v5: None Changes in v4: None Changes in v3: None drivers/gpu/drm/rockchip/dw-mipi-dsi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c index c2d7674..a653384 100644 --- a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c +++ b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c @@ -532,8 +532,8 @@ static int dw_mipi_dsi_get_lane_bps(struct dw_mipi_dsi *dsi, mpclk = DIV_ROUND_UP(mode->clock, MSEC_PER_SEC); if (mpclk) { - /* take 1 / 0.9, since mbps must big than bandwidth of RGB */ - tmp = mpclk * (bpp / dsi->lanes) * 10 / 9; + /* take 1 / 0.8, since mbps must big than bandwidth of RGB */ + tmp = mpclk * (bpp / dsi->lanes) * 10 / 8; if (tmp < max_mbps) target_mbps = tmp; else