Message ID | 20250308190230.7508-3-philmd@linaro.org |
---|---|
State | Superseded |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a5d:64ce:0:b0:38f:210b:807b with SMTP id f14csp288431wri; Sat, 8 Mar 2025 11:05:26 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCWdZo/9bz57rFn++0XUW/vW8+l6VkzOsLG7A7E/toIAUmv/FeZcvH5pXA+F+v76vwgTsntNrw==@linaro.org X-Google-Smtp-Source: AGHT+IGnUoIQON3FovL71lDG337fBUVFqQ70tGefFjIDoD2IZVTFmUaStpduiL8eP5ge/UZb58T7 X-Received: by 2002:ad4:5806:0:b0:6e6:606b:a7be with SMTP id 6a1803df08f44-6e90067766bmr106967746d6.34.1741460726464; Sat, 08 Mar 2025 11:05:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1741460726; cv=none; d=google.com; s=arc-20240605; b=FhkQP0qkd+Sdi+JsvB/KZvlsrearvcdo4n6jfqsu++8ZT/IInsZ+cJKBc4TyY4apGV C8qhU7/apgYMFcIH10bDIuXBQ9AjxBEf2bhGCG3qt9HuyYZF2TrWZJUYRHkk7bwp1KZD 8rIXT54AcpbLbwZ3BkLZZkjPWW+UmNQSg830C/gyrUIPcb6QExcuoe17PrZDdnuFFJxt 1WfzwWbxJ5GpwkoXZlKRfYyG+PEo5Oyw/Q6NYahhwyKtYIJ8R6F2cl6JWfpF6H0nMAwn zRO1iQSp0KhPSKwBBhPRgq9LzJPCYVcuAN8n6sJk4jT/8hc9bUups7UBVbeo6DqNsHfe HPYg== 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=rGeGYkd/RvTeD7MNw4buaroHbkJmR8tAE2eHN3vxKfs=; fh=DS3W9RyuoVCBtn3AsFwCPBTMGD/N0zrnucneM0DLJCs=; b=GQijdrDYcAFgUNQuZnUoB9yADmGLN9dFYqQ8T/QfFcs9bJ17kn5iQ09ra2ro10GJto hYDOKpwbJ0glNvTZO1CDdKEEJMOZEj9rcwg17CjnnqwgftqxCAi5GS/XclPFehd/0Dv9 1I5X8cZbFD6QoT17txiCjXCMvbaNAZN3s5igiWIZlb676UgFKinTu7xSGdR5j9UPBqp/ BdEqEmatU6e2mZoP+xoLGpNCEQ5oNkdioUq6D+srPVfNch72Jk52VRpb0rGBg6IuIkhj Y+9xjHMSgj7jFRgnP27Dy1LdVGzPNUNq51VMJ6hppd2Jwp2RwCXVeLxd3Y7HfN7GzTaN Bxdg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=A1o1VRyd; 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: <qemu-devel-bounces+patch=linaro.org@nongnu.org> Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 6a1803df08f44-6e8f70950cfsi61488806d6.165.2025.03.08.11.05.26 for <patch@linaro.org> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 08 Mar 2025 11:05:26 -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=A1o1VRyd; 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 <qemu-devel-bounces@nongnu.org>) id 1tqzS1-00077n-UE; Sat, 08 Mar 2025 14:03:10 -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 <philmd@linaro.org>) id 1tqzRi-0006mH-Pk for qemu-devel@nongnu.org; Sat, 08 Mar 2025 14:02:52 -0500 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1tqzRc-0003VC-2C for qemu-devel@nongnu.org; Sat, 08 Mar 2025 14:02:46 -0500 Received: by mail-wr1-x431.google.com with SMTP id ffacd0b85a97d-3912fdddf8fso1382123f8f.1 for <qemu-devel@nongnu.org>; Sat, 08 Mar 2025 11:02:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1741460562; x=1742065362; 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=rGeGYkd/RvTeD7MNw4buaroHbkJmR8tAE2eHN3vxKfs=; b=A1o1VRydyRsDAzvzUxpEwF3ebPzNa409/VY2s7KvKS5rr9X/c7rtlaQpQ3Jqs8mUAU Ety96WWOgZ3iPCOY6vWg0nSrBGpqU4q8eGNKRubXJP8WrjxOEEqhAYGf1jwCSMdyNoEH 7BpB2zptxhuVbp8R7wtF+zPYGnDEwZSqxv/cKqLHnKOP+W0X3W+l8qr/oNSfjZ5BXAxR lDuWXQDSPBuXaxbUqdK/N+DSyVPm9IsMUw7WsHV1udbrasu9X9xBAOpSrFUh74ZIouon 2LU5p92TsfcgdqAmYQnCyfyOZGlUHsB82WCz9MQjUIJ7FKtVwzlY5/cp/4KepmMFUXH5 BayQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1741460562; x=1742065362; 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=rGeGYkd/RvTeD7MNw4buaroHbkJmR8tAE2eHN3vxKfs=; b=jubIEX3HzzkfrUdHfssI1BWD3ZN9YBvhcJRX0VAckGmeQAjzRbauI+hTNIiVMkrDrQ 5LA5mgxCqLfBevwsotuRotC6I+QokkMsUNnpmzndB/EfyB+Z783AMvOBecrv9jt+PH9Q 9L7LY9eBbBW9F5KedOfn2xsFaNUMr/CIyHu97vNmSVSWz6XUVrf2QWquIyottyX1MCB8 23kWG76wLv6l+LOYCMzdP7OzwS//bUaB6iNmMu5wr+gzYBYIwRmS25NUJRptdPLnQV6E /psbVc2vCLb6qrkWOQl3Q14foB7lFXdeZF2CF83P713IYhvJoSiyC8FfRwEkUzkQY/bn 9gcQ== X-Forwarded-Encrypted: i=1; AJvYcCXTUmSwkFKF9tv3e21o9oPyk1N7QjvNyycivTxHBlORQ9SXJcHq1Hdqz0mP4J4VYscYAaqF+FtUGdSj@nongnu.org X-Gm-Message-State: AOJu0YznfIylC4WPG37SIn3QxFfjiMbztN3uN1/u3vweY/c6STQrmoT8 bTDLU9jswMZJnNP+rQQXA5eb7Ukrt0vbfKhCHQJchVVj0c88zyQlje1dYxwXtqo= X-Gm-Gg: ASbGncscUuut7thAWcZ0jD2aUbWxuBsD73r5uq4PRSQ15hothGJ1+NEGxfwsEE9Ni0N SzNdHUZge6pddFiVNr+CWVaFvKgXYJ0MVmSNobHjP5A96AzZmRAXgo0/GzntWhTTpIakA2oDATy 07B5NHqrjYLkduKEEviqH4KM9aTBHc+/fXQ8wPgR6+5RQkkCodz/W+HvzG/plesmZDWGCltniFt 1SQBDHzyr5Ek+QNcoCgh79/nIte6Xm8BFnE3yQI977rrxufXIfkjKxOXafe4Hd2ShX6FPmz4NYn +zrjPgM6bKqwlXCHJYEEuO5KvQt/fTQqrX/Vd3clGCtzgSnPV+60KiQdVFQDyklkIrw1gLtYzUT n7X1n2UGSEhOtIMc6YqQ= X-Received: by 2002:a5d:6c6a:0:b0:38d:dc03:a3d6 with SMTP id ffacd0b85a97d-3913aed81aamr2276681f8f.4.1741460562232; Sat, 08 Mar 2025 11:02:42 -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-43ce9f2d081sm27971865e9.21.2025.03.08.11.02.41 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Sat, 08 Mar 2025 11:02:41 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org> To: BALATON Zoltan <balaton@eik.bme.hu>, qemu-devel@nongnu.org Cc: Bernhard Beschow <shentey@gmail.com>, Peter Maydell <peter.maydell@linaro.org>, qemu-ppc@nongnu.org, Andrey Smirnov <andrew.smirnov@gmail.com>, Jean-Christophe Dubois <jcd@tribudubois.net>, Bin Meng <bmeng.cn@gmail.com>, qemu-arm@nongnu.org, qemu-block@nongnu.org, Guenter Roeck <linux@roeck-us.net>, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org> Subject: [PATCH v3 02/12] hw/sd/sdhci: Introduce SDHCIClass stub Date: Sat, 8 Mar 2025 20:02:20 +0100 Message-ID: <20250308190230.7508-3-philmd@linaro.org> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20250308190230.7508-1-philmd@linaro.org> References: <20250308190230.7508-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::431; envelope-from=philmd@linaro.org; helo=mail-wr1-x431.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=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>, <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>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org |
Series |
hw/sd/sdhci: Set reset value of interrupt registers
|
expand
|
diff --git a/include/hw/sd/sdhci.h b/include/hw/sd/sdhci.h index 48247e9a20f..c4b20db3877 100644 --- a/include/hw/sd/sdhci.h +++ b/include/hw/sd/sdhci.h @@ -107,6 +107,13 @@ struct SDHCIState { }; typedef struct SDHCIState SDHCIState; +typedef struct SDHCIClass { + union { + PCIDeviceClass pci_parent_class; + SysBusDeviceClass sbd_parent_class; + }; +} SDHCIClass; + /* * Controller does not provide transfer-complete interrupt when not * busy. @@ -123,6 +130,8 @@ DECLARE_INSTANCE_CHECKER(SDHCIState, PCI_SDHCI, #define TYPE_SYSBUS_SDHCI "generic-sdhci" DECLARE_INSTANCE_CHECKER(SDHCIState, SYSBUS_SDHCI, TYPE_SYSBUS_SDHCI) +DECLARE_CLASS_CHECKERS(SDHCIClass, SYSBUS_SDHCI, + TYPE_SYSBUS_SDHCI) #define TYPE_IMX_USDHC "imx-usdhc" diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c index 149b748cbee..4917a9b3632 100644 --- a/hw/sd/sdhci.c +++ b/hw/sd/sdhci.c @@ -1960,6 +1960,7 @@ static const TypeInfo sdhci_types[] = { .instance_size = sizeof(SDHCIState), .instance_init = sdhci_sysbus_init, .instance_finalize = sdhci_sysbus_finalize, + .class_size = sizeof(SDHCIClass), .class_init = sdhci_sysbus_class_init, }, {
TYPE_SYSBUS_SDHCI is a bit odd because it uses an union to work with both SysBus / PCI parent. As this is not a normal use, introduce SDHCIClass in its own commit. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> --- include/hw/sd/sdhci.h | 9 +++++++++ hw/sd/sdhci.c | 1 + 2 files changed, 10 insertions(+)