{"id":2175691,"url":"http://patchwork.ozlabs.org/api/1.0/patches/2175691/?format=json","project":{"id":14,"url":"http://patchwork.ozlabs.org/api/1.0/projects/14/?format=json","name":"QEMU Development","link_name":"qemu-devel","list_id":"qemu-devel.nongnu.org","list_email":"qemu-devel@nongnu.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20251218181812.58363-5-philmd@linaro.org>","date":"2025-12-18T18:18:09","name":"[4/6] hw/timer/hpet: Mark implementation as being little-endian","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"cca65a0cc15060ffc8dcf2790d7f7661b36b74ae","submitter":{"id":85046,"url":"http://patchwork.ozlabs.org/api/1.0/people/85046/?format=json","name":"Philippe Mathieu-Daudé","email":"philmd@linaro.org"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/qemu-devel/patch/20251218181812.58363-5-philmd@linaro.org/mbox/","series":[{"id":485895,"url":"http://patchwork.ozlabs.org/api/1.0/series/485895/?format=json","date":"2025-12-18T18:18:07","name":"hw: Preparatory cleanups previous to remove DEVICE_NATIVE_ENDIAN","version":1,"mbox":"http://patchwork.ozlabs.org/series/485895/mbox/"}],"check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2175691/checks/","tags":{},"headers":{"Return-Path":"<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256\n header.s=google header.b=v33p0i4V;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org\n (client-ip=209.51.188.17; helo=lists.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)"],"Received":["from lists.gnu.org (lists.gnu.org [209.51.188.17])\n\t(using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4dXJr7059hz1xty\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 19 Dec 2025 05:20:39 +1100 (AEDT)","from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1vWIb1-0006YA-Ig; Thu, 18 Dec 2025 13:19:28 -0500","from eggs.gnu.org ([2001:470:142:3::10])\n by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1vWIaW-0006PD-72\n for qemu-devel@nongnu.org; Thu, 18 Dec 2025 13:19:03 -0500","from mail-wm1-x341.google.com ([2a00:1450:4864:20::341])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1vWIaQ-00031P-S1\n for qemu-devel@nongnu.org; Thu, 18 Dec 2025 13:18:55 -0500","by mail-wm1-x341.google.com with SMTP id\n 5b1f17b1804b1-477b5e0323bso11461425e9.0\n for <qemu-devel@nongnu.org>; Thu, 18 Dec 2025 10:18:46 -0800 (PST)","from localhost.localdomain (88-187-86-199.subs.proxad.net.\n [88.187.86.199]) by smtp.gmail.com with ESMTPSA id\n ffacd0b85a97d-4324eaa08efsm199771f8f.29.2025.12.18.10.18.42\n (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256);\n Thu, 18 Dec 2025 10:18:42 -0800 (PST)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1766081924; x=1766686724; darn=nongnu.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=Bvj1AJund8BJzCKIAsZJhSHjk28uN32H7UcwVRZ2KTY=;\n b=v33p0i4VKUWoTrO5d25jBdmpuJ/6wkvkpqkZpouGO52lZpi6RRDN3mPlsMxjhehcu5\n JXv+3BTR6qsS3Q+YXKOGNtY85jciKbHGbdYJEfTg8GqiJl9aGBpfc3wKj5GwlbKOnsvw\n FoDUOE/N2gD+lkMsquR279yJiloaNjZ0eOio5poMBokTxvtzUQCU9/ZW2AwZD2sFh+SX\n MTmaaRLVZCi3zHg2dE6ug+5TSEFJX71Nfb6H2cUDqjbkm9ptrv62S9oamIo+p/49OpV2\n vdhSDaKE52miIfGdOI5HhaUU/xYTBIBLpSkc+rfIyKf9wlF3inXo1kRB5Aze5DXGc10/\n HDuA==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20230601; t=1766081924; x=1766686724;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=Bvj1AJund8BJzCKIAsZJhSHjk28uN32H7UcwVRZ2KTY=;\n b=L2jr9pIPaBo0RrdctX6l/bkjcOAdMPwnyrR4vyCXqTMfAWpC5UUDE59/SvuRAxw9C8\n s2HQR3mgViZlGXt+c9G+ZqCnOq88T66zBVzkSQlgc3SZwdl6vuwe0KhylRPFM49O9esz\n gRt1n8eEbl61+fDBHYSDF9sSP9ZhP7Gu7ut9yoM3sLf5WVxG2/vlgx/9oFntx/FnO+6Q\n 1WxPeEQlSYA0wY6VsyKwqol+2K2YMFXdVIMRsqNfrKfxE0GmWTj2oJpb/S4/399ddLcU\n 9vpSnZNdz2zfQ5IaM7T4WueUAaHL7mibTw5S2uBTSaUmSCCA1CEQSSOFuLPNPSR0UAZm\n o/3w==","X-Gm-Message-State":"AOJu0YyPnrhAvEU/VltJ2buKOQk6wNUKoVWAxE2BU7AhBk4MnZrgJnDS\n EPjVM7A0chFoxY6nBplyxTUE/kUY00YkOrxDLz4VqSl1D0HDplQ4jK9EKo/beb6dRWnTLFfKB00\n cM6h+Kvo=","X-Gm-Gg":"AY/fxX6lcUHf9sawhAzGZz9/CylolwCvyWi58HiaAbs9yT5hcDrmTu6D2klH6XbYS5J\n vWZonrk5nvT57R5whWxW196/wNybPa7d8HL6qLBO763flPIKl2/pKSwyYidAkglP6xH5ZJk2Zzo\n 9ALNL+/htnyHD3epOZ6XiemzPBW0NsYHNEZIIWH3kQL8fMFLv+Rf9q6m449a7u4nX1HrXYCtSAi\n SAb01vL0JnlL+NkE6vcYG9aqhmBKf8KE/hL5WWSo6a/JvZCp5IvyB1YcAMDHNEiS9zWJZo7SAiF\n KeGe8qg/kUkxLXCZ5nFZxx91JuaF1WcAkkGoqmFJfZ0Lg0oIgkA3CKw5Zl077PBP8J207wsuT4T\n s8XRxyXuY4ibENdCEcUkZa4WIZWUmuk1fMTs4u7254P+bUBwbnsghvKtziJRlBLJfD1OCU24XWP\n 29iUnz7dXW65PPGu1LjDx2UetwOhNPcjA9P50+jwEKo+AFBwlWr1a517YzRFmD","X-Google-Smtp-Source":"\n AGHT+IHHuTTKYx9RGCYajCMCUuN820Kiap/GpFsIBYAXwUF34Sg0U5YEuJQg4DCduJdHoGUzZRCizQ==","X-Received":"by 2002:a05:6000:250d:b0:430:fa12:3b6e with SMTP id\n ffacd0b85a97d-432448bf55emr4584653f8f.24.1766081924100;\n Thu, 18 Dec 2025 10:18:44 -0800 (PST)","From":"=?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org>","To":"qemu-devel@nongnu.org","Cc":"Paolo Bonzini <pbonzini@redhat.com>,\n Peter Maydell <peter.maydell@linaro.org>, Jason Wang <jasowang@redhat.com>,\n \"Michael S. Tsirkin\" <mst@redhat.com>, Max Filippov <jcmvbkbc@gmail.com>,\n qemu-arm@nongnu.org, Manos Pitsidianakis <manos.pitsidianakis@linaro.org>,\n qemu-rust@nongnu.org,\n =?utf-8?q?Marc-Andr=C3=A9_Lureau?= <marcandre.lureau@redhat.com>,\n\t=?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org>","Subject":"[PATCH 4/6] hw/timer/hpet: Mark implementation as being little-endian","Date":"Thu, 18 Dec 2025 19:18:09 +0100","Message-ID":"<20251218181812.58363-5-philmd@linaro.org>","X-Mailer":"git-send-email 2.52.0","In-Reply-To":"<20251218181812.58363-1-philmd@linaro.org>","References":"<20251218181812.58363-1-philmd@linaro.org>","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Received-SPF":"pass client-ip=2a00:1450:4864:20::341;\n envelope-from=philmd@linaro.org; helo=mail-wm1-x341.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,\n DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,\n RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,\n SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no","X-Spam_action":"no action","X-BeenThere":"qemu-devel@nongnu.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<qemu-devel.nongnu.org>","List-Unsubscribe":"<https://lists.nongnu.org/mailman/options/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>","List-Archive":"<https://lists.nongnu.org/archive/html/qemu-devel>","List-Post":"<mailto:qemu-devel@nongnu.org>","List-Help":"<mailto:qemu-devel-request@nongnu.org?subject=help>","List-Subscribe":"<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=subscribe>","Errors-To":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org","Sender":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org"},"content":"The HPET component is only built / used by X86 targets, which\nare only built in little endianness. Thus we only ever built\nas little endian, never testing the big-endian possibility of\nthe DEVICE_NATIVE_ENDIAN definition. Simplify by only keeping\nthe little endian variant.\n\nSigned-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>\n---\n hw/timer/hpet.c                  | 2 +-\n rust/hw/timer/hpet/src/device.rs | 2 +-\n 2 files changed, 2 insertions(+), 2 deletions(-)","diff":"diff --git a/hw/timer/hpet.c b/hw/timer/hpet.c\nindex 1acba4fa9db..bfad626d5e1 100644\n--- a/hw/timer/hpet.c\n+++ b/hw/timer/hpet.c\n@@ -648,7 +648,7 @@ static const MemoryRegionOps hpet_ram_ops = {\n         .min_access_size = 4,\n         .max_access_size = 8,\n     },\n-    .endianness = DEVICE_NATIVE_ENDIAN,\n+    .endianness = DEVICE_LITTLE_ENDIAN,\n };\n \n static void hpet_reset(DeviceState *d)\ndiff --git a/rust/hw/timer/hpet/src/device.rs b/rust/hw/timer/hpet/src/device.rs\nindex 3564aa79c6e..4f4be84115e 100644\n--- a/rust/hw/timer/hpet/src/device.rs\n+++ b/rust/hw/timer/hpet/src/device.rs\n@@ -708,7 +708,7 @@ unsafe fn init(mut this: ParentInit<Self>) {\n             MemoryRegionOpsBuilder::<HPETState>::new()\n                 .read(&HPETState::read)\n                 .write(&HPETState::write)\n-                .native_endian()\n+                .little_endian()\n                 .valid_sizes(4, 8)\n                 .impl_sizes(4, 8)\n                 .build();\n","prefixes":["4/6"]}