Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 8130ECCF9E0 for ; Fri, 24 Oct 2025 19:12:25 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1vCNCp-0005se-Ah; Fri, 24 Oct 2025 15:12:07 -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 1vCNCn-0005rw-Pv for qemu-arm@nongnu.org; Fri, 24 Oct 2025 15:12:05 -0400 Received: from mail-wm1-x32d.google.com ([2a00:1450:4864:20::32d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1vCNCl-0006DQ-TB for qemu-arm@nongnu.org; Fri, 24 Oct 2025 15:12:05 -0400 Received: by mail-wm1-x32d.google.com with SMTP id 5b1f17b1804b1-4710665e7deso11835965e9.1 for ; Fri, 24 Oct 2025 12:12:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1761333122; x=1761937922; 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=khQ4f+JLpb7fh8Bk0A11QSSL3qpoF8Qk2ODQYUaP4ck=; b=ALG0TTGap+2fbqxReEqD73Rm+xljM/4kQC1p3bfSPq80OflGJXJ347XZdyByBrUCyP z8aYhOCh2SXFuI/FgMJfJOcQGqbg0VkECyL6VB+5yNba7NCDljv9UXxaUMV2M4x7SYLl 0FYHMwJ4lSPXkDP4rxwO67puYTYdY1obr2QeWVbcKwyJHQXObrh2ORXEjzpVZLBAjKbT MWNNHvI6gMjsDrOdqsCmCGWtPckBcrUOxlMmzdMu/E4mXmKHhgrLxLj/SfqpMxCWPp8N mhL41+YwznCMK2VLTQhraOLd5xtRC4FASB0vorqvn4paTLVAGN7/YRHo88WldAT6ieio NknA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1761333122; x=1761937922; 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=khQ4f+JLpb7fh8Bk0A11QSSL3qpoF8Qk2ODQYUaP4ck=; b=fdq96rK7y4azyUNO3xpeEF533tNYKXEwuOYzeEMR4e9U629eCts23V67pKFgdpu20r oUnKK8ZTUrIbyZS/9/upI0ImmQPjUsL713u4AqvWF3Bw/1fdYMj9XyXllErFbNbccTzI 8ciBZDa6WJCik30C9JGyJNyGcxTGVUIdKjGb+DN8NHMOOuyYYew1ONdRuMAq0seoH2Bk vRXFHRA8IjwhAfFtx8TIHisTc74uh2i836hW+AvZzigSHgawrCzEBM9SLUe99K+iNxDI ysuTsOXtVjPYCFjGNDGfm/3ZcF7ZBuF7iRts1TaWGIaEzRRE40CffkQJrcjqLVZTjsXk mCQw== X-Gm-Message-State: AOJu0YwHtiJxW3GBaFdmROcke2uyqJGJ5OWoeoZde+TWcZP6WXvOZXZd tUwLykNoNDQ2LVQcAjLkZ6L9hhlgOS/QDHI0ef3kdJnLQYHfJEWI3TGPA/BpD9m1DyP+0bfHEO1 DlB7xpdw= X-Gm-Gg: ASbGncs/ZLu5e3S9jRjDIqWIR8rttE3dRMJd5OLPlAKuKr9Ru44fDI4Wnbtxr5ANdMl kMQvdqRud19Pk+m/bTkeqb5pkL9/tjpMNnb+vn3T7gfTMtLtlfpTJhIzWJZorXhTwddKZxWAxC7 MWh+61TN6Co15joQv1z+q6dOz/eI1NMwsAemeAY06oLDI1heD+wmUbgIryL4tXGPv/6rzd44ghU VXYRWRee2JeU1dhQlbaXcDRnH1nR7YZ5Jol1cmSTuHC0Hb2p51CMnJZlBqR/oMMPYQHL0aTFp9C TyzPlrRceI/5M1QkjbcHHA0WpHuYFyrNF+1cKcuwTGKkf6C+KAQ1rCWNXLa5lJWTDf1Xf0G8cso awaYMa0yuo+Sq6l05Jaqb2dhQPibB6rR9CLwy2tEpPhUe3HR6xfP7IPycOd2onQCpmMOS6+zmpi ewuKCAJdgEt2GupDkH+E9aZiDybiOTCS+XDFZpCOZBhKhTNHZM+rh9Vc3CR1Aa3TtKeABaCzs= X-Google-Smtp-Source: AGHT+IHv4l1XosmJ+AbMe81Cl8qn4LTSeuXJyvjLUOdckWaUg/XuRfICJNFoWIyYFbUOLQVYHPdHwQ== X-Received: by 2002:a05:600c:4f09:b0:471:a73:9c49 with SMTP id 5b1f17b1804b1-475caf930dfmr70530855e9.2.1761333121675; Fri, 24 Oct 2025 12:12:01 -0700 (PDT) Received: from localhost.localdomain (88-187-86-199.subs.proxad.net. [88.187.86.199]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-475caf15b10sm123156845e9.11.2025.10.24.12.12.00 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Fri, 24 Oct 2025 12:12:00 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: qemu-arm@nongnu.org, qemu-riscv@nongnu.org, qemu-block@nongnu.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , "Michael S. Tsirkin" , Paolo Bonzini Subject: [PATCH 05/27] hw/timer/hpet: Use proper SysBus accessors Date: Fri, 24 Oct 2025 21:03:52 +0200 Message-ID: <20251024190416.8803-6-philmd@linaro.org> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20251024190416.8803-1-philmd@linaro.org> References: <20251024190416.8803-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::32d; envelope-from=philmd@linaro.org; helo=mail-wm1-x32d.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-arm@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-arm-bounces+qemu-arm=archiver.kernel.org@nongnu.org Sender: qemu-arm-bounces+qemu-arm=archiver.kernel.org@nongnu.org SysBusDevice::mmio[] is kind of internal. Use the proper sysbus_mmio_get_region() accessor. Signed-off-by: Philippe Mathieu-Daudé --- hw/timer/hpet.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/timer/hpet.c b/hw/timer/hpet.c index 1acba4fa9db..4ed79d72620 100644 --- a/hw/timer/hpet.c +++ b/hw/timer/hpet.c @@ -655,6 +655,7 @@ static void hpet_reset(DeviceState *d) { HPETState *s = HPET(d); SysBusDevice *sbd = SYS_BUS_DEVICE(d); + MemoryRegion *mr = sysbus_mmio_get_region(sbd, 0); int i; for (i = 0; i < s->num_timers; i++) { @@ -677,7 +678,7 @@ static void hpet_reset(DeviceState *d) s->hpet_offset = 0ULL; s->config = 0ULL; hpet_fw_cfg.hpet[s->hpet_id].event_timer_block_id = (uint32_t)s->capability; - hpet_fw_cfg.hpet[s->hpet_id].address = sbd->mmio[0].addr; + hpet_fw_cfg.hpet[s->hpet_id].address = mr->addr; /* to document that the RTC lowers its output on reset as well */ s->rtc_irq_level = 0; -- 2.51.0