From patchwork Thu Feb 15 10:50:14 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: 772887 Delivered-To: patch@linaro.org Received: by 2002:adf:9dc2:0:b0:33b:4db1:f5b3 with SMTP id q2csp761172wre; Thu, 15 Feb 2024 02:51:01 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCXzy9agmzuGWkoUTAPA6roFYv28wH038kX6zHu6bWnIN5+yolpCrFGXcq7BqOFZRa5x4TnVFYqBPlhnijz8+E8o X-Google-Smtp-Source: AGHT+IHN4oAH7JmmH/CDSVu3uiAT20QFfyG5+cFhx5L+rTIaWOnBaWTLrjzcnG5OEanP9Tts+YcN X-Received: by 2002:ae9:e608:0:b0:787:1625:3312 with SMTP id z8-20020ae9e608000000b0078716253312mr1422965qkf.44.1707994261670; Thu, 15 Feb 2024 02:51:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1707994261; cv=none; d=google.com; s=arc-20160816; b=O0G7Ax5NqCWistgO2DCvj4bfqfwbJsU9ppFgmYwOwlLQ7Kaf11z4W7sSkKCqea/zvb bBDPz82f5Pw8Endg8duRlaRI1IXptEIz+zRVnhiKvUk7uk7KjTH04FWsGItY9x7Yud+B xKbLD8/56zhrH82q3JK9Axxea9JPvA/+9695oRsYJWcB9aw6QbJw+xIGy+4Fodu0Hl6V ZH/5XMf1t2kOEHhENZq4ZQYGUzMiueIktIgldyJoHMQhnESinnaIPR7sqNaprPQ+lyfq hATrfqF1LAmKvBc9AgMEFHdZIPmLHY7SAbv/8q0SpNP361N5x+KNp83wTVRgs0+obrgM PRhg== 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=VAFRh/EAl/HtsoAFF4atOhVIQ1s/gH8aym6XGe49VAg=; fh=A+lY13+jFVcdA8ecQ4hcAHs/x8ylQFF0oU/oe2DVPZ8=; b=J0VFLn9/izhpFTrvANo4BFYF9OBQRBaG+lWc0yWC4LL/6hsYUhW4JJu8MeIWlzhORE 2+l8Ry4z3jGkrPVOuI1wNr1oR8dWlZxATuNZl/8qNs1cycmtZLyRUqNEGynZ/abJWAxQ q3cw0fopPbkaaqypuJacI/HeYEd/jr9Eft5H5pQNVWWJXw2LtdvSz7aVSCmOlTBDP0ft Hq0qZSTO8dEhGfqDQr5mo81kXSYKgcr1JvEoZ8MevrALDc/buhixX8+fhp0nRCAQXPQZ XwAnFKLnTD/zojqm9fYiNtt0sK6vh2PJE5sc+BVpqM5H6kddjuhLMHG0xW005UrMzYcm dtWQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RZYCVcoK; 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 g7-20020a05620a218700b007872453d88bsi1209745qka.289.2024.02.15.02.51.01 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 15 Feb 2024 02:51:01 -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=RZYCVcoK; 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 1raZK9-0001su-Vv; Thu, 15 Feb 2024 05:50:38 -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 1raZK8-0001sW-8m for qemu-devel@nongnu.org; Thu, 15 Feb 2024 05:50:36 -0500 Received: from mail-ed1-x52f.google.com ([2a00:1450:4864:20::52f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1raZK6-0007ak-Gp for qemu-devel@nongnu.org; Thu, 15 Feb 2024 05:50:36 -0500 Received: by mail-ed1-x52f.google.com with SMTP id 4fb4d7f45d1cf-55f279dca99so1213662a12.3 for ; Thu, 15 Feb 2024 02:50:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707994233; x=1708599033; 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=VAFRh/EAl/HtsoAFF4atOhVIQ1s/gH8aym6XGe49VAg=; b=RZYCVcoKUk25g6ygDPRmTfYDjY6gFVAAaA2ZJ7O5NCm+UoSrDGq6RCequhtnasYoVx 0x3ulLOrtkZs4nIUMktDGlFenZplBklRJ+g6AGutENCtumRLxWHw6EpFbX3JHiwBoKN1 9LEtgrraz7q5t8JW7p5EvfC/t+weNQcwbl2NcJw/jQ+tUaqLZzQ/bRzSuA6ZZcKieM1u CCxQFLoacY+kDARDLeHqaWo8TYEokC0cBsgkrm9ehQEQC8vo5ecD+KwxPl1Ves/ip5t5 AqcJU/C++4dS7KJaQbEudcAkxohJjdtvNC1VN/+QbFf9sw5jFf8QK+24W9+QwePIbtiu PLqQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707994233; x=1708599033; 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=VAFRh/EAl/HtsoAFF4atOhVIQ1s/gH8aym6XGe49VAg=; b=c9U2Zy6wYwSRSkyeCema4dvyPH064tysoYe/eHj3CxrkPQid31rbk81oqlHumIPSQP Y0eueKZCr27Df6+NRqD6qHDvgzQ71o3t2zUyZymJA9bzlfeCddlh1j24oo2dmBPRjXP1 WHyS8e7P5VmMAd+IlpQTB48N8v9CMDbtgqTagddtMn0LpWD7RWgv/Un+bMLrjNEO2Xs9 34vpBevh4/pRf7ab0IrcZbwabAum+ATgC6NrqRGmH2/grl8sW0fc+pPmu9r0D6UQkB6d DKFv+ue/a5GfS93fXGr3JQZ/Ar7aK2aArxHTeX5z5g/WeRbjaKhwlNLblpIcwnBOOyFZ 4Y3w== X-Gm-Message-State: AOJu0YwK72YV77DjM9QaLUKLr0gWoDSmX5jAuE6p5CMY+qm7Lzkyjm6r yWoPIljST7hDTkO1PwIbP355U/p24dFvcm522py249zv0SsEW3t9qyyQdo6tCtt5nt7UJ1Zyka9 q/WM= X-Received: by 2002:aa7:d6cb:0:b0:561:123f:a98f with SMTP id x11-20020aa7d6cb000000b00561123fa98fmr916202edr.24.1707994232894; Thu, 15 Feb 2024 02:50:32 -0800 (PST) Received: from localhost.localdomain ([92.88.170.215]) by smtp.gmail.com with ESMTPSA id v20-20020aa7d9d4000000b00561fbfebdb5sm417338eds.96.2024.02.15.02.50.31 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Thu, 15 Feb 2024 02:50:32 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Paolo Bonzini , qemu-ppc@nongnu.org, =?utf-8?q?C?= =?utf-8?q?=C3=A9dric_Le_Goater?= , Nicholas Piggin , BALATON Zoltan , Daniel Henrique Barboza , Thomas Huth , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PATCH v3 2/4] hw/ppc/ppc4xx_pci: Extract PCI host definitions to hw/pci-host/ppc4xx.h Date: Thu, 15 Feb 2024 11:50:14 +0100 Message-ID: <20240215105017.57748-3-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20240215105017.57748-1-philmd@linaro.org> References: <20240215105017.57748-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::52f; envelope-from=philmd@linaro.org; helo=mail-ed1-x52f.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, T_SCC_BODY_TEXT_LINE=-0.01 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: BALATON Zoltan Reviewed-by: Thomas Huth Signed-off-by: Philippe Mathieu-Daudé --- MAINTAINERS | 1 + include/hw/pci-host/ppc4xx.h | 17 +++++++++++++++++ include/hw/ppc/ppc4xx.h | 5 ----- hw/ppc/ppc440_bamboo.c | 1 + hw/ppc/ppc440_pcix.c | 2 +- hw/ppc/ppc440_uc.c | 1 + hw/ppc/ppc4xx_pci.c | 2 +- hw/ppc/sam460ex.c | 1 + 8 files changed, 23 insertions(+), 7 deletions(-) create mode 100644 include/hw/pci-host/ppc4xx.h diff --git a/MAINTAINERS b/MAINTAINERS index a24c2b51b6..a9458121d9 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -2068,6 +2068,7 @@ F: hw/ppc/ppc4xx*.c F: hw/ppc/ppc440_uc.c F: hw/ppc/ppc440.h F: hw/i2c/ppc4xx_i2c.c +F: include/hw/pci-host/ppc4xx.h F: include/hw/ppc/ppc4xx.h F: include/hw/i2c/ppc4xx_i2c.h F: hw/intc/ppc-uic.c diff --git a/include/hw/pci-host/ppc4xx.h b/include/hw/pci-host/ppc4xx.h new file mode 100644 index 0000000000..32396417fc --- /dev/null +++ b/include/hw/pci-host/ppc4xx.h @@ -0,0 +1,17 @@ +/* + * QEMU PowerPC 4xx PCI-host definitions + * + * Copyright (c) 2018-2023 BALATON Zoltan + * + * SPDX-License-Identifier: GPL-2.0-or-later + */ + +#ifndef HW_PCIHOST_PPC4XX_H +#define HW_PCIHOST_PPC4XX_H + +#define TYPE_PPC4xx_HOST_BRIDGE "ppc4xx-host-bridge" +#define TYPE_PPC4xx_PCI_HOST "ppc4xx-pci-host" +#define TYPE_PPC440_PCIX_HOST "ppc440-pcix-host" +#define TYPE_PPC460EX_PCIE_HOST "ppc460ex-pcie-host" + +#endif diff --git a/include/hw/ppc/ppc4xx.h b/include/hw/ppc/ppc4xx.h index ea7740239b..1bd9b8821b 100644 --- a/include/hw/ppc/ppc4xx.h +++ b/include/hw/ppc/ppc4xx.h @@ -29,11 +29,6 @@ #include "exec/memory.h" #include "hw/sysbus.h" -#define TYPE_PPC4xx_HOST_BRIDGE "ppc4xx-host-bridge" -#define TYPE_PPC4xx_PCI_HOST "ppc4xx-pci-host" -#define TYPE_PPC440_PCIX_HOST "ppc440-pcix-host" -#define TYPE_PPC460EX_PCIE_HOST "ppc460ex-pcie-host" - /* * Generic DCR device */ diff --git a/hw/ppc/ppc440_bamboo.c b/hw/ppc/ppc440_bamboo.c index c75c3083e6..e18f57efce 100644 --- a/hw/ppc/ppc440_bamboo.c +++ b/hw/ppc/ppc440_bamboo.c @@ -24,6 +24,7 @@ #include "elf.h" #include "hw/char/serial.h" #include "hw/ppc/ppc.h" +#include "hw/pci-host/ppc4xx.h" #include "sysemu/sysemu.h" #include "sysemu/reset.h" #include "hw/sysbus.h" diff --git a/hw/ppc/ppc440_pcix.c b/hw/ppc/ppc440_pcix.c index d84418cb7b..1926ae2a27 100644 --- a/hw/ppc/ppc440_pcix.c +++ b/hw/ppc/ppc440_pcix.c @@ -25,7 +25,7 @@ #include "qemu/module.h" #include "qemu/units.h" #include "hw/irq.h" -#include "hw/ppc/ppc4xx.h" +#include "hw/pci-host/ppc4xx.h" #include "hw/pci/pci_device.h" #include "hw/pci/pci_host.h" #include "trace.h" diff --git a/hw/ppc/ppc440_uc.c b/hw/ppc/ppc440_uc.c index 7d6ca70387..1312aa2080 100644 --- a/hw/ppc/ppc440_uc.c +++ b/hw/ppc/ppc440_uc.c @@ -14,6 +14,7 @@ #include "qemu/log.h" #include "hw/irq.h" #include "hw/ppc/ppc4xx.h" +#include "hw/pci-host/ppc4xx.h" #include "hw/qdev-properties.h" #include "hw/pci/pci.h" #include "sysemu/reset.h" diff --git a/hw/ppc/ppc4xx_pci.c b/hw/ppc/ppc4xx_pci.c index e4101398c9..b6c6c8993c 100644 --- a/hw/ppc/ppc4xx_pci.c +++ b/hw/ppc/ppc4xx_pci.c @@ -24,7 +24,7 @@ #include "qemu/osdep.h" #include "qemu/log.h" #include "hw/irq.h" -#include "hw/ppc/ppc4xx.h" +#include "hw/pci-host/ppc4xx.h" #include "migration/vmstate.h" #include "qemu/module.h" #include "sysemu/reset.h" diff --git a/hw/ppc/sam460ex.c b/hw/ppc/sam460ex.c index 1e615b8d35..a28498f39c 100644 --- a/hw/ppc/sam460ex.c +++ b/hw/ppc/sam460ex.c @@ -25,6 +25,7 @@ #include "elf.h" #include "exec/memory.h" #include "ppc440.h" +#include "hw/pci-host/ppc4xx.h" #include "hw/block/flash.h" #include "sysemu/sysemu.h" #include "sysemu/reset.h"