From patchwork Wed Apr 10 09:10:53 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?Q2zDqW1lbnQgTMOpZ2Vy?= X-Patchwork-Id: 13623920 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 9A8E9CD11C2 for ; Wed, 10 Apr 2024 09:11:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=9V+axbbwj7bjbbOCaNr0tUMoJjvkcRsVYOobblwF7rA=; b=YF/Vo58msgK1Dn YKihFysG1TRZfF6dd553WDkJqAWkllzgHyZm4P/1fsTrRFFIgkSmNErtKVw3Z4AMDVJL513CfWLJB 8WWY6Z3qfhYLHYNWJyOeK9pLFrrWtWKrkx3juhhWivXPoPaa27pvpHL89lrB1n1khNbW8tlbbRoy3 scsMmlL4b7Fb01zWVJ+Nult4NiT80cHGeyKix+jM275gX0xUiPu/0ly0F+yWF6hoJ/SEd1TVqAMcw bkwyZMfpj9hAG79JCx9XY+2S29hcFyFseECcuxo+kOPrGBh73I1R6PkFanqLEtN8LyvW17GjnYere 98+Mfi3YP/XOzIQpOUPw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1ruTzF-0000000639v-0nGX; Wed, 10 Apr 2024 09:11:21 +0000 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1ruTz7-00000006326-1czC for linux-riscv@lists.infradead.org; Wed, 10 Apr 2024 09:11:15 +0000 Received: by mail-wr1-x42c.google.com with SMTP id ffacd0b85a97d-345606e8ac0so589022f8f.0 for ; Wed, 10 Apr 2024 02:11:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1712740270; x=1713345070; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=9SSkPjIJRaiY6nqvP2nXREr1dqNKWljAWGAyK7z7Oro=; b=bSe7kzegkFEedB6L12hakcSAV8DJUNN9JmtTqaoq7wM6D3G/YCpZtQ0NheVq1ukeAa u+7hWu77A/FqTue0tAuh2JBA/3YcLjaQ4Zf6QElulYJy8kSGcGT6rNtMiyG45H9sd5Sc bFAcWFu7PQk7mAV6wZaD/8NpVgzrm1OEZO5psEi6BO+qrmEQS32VIXUPhGF2bSDWYEiP qjMAm2VjMydFnVPyxanwiyQkN/mMmc/Dn7C2qwESI2zPG/bw2BLnHYnuAzGcgQoBN1n2 8fOhoPRRlkANEchTXx7FUT9b0g+yovN9cDjPCGTohNQMVkWE2mwRThPix4lLGUZJZ/jj DZgg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712740270; x=1713345070; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=9SSkPjIJRaiY6nqvP2nXREr1dqNKWljAWGAyK7z7Oro=; b=puRNeK7OT4wOfqtwjF730PUBWXtxpPib+3hxycqLNvSrWgkNuD8RgfMBXLsazc9dxZ tqHBxBFyHiwhdHuSq7ImfMsLUXq3MHAVasMHb9ow9hyPag+K/rRaWSk8+Tc6d7m3UBY2 YZNLHCZrc/yn81BEdCA/ZeE8Y29RcjNssRNUXYue6cDrfI5sU8KV2aThdvUdO0kxQ93n ecJyD+tha23TgPkRG+3Rt7ztZSi0cqrZRaSX34YDL/X6jNK2+HTwayH4pdbgE2F9jIcV ThUea+wtxhoeOwWJ46d0ih8kd2D4uYznYkDwsWf/MvF5pJaGhcQQ481eGr1l3mKkngzw mhZA== X-Forwarded-Encrypted: i=1; AJvYcCUV89+rmDwmBH8ar+iLT69us5NNJ6iammmld0FQrzDoRXyqFV1IftqHKOEictel2UkUWQtPjq21VPjzTa4OwUEbnqX7jGYZCT4aqjVwMT5y X-Gm-Message-State: AOJu0Yy+ASJD+7oLaFax7ysr9uqnzJo2yT9aLrVO5uH034nL8bLFR9Pj LihBpQFL7nSlUZYnsWrP5s5HPVg6Zn+q2woGAs2D49KCaBHW+ltQA+HoMJIY3V0= X-Google-Smtp-Source: AGHT+IGq6GULyAjPCGB9cLzSRwOlrzNIJikNMv8sgGSqEmo6q9aRp4LbhqVra1QQcW7xHav631ZdHA== X-Received: by 2002:a5d:4a52:0:b0:346:500f:9297 with SMTP id v18-20020a5d4a52000000b00346500f9297mr1449075wrs.2.1712740270397; Wed, 10 Apr 2024 02:11:10 -0700 (PDT) Received: from carbon-x1.. ([2a01:e0a:999:a3a0:d4a6:5856:3e6c:3dff]) by smtp.gmail.com with ESMTPSA id d6-20020a056000114600b003456c693fa4sm9079086wrx.93.2024.04.10.02.11.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Apr 2024 02:11:09 -0700 (PDT) From: =?utf-8?b?Q2zDqW1lbnQgTMOpZ2Vy?= To: Jonathan Corbet , Paul Walmsley , Palmer Dabbelt , Albert Ou , Conor Dooley , Rob Herring , Krzysztof Kozlowski , Anup Patel , Shuah Khan Cc: =?utf-8?b?Q2zDqW1lbnQgTMOpZ2Vy?= , Atish Patra , linux-doc@vger.kernel.org, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, kvm@vger.kernel.org, kvm-riscv@lists.infradead.org, linux-kselftest@vger.kernel.org Subject: [PATCH 00/10] Add support for a few Zc* extensions as well as Zcmop Date: Wed, 10 Apr 2024 11:10:53 +0200 Message-ID: <20240410091106.749233-1-cleger@rivosinc.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240410_021113_585747_BA5DEC37 X-CRM114-Status: UNSURE ( 8.38 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org Add support for (yet again) more RVA23U64 missing extensions. Add support for Zcmop, Zca, Zcf, Zcd and Zcb extensions isa string parsing, hwprobe and kvm support. Zce, Zcmt and Zcmp extensions have been left out since they target microcontrollers/embedded CPUs and are not needed by RVA23U64 This series is based on the Zimop one [1]. Link: https://lore.kernel.org/linux-riscv/20240404103254.1752834-1-cleger@rivosinc.com/ [1] Clément Léger (10): dt-bindings: riscv: add Zca, Zcf, Zcd and Zcb ISA extension description riscv: add ISA parsing for Zca, Zcf, Zcd and Zcb riscv: hwprobe: export Zca, Zcf, Zcd and Zcb ISA extensions RISC-V: KVM: Allow Zca, Zcf, Zcd and Zcb extensions for Guest/VM KVM: riscv: selftests: Add some Zc* extensions to get-reg-list test dt-bindings: riscv: add Zcmop ISA extension description riscv: add ISA extension parsing for Zcmop riscv: hwprobe: export Zcmop ISA extension RISC-V: KVM: Allow Zcmop extension for Guest/VM KVM: riscv: selftests: Add Zcmop extension to get-reg-list test Documentation/arch/riscv/hwprobe.rst | 24 ++++++++++++ .../devicetree/bindings/riscv/extensions.yaml | 37 +++++++++++++++++++ arch/riscv/include/asm/hwcap.h | 5 +++ arch/riscv/include/uapi/asm/hwprobe.h | 5 +++ arch/riscv/include/uapi/asm/kvm.h | 5 +++ arch/riscv/kernel/cpufeature.c | 5 +++ arch/riscv/kernel/sys_hwprobe.c | 5 +++ arch/riscv/kvm/vcpu_onereg.c | 10 +++++ .../selftests/kvm/riscv/get-reg-list.c | 20 ++++++++++ 9 files changed, 116 insertions(+) Reviewed-by: Deepak Gupta