From nobody Tue Feb 10 00:59:15 2026 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=reject dis=none) header.from=fb.com ARC-Seal: i=1; a=rsa-sha256; t=1630104143; cv=none; d=zohomail.com; s=zohoarc; b=Hd8doPfQMHTL4Hx3gmttIWC6gLaHSfhHlayl0Nxi1cXh/8EQegJlFL1JEBuvtUyB+iWhffe2lk9TqvVQgD474rMyifsH+iRTMbY4Zj634v/XKh0TW6jrX2YOlUakerjR1RyJ0XcOrDF4dbivH675HHueG0OcDtrx7APsHH3tS6k= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1630104143; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject; bh=/loIWSp6B85T8RoaS4kqWMLnn9oXmwg9e4FVG1PWIgU=; b=Ps7KPXLavKthYT1co4LUfxU8GZNn2at4IrK2eJv+uji+ecDDo6mMciQMQbnzQE1kixgqRUSoxIbUJH+CPXocU+BJR6Jfan3twATIA3yDxLioqZA1ecA2Yx+zgsp4BvB38OMF6eqkNpSrcw7ThYYhFohL/IT1iSFJ9WPRwoanHP4= 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=reject dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1630104143838376.38639167502606; Fri, 27 Aug 2021 15:42:23 -0700 (PDT) Received: from localhost ([::1]:50932 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mJkYI-00051V-Qo for importer@patchew.org; Fri, 27 Aug 2021 18:42:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59548) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mJj3T-0006Wo-BS for qemu-devel@nongnu.org; Fri, 27 Aug 2021 17:06:28 -0400 Received: from mx0a-00082601.pphosted.com ([67.231.145.42]:34358) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mJj3O-0003DU-D0 for qemu-devel@nongnu.org; Fri, 27 Aug 2021 17:06:25 -0400 Received: from pps.filterd (m0109333.ppops.net [127.0.0.1]) by mx0a-00082601.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 17RL6Kpp032656 for ; Fri, 27 Aug 2021 14:06:20 -0700 Received: from mail.thefacebook.com ([163.114.132.120]) by mx0a-00082601.pphosted.com with ESMTP id 3apfpfrk0q-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 27 Aug 2021 14:06:20 -0700 Received: from intmgw001.27.prn2.facebook.com (2620:10d:c085:108::4) by mail.thefacebook.com (2620:10d:c085:11d::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Fri, 27 Aug 2021 14:06:11 -0700 Received: by devvm660.prn0.facebook.com (Postfix, from userid 385188) id 3056DE74C04; Fri, 27 Aug 2021 14:06:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : content-type; s=facebook; bh=/loIWSp6B85T8RoaS4kqWMLnn9oXmwg9e4FVG1PWIgU=; b=q3o0hOR0Ktm5lnAgSyLGFu1whrBSsfOpEocZjbOUTLGRKZlEoFL7Ga+KAPKT1oGw3loO N6aHGlshNB06P9TyeWcl8zgxSQkCpMdinRCl7GXs5Y8TVCaC1kvhureyY4Nbv0b3Hgfc /+2/nrJVJTVFuobnA5OE3uj9qxbCz67eBg8= From: To: CC: , , , , Peter Delevoryas Subject: [PATCH 1/5] hw/arm/aspeed: Add get_irq to AspeedSoCClass Date: Fri, 27 Aug 2021 14:04:13 -0700 Message-ID: <20210827210417.4022054-2-pdel@fb.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210827210417.4022054-1-pdel@fb.com> References: <20210827210417.4022054-1-pdel@fb.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-FB-Internal: Safe X-FB-Source: Intern X-Proofpoint-ORIG-GUID: j8RUzjmtdN7J_TqglAgIDRHA59u2GZQs X-Proofpoint-GUID: j8RUzjmtdN7J_TqglAgIDRHA59u2GZQs X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391, 18.0.790 definitions=2021-08-27_06:2021-08-27, 2021-08-27 signatures=0 X-Proofpoint-Spam-Details: rule=fb_default_notspam policy=fb_default score=0 phishscore=0 suspectscore=0 clxscore=1015 bulkscore=0 mlxlogscore=999 priorityscore=1501 impostorscore=0 adultscore=0 lowpriorityscore=0 spamscore=0 mlxscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2107140000 definitions=main-2108270125 X-FB-Internal: deliver 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=67.231.145.42; envelope-from=prvs=78736a82b9=pdel@fb.com; helo=mx0a-00082601.pphosted.com X-Spam_score_int: -34 X-Spam_score: -3.5 X-Spam_bar: --- X-Spam_report: (-3.5 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.743, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Fri, 27 Aug 2021 18:37:43 -0400 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 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" X-ZohoMail-DKIM: pass (identity @fb.com) X-ZM-MESSAGEID: 1630104144814100001 Content-Type: text/plain; charset="utf-8" From: Peter Delevoryas The AST2500 uses different logic than the AST2600 for getting IRQ's. This adds a virtual `get_irq` function to the Aspeed SOC class, so that the shared initialization code in `hw/arm/aspeed.c` can retrieve IRQ's. Signed-off-by: Peter Delevoryas --- hw/arm/aspeed_ast2600.c | 1 + hw/arm/aspeed_soc.c | 1 + include/hw/arm/aspeed_soc.h | 1 + 3 files changed, 3 insertions(+) diff --git a/hw/arm/aspeed_ast2600.c b/hw/arm/aspeed_ast2600.c index e3013128c6..56e1adb343 100644 --- a/hw/arm/aspeed_ast2600.c +++ b/hw/arm/aspeed_ast2600.c @@ -527,6 +527,7 @@ static void aspeed_soc_ast2600_class_init(ObjectClass *= oc, void *data) sc->irqmap =3D aspeed_soc_ast2600_irqmap; sc->memmap =3D aspeed_soc_ast2600_memmap; sc->num_cpus =3D 2; + sc->get_irq =3D aspeed_soc_get_irq; } =20 static const TypeInfo aspeed_soc_ast2600_type_info =3D { diff --git a/hw/arm/aspeed_soc.c b/hw/arm/aspeed_soc.c index 3ad6c56fa9..c373182299 100644 --- a/hw/arm/aspeed_soc.c +++ b/hw/arm/aspeed_soc.c @@ -476,6 +476,7 @@ static void aspeed_soc_ast2400_class_init(ObjectClass *= oc, void *data) sc->irqmap =3D aspeed_soc_ast2400_irqmap; sc->memmap =3D aspeed_soc_ast2400_memmap; sc->num_cpus =3D 1; + sc->get_irq =3D aspeed_soc_get_irq; } =20 static const TypeInfo aspeed_soc_ast2400_type_info =3D { diff --git a/include/hw/arm/aspeed_soc.h b/include/hw/arm/aspeed_soc.h index d9161d26d6..ca16e1e383 100644 --- a/include/hw/arm/aspeed_soc.h +++ b/include/hw/arm/aspeed_soc.h @@ -84,6 +84,7 @@ struct AspeedSoCClass { const int *irqmap; const hwaddr *memmap; uint32_t num_cpus; + qemu_irq (*get_irq)(AspeedSoCState *s, int ctrl); }; =20 =20 --=20 2.30.2