Message ID | 20221114221754.385090-3-lyude@redhat.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp2393779wru; Mon, 14 Nov 2022 14:24:43 -0800 (PST) X-Google-Smtp-Source: AA0mqf5qJ6wkbdMM6YkTpRUpkUWzycKrPmEUF/4dy31WyEZgXpsyX9Y1wXA4GEQ8nCPqXoqcFWfq X-Received: by 2002:a17:907:7672:b0:7ad:c35a:ad76 with SMTP id kk18-20020a170907767200b007adc35aad76mr11856108ejc.705.1668464682859; Mon, 14 Nov 2022 14:24:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668464682; cv=none; d=google.com; s=arc-20160816; b=vcHKmu4LjQHPecA9sGmJ8hjyk+ZMJXGyz4+MZltLPq0Ws0dxTFrosbFWDjQpt9eH7P rgb1cGfivqGyeRN4ZHA/39/nL/WYgSTq7zo1oxskRY2oHX0sN4C8WJUKZRkcwOavgb+H LFQ2m/Ai5vYtL/3tQral6wrMxFRZDx9Q4bToLAlo8jt48MQbWmD4FcWsSqvX35glNcAT xgeuVFxU5IdgIW49HLl/8l24tjVOeQZr7G236q2rwCQHoDFpAvVeNmFa+i6CLUgTX6MJ XKRHtI6weBEtst+1H5ngKkDiHuM5Ak3K3/6/jkkU7xwLBrnGk5J1gdHmadTIGpD+BRUQ Vtag== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=T5iG8aiTSRDbls3qGdvQepXmN8J8nzm4Ph5iY3bMF3o=; b=W/iaTlnkIWb4DH0EsuRV4YDGcTeHaHTbAR+tmAHPLnql4m0fGkecYa7WGi9BtLMUzu kNQMxNhqjzBwEWJRIDJ5FVaa160lNYWbodwX03IQ9V8NsURctiC7hn1DZxmnpQenhTrs eeC5f5DShEfGr+IJglI+YPHqwpfU5ABbgAYkqXj3SJBGdNyROG8NoVWn1j8Dnwpo770r qzQN+kvR8V2iK1ofzSD6uBfxestFjHI/EKbgkCfCe0lp/LfwzDhAyiyjmkK5Abl6V9iQ sn8qCoS7jtlXIDfa7cBzTGY5AP5VPQH/wD1iWdCI6T+kQJgDYG6brH97WXo8OGx9hgZW pzKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=Q9sT7nHX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hs38-20020a1709073ea600b007ac60b83407si10191834ejc.725.2022.11.14.14.24.18; Mon, 14 Nov 2022 14:24:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=Q9sT7nHX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237296AbiKNWUK (ORCPT <rfc822;zwp10758@gmail.com> + 99 others); Mon, 14 Nov 2022 17:20:10 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54082 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236787AbiKNWTp (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 14 Nov 2022 17:19:45 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0FAD464CF for <linux-kernel@vger.kernel.org>; Mon, 14 Nov 2022 14:18:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1668464325; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=T5iG8aiTSRDbls3qGdvQepXmN8J8nzm4Ph5iY3bMF3o=; b=Q9sT7nHXjjg7DrZrkbGQeUYXIXJr93NpJawqWad7XgiI+UzGO10Dsf2UnnRtV7hl70KUUc 6gghlp62e6dcO4iTb3v/Vh/cwHEuIZQY5U4Y3hnOTByC4gm47/tA/YcuCDAspyfqqCQpQB N9tjpwXNC3z9RDklY2eheO4DKpvLFVw= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-606-IwuVXJEEOtidz6g12tO4eA-1; Mon, 14 Nov 2022 17:18:41 -0500 X-MC-Unique: IwuVXJEEOtidz6g12tO4eA-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id D6BFA8027EB; Mon, 14 Nov 2022 22:18:39 +0000 (UTC) Received: from emerald.lyude.net (unknown [10.22.18.150]) by smtp.corp.redhat.com (Postfix) with ESMTP id 680E849BB60; Mon, 14 Nov 2022 22:18:39 +0000 (UTC) From: Lyude Paul <lyude@redhat.com> To: amd-gfx@lists.freedesktop.org Cc: Wayne Lin <Wayne.Lin@amd.com>, stable@vger.kernel.org, David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>, Jani Nikula <jani.nikula@intel.com>, Thomas Zimmermann <tzimmermann@suse.de>, Imre Deak <imre.deak@intel.com>, Alex Deucher <alexander.deucher@amd.com>, Mikita Lipski <mikita.lipski@amd.com>, dri-devel@lists.freedesktop.org (open list:DRM DRIVERS), linux-kernel@vger.kernel.org (open list) Subject: [PATCH v2 2/4] drm/display/dp_mst: Fix drm_dp_mst_add_affected_dsc_crtcs() return code Date: Mon, 14 Nov 2022 17:17:53 -0500 Message-Id: <20221114221754.385090-3-lyude@redhat.com> In-Reply-To: <20221114221754.385090-1-lyude@redhat.com> References: <20221114221754.385090-1-lyude@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.1 on 10.11.54.9 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749512023208124145?= X-GMAIL-MSGID: =?utf-8?q?1749512023208124145?= |
Series |
[v2,1/4] drm/amdgpu/mst: Stop ignoring error codes and deadlocking
|
|
Commit Message
Lyude Paul
Nov. 14, 2022, 10:17 p.m. UTC
Looks like that we're accidentally dropping a pretty important return code here. For some reason, we just return -EINVAL if we fail to get the MST topology state. This is wrong: error codes are important and should never be squashed without being handled, which here seems to have the potential to cause a deadlock. Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Wayne Lin <Wayne.Lin@amd.com> Fixes: 8ec046716ca8 ("drm/dp_mst: Add helper to trigger modeset on affected DSC MST CRTCs") Cc: <stable@vger.kernel.org> # v5.6+ --- drivers/gpu/drm/display/drm_dp_mst_topology.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/display/drm_dp_mst_topology.c b/drivers/gpu/drm/display/drm_dp_mst_topology.c index ecd22c038c8c0..51a46689cda70 100644 --- a/drivers/gpu/drm/display/drm_dp_mst_topology.c +++ b/drivers/gpu/drm/display/drm_dp_mst_topology.c @@ -5186,7 +5186,7 @@ int drm_dp_mst_add_affected_dsc_crtcs(struct drm_atomic_state *state, struct drm mst_state = drm_atomic_get_mst_topology_state(state, mgr); if (IS_ERR(mst_state)) - return -EINVAL; + return PTR_ERR(mst_state); list_for_each_entry(pos, &mst_state->payloads, next) {