From patchwork Sun Feb 16 21:01:00 2025 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: 865548 Delivered-To: patch@linaro.org Received: by 2002:a5d:64e6:0:b0:38f:210b:807b with SMTP id g6csp828890wri; Sun, 16 Feb 2025 13:02:12 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCW52EQiQI/aeTpeYgLgSFRul9UACGbPaMKnofAU/KliLhs+Ot2kqPf9JT6Zp8SQ9lwKdaDUTg==@linaro.org X-Google-Smtp-Source: AGHT+IH3ll4S/TmsrfbUSaMxTDQXurjLzZwrWgS4G5RfeIdoCWHOpp0hlq6KTMxNPkYhdda80dkv X-Received: by 2002:a05:620a:3728:b0:7c0:5eea:a70f with SMTP id af79cd13be357-7c08aaccd4emr970186985a.58.1739739732659; Sun, 16 Feb 2025 13:02:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1739739732; cv=none; d=google.com; s=arc-20240605; b=Xdlhz9svn4qtLWg2FXjlYkZOp9nN2UfNoNIdnT9s2ZiySBNHOELT9lYEI6byAf1hxa cpfxrJH+UZsOX8XvTrVF/MlaJuXZ5wTTKQCAtil3/NuHKCCSuq9B3ShuYlHjMrU8laRM PShEpnDT4hHubU4wGVELHxnbpMB6a/Uic+TfqaSBD6dmISW7VyQ9gKH7t6zEgC3g/uD7 zwam16EsROYFXtPkYMsuct04Bb56lrzPWsBQMq24SHggM4ODyL2cI3C1CO2Xd/VkXnfR 9raz9DtexAN9/O9Evf6QfXEchbuFXr5qapdMRnuWDqLSF4MxzFOhYF+GV4Hp63LhSr4b MIdA== 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=f2SZToQUGAon9B+NPJXa9k1BqlC2qKJH86P1xDJbKio=; fh=qtn8prgQtzf5IzCNvLChUZDElvNECP6ej9YfjQeBz3I=; b=NjR8J42wh8bpVdqCAOocQGy171xTfFFEWFlht5P3ABTWJ2PcAftIjOC7wqt5aD6obN v8oaPGgKrjs8Fwd+Am+XLL9MxqamXLVagzN09O8VWtkOkSHVsB21JMyD8i2hwe+qZGab q2CtVOugVbxC6BHxtl/xRUk/ExDIEHCyWoWBEtme2BMlJreeSUaGpx7NE006Q/I/pJYT 31DTm0t14X4tyhQ9mndK11Yg6upsdfgHFiDgE9UFXQcRJLQv7trSZstuczg/Ks5q3NXg cTsQoOEAmiDfSorynnx8Tv4KDx/hiti/vc4+TUUVBXnAX2kceUGYqFIPz6T9DligRrdY ymTQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=MjPXibZr; 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 af79cd13be357-7c0964d321esi151758585a.535.2025.02.16.13.02.12 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sun, 16 Feb 2025 13:02:12 -0800 (PST) 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=MjPXibZr; 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 1tjllz-0003FU-Q2; Sun, 16 Feb 2025 16:01:58 -0500 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 1tjllu-00037x-KQ for qemu-devel@nongnu.org; Sun, 16 Feb 2025 16:01:50 -0500 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 1tjlls-0007wH-1C for qemu-devel@nongnu.org; Sun, 16 Feb 2025 16:01:49 -0500 Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-43963935585so36582625e9.0 for ; Sun, 16 Feb 2025 13:01:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1739739706; x=1740344506; 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=f2SZToQUGAon9B+NPJXa9k1BqlC2qKJH86P1xDJbKio=; b=MjPXibZrEzX6WvzpTo/cupGjFvP6w9YrsM4BJapAH8PHKk+Bp2lcnrv7cgsZCloXbF KHo5w18RJa/nzXjuY6AP2/bxtmQXqFXvvjL+fT6/DuIU7x0ctYABSKqUaFw3RS8KLI+P KkcgcfUnMbhbDincJ6fSeQFDQVzizHwWsgu20knyAo9XREmKdNNvgwRRKCgYbqYKH9Yn KE6RRbE63SLy7/zMBUB1D1TCHTbO/L3LWkdUmDtt9gn0DecUW8CDCTmUit/h8ooj6d68 tprYlYP2HxEMfeDkKnFyuQzAELQ4EOpTW77xYRmYwd1j0pjfU2AX+fm4hHq7X4G7cU3Y /qYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1739739706; x=1740344506; 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=f2SZToQUGAon9B+NPJXa9k1BqlC2qKJH86P1xDJbKio=; b=u3LLw3PYCAeAWPeZ/ZV+juUjoECCtAoKjsfaxNSRbBMK4AP4iPSVRRmDV4aTJZI0zI 5X6/qxT3Di2mj5IJNYGxG7QSY6bg38BU+NYfU0bPxTqXTwm74c6uK6pgmOyhAML0MkMv r/YRTCt56MBTZNgMxwkZrLLYY+FzCPz8X2hSCCIqnlOBt7AiMV3fTZCLr54dE0nDRdOC JI2c8agHGQgqJropWw+7psHIqZZ7MXJqhtEEZ2woZbNGRxp/TuCJCxiI0GK0hREFy/r5 atmdtyYVIY2LnvjsfM0cg/bC42EKhrNyGKI7S7pg7BB9lqnbGI8cFPx8+cm/otw/Rna2 MudQ== X-Gm-Message-State: AOJu0YzQooIeoDYs+UqQAwNLcYufHRpmmSF6L2TFQ9aAiFisFArWklQh NnRK6qCEXs/IUWJnfgHNfeMjItU05QvD4cu6UhWueNHo0/UFmyCmZ3VPgq3CPOQ2mpGL/0VWeBc uIXQ= X-Gm-Gg: ASbGncum9Z8wYOMRJwoNXv/aR7p6GQHLcTZ8aSKVp/e9nk1HThxmq2AV90uXsHnjga0 3/1QVhKfu1MDPvbgQirDPmbH9I6POS8eLERHmOtD+ap24mHySf2Lzh1CXfIeutHkvIU2fJNGC9A oRIqDdZ0ZTJshM2OI2UZT/V353k6uRlsIL2e84TGmTgV8KOpF/Jv16dfV097OOEoX/YrjvfcK5D v05Ii3YtY8wVjtap90g8e4tzTrpGwJyMK2q5zyVn2z3Y5ycEqIYgSFwIxvMkMgqLTb6QiLOryvp wLg33A5kPiwOqAximnrr5NSLvPAK67ShiQ/mP6bjhzPh2+vQ5B7Qb6aFGURmHTIDi17YljM= X-Received: by 2002:a05:600c:4711:b0:439:60ef:ce88 with SMTP id 5b1f17b1804b1-4396e710d27mr71142705e9.23.1739739706082; Sun, 16 Feb 2025 13:01:46 -0800 (PST) Received: from localhost.localdomain (88-187-86-199.subs.proxad.net. [88.187.86.199]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-439618264a3sm102167645e9.23.2025.02.16.13.01.44 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Sun, 16 Feb 2025 13:01:44 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Richard Henderson Subject: [PULL 36/39] hw/mips: Mark Boston machine devices as little-endian Date: Sun, 16 Feb 2025 22:01:00 +0100 Message-ID: <20250216210103.70235-9-philmd@linaro.org> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20250216210103.70235-1-philmd@linaro.org> References: <20250216210103.70235-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, 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org The Boston machine is only built as little-endian. Therefore the DEVICE_NATIVE_ENDIAN definition expand to DEVICE_LITTLE_ENDIAN (besides, the DEVICE_BIG_ENDIAN case isn't tested). Simplify directly using DEVICE_LITTLE_ENDIAN. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-Id: <20250212113938.38692-3-philmd@linaro.org> --- hw/mips/boston.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/mips/boston.c b/hw/mips/boston.c index 364c328032a..4690b254dda 100644 --- a/hw/mips/boston.c +++ b/hw/mips/boston.c @@ -220,7 +220,7 @@ static void boston_lcd_write(void *opaque, hwaddr addr, static const MemoryRegionOps boston_lcd_ops = { .read = boston_lcd_read, .write = boston_lcd_write, - .endianness = DEVICE_NATIVE_ENDIAN, + .endianness = DEVICE_LITTLE_ENDIAN, }; static uint64_t boston_platreg_read(void *opaque, hwaddr addr, @@ -299,7 +299,7 @@ static void boston_platreg_write(void *opaque, hwaddr addr, static const MemoryRegionOps boston_platreg_ops = { .read = boston_platreg_read, .write = boston_platreg_write, - .endianness = DEVICE_NATIVE_ENDIAN, + .endianness = DEVICE_LITTLE_ENDIAN, }; static void mips_boston_instance_init(Object *obj) @@ -758,7 +758,7 @@ static void boston_mach_init(MachineState *machine) s->uart = serial_mm_init(sys_mem, boston_memmap[BOSTON_UART].base, 2, get_cps_irq(&s->cps, 3), 10000000, - serial_hd(0), DEVICE_NATIVE_ENDIAN); + serial_hd(0), DEVICE_LITTLE_ENDIAN); lcd = g_new(MemoryRegion, 1); memory_region_init_io(lcd, NULL, &boston_lcd_ops, s, "boston-lcd", 0x8);