From nobody Wed Nov 27 20:29:57 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1696843310; cv=none; d=zohomail.com; s=zohoarc; b=R/luhBLozqCdyCO2ay+ZbJ8fgWV7Lyc5qtUyY07MYwPc2rVEjs7WFY3PAiGBA+1u+LACOEqAh3wmdJKLwXFNgIQwFh6B+JF7+RS9eVrCwjiPTysD5CaY1pwkKWd2tjDBYr+RvtgartCP40w40CQzRaFujndSNoCjUqBWNgQaoRM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1696843310; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=DkY2Js0F8feI+eDewmK7f1DkRmkJTMBbTxH6PGU0fdY=; b=ZuWCcbB72Q3XHKJ0NrWfYZPSpK6+ZBIcxjs9XRiVbd8M3oC8Kf4eDtjvrSlauRqn1vGYnjGZEyvaRT7BnNdJ0gX2C7gP1BqZm1mh2LTEC3HaSN5WwzZSRcHanMYNspCrQreZA+WQIz6d/yLxJeYsxDx+R5185IE3m084O4GX50Y= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1696843310442956.987434247349; Mon, 9 Oct 2023 02:21:50 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qpmSI-0007sh-4t; Mon, 09 Oct 2023 05:21:38 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qpmSE-0007rl-9Y for qemu-devel@nongnu.org; Mon, 09 Oct 2023 05:21:35 -0400 Received: from mail-ed1-x52e.google.com ([2a00:1450:4864:20::52e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qpmSC-00018s-Lm for qemu-devel@nongnu.org; Mon, 09 Oct 2023 05:21:34 -0400 Received: by mail-ed1-x52e.google.com with SMTP id 4fb4d7f45d1cf-5334f9a56f6so7360990a12.3 for ; Mon, 09 Oct 2023 02:21:31 -0700 (PDT) Received: from m1x-phil.lan (thr44-h01-176-170-217-185.dsl.sta.abo.bbox.fr. [176.170.217.185]) by smtp.gmail.com with ESMTPSA id z21-20020aa7d415000000b005361a6da384sm5895820edq.19.2023.10.09.02.21.28 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 09 Oct 2023 02:21:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1696843290; x=1697448090; darn=nongnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=DkY2Js0F8feI+eDewmK7f1DkRmkJTMBbTxH6PGU0fdY=; b=L/N9Aiv3JaGMHuzrKQZs7uMmh4T3z+QjmlrmJW/WDI36DjDb6bzj52q6eR+KZ/iGBw 2xaWu3qPV4E2hLpDbheHmBaqHYuaWNgyvzQWk8RbUyd5ybnz7ZbbERrkm7x/LpMeUSjc TmDEOk7Xpn7AkAX41cxlLFu6yYGijkl6b89kfzkWXIqiVQNMuY/T+H2o7pZC4Ec83n5C 8vhiHGpUhSguuHTARmRWSfkI9mjSp1/er3GKkv2WxL/lbHGJEpvMLzqex9xuwh6eyxYq g5Y3zj6/y0g2AuC2SPwmiIMirV8oKijiH9iVBBXw8eOYF1UMFdnTYEAuCtNojA+hUDMc nFqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696843290; x=1697448090; 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=DkY2Js0F8feI+eDewmK7f1DkRmkJTMBbTxH6PGU0fdY=; b=ReIT5euKJemBJ91FLBVLomlvW5XFVTna80VFFOHvXA1hfRRFojURmTTJZ0z8/mSpaz h0L5qRswSGAXxLig5NEGNhPkLL1QQXFZP/P2qaTTM58sXekf1AsQU4EDjPrj9+B1JyFT 143E+1R9b47G5Rcbpz38TUp3KPw10ANximZArXfFeSQUjkeZQf5KV18LIwU8PeiJifes TBBPa9q2fGIrMqGSNeS8FpjymFilyLs0Aj8yLWHInJt4Qs7Ngqr3VapM2D4gHvmv7A5c sso3vo3IJ1ptN12AvhCR9r7HvJ5Qww/kUTNO9AqbaZWzRnKe1LDfoLsyFur0YOw0RJXc NVOA== X-Gm-Message-State: AOJu0YwkjTaVSh530BVBZGqNO+NlNOj+AbBy+/t1t/BWpwnZUoryEU5v Vy2mNHdHjalVwDLtGxqzVWj1TiCZIv82Lg4fpIU= X-Google-Smtp-Source: AGHT+IFd0BpmX/PHPE7PbyRs+oZjMI3xTiPondbYmegxdnwGD0M/q/kv9lu8oIcPcgg4cn9cwxCnpg== X-Received: by 2002:aa7:d9d9:0:b0:538:8949:9e02 with SMTP id v25-20020aa7d9d9000000b0053889499e02mr13807053eds.30.1696843290015; Mon, 09 Oct 2023 02:21:30 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Aurelien Jarno , Corey Minyard , Jiaxun Yang , BALATON Zoltan Subject: [PATCH] hw/mips/malta: Use sdram_type enum from 'hw/i2c/smbus_eeprom.h' Date: Mon, 9 Oct 2023 11:21:27 +0200 Message-ID: <20231009092127.49778-1-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::52e; envelope-from=philmd@linaro.org; helo=mail-ed1-x52e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1696843312361100003 Since commit 93198b6cad ("i2c: Split smbus into parts") the SDRAM types are enumerated as sdram_type in "hw/i2c/smbus_eeprom.h". Using the enum removes this global shadow warning: hw/mips/malta.c:209:12: error: declaration shadows a variable in the glob= al scope [-Werror,-Wshadow] enum { SDR =3D 0x4, DDR2 =3D 0x8 } type; ^ include/hw/i2c/smbus_eeprom.h:33:19: note: previous declaration is here enum sdram_type { SDR =3D 0x4, DDR =3D 0x7, DDR2 =3D 0x8 }; ^ Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: BALATON Zoltan Reviewed-by: Richard Henderson --- hw/mips/malta.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/mips/malta.c b/hw/mips/malta.c index dac27fad9d..62d04ed113 100644 --- a/hw/mips/malta.c +++ b/hw/mips/malta.c @@ -206,7 +206,7 @@ static eeprom24c0x_t spd_eeprom =3D { =20 static void generate_eeprom_spd(uint8_t *eeprom, ram_addr_t ram_size) { - enum { SDR =3D 0x4, DDR2 =3D 0x8 } type; + enum sdram_type type; uint8_t *spd =3D spd_eeprom.contents; uint8_t nbanks =3D 0; uint16_t density =3D 0; --=20 2.41.0