From patchwork Sat Mar 25 13:45:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Rix X-Patchwork-Id: 74913 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp420368vqo; Sat, 25 Mar 2023 06:52:47 -0700 (PDT) X-Google-Smtp-Source: AKy350ZOBj8bP4X7lcJJMB4QgNe+eT0PRyP24VcUsxpTF9RB0g7O5hHM8MkBwWn9BAOHVPfUYd4X X-Received: by 2002:aa7:c68b:0:b0:4fb:78a0:eabf with SMTP id n11-20020aa7c68b000000b004fb78a0eabfmr6432041edq.29.1679752367158; Sat, 25 Mar 2023 06:52:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679752367; cv=none; d=google.com; s=arc-20160816; b=uXloi46lcV1bIfee+nEff+dvUCjmUmAKcbEaplzSnRVPPkRqDu8MPicuWUpJAQKJcu mXlKK/x2ZZq7Yt6swUod1X0HD4rReOfWyewyo/WtvvUBeMQOURsjnV0Hv1u91D5zPkiY dbxNMhgZt/qg0qYUEaEuyQCuoCACu/pL0RNd9/if+ZyhlGHieTAtpfAmJwKzAZAxxK3F O787gGSnHEMG3E+cA8SuBraSpoaUxPrnJrpMhv0tqrTSVLeJHn0egAPzbAx5x0NgCCWE GpmGPzARiR0eWO5On4hm5zxQfnVElYtskC24hNTWoZvZqi6DOHntaaRjmc7hw7cK430C wIhA== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=CA7h/KT6ar6s3WSm/PcPsckHI4JxnLRkTxYhhO4xj4k=; b=qGplMXFR6PPj2d7XFDgiGB+Q7qvCrXiZsCk8JmSCIdLYMh0rABwtNwukAWStDrBNoD glT3mZcxs8BbkzVfKOgMJoJBC2WpI59RGSlrKVdY/9NUXV121SaWCoZe6OJWqRnoKDed Q7/buzFXQq3JQFgHY4mn9MCQPdLh6dJr5xzLYiJFwy5C1xBVDOwRZ2t74YG5mCo3axwS MFM9tkx7yN31y9F0iC9LwwH7jOm/cX+BbItIcu+CeqNPebVJ3FkJrbIu7OZg5g4jeLYa VTemFJlI9ow4Laj4EDOiA2jcMA9MYnZXP+aI310Rs9u/4aGzeAe1CqnbPUHqMeEntfrK 06Pg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=MWBMm6KR; 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 v24-20020aa7d658000000b00501dd8e9f9dsi13747374edr.370.2023.03.25.06.52.24; Sat, 25 Mar 2023 06:52:47 -0700 (PDT) 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=MWBMm6KR; 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 S229805AbjCYNqP (ORCPT + 99 others); Sat, 25 Mar 2023 09:46:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38050 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229600AbjCYNqN (ORCPT ); Sat, 25 Mar 2023 09:46:13 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AAAD8125AB for ; Sat, 25 Mar 2023 06:45:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1679751908; 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; bh=CA7h/KT6ar6s3WSm/PcPsckHI4JxnLRkTxYhhO4xj4k=; b=MWBMm6KR749nnm1mC0XzCkmKYGsvH5C5N9ULOrWBOVtl+3qZCIKVzAFICpkXN4p5oaxx0V lGsrwUmJKoIr1CcNMgma5uqksQHidmmaADoKzdtwKfMNpgTe4UyjcSHvodv9oCT5JidDbV jQqWA3do9qEAbqxpkdKPNjNa0yk13Pc= Received: from mail-qt1-f198.google.com (mail-qt1-f198.google.com [209.85.160.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-173-ZeduFHGWOzWUrcJJ4H1h0w-1; Sat, 25 Mar 2023 09:45:07 -0400 X-MC-Unique: ZeduFHGWOzWUrcJJ4H1h0w-1 Received: by mail-qt1-f198.google.com with SMTP id b11-20020ac87fcb000000b003e37d72d532so2794232qtk.18 for ; Sat, 25 Mar 2023 06:45:07 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679751907; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=CA7h/KT6ar6s3WSm/PcPsckHI4JxnLRkTxYhhO4xj4k=; b=iWhV/YrIli1zU8XpZahj0cz/gYlYlS/RdHszR8AG8eEWtg3+1+ckSe+DVXSBLDC7EQ oZnCeA8QAHBuMu3xtDQuyWlx3CV9B8bd3tlIBoYIXFqUEJppdRvPWmnxT8Gig9qoBUJP 93dROP3MQhpkK3vXi0GBIlVxNyFJZBVFPP8HpFWB1K/g6RPYEwedVuj8jMo/h+jcjOtB MF30aDPKP1UPvma5regGHAsbYfpzj3wwJq1XMfuKRlngfy74yOUO1+n52rNk2cTFw2Bv 6PjXU/vyenUEN2TomkmYvzDg5X1yQNeKYzcrzO93/JlOBzUbjsEcfDdMC2lph0Z1pcV7 3Zlw== X-Gm-Message-State: AO0yUKUpWZrde4aAJq18zaRO5zJVw60S4KynoZWG8yV3S1B+GpiuUGKj XQ4BkVMmwWS5DRRvkygg1t5i+eawb+ZnXDnzrii7DnxpgL03KE3Vo6eIl4dVoki+OoJs2zX1NeU iehubnBo/bZ0t0xP7AdGu1ywt X-Received: by 2002:a05:622a:647:b0:3e3:9948:98d1 with SMTP id a7-20020a05622a064700b003e3994898d1mr10992011qtb.38.1679751907344; Sat, 25 Mar 2023 06:45:07 -0700 (PDT) X-Received: by 2002:a05:622a:647:b0:3e3:9948:98d1 with SMTP id a7-20020a05622a064700b003e3994898d1mr10991982qtb.38.1679751907150; Sat, 25 Mar 2023 06:45:07 -0700 (PDT) Received: from dell-per740-01.7a2m.lab.eng.bos.redhat.com (nat-pool-bos-t.redhat.com. [66.187.233.206]) by smtp.gmail.com with ESMTPSA id h23-20020ac85497000000b003e3927a2cd8sm2528739qtq.3.2023.03.25.06.45.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 25 Mar 2023 06:45:06 -0700 (PDT) From: Tom Rix To: harry.wentland@amd.com, sunpeng.li@amd.com, Rodrigo.Siqueira@amd.com, alexander.deucher@amd.com, christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch, nathan@kernel.org, ndesaulniers@google.com, Jun.Lei@amd.com, wenjing.liu@amd.com, Jimmy.Kizito@amd.com, Cruise.Hung@amd.com Cc: amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, Tom Rix Subject: [PATCH] drm/amd/display: remove unused matching_stream_ptrs variable Date: Sat, 25 Mar 2023 09:45:03 -0400 Message-Id: <20230325134503.1335510-1-trix@redhat.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 X-Spam-Status: No, score=-0.2 required=5.0 tests=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,T_PDS_OTHER_BAD_TLD autolearn=unavailable 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1761348018582828574?= X-GMAIL-MSGID: =?utf-8?q?1761348018582828574?= clang with W=1 reports drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc_link_enc_cfg.c:625:6: error: variable 'matching_stream_ptrs' set but not used [-Werror,-Wunused-but-set-variable] int matching_stream_ptrs = 0; ^ This variable is not used so remove it. Signed-off-by: Tom Rix Reviewed-by: Nick Desaulniers --- drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) 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 41198c729d90..30c0644d4418 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 @@ -622,7 +622,6 @@ bool link_enc_cfg_validate(struct dc *dc, struct dc_state *state) int i, j; uint8_t valid_count = 0; uint8_t dig_stream_count = 0; - int matching_stream_ptrs = 0; int eng_ids_per_ep_id[MAX_PIPES] = {0}; int ep_ids_per_eng_id[MAX_PIPES] = {0}; int valid_bitmap = 0; @@ -645,9 +644,7 @@ bool link_enc_cfg_validate(struct dc *dc, struct dc_state *state) struct link_enc_assignment assignment = state->res_ctx.link_enc_cfg_ctx.link_enc_assignments[i]; if (assignment.valid) { - if (assignment.stream == state->streams[i]) - matching_stream_ptrs++; - else + if (assignment.stream != state->streams[i]) valid_stream_ptrs = false; } }