From patchwork Thu Apr 18 12:42:32 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: 13634681 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 56971C4345F for ; Thu, 18 Apr 2024 12:44:53 +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:References:In-Reply-To: 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: List-Owner; bh=Ht8J48sFZwUwjp6RKdfF0/O6LTbBO+RU1M1DTddgh7M=; b=IZGcuphoxPyGIK uvG6krpuEJtwZlTH7oZ2FxLMR1a0arOs36FbkS0Ax7Gu3PQdONoWX/p9/pworgdgIDZzO6ENgihCe /R7Y3rQ4I0+gCbUzZoE1UlzcxDcCGOUW9zGkUP1Iz+c74N68/bHuX8C2mfDtEbSR+MGW7eW1bnzBq zY8xtpIUMDaSW+F4BPkAkHTavY78Q5w227MxI2KU95RK8lJBDPrtpdhJ406ltEapAB9Lv4vctGHVu XFseY3UjIpRTPAKA+w4OB/wcl3JZd9t65pKsto6sNx1JLtncpIkTPPPAJdcbjXRf59IKxQUrdVYc2 FXATUV4B/kHhv2HGt6Lw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rxR8D-00000002DA6-19xL; Thu, 18 Apr 2024 12:44:49 +0000 Received: from mail-lj1-f177.google.com ([209.85.208.177]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rxR7Y-00000002CXX-1Jxl for linux-riscv@lists.infradead.org; Thu, 18 Apr 2024 12:44:11 +0000 Received: by mail-lj1-f177.google.com with SMTP id 38308e7fff4ca-2dac628f08fso2491291fa.3 for ; Thu, 18 Apr 2024 05:44:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1713444245; x=1714049045; darn=lists.infradead.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=AJJluMz+u6UTg8XM641LtNTBq3D7zPplm+46K1BBT3g=; b=h3AajMf0R3IqZsLbddCI39mu5GWOuomWIRGSyiZqRHQx5OEqUn9fGhOAgNuMpkD2o/ k1bzvqb2K4auDpvfTB0ltonfSuEx0pHHKhbnyGrqx+GX3k6CNC9FkT4VNt5Ei6vJNXte H9hZeg4zgphQ1T7GfABYu6BrdFZO9lH9UBHcHtWDFCmW7L0QPYlzOvzNAU4D/4Zte2cc FIzoA7TspDGbdpcyvzBrNX6amzh6dXymInqAKbrPofOc8q84B+l3TTilGw7WFYK5nblM iNfkSssMgzJPIkhywkcenlDcS/0UTEObT3KAJYQVn00AAXuuRL/mHYgMZ8SDVDQi85ye ugKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713444245; x=1714049045; 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=AJJluMz+u6UTg8XM641LtNTBq3D7zPplm+46K1BBT3g=; b=Q/6883TcxG4KWvOEI5U5x5GJj4j0Q36rpxQLWTsZJ2c+caFqQ2YYw+4yCNchpygW+r ePESlevo0RoDRmQ3PchknDeTAYldCHV3+UUrDkEdRTXaHBoFAaYvjuBtDjWv63otG7bI 4I46LbV1d5esr9jMo1V9xB0Rq1XsGCiUINctCJSYNntkG594I5pqpjf+gQRwKjOH029r j492nQ2oLzG4M1XDuAJ5gPY+5g/ijDOcaUpqLPMB20BL0L+QsAo1yLJJXmFL7OVgS7Ue +329/qmCsNsPfDoLp0ssIMGLbfxdPYoFhJxfwvS/RXJZTS4/tZGprKZ2Cw2f2rmwGzNm sHmg== X-Forwarded-Encrypted: i=1; AJvYcCWcIzehDGA57UU9E+pv+TQ2yM6O1L0rf1Rfj9S+DxBC8l/HnBHFSMb9kbO69ckE/jn5uuO4mBnAsKklz3cB9uA/aRvpU0AXT421vF1R4UXb X-Gm-Message-State: AOJu0YylsxlGah1RJzPnh6IP4kYJYbPFwHx3DdXNjg12nODqgZ/Mkm2M aMdxDjtFAog+/XWKj308Ix0AB7ory2sNr/5MUJj5+hMpU9pecyxlhb5/y5ilsNo= X-Google-Smtp-Source: AGHT+IEA98F7NhkSpgbqjXTJDAARemLQxPRyTCHu7WNOEPKgiNpZ7WkvoQPUAaqjKtkLyPbtJUVEhQ== X-Received: by 2002:a2e:9ccf:0:b0:2d9:e54d:8208 with SMTP id g15-20020a2e9ccf000000b002d9e54d8208mr1639216ljj.0.1713444245128; Thu, 18 Apr 2024 05:44:05 -0700 (PDT) Received: from carbon-x1.. ([2a01:e0a:999:a3a0:7b64:4d1d:16d8:e38b]) by smtp.gmail.com with ESMTPSA id bi18-20020a05600c3d9200b00418d5b16fa2sm3373412wmb.30.2024.04.18.05.44.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Apr 2024 05:44:04 -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 v2 09/12] riscv: add ISA extension parsing for Zcmop Date: Thu, 18 Apr 2024 14:42:32 +0200 Message-ID: <20240418124300.1387978-10-cleger@rivosinc.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240418124300.1387978-1-cleger@rivosinc.com> References: <20240418124300.1387978-1-cleger@rivosinc.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240418_054408_509416_105C5312 X-CRM114-Status: UNSURE ( 9.54 ) 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 parsing for Zcmop ISA extension which was ratified in commit b854a709c00 ("Zcmop is ratified/1.0") of the riscv-isa-manual. Signed-off-by: Clément Léger --- arch/riscv/include/asm/hwcap.h | 1 + arch/riscv/kernel/cpufeature.c | 1 + 2 files changed, 2 insertions(+) diff --git a/arch/riscv/include/asm/hwcap.h b/arch/riscv/include/asm/hwcap.h index b7551bad341b..cff7660de268 100644 --- a/arch/riscv/include/asm/hwcap.h +++ b/arch/riscv/include/asm/hwcap.h @@ -86,6 +86,7 @@ #define RISCV_ISA_EXT_ZCB 77 #define RISCV_ISA_EXT_ZCD 78 #define RISCV_ISA_EXT_ZCF 79 +#define RISCV_ISA_EXT_ZCMOP 80 #define RISCV_ISA_EXT_XLINUXENVCFG 127 diff --git a/arch/riscv/kernel/cpufeature.c b/arch/riscv/kernel/cpufeature.c index 09dee071274d..f1450cd7231e 100644 --- a/arch/riscv/kernel/cpufeature.c +++ b/arch/riscv/kernel/cpufeature.c @@ -265,6 +265,7 @@ const struct riscv_isa_ext_data riscv_isa_ext[] = { __RISCV_ISA_EXT_DATA(zcb, RISCV_ISA_EXT_ZCB), __RISCV_ISA_EXT_DATA(zcd, RISCV_ISA_EXT_ZCD), __RISCV_ISA_EXT_DATA(zcf, RISCV_ISA_EXT_ZCF), + __RISCV_ISA_EXT_DATA(zcmop, RISCV_ISA_EXT_ZCMOP), __RISCV_ISA_EXT_DATA(zba, RISCV_ISA_EXT_ZBA), __RISCV_ISA_EXT_DATA(zbb, RISCV_ISA_EXT_ZBB), __RISCV_ISA_EXT_DATA(zbc, RISCV_ISA_EXT_ZBC),