Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp2352244pxb; Mon, 20 Sep 2021 19:49:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzHz3ZYtkdO1EvMyI/+u0ICL9lYsUY2SQMZeJo+ZJRVMEZNf51u+FP70qWti7qHiLIB8hy0 X-Received: by 2002:a05:6402:17cd:: with SMTP id s13mr32498081edy.321.1632192555565; Mon, 20 Sep 2021 19:49:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632192555; cv=none; d=google.com; s=arc-20160816; b=RYJVJDDof0SBUTkNQPJHIr736KjAvdU8TuIJ1cCfozVbHQjhQVrXoMYS94/ZSW4Mr0 lr1JxNYoewXtAUqWS6ycv4Sn4kcY3KeAJpNdDyEwzPjMLIAdR1gvxHUhKUdTMS6psYHf B5YkKzk7SRLU6t1zNc9Uj5H/x722DkSmoPELgqp9XopDJxJCEyKDA8lgJuK+SSsyY2gI HOht6Mfn7/p0piER6KFZHdy2RNdc3N90SJ9DUfesIBE9VMnsQib2TN4jRdMuRfG57GrZ y9hT8Cz92ByN03QANCsr/PGobfOo7zhXS2vNlQVyuknVmg9jv/2XB7+Ddsk6K3uAG95A 8dlg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Ai3Gu4TslG4Jple3zjBws1w84XxJ9RkGf2lUNBq8OFg=; b=mRpOuxIrPXduDs72dafcZhH8l/0+dVgytQ+TdX0PpFxzCQpPP6af12gBL7a6pT12eG KlEMEEMm+sWOoynSI5nByChuFB9a910ofxydt4BdO9Li0LNJSQc80m+sHa9eupWdawUg x0S5yoQDEUon8lHhC58hz9gOHTLw5IpPGtsH3JMQnwGwRJRXbgWsKPpoc91jcK1nn+OI UIuhAIRDecdJ+BZd5LGdBmSZP9GHw0HEAItHNfM97tZIgIM2GkUbtMaZz/mjC3Iu1n9s TsIUQvRmdt4QnkaPHvlhqJcV6XyOg17PxNw40Pcyx+O5c7d+zxfKZ9kcO8b20/U+MImN wkbQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kBjgPlKM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e6si16880342ejk.740.2021.09.20.19.48.51; Mon, 20 Sep 2021 19:49:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kBjgPlKM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1379683AbhITSaL (ORCPT + 99 others); Mon, 20 Sep 2021 14:30:11 -0400 Received: from mail.kernel.org ([198.145.29.99]:46128 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1378263AbhITSYT (ORCPT ); Mon, 20 Sep 2021 14:24:19 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2291A61A86; Mon, 20 Sep 2021 17:24:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1632158684; bh=3qHHijCYxJm+P+XXOkVa9sKBdREAC2QdlWEg93aqQQU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kBjgPlKME93p7XsgDbsSTY3AsuH3iQBhaODJ03yFR8Hm0f7pX2nLsQvEPHKcLzWu6 wW9gqe4LPM1K/Dh+K5TQ4nBvENihouUBZKVwrFC8aa1AE5HnBJhjbxeU30I3f0dJmp kcnQa0n40vIe1wd0w3/w2gx2YdE69qESiUriYmsA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Peter Collingbourne , Robert Foss , John Stultz , Anibal Limon , Bjorn Andersson , Vinod Koul Subject: [PATCH 5.10 001/122] drm/bridge: lt9611: Fix handling of 4k panels Date: Mon, 20 Sep 2021 18:42:53 +0200 Message-Id: <20210920163915.808718406@linuxfoundation.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210920163915.757887582@linuxfoundation.org> References: <20210920163915.757887582@linuxfoundation.org> User-Agent: quilt/0.66 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Robert Foss commit d1a97648ae028a44536927c87837c45ada7141c9 upstream. 4k requires two dsi pipes, so don't report MODE_OK when only a single pipe is configured. But rather report MODE_PANEL to signal that requirements of the panel are not being met. Reported-by: Peter Collingbourne Suggested-by: Peter Collingbourne Signed-off-by: Robert Foss Tested-by: John Stultz Tested-by: Anibal Limon Tested-by: Peter Collingbourne Reviewed-by: Bjorn Andersson Acked-by: Vinod Koul Link: https://patchwork.freedesktop.org/patch/msgid/20201217140933.1133969-1-robert.foss@linaro.org Cc: Peter Collingbourne Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/bridge/lontium-lt9611.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) --- a/drivers/gpu/drm/bridge/lontium-lt9611.c +++ b/drivers/gpu/drm/bridge/lontium-lt9611.c @@ -867,8 +867,14 @@ static enum drm_mode_status lt9611_bridg const struct drm_display_mode *mode) { struct lt9611_mode *lt9611_mode = lt9611_find_mode(mode); + struct lt9611 *lt9611 = bridge_to_lt9611(bridge); - return lt9611_mode ? MODE_OK : MODE_BAD; + if (!lt9611_mode) + return MODE_BAD; + else if (lt9611_mode->intfs > 1 && !lt9611->dsi1) + return MODE_PANEL; + else + return MODE_OK; } static void lt9611_bridge_pre_enable(struct drm_bridge *bridge)