Received: by 2002:a05:6359:6284:b0:131:369:b2a3 with SMTP id se4csp3315105rwb; Mon, 7 Aug 2023 11:23:39 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFZT/Fl/S4Aw/hMPcctV9CF1vCK/sP3gHZZPv1Q5sC8vkDuT6CZqTuaiWfzR5CZaXp/iC0K X-Received: by 2002:a17:90a:f690:b0:269:20b4:c5b8 with SMTP id cl16-20020a17090af69000b0026920b4c5b8mr7050389pjb.27.1691432619325; Mon, 07 Aug 2023 11:23:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691432619; cv=none; d=google.com; s=arc-20160816; b=AhH0DB/jDx9bb7fdOrseBGHZtnrV1YpdMr/5VQ1uEor/RMsOA9rjCOerS/EG33Ut/C esrn3YjGiQBbUn/BjVWUv9mRtOhLI46bzbisLF6+vwWujJ/j8zluF4kseiPk3aWoJMvM iK09lRpUJpfve/ul9/HI0ON3j4rCvB4NNgnNIpRUV609+HZFiRqVxoTs3wUE1TsNm84X PS2x29XXPDXK2nGKUsLme9/q7pGiPSBKtINttYzc2y27z3SKj+Ska8f882Z2mG2BauTH A+AUwfonoNVcS2si7PteFJA7wTizpCI3I/GGAPdz/vTrt2DWrts+tSEIkbb1oBVWLYFr M6UA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=0sPbbuQHjUxy7oDdnPJjchuEOxUnF5YIqG/ENh0PvEY=; fh=YwR8hmjC2QSif+72cT3/sIS32/1FMEJSAUJ+j+OuTzU=; b=Dx+d9gtTziR1xY6UXGEOQYhmwdJPGBop8HlO87d5rFyMpSWRQRKR66AV9+tLirkvGb P1de3dl3MFtsWEKPJRThWQHeghuh66/t2Cgna7lG0Tk91XfRAANrJwlFBG1NIkTaU5wb NsgiaIJ9eoj+ZxdtCvLLd5xnh76+wed7SqjuRk81dT3aE9KVSXEa5s9w7boEKqiMhFTA IzBki0JhRy6pPNe+j9M/YLh0ANYx6ZsJFc3DKHcIVvU97qaV3t5lGk2o49b/6RFuZBal Ekyjy/B4DuPbPCedHFDBD/wKEA9ENPR9kub24FhPC8yJUjOhSkbLI1pL1rJcO3ellqkt AiSg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=m2cV+Xgs; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t14-20020a170902e84e00b001bbc138af14si5997372plg.160.2023.08.07.11.23.27; Mon, 07 Aug 2023 11:23:39 -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=@gmail.com header.s=20221208 header.b=m2cV+Xgs; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229797AbjHGRB6 (ORCPT + 99 others); Mon, 7 Aug 2023 13:01:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37288 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229585AbjHGRB5 (ORCPT ); Mon, 7 Aug 2023 13:01:57 -0400 Received: from mail-oo1-xc32.google.com (mail-oo1-xc32.google.com [IPv6:2607:f8b0:4864:20::c32]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A84A499 for ; Mon, 7 Aug 2023 10:01:56 -0700 (PDT) Received: by mail-oo1-xc32.google.com with SMTP id 006d021491bc7-56ccdb2c7bbso3124081eaf.1 for ; Mon, 07 Aug 2023 10:01:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691427716; x=1692032516; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=0sPbbuQHjUxy7oDdnPJjchuEOxUnF5YIqG/ENh0PvEY=; b=m2cV+XgsH/1HSspbcpCMx+3r5uswy4jWSGM9tllwSpxcWEdFFaullwKWraLSzrdu9R sm4rdsKfU2pLAKdAL7bwbq42jsH+UbIOhoOgKCbEdrM2UWJOA7f3S9w30HyQHw97ikqj 06xYa2nUfu94x/XMPH2tIHbccwxFHP+pMi6VDOwh6XAIX2kRT25yUWsIvDlX+W4w7mB0 R+7zI3lEMUIhxvgqmkv2zoNai8VVgAea2KvSmOAqJGzBr0WIz/Ot0oeD1R99quCiyr4F 7/Ic98LILCIMDYJ3+Ph/DfrjsLELA9yWOX6BJQPJPQCMQQaIu4vtulz+988gXJO6eNpv zO4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691427716; x=1692032516; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0sPbbuQHjUxy7oDdnPJjchuEOxUnF5YIqG/ENh0PvEY=; b=hw8kgcN+oypR7JY2OvdHjXouksXjd9YHN+vEf2gB8M/yiFQbWdHl/QtIikc3Vv/Zrk eRRdbojxD0kKMraFylOfEmSseZ9OAwLk+BHluHhKRQ7EgTBimvRDAqyJYl5tW2uDgLiy HOVDF1QSs00Maf6SdFUvMiAm+r4ibbqSjJrUrXuO2PihwSbJCPCZh6BsO/uaB5f5RlvB PhULJdNY/a3y+5r2bQ8PHUhAaMRzCfpez3JQkV0RPFtgPLryURinD2C56W+56SGIBo0r Hn+rTF2RfA+U4VmkjqQw0+vXM63BORrLIwCUGuyjKyWb/hW/IbcZRmp12DzfyarnSeQH yyEA== X-Gm-Message-State: AOJu0Yz9uXaxglWrNuVLEWreiehVgHK+QlEFE8JprUzx0WoaFQPF4mv9 3mZA79cLjn8GzoPIWzqrxVCzIBKJUn4uWLTdBcY2PF66 X-Received: by 2002:a4a:6c5b:0:b0:56c:e928:2889 with SMTP id u27-20020a4a6c5b000000b0056ce9282889mr8692494oof.3.1691427715991; Mon, 07 Aug 2023 10:01:55 -0700 (PDT) MIME-Version: 1.0 References: <20230802020312.9233-1-sunran001@208suo.com> In-Reply-To: <20230802020312.9233-1-sunran001@208suo.com> From: Alex Deucher Date: Mon, 7 Aug 2023 13:01:45 -0400 Message-ID: Subject: Re: [PATCH] drm/amd/pm: Clean up errors in smu8_smumgr.h To: Ran Sun Cc: alexander.deucher@amd.com, dri-devel@lists.freedesktop.org, amd-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS 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: X-Mailing-List: linux-kernel@vger.kernel.org Need to be careful with these changes to make sure we aren't changing the size calculations somewhere. Alex On Tue, Aug 1, 2023 at 10:03=E2=80=AFPM Ran Sun wrot= e: > > Fix the following errors reported by checkpatch: > > ERROR: Use C99 flexible arrays > > Signed-off-by: Ran Sun > --- > drivers/gpu/drm/amd/pm/powerplay/smumgr/smu8_smumgr.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/amd/pm/powerplay/smumgr/smu8_smumgr.h b/driv= ers/gpu/drm/amd/pm/powerplay/smumgr/smu8_smumgr.h > index c7b61222d258..475ffcf743d2 100644 > --- a/drivers/gpu/drm/amd/pm/powerplay/smumgr/smu8_smumgr.h > +++ b/drivers/gpu/drm/amd/pm/powerplay/smumgr/smu8_smumgr.h > @@ -73,7 +73,7 @@ struct smu8_register_index_data_pair { > > struct smu8_ih_meta_data { > uint32_t command; > - struct smu8_register_index_data_pair register_index_value_pair[1]= ; > + struct smu8_register_index_data_pair register_index_value_pair[0]= ; > }; > > struct smu8_smumgr { > -- > 2.17.1 >