Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp505023pxx; Wed, 28 Oct 2020 09:50:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzHPVj6fYfHElB+KV9K7jCWV/UjM7lW3U9EUkRvQltzc5zgML0+Q7awWiZvmSYlwN3kBYuG X-Received: by 2002:a17:906:d8ce:: with SMTP id re14mr2996487ejb.275.1603903843914; Wed, 28 Oct 2020 09:50:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603903843; cv=none; d=google.com; s=arc-20160816; b=oqd1QrdsKzDmF6hZbKfNBZbtQUDMhPDnseRzwdEPA8+P0MzhrBJ4hUqtgVVt2b72dl Ct+pgKosEdpvJIpNWQEQh3q3FxFA6TSP+PJF7pWoRh9iXuATqEYhGHnW6YJBunVI/kME kNjiwrwcmGNnDE1nBMiLn1QFWRs1Z6XqC6/zKnsEbe09HtZCvljVe6W/ZoxQ5W7CoN7L 7VPdZe8aSuzEOmaeO7DiWVZgI9W4Pngdbcccmj0pD0DIcaPK1Hk92JsFXxQfJHvystoe PHA0KdCJYe3expbxiUWAT3Kbrhy2KSCsIHu07oiw4lWzsR6K31QYXBzCKqvlkDS8T2ku BKCw== 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=Or3H7lbNsPgAX6IBDpN1kIHowbVy0Ncho2ZbvGm3hrE=; b=Bh2xQwu18RmUIdt+V9YuZlOPmphHqGJ5fb0quH13JOyMgEbUNt62x5Bug1JPHA+a+/ M1EZm+mEAPOVA1J2cVnAlwYTzdoOMciE6nKUwaRzzHbrvbAywHa6GTJAzjRVYHNT1KKw jUCxrk/OPjvs8fX6V7Nnlg1WNSE0gzgmmN46hzB8QjTmRBl3uZpgz38yUDgvYrCXsSed 6As3AD5DmzJrC9VZ5JopJ0jJY+eLgWE30n9XadA1BR59fPVSTCV0SJJjMBWEkX3wx6Y7 8bGnK+EEJqn7ZG6iY/+1y+n0ytaxBWh900tiRy7oLwqZVC7rRhC4SIGatza/SjQVi0F3 L2nQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=hPPbzQKb; 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=fail (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 bs17si4061011ejb.543.2020.10.28.09.50.18; Wed, 28 Oct 2020 09:50:43 -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=@kernel.org header.s=default header.b=hPPbzQKb; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1818742AbgJ0RXI (ORCPT + 99 others); Tue, 27 Oct 2020 13:23:08 -0400 Received: from mail.kernel.org ([198.145.29.99]:55358 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1780603AbgJ0Oys (ORCPT ); Tue, 27 Oct 2020 10:54:48 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (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 8B8F122202; Tue, 27 Oct 2020 14:54:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603810488; bh=Y6cgY3oUu3wLw2JdIFybvkHTjbjzW/z4guvS7ng9Q6A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hPPbzQKbM/iwLfJZUZjuW3WiLnes+ud7lZemu+flAmF6h7Mk+oKed/bhT92fBJgdG h4Bl6B8Irdnhsm1Mgj/Ey/BZSG32Lj9BExXJ/VVuNC4LKha2abSgHGwbW1U+6vbpnG CFG+VQ7PuxGpHz7O/iZTAFolpAdApj38wqHJC/mI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Leo Li , Tianjia Zhang , Alex Deucher , Sasha Levin Subject: [PATCH 5.8 157/633] drm/amd/display: Fix wrong return value in dm_update_plane_state() Date: Tue, 27 Oct 2020 14:48:20 +0100 Message-Id: <20201027135530.049979849@linuxfoundation.org> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201027135522.655719020@linuxfoundation.org> References: <20201027135522.655719020@linuxfoundation.org> User-Agent: quilt/0.66 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: Tianjia Zhang [ Upstream commit c35376137e940c3389df2726a92649c01a9844b4 ] On an error exit path, a negative error code should be returned instead of a positive return value. Fixes: 9e869063b0021 ("drm/amd/display: Move iteration out of dm_update_planes") Cc: Leo Li Signed-off-by: Tianjia Zhang Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index 7c1cc0ba30a55..78cf9e4fddbdf 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -8178,8 +8178,7 @@ static int dm_update_plane_state(struct dc *dc, dm_old_plane_state->dc_state, dm_state->context)) { - ret = EINVAL; - return ret; + return -EINVAL; } -- 2.25.1