From nobody Sat Nov 23 22:48:42 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1730847191; cv=none; d=zohomail.com; s=zohoarc; b=TLroqk9eBTu0uY3B8f/hR0m0JPHWR4pIbfuugIe/MntLQRspnlYOJNABADhrNUdtPXWdN0J4SjMaxa0/XUnba8D4m6c/Pgx31ZodDpPQPh62Jil1Qj5Q7X/2Tq7CbC7nOWQdak+I2Tkn0O/bAgiLlTz5BsvG2LpOZzhTVr09kfg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1730847191; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=3LEHugE7mZCgdtSwZax7wqcEWyZpEObOLM8OQShnbTo=; b=cznsq7GoOoue9Lsjavx+bCgwDJdHJv5GgqnacBqADH4Mv2xFB+K1XK1DP83/jdTrA4BnMHwzzRRR5bosimgY/FhLFmAtgzmcxxCuxSZ5vGA4E1EP4U9UMpgZSCOFNIFLwLPoO9C1m79T0jyNhxFntPTaz1mCYvjiGxjh3nGwOUs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1730847191717552.7923361270339; Tue, 5 Nov 2024 14:53:11 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t8SLL-00058Y-Bm; Tue, 05 Nov 2024 17:48:11 -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 1t8SLB-00054E-9W for qemu-devel@nongnu.org; Tue, 05 Nov 2024 17:48:03 -0500 Received: from mail-wr1-x436.google.com ([2a00:1450:4864:20::436]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t8SL8-00049l-4q for qemu-devel@nongnu.org; Tue, 05 Nov 2024 17:48:00 -0500 Received: by mail-wr1-x436.google.com with SMTP id ffacd0b85a97d-37d808ae924so3353902f8f.0 for ; Tue, 05 Nov 2024 14:47:57 -0800 (PST) Received: from localhost.localdomain ([89.101.134.25]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-381c116b181sm17221812f8f.107.2024.11.05.14.47.55 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 05 Nov 2024 14:47:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1730846876; x=1731451676; 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=3LEHugE7mZCgdtSwZax7wqcEWyZpEObOLM8OQShnbTo=; b=ENi0W8YEzoo/it7UPJUl/pSfM/smuTMkmi/1MA4/Xf6ckP3qG+ARtsoM0wSThPjsyY WjX/BTCqV/ireBvjOiCf2g6o2F7FPDwQ+W8hS4lmWTzr8zot4PfQMZIBn96T6IHtS5/x R27e8IBXR+VwuUNRFoZeDzDRRMSyOw6ajL4RHcfAivK4laALYJ/fMIDYAj8Jj42QFhFD ifDK49t7xvQwoBPPEXVZ3hcPBZDlQGfV6o7ylxc0efb2TRH/9x5WNgQJJByHP0ZjfFMS 5T4xTFJ74qArmLQRslq9hfbc+W42rp5rGOK/moDhp5k5IGAOiWHagUVzRhmOZ+92OR4e zS5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730846876; x=1731451676; 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=3LEHugE7mZCgdtSwZax7wqcEWyZpEObOLM8OQShnbTo=; b=M+13MpP6t/u7ThPp47Ok/Y5I0tMREomKdh0HaBJIoeoudjzI/jwsdCagVb1LQEdiTr X8QvWSgWAPQ7CvqMwA24HkubjW2+ftRzK/6AzNVbnllMGc0+LJwRc9rJdksJ2OYHA2aK dsFDl3cqOJkaszjNYv8KV/fR8+pUIGJ8yJc31syz3D0Ol/Dr37/7jbxiOzrzvUbZVeLK dl1ywpBT3oAWZjZtFqkvZ4WXh5sO9nQJW1xZLO2ia36GClUkTOVmH0PPlnuatq54cTIf 3QC+mneyHT5QKUbVUsspi9tyVd8W+CIL8yeLJxEQYAF68Cja7KMmzwFSzKJI8RhimoB+ LlpA== X-Gm-Message-State: AOJu0YwiTnP218EzdQO44U5Dx6EgtzqwDPqYK5LJpixOrGix25GiRIc7 zXkDwRfz+hIn4hMtgaJ6mkeRn7dhjReqQc2DDmIJflYqZfVFFQ1WCwuXS+HBIe7It5z9c+p02gK zwOkd8g== X-Google-Smtp-Source: AGHT+IE3LcyMwk+41P/4VbRLJ8/i5lRJJokq8cblDLqdy520BlTmSPchWnTFG7B3BBIHTXInMxnz/w== X-Received: by 2002:a5d:5705:0:b0:37d:2e59:68ca with SMTP id ffacd0b85a97d-380611633f3mr25596560f8f.28.1730846876407; Tue, 05 Nov 2024 14:47:56 -0800 (PST) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Anton Johansson , Alistair Francis Subject: [PULL 05/29] hw/microblaze/s3adsp1800: Declare machine type using DEFINE_TYPES macro Date: Tue, 5 Nov 2024 22:47:03 +0000 Message-ID: <20241105224727.53059-6-philmd@linaro.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241105224727.53059-1-philmd@linaro.org> References: <20241105224727.53059-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::436; envelope-from=philmd@linaro.org; helo=mail-wr1-x436.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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1730847192018116600 Replace DEFINE_MACHINE() by DEFINE_TYPES(), converting the class_init() handler. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Anton Johansson Reviewed-by: Alistair Francis Message-Id: <20241105130431.22564-6-philmd@linaro.org> --- hw/microblaze/petalogix_s3adsp1800_mmu.c | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/hw/microblaze/petalogix_s3adsp1800_mmu.c b/hw/microblaze/petal= ogix_s3adsp1800_mmu.c index 581b0411e29..6c0f5c6c651 100644 --- a/hw/microblaze/petalogix_s3adsp1800_mmu.c +++ b/hw/microblaze/petalogix_s3adsp1800_mmu.c @@ -55,6 +55,9 @@ #define ETHLITE_IRQ 1 #define UARTLITE_IRQ 3 =20 +#define TYPE_PETALOGIX_S3ADSP1800_MACHINE \ + MACHINE_TYPE_NAME("petalogix-s3adsp1800") + static void petalogix_s3adsp1800_init(MachineState *machine) { @@ -132,11 +135,21 @@ petalogix_s3adsp1800_init(MachineState *machine) NULL); } =20 -static void petalogix_s3adsp1800_machine_init(MachineClass *mc) +static void petalogix_s3adsp1800_machine_class_init(ObjectClass *oc, void = *data) { + MachineClass *mc =3D MACHINE_CLASS(oc); + mc->desc =3D "PetaLogix linux refdesign for xilinx Spartan 3ADSP1800"; mc->init =3D petalogix_s3adsp1800_init; mc->is_default =3D true; } =20 -DEFINE_MACHINE("petalogix-s3adsp1800", petalogix_s3adsp1800_machine_init) +static const TypeInfo petalogix_s3adsp1800_machine_types[] =3D { + { + .name =3D TYPE_PETALOGIX_S3ADSP1800_MACHINE, + .parent =3D TYPE_MACHINE, + .class_init =3D petalogix_s3adsp1800_machine_class_init, + }, +}; + +DEFINE_TYPES(petalogix_s3adsp1800_machine_types) --=20 2.45.2