From patchwork Mon Sep 30 09:11:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 831541 Delivered-To: patch@linaro.org Received: by 2002:a5d:66c8:0:b0:367:895a:4699 with SMTP id k8csp1852357wrw; Mon, 30 Sep 2024 02:13:41 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCX/t2hMthOTuxI1hO4cqD92EqJVeffbF0MNYV2WM19WDL3ViPwJOESlD6gKlD6fmhQ8XLxjSA==@linaro.org X-Google-Smtp-Source: AGHT+IF80AU8gGQW2zwEyATsBMJX/eXmDOc19Q7DEZLyHGlyLoBHHByvUHRSNGjU6W7c7Mjj/KMc X-Received: by 2002:a05:620a:4514:b0:7a9:ac57:ff58 with SMTP id af79cd13be357-7ae378558a2mr1871165285a.37.1727687620795; Mon, 30 Sep 2024 02:13:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1727687620; cv=none; d=google.com; s=arc-20240605; b=gpJfKuupfYdKtC6Q2vp6TUChU3cgElTxMudZLokVSoIeimjmKB2+hL4QT0swDx0SJX woQc1LXD4sv40Qe+Y5lLSAu+ZId2RaumAfJMGroC+IFs/+1++fu50zaNYKkIPEyn1KKN ms96kh9XP3DsD74oWU+z25YvurYWhRuAxgWPuxhqBAD9tYNLCBa3nltRxf2Nd/NoCQGS gre14mdBCf2kcqgF95PRG2Jnq5Khj83zMNjC940FEc7f6a+XL33gPJ7h+4aEdPJvpbcA 6z60jBNqZY5KMJZ1qsSIlyPdRfDml34UX8TpPRWREUmOGxC0PsPHCzBcN+Rv/JSL2yOL LA9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=EToKFctF2fRtYpb52soo3m8yr83BCZf/5mioMKUv2bg=; fh=k5rVqKUsbd8Y0L3bPWUhjMmTdbpOHX+if6Hlm9il+vc=; b=MglBITcIUs0eZGkHNUGD04syGVrJdtmbINMdb3Jfpbzy5oBDO4MQ98t/iopwvUZ2fg 3L5T9Lpvl3o8oCtIvRZDvPBI9U4XyuiYclPylxA6vS6ImB8pJ6AXctPDXD/EVTjO88QD e7J3snxFnukFv/6yzV0UP4AuVf8QOmWL1SLRQEcmnBLIrjUUTi584N0Dn+D1z7msP00G gZcHsDL971pmcBpM6UTmSa4h8ZbeLxqokpmPZORSuwRnJDW0DoGXufGataeVDQ+xc3SW nQw6SOfhFP/TnBH95lkru/GRSCY2Gfq7CXNZqGznP9gR+3AGQ27VKdSjZzYvDmafoTLD 17DQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=L8Y6AQHh; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d75a77b69052e-45c9f28f7a7si81563211cf.5.2024.09.30.02.13.40 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 30 Sep 2024 02:13:40 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=L8Y6AQHh; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1svCSM-00052h-Ku; Mon, 30 Sep 2024 05:12: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 1svCSK-0004kY-Cq for qemu-devel@nongnu.org; Mon, 30 Sep 2024 05:12:36 -0400 Received: from mail-wm1-x335.google.com ([2a00:1450:4864:20::335]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1svCSI-0004gh-OW for qemu-devel@nongnu.org; Mon, 30 Sep 2024 05:12:36 -0400 Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-42cb9a0c300so31647385e9.0 for ; Mon, 30 Sep 2024 02:12:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1727687552; x=1728292352; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=EToKFctF2fRtYpb52soo3m8yr83BCZf/5mioMKUv2bg=; b=L8Y6AQHh799tW7TKo2t/YZQ6SB+Lso2wVe0mPLV/Sd0F8axe6JRotPqm59lcmIafbb 8bAawoc4VP9mnRR36YGpmhVdZZnZ7uq8ToxUuYO+bTdoOGhnaRt800mWZ8+3E2Kh/E1e tAw+C6RGKZZToC4wP0dPR+/C8CZR1CXoOyfJjUm6DFHNJgAXnzC4jZBxm6jj7pJUgy+6 CfZrnfy5Pxm47doyGLLjCV8Fy4z8JZS+A7GhINQBo6mWQxFL0nMaSe0tAZxmt8G4VSEt zpUeH7MvkkPOYzf/zv21bt47Por2ZYLvmcN0zjRsGVKTskKT6BE5xv8WdSy8TyLcU7UN KwtA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1727687552; x=1728292352; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=EToKFctF2fRtYpb52soo3m8yr83BCZf/5mioMKUv2bg=; b=qskFoFVlTZum36JgkutnO3K2RdlyyZG1qslzXsBs5cWvs/eR3aMOq1U4ZbPKWzMf2G drLHUUEXqhNpWzSSsxtMVZqteY4q9GbWy8zRCjTXx4SxYLfFFzzAybA/qwUcFEwV5EZ+ dQDk5h8Kvnwrw5f3qxqCTa0Cobq9HG4/KlPZG51EwUECZKFZHi9xRgdWfX9YxXS7zvAW KkNt6bYlXvzOmvYqKrPvoD+rznSKA/UDmy3uPNqf7dXRDGykCXyURZ7vPZ39Cc/dR+P4 xbT9Z3ToBMtXM44zSUlPlcsYn7v0FI+jdjx8+s/Y5uR9RuFsVdOYKFd7shp0UKG1OKsU U/Cg== X-Gm-Message-State: AOJu0Yzr45Pn3bD7H/8yowpbb9HOa0PJvN7H8BMY68PTzVkBIDbjmVet XeB7Z73WUAs7rKohh3MAQtKDo5vvQ+H9aaREzxECrXklr8I3L32X87MTuaoB05+oqwAnIRls6Qg A X-Received: by 2002:a05:600c:4751:b0:42c:de9b:a1b5 with SMTP id 5b1f17b1804b1-42f5849732amr77291775e9.32.1727687552382; Mon, 30 Sep 2024 02:12:32 -0700 (PDT) Received: from localhost.localdomain (183.red-88-28-18.dynamicip.rima-tde.net. [88.28.18.183]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42e96a52915sm144727645e9.39.2024.09.30.02.12.30 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 30 Sep 2024 02:12:31 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Thomas Huth , Aurelien Jarno , =?utf-8?q?Herv=C3=A9_Poussineau?= , =?utf-8?q?Philipp?= =?utf-8?q?e_Mathieu-Daud=C3=A9?= , Richard Henderson , Jiaxun Yang , Aleksandar Rikalo , Huacai Chen , Anton Johansson Subject: [PATCH 12/12] hw/mips/malta: Remove TARGET_BIG_ENDIAN #ifdef'ry Date: Mon, 30 Sep 2024 11:11:01 +0200 Message-ID: <20240930091101.40591-13-philmd@linaro.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240930091101.40591-1-philmd@linaro.org> References: <20240930091101.40591-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::335; envelope-from=philmd@linaro.org; helo=mail-wm1-x335.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, 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Move code evaluation from preprocessor to compiler so the if() ladder is always processed. Mostly to unify style in not using TARGET_BIG_ENDIAN #ifdef anymore. Signed-off-by: Philippe Mathieu-Daudé --- hw/mips/malta.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/hw/mips/malta.c b/hw/mips/malta.c index 71cc11fc45..a3b6f63089 100644 --- a/hw/mips/malta.c +++ b/hw/mips/malta.c @@ -1196,8 +1196,7 @@ void mips_malta_init(MachineState *machine) * In little endian mode the 32bit words in the bios are swapped, * a neat trick which allows bi-endian firmware. */ -#if !TARGET_BIG_ENDIAN - { + if (!TARGET_BIG_ENDIAN) { uint32_t *end, *addr; const size_t swapsize = MIN(bios_size, 0x3e0000); addr = rom_ptr(FLASH_ADDRESS, swapsize); @@ -1210,7 +1209,6 @@ void mips_malta_init(MachineState *machine) addr++; } } -#endif } /*