Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp891439pxt; Fri, 6 Aug 2021 17:09:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwAO1RpX+8aoS38FN8wrs6n9fF8EPCknS+wxCU7TsPvPHADo1VnvCyq8VmQwB4y4XG076X6 X-Received: by 2002:a6b:ba02:: with SMTP id k2mr986920iof.164.1628294959507; Fri, 06 Aug 2021 17:09:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628294959; cv=none; d=google.com; s=arc-20160816; b=YkpEE5GsWol38AuXmNg2oAFi6YNZjeRkpfKYFXuIOUnjBJrgoEIY1l+/Zl3Ac6UfCM qi5AJoYd9NEL1fHciywrnzgGYeud+A0MwUyqV+z0W6t/8lOklS5FJnJKos/8evdsjgIW o+ZHgSjoPCJaApGbvSHmgxEwzn3pMWDHvEsq4lWvug4pSPf7GtUDy0iCHTpqYt/0rUas l47aKQQ7sSr2EI/q8XQv33nd9rso6fNoY1EKJf0Y05vXcqK/eP3UeA2LgK1iTO2Z7cIx xnhMDmPp4t8tprBBiIo7TMrr8wRvXEKZMXCpCUHqJE8Qfxc5CFIagH/2G7gCf/cKah2f DbAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=44uVScQ9Gw/XAJ45c0vruto85d4GkUi4W4Jmj+tsVH8=; b=NbTpaaEme+UEX1899Qf33snX6GepkP+oUowAS1KM8cErvN50HcbLH7qqslND14ybPr s3oMwZogQraNJwV8hj4g/x42XD8TwzbD/3/6XENjdSlcPHIxEQGBj7LyYei5PO96b1tA uUZ9yNg1+8F9QJvLfGVu+toX68eKdRl2AJ7bIn1HcHCjMD4tq+SMWd6PZiFHTdYujz0k DpkqBa4fz+XmpEb+GiYmK/41rBpHyXS+b6vKo/WKxx+auqtMWZbtwB5IV1oyW1Y9onOz 8PkTlrG0rGNmx5KFxEL5CZZaBh9gv5ZYszz6KTBM3MQWtAosAGZHLQtVZGyMvDCeUI4X zb+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UlGtN2N+; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c10si8728149ioq.4.2021.08.06.17.09.08; Fri, 06 Aug 2021 17:09:19 -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=@gmail.com header.s=20161025 header.b=UlGtN2N+; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244269AbhHFT6q (ORCPT + 99 others); Fri, 6 Aug 2021 15:58:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47764 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232086AbhHFT6o (ORCPT ); Fri, 6 Aug 2021 15:58:44 -0400 Received: from mail-ot1-x332.google.com (mail-ot1-x332.google.com [IPv6:2607:f8b0:4864:20::332]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7AE0EC0613CF; Fri, 6 Aug 2021 12:58:27 -0700 (PDT) Received: by mail-ot1-x332.google.com with SMTP id e13-20020a056830200db02904f06fa2790cso10204528otp.1; Fri, 06 Aug 2021 12:58:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=44uVScQ9Gw/XAJ45c0vruto85d4GkUi4W4Jmj+tsVH8=; b=UlGtN2N+/E7iiZYxJKvzovkSO19giQwJd+k/KHky2IbaJkpv1Uak4W1uJn6H8BFiiU G+xiGSKGeR+7ThNnHhDMmpUIROTHWo5oXjIWRUmY1IlldNyqs4V6G/GWO3ysIoNqa/wh vZAarLxtlCu5ja19o3NIDmGyWxIf19NLbIbmwNmasbzJMDcsvWFSFYCy2+ClNx8Ih4Ok UNa5v/n7S/SzlZ9icFqH6a/jd+XiAssHlSLipwEbvxLmhNu2dvEgmGmd3HVhMjzgP6kz zIcc9/unMPkbQvBMHMGRoAJ9tPRVbr85crNJUdz8tSqqO9veN61s/GoH2EoQWrkESm3B 0E1g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=44uVScQ9Gw/XAJ45c0vruto85d4GkUi4W4Jmj+tsVH8=; b=HpcEuA7O8LUvbwVP7Db+pUZq8L/qtZSlIX89HV0TV2gBZon4KrgJak8z1kQd2tdkg+ xVBG/al7IJfTrcPnLzHqhz0lsKFyh/eVsPkeFJJgeZp8aA8qVDieVqpMeyJhKg4h4ado oba8rAwvhqhlDXC1FF1ascepn/eWIYl6RZOqicT1ltSPkE4Zzn9PekHv/6CMwz5bDBze 25/VIPwKxGvfEIMnPqh3xsBJbnHpnYykQl63MqOx09J1ken3w8OZlApqlO3iTEJB0WpI I9+04klqWAFzSoGLBWoOiC2DkoBhESXBRa1uZRuZhRDdxtoeXAW63zRdfRjb6zxNK3k+ 78SA== X-Gm-Message-State: AOAM532GZhl1Dd0FNpMq8tFGxuCFq0r+n7MwL/BfuUWgBfC4HLWMrBNC GoGpI5eP5NYmIfqCktHa6n52STZp//F2bAR5VIU= X-Received: by 2002:a9d:5a15:: with SMTP id v21mr7881368oth.132.1628279906863; Fri, 06 Aug 2021 12:58:26 -0700 (PDT) MIME-Version: 1.0 References: <20210806111615.11803-1-colin.king@canonical.com> In-Reply-To: <20210806111615.11803-1-colin.king@canonical.com> From: Alex Deucher Date: Fri, 6 Aug 2021 15:58:15 -0400 Message-ID: Subject: Re: [PATCH] drm/amd/display: Remove redundant initialization of variable eng_id To: Colin King Cc: Harry Wentland , Leo Li , Alex Deucher , =?UTF-8?Q?Christian_K=C3=B6nig?= , xinhui pan , David Airlie , Daniel Vetter , Jun Lei , Jimmy Kizito , amd-gfx list , Maling list - DRI developers , kernel-janitors@vger.kernel.org, LKML Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Applied. Thanks! Alex On Fri, Aug 6, 2021 at 7:16 AM Colin King wrote: > > From: Colin Ian King > > The variable eng_id is being initialized with a value that is never > read, it is being re-assigned on the next statment. The assignment > is redundant and can be removed. > > Addresses-Coverity: ("Unused value") > Signed-off-by: Colin Ian King > --- > drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c b/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c > index 1a89d565c92e..de80a9ea4cfa 100644 > --- a/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c > +++ b/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c > @@ -305,7 +305,7 @@ struct link_encoder *link_enc_cfg_get_next_avail_link_enc( > const struct dc_state *state) > { > struct link_encoder *link_enc = NULL; > - enum engine_id eng_id = ENGINE_ID_UNKNOWN; > + enum engine_id eng_id; > > eng_id = find_first_avail_link_enc(dc->ctx, state); > if (eng_id != ENGINE_ID_UNKNOWN) > -- > 2.31.1 >