From patchwork Sat Mar 1 17:20:43 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brian Cain X-Patchwork-Id: 13997634 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AA92AC282CD for ; Sat, 1 Mar 2025 17:22:21 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1toQWe-0003Ca-6I; Sat, 01 Mar 2025 12:21:20 -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 1toQWO-0003A6-IS for qemu-devel@nongnu.org; Sat, 01 Mar 2025 12:21:06 -0500 Received: from mx0a-0031df01.pphosted.com ([205.220.168.131]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1toQWM-0008Rl-Ly for qemu-devel@nongnu.org; Sat, 01 Mar 2025 12:21:04 -0500 Received: from pps.filterd (m0279867.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 521FU2sE019495 for ; Sat, 1 Mar 2025 17:21:01 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= oowa8xzNbisARaR2AAsHXbMLYCEW7CydVAB/AuyNvzg=; b=RI+8mF4jk2AoTEIH KQENK7pS+pINXa94dLA81Ci50KcoPqTkUP+Iw410ce6Le7BTuwAHK7yZMZ8m60tX ySo3t1Uk3hEYN+vGvoME9fLSU3EX3IWda9NLcYmrtSm95rObdI0yie1FAmCiiM/u EuIV1lZz4N95VLNZn0/q2UrkLusa26GwsWZYMDCS5aodnSDzGz6VpaLJ37zQf2gv Sj0hNHz+pOEKvK3GsW5CEIGjgw8gRPswRJfwfC8HCSUb7a/GUNbm9vdd/qXsvce/ rXbBPCvy+q8gxcqYQxgmric+t/FTgQPssF5YVzNk3/fc2lQPOpA2u8S29ljaovAh iSe3cA== Received: from mail-pj1-f69.google.com (mail-pj1-f69.google.com [209.85.216.69]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 453t6k1478-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sat, 01 Mar 2025 17:21:01 +0000 (GMT) Received: by mail-pj1-f69.google.com with SMTP id 98e67ed59e1d1-2fecd603bb8so2069930a91.3 for ; Sat, 01 Mar 2025 09:21:01 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1740849660; x=1741454460; 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=oowa8xzNbisARaR2AAsHXbMLYCEW7CydVAB/AuyNvzg=; b=eUW293nIoBLyQWSv43Re8fLB6K2b7MI4HlApnaabiS1BUP2QT7XpH0Od879tJctIi+ EN42re1wyJfbXGZrMnE4DqOxemQXMWwMAH9+KcktgnO3xCd4Kr6OgQUirRt5qswrim4S 3whqJBR42HUGefwOrB+r+++Yzq5BDBDkkNEe3Rku0ZhyZlzjS1tUhVrB46R+b1WiBJTc qPRoCGmowCmz29ujIEG+M8yq+IaCW4LqrrtOU46uVJ08BtpsOemSXEr/GW8gy/JiZiTp GcuPWLr4Sh1Wy4JXjPTD8HSVUG7flftwDYTdbPFcK3lOHOYeZ0/eNDf27Ml7vWIfxK1Q 2V9w== X-Gm-Message-State: AOJu0Yz1VAnkHMWSmDkJS1ht+2Ps4ZNWtcgA8093KdDaEoxYBbjmR0sM TfIxT+GbK7Qm4S0CSX4SEMnKbg5yfZO8fCzUFtsIHA2L3FUwyzxXTf9ue+jm8i+98dSd7ezRYzh wMbXLTkUK32BjXawqwlNrrQO076OIRpPhQH9PVrqmjpL15WKhet9ffe4gPmvYpg== X-Gm-Gg: ASbGnctsnPetne/mZgrYSDzsySnKT7unN5wA54AsJ/Ab86ouqNy6HqGhhdEwM2qyCsA IRbRlDUa9pPOryRrDE0T/1nkAsvkxl2gSu5J1HTOGCFDIJg3VjoaK+WqWDJSdprwwxnWBzjHPqp naIqOqCDgn2PrZozRzl4kTsJyvVnej1Wd9O5daLnFWaeEU26O85+p2k8u9x6sXkGwp40dCbzmoR 5rpV2OkmU8GYyUtKR+XeN3SvyKXp7ekh7TdkdXGb7Om1+Ttt/O2ZcZ2Kvq+p9otwn3eUdLmiqFM bscEi/CXCrm6+qOo4UDgwAvAinL50EtpBS8dQcKwsJNP0YrBL148uT/CzIlyL8Be X-Received: by 2002:a17:90b:4acb:b0:2ee:e518:c1cb with SMTP id 98e67ed59e1d1-2febab2ed94mr13301142a91.7.1740849660122; Sat, 01 Mar 2025 09:21:00 -0800 (PST) X-Google-Smtp-Source: AGHT+IHsFOQuVIv52osRMr2gU5oL5hhftm62jjmjvQlRBDSHVqzFnRKLU0Q0KvNZpoaKRVWMLqXUkw== X-Received: by 2002:a17:90b:4acb:b0:2ee:e518:c1cb with SMTP id 98e67ed59e1d1-2febab2ed94mr13301108a91.7.1740849659687; Sat, 01 Mar 2025 09:20:59 -0800 (PST) Received: from hu-bcain-lv.qualcomm.com (Global_NAT1.qualcomm.com. [129.46.96.20]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-223501f9dacsm51308275ad.83.2025.03.01.09.20.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 01 Mar 2025 09:20:59 -0800 (PST) From: Brian Cain To: qemu-devel@nongnu.org Cc: brian.cain@oss.qualcomm.com, richard.henderson@linaro.org, philmd@linaro.org, quic_mathbern@quicinc.com, ale@rev.ng, anjo@rev.ng, quic_mliebel@quicinc.com, ltaylorsimpson@gmail.com, alex.bennee@linaro.org, quic_mburton@quicinc.com, sidneym@quicinc.com, Paolo Bonzini Subject: [PATCH 6/8] target/hexagon: add build config for softmmu Date: Sat, 1 Mar 2025 09:20:43 -0800 Message-Id: <20250301172045.1295412-7-brian.cain@oss.qualcomm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250301172045.1295412-1-brian.cain@oss.qualcomm.com> References: <20250301172045.1295412-1-brian.cain@oss.qualcomm.com> MIME-Version: 1.0 X-Proofpoint-GUID: 7REFEGQyfTS8CKpaDqCUe-maZo8gDQZi X-Proofpoint-ORIG-GUID: 7REFEGQyfTS8CKpaDqCUe-maZo8gDQZi X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1057,Hydra:6.0.680,FMLib:17.12.68.34 definitions=2025-03-01_07,2025-02-28_01,2024-11-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 impostorscore=0 priorityscore=1501 bulkscore=0 mlxlogscore=869 mlxscore=0 lowpriorityscore=0 clxscore=1015 spamscore=0 malwarescore=0 adultscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2502100000 definitions=main-2503010139 Received-SPF: pass client-ip=205.220.168.131; envelope-from=brian.cain@oss.qualcomm.com; helo=mx0a-0031df01.pphosted.com X-Spam_score_int: -26 X-Spam_score: -2.7 X-Spam_bar: -- X-Spam_report: (-2.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, 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+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Signed-off-by: Brian Cain --- MAINTAINERS | 1 + configs/devices/hexagon-softmmu/default.mak | 7 +++++++ configs/targets/hexagon-softmmu.mak | 6 ++++++ target/Kconfig | 1 + target/hexagon/Kconfig | 2 ++ target/hexagon/meson.build | 9 +++++++++ 6 files changed, 26 insertions(+) create mode 100644 configs/devices/hexagon-softmmu/default.mak create mode 100644 configs/targets/hexagon-softmmu.mak create mode 100644 target/hexagon/Kconfig diff --git a/MAINTAINERS b/MAINTAINERS index 0fb5711184..deeb7878c8 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -241,6 +241,7 @@ F: linux-user/hexagon/ F: tests/tcg/hexagon/ F: disas/hexagon.c F: configs/targets/hexagon-linux-user/default.mak +F: configs/devices/hexagon-softmmu/default.mak F: docker/dockerfiles/debian-hexagon-cross.docker F: gdb-xml/hexagon*.xml F: docs/system/target-hexagon.rst diff --git a/configs/devices/hexagon-softmmu/default.mak b/configs/devices/hexagon-softmmu/default.mak new file mode 100644 index 0000000000..08e709aea7 --- /dev/null +++ b/configs/devices/hexagon-softmmu/default.mak @@ -0,0 +1,7 @@ +# Default configuration for hexagon-softmmu + +# Uncomment the following lines to disable these optional devices: + +# Boards are selected by default, uncomment to keep out of the build. +# CONFIG_HEX_DSP=y +# CONFIG_L2VIC=y diff --git a/configs/targets/hexagon-softmmu.mak b/configs/targets/hexagon-softmmu.mak new file mode 100644 index 0000000000..8c208bf468 --- /dev/null +++ b/configs/targets/hexagon-softmmu.mak @@ -0,0 +1,6 @@ +# Default configuration for hexagon-softmmu + +TARGET_ARCH=hexagon +TARGET_SUPPORTS_MTTCG=y +TARGET_XML_FILES=gdb-xml/hexagon-core.xml gdb-xml/hexagon-hvx.xml gdb-xml/hexagon-sys.xml +TARGET_LONG_BITS=32 diff --git a/target/Kconfig b/target/Kconfig index d0c7b59d9c..37781146b9 100644 --- a/target/Kconfig +++ b/target/Kconfig @@ -16,6 +16,7 @@ source sh4/Kconfig source sparc/Kconfig source tricore/Kconfig source xtensa/Kconfig +source hexagon/Kconfig config TARGET_BIG_ENDIAN bool diff --git a/target/hexagon/Kconfig b/target/hexagon/Kconfig new file mode 100644 index 0000000000..7e556f3506 --- /dev/null +++ b/target/hexagon/Kconfig @@ -0,0 +1,2 @@ +config HEXAGON + bool diff --git a/target/hexagon/meson.build b/target/hexagon/meson.build index aa729a3683..d2b56b9e65 100644 --- a/target/hexagon/meson.build +++ b/target/hexagon/meson.build @@ -245,6 +245,7 @@ decodetree_trans_funcs_generated = custom_target( command: [python, files('gen_trans_funcs.py'), semantics_generated, '@OUTPUT@'], ) hexagon_ss.add(decodetree_trans_funcs_generated) +hexagon_softmmu_ss = ss.source_set() hexagon_ss.add(files( 'cpu.c', @@ -264,6 +265,13 @@ hexagon_ss.add(files( 'mmvec/system_ext_mmvec.c', )) +hexagon_softmmu_ss.add(files( + 'hex_mmu.c', + 'hex_interrupts.c', + 'hexswi.c', + 'machine.c', +)) + # # Step 4.5 # We use flex/bison based idef-parser to generate TCG code for a lot @@ -401,3 +409,4 @@ analyze_funcs_generated = custom_target( hexagon_ss.add(analyze_funcs_generated) target_arch += {'hexagon': hexagon_ss} +target_system_arch += {'hexagon': hexagon_softmmu_ss}