From patchwork Mon Sep 13 13:13:49 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 509768 Delivered-To: patch@linaro.org Received: by 2002:a02:c816:0:0:0:0:0 with SMTP id p22csp619214jao; Mon, 13 Sep 2021 07:36:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwhGPxHmvi5WbBZFNxqZhoLcInKythJK1YjBVV4QlBTBigpfcXtR1SRsBUA4Stp39AQqLFt X-Received: by 2002:a05:6402:4cd:: with SMTP id n13mr13514031edw.215.1631543760292; Mon, 13 Sep 2021 07:36:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631543760; cv=none; d=google.com; s=arc-20160816; b=yrDZIdei4dntrdJEvTTIb39DIX6ghnqs9HeIQ5wFFfGua5Mz9x2QuMWM2w/4qHCHO6 +ATE/cMj8m8gac47ECH+ULpmD74LpC+tKW8IHQjGav0a69J9+AdYsZo4W9fwHbNjtN+n zgKc4OPHhDzJj56p81l2VQ2dvGWnqO8Sv3/X4SyPP5XfR3QGYOQdom6jNtK2qlY0iyuR a82Lw7rSgF6s5VySd5d9Zv4CwuwVaW1UbNJOEFVnGJ2opZnaxWHjn0dXgN2Cni/73iQ3 GafPlFeGDA5YMCD/blEEchkVLZdJDajpBUZMA85IE6v5sircr8SiV5vMTcwQmlpU2gIS 2ZZg== 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=JnrleraATE27E4z7XALpfivGrrAvGshap3pUaIvMCW4=; b=PWZs1DoTrS5JxtgJTVNd6jeUNOoY9mvuOK5UXWOr7eWZtooc2zV00GIOAzamI+dMg9 3o6YBcjStBYDDodIzGJAf82tG9Y/RyFO6TFWB+1De7kw78b35sUO1BE6ZnKaHKz0NYBA kY61lCQ6qQl3R8aS2S0U1a6J6Vneb723ilOUxxCpEYoTXc2ky4B8qH9ep0dP6uRStBjJ TCOYTqmTmeXT4l9lzQPOsQQR1mWpXwgeXjwqgYxVCNxChaFmNVIf6r1RBpOPRCgKm75F 0JEHcoNlixpdcjJdEXc1eWT5sEd2pXIGDwM1p9gj39PpmvcrxWefdW8BVOXlYGXmFGwE WSAQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=0kmmM24G; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-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 er10si175213ejc.675.2021.09.13.07.36.00; Mon, 13 Sep 2021 07:36:00 -0700 (PDT) Received-SPF: pass (google.com: domain of stable-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=0kmmM24G; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-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 S1345613AbhIMOhO (ORCPT + 11 others); Mon, 13 Sep 2021 10:37:14 -0400 Received: from mail.kernel.org ([198.145.29.99]:55828 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347690AbhIMOfV (ORCPT ); Mon, 13 Sep 2021 10:35:21 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2EF73617E3; Mon, 13 Sep 2021 13:53:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1631541209; bh=k7R7caureSstJbIJr1FTSSD6NyAVWVoz5kkbTZepus4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=0kmmM24GI1Uj6smXYRP4omNJpG4YXFiAhsl1Q8ydOtnjPm10AXIp9oknn+DluzhKl n2gMH30lCHLQjtrkv4O5d+pK6+JdzWR/nloefLKGv6OMMD5T0v7MO6d0mhuUm4b+to JZ8wrCWJzi/ia7t6hrSDPpNiNL/9qczFKIxsTMXo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Robert Foss , Jernej Skrabec , Sasha Levin Subject: [PATCH 5.14 175/334] drm: bridge: it66121: Check drm_bridge_attach retval Date: Mon, 13 Sep 2021 15:13:49 +0200 Message-Id: <20210913131119.263275770@linuxfoundation.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210913131113.390368911@linuxfoundation.org> References: <20210913131113.390368911@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Robert Foss [ Upstream commit bd03d440e2589b9c328f40ce60203adf2b19d2e2 ] The return value of drm_bridge_attach() is ignored during the it66121_bridge_attach() call, which is incorrect. Fixes: 988156dc2fc9 ("drm: bridge: add it66121 driver") Signed-off-by: Robert Foss Acked-by: Jernej Skrabec Link: https://patchwork.freedesktop.org/patch/msgid/20210805185039.402178-1-robert.foss@linaro.org Link: https://patchwork.freedesktop.org/patch/msgid/20210805185039.402178-1-robert.foss@linaro.org Signed-off-by: Sasha Levin --- drivers/gpu/drm/bridge/ite-it66121.c | 2 ++ 1 file changed, 2 insertions(+) -- 2.30.2 diff --git a/drivers/gpu/drm/bridge/ite-it66121.c b/drivers/gpu/drm/bridge/ite-it66121.c index 7149ed40af83..2f2a09adb4bc 100644 --- a/drivers/gpu/drm/bridge/ite-it66121.c +++ b/drivers/gpu/drm/bridge/ite-it66121.c @@ -536,6 +536,8 @@ static int it66121_bridge_attach(struct drm_bridge *bridge, return -EINVAL; ret = drm_bridge_attach(bridge->encoder, ctx->next_bridge, bridge, flags); + if (ret) + return ret; ret = regmap_write_bits(ctx->regmap, IT66121_CLK_BANK_REG, IT66121_CLK_BANK_PWROFF_RCLK, 0);