From patchwork Fri Feb 10 16:37:43 2023 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: 652351 Delivered-To: patch@linaro.org Received: by 2002:adf:f90f:0:0:0:0:0 with SMTP id b15csp1060187wrr; Fri, 10 Feb 2023 08:40:11 -0800 (PST) X-Google-Smtp-Source: AK7set/SXPLtfANWwcIc1Z5K7jBrX5b+wpXFjNNHNEWX6xaUGyVuBfrXV3L0+8C+2BaUQnucyBo9 X-Received: by 2002:a05:622a:d2:b0:3b6:2b39:4373 with SMTP id p18-20020a05622a00d200b003b62b394373mr25139067qtw.23.1676047210860; Fri, 10 Feb 2023 08:40:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676047210; cv=none; d=google.com; s=arc-20160816; b=0DwCkFng3V/dI3MG362J+0haXWvn8k6LEzj4Nm4Y3ZZJBj/q2Sh9rPnTBgREmquHHE LbksJoosA70u+q+1VD7vMz8a+mM/B2VPuQc8sKXIJ40LGpLc5vnCnjCgCe9WGg5dq80/ lmJlnmcFxG9N+SlG3CPHQPL/ldPQmh3ZLt7nKH2J1eRtzkftLzoTFvgwCtzx2uQ0UYZw jCDTO5JZEjBrxiv4YcOC+hMhjegIx08u59EdmHmLjLLsM6OVf0rJnnSQLvE8JDmwVEWJ +GB78GkKUGPGs2uWbh0EO+wlCo8Ql77LT/ridtU5lmvJB7Ox/GvLZqQUoA3FCQzjMOHh Jq3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; 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=YoHT59j3PIEbNQgJjg9OB8ZAxg8LDaeoLJEvNKTWr5M=; b=kDN6bnYj9y5qUhXxWQw1U+wzQiRf+RLQoQopDE9jbd4BHv3k5KfdECncHyUPnsJvOQ tZJ0FgoXX82wfrv5othxbJdNUcTwPMAFocsnY/ulsIDqfwkCnmwn2QCH1zuEwHaxRI56 fZbfT7slGxpqrJbIJV+XSDTmny6Ig+rcG79vlTIHapFl1m9ZikMkoDIugFIQCY5KQ0wL O/lui5tSRPhU40ZumV3qI4LXZLs/KHIymisCBzvAsYPuE8HfaNmfUQUjI1nvjtX4y9Ho BNpQOR0t5K1liL3cKqo/zvn/Wnl96Oa9l4EutB9lXAJvOwBygiaQvl/mkKRxf/sw+sbR IL2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RJoxFnL0; 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 Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id f9-20020ac859c9000000b003b9a411a972si3941852qtf.547.2023.02.10.08.40.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 10 Feb 2023 08:40:10 -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=RJoxFnL0; 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 Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pQWQL-0002Nw-Ia; Fri, 10 Feb 2023 11:38:57 -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 1pQWQD-0001ih-1E for qemu-devel@nongnu.org; Fri, 10 Feb 2023 11:38:49 -0500 Received: from mail-wr1-x42a.google.com ([2a00:1450:4864:20::42a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pQWQ4-0000G0-4V for qemu-devel@nongnu.org; Fri, 10 Feb 2023 11:38:42 -0500 Received: by mail-wr1-x42a.google.com with SMTP id o15so2321590wrc.9 for ; Fri, 10 Feb 2023 08:38:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; 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=YoHT59j3PIEbNQgJjg9OB8ZAxg8LDaeoLJEvNKTWr5M=; b=RJoxFnL0XsRpjQueoM/BiLfGNgDKnkzHECga3h6hdsHDbcxkSPL18g6p3QjWhJkY7C Vur4IzZxjtUXBqgOa6igkmngsr3WAVi+8qXGtQT3LG1qPYNmsziCWQALnkEIT+cgzDmN 0c2FQ/ZmoSZT7572TifeIa4joU9QssrjLqcD4OykuaGfHf9GWkRd7dHox5W596TLUtjC noPyCquajhwa63361h4ITMucScL1AW6y6yTq5Bs104Ae37TjFWITqKKXHRFUU2DrLZSS 8ctjmpipHEsE16JwwiAPrky3K0AIS/3PAVJyK4LR8PocLjLsvc+kE5YI++58w0XBodu5 gukQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=YoHT59j3PIEbNQgJjg9OB8ZAxg8LDaeoLJEvNKTWr5M=; b=CqisFN6MM0EexOB3cKKPVqhpleh1qSWUfIj3VFNEzCXvd2bOfW19+XADd/Zr41qfYu anl7DbPprZ4bAirpxIh25cMqSxS9OUJt8ul0Hmhsype6PU2xSqh7Cy5TcaV3e/tSRrcO zWjA+Is1/kkr1LaRfh53zfi4hVlKjG21C4DPQV6jadxprg2ynBzhAC5wlSq63oosjLBR 7Yv/pRODQJWjN7CaE97ELum90NV8D3L+u3/sdNAx0fvRoRL9kr0r2mgoG7pnOZep/W5r vAQcQ9i3VGNNEIic/vfcNBHXUWOJlSAaSac7OalnA+hjAUw9QgGRFBcOnH0h2g8cnEN+ mfrw== X-Gm-Message-State: AO0yUKX2dzBctbvHxjkPte+iap+FQ4Un5udkC5uTGTUWomjYisB0ogNE oRy/gA60jDKJA9+iiA5Imxt4WNbFJFHBmLEh X-Received: by 2002:a05:6000:1811:b0:2c5:4b17:166 with SMTP id m17-20020a056000181100b002c54b170166mr1888960wrh.48.1676047116584; Fri, 10 Feb 2023 08:38:36 -0800 (PST) Received: from localhost.localdomain ([81.0.6.76]) by smtp.gmail.com with ESMTPSA id i8-20020a5d4388000000b002c5493a17efsm2023496wrq.25.2023.02.10.08.38.35 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Fri, 10 Feb 2023 08:38:36 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Thomas Huth , Sergio Lopez , Richard Henderson , qemu-ppc@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PATCH 10/11] hw/isa: Use isa_address_space_io() to reduce access on global 'isabus' Date: Fri, 10 Feb 2023 17:37:43 +0100 Message-Id: <20230210163744.32182-11-philmd@linaro.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230210163744.32182-1-philmd@linaro.org> References: <20230210163744.32182-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42a; envelope-from=philmd@linaro.org; helo=mail-wr1-x42a.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 Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- hw/isa/isa-bus.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/isa/isa-bus.c b/hw/isa/isa-bus.c index d19826f96e..d12973103f 100644 --- a/hw/isa/isa-bus.c +++ b/hw/isa/isa-bus.c @@ -114,7 +114,7 @@ static inline void isa_init_ioport(ISADevice *dev, uint16_t ioport) void isa_register_ioport(ISADevice *dev, MemoryRegion *io, uint16_t start) { - memory_region_add_subregion(isabus->address_space_io, start, io); + memory_region_add_subregion(isa_address_space_io(dev), start, io); isa_init_ioport(dev, start); } @@ -133,7 +133,7 @@ int isa_register_portio_list(ISADevice *dev, isa_init_ioport(dev, start); portio_list_register(piolist, OBJECT(dev), pio_start, opaque, name, - isabus->address_space_io, start); + isa_address_space_io(dev), start); return 0; }