Received: by 2002:ab2:60d1:0:b0:1f7:5705:b850 with SMTP id i17csp612855lqm; Wed, 1 May 2024 10:11:21 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUiX9TDFcqkYbsBLa2wwQR6+WNjJcKCSWPjObFWRA4V8/c5yg96hi9v7VH2TBYcsYXRXiEXwQ747TQzTYD6srSUtPOyVVGvB24G9vdqWQ== X-Google-Smtp-Source: AGHT+IFvKGbUD5usXNK4MiQqbvs+rGwpDwWGTmkhYwQiNdxFcetuw2/xMo4pmtKO5oNmbfK1E4Vp X-Received: by 2002:a05:6214:1bc6:b0:6a0:c9ef:3aae with SMTP id m6-20020a0562141bc600b006a0c9ef3aaemr3963001qvc.23.1714583481035; Wed, 01 May 2024 10:11:21 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714583481; cv=pass; d=google.com; s=arc-20160816; b=0/+S0KJRToSpI6YsIQJ3/r509cqmyw4eoBiW0QQK1T/Kc1C7CIxH+5SXPk2u0CtFaq l5JKuxsp8j2vt/j8wKYAvJUQYV2P3Xt9a/0MtrPYzZXDWwF+ZsmJhxGqcnhOdeGBQBBz B5agAT8+x6MCebZLMHOS3od1lenH1JOh/CD4wVz8KvhNnBkh+JjD3gOzwkDC0lDxvTdf E1Gzpo0UNn2EilLuIBkWL5Ra25/mfd21dxXBgBfMYLmkLXopsSvjF+6uzOmz+s8NtRZh NcVUBy3cgklA70bm6wnGBXno1k9ezbDgZTMqtXE6HKoqEwEgmQe0uRAG1lN6dXkOaf2V 9WCQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=7VEcP2FdbTuUC3sLwg55sFZlBNkkI24Wn6q64j9hZkM=; fh=TruDQ1SBFSgZSw6QsG21c/4N1Up7lMcWl86bOxFmOKk=; b=wizDOJ18eFXY/JuU1gY2NJPl+Uxe1eRVBsVAaI4pynW9Vvap3kRCUgIrWh8826Z14+ K4zXLsrjeLj6/e4esOUe8QQgLgtwdTu9yDaK+pqvRGSEqqTLkwu6oITHElvUXtEa7+fs bLGd/BL0/95V9xhZkRL3H89LtGZgEycdg92RzEuBDGZVpgT4YaWiJQR/+WVQJ/p9Ijy6 FKo6ZUZry1cWID1E15K3z8cUbfuBoQfywvpvcFSk07xJOSO3acN+rGPTAl6EgDN/q435 KI4qdfLkAjYO//mS7KLX0xM1ZToixbXtIZfm4ddJF2iFBRTOVW3wsRzFAEt0JeKnCA+k wm1w==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@rivosinc-com.20230601.gappssmtp.com header.s=20230601 header.b=uHTrGo5J; arc=pass (i=1 spf=pass spfdomain=rivosinc.com dkim=pass dkdomain=rivosinc-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-165628-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-165628-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id iy14-20020a0562140f6e00b0069902184208si32429006qvb.265.2024.05.01.10.11.20 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 May 2024 10:11:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-165628-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@rivosinc-com.20230601.gappssmtp.com header.s=20230601 header.b=uHTrGo5J; arc=pass (i=1 spf=pass spfdomain=rivosinc.com dkim=pass dkdomain=rivosinc-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-165628-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-165628-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 7F0EC1C21568 for ; Wed, 1 May 2024 17:11:20 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B38011B949; Wed, 1 May 2024 17:11:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=rivosinc-com.20230601.gappssmtp.com header.i=@rivosinc-com.20230601.gappssmtp.com header.b="uHTrGo5J" Received: from mail-pl1-f170.google.com (mail-pl1-f170.google.com [209.85.214.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2F51F17C74 for ; Wed, 1 May 2024 17:11:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.170 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714583464; cv=none; b=HzZyozZzCxYUIhG2bkso1Lap2HP/iwzSvZFbEFkIkWwKwSPOn4Y49/fOOdOYJFJt/zkXB20Bk5jLroy9fyeL4x/agVDq6kxku4JC2tT/d70qJRFCL9pkFxJSCFMNYQN2bSfmBQ5Fn7SJiZPIio4VcKU43g3QwQUBbaQadjhkSA8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714583464; c=relaxed/simple; bh=pZAOS/T1u3WYFJhsFU1zktGFGi+9KYNTImhhH3xfeKo=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=BiAJTU1CkCd4ed3P4bk7q+CPArxWqLEMmaxuSd9YdqKKmySZfAB1Fvm5t54Yc2bgw01sf/nlLCKlGBIotXnWo4Ze8Za+44e8scNRXUZxycxf+4TGch1Oy1Jm61UWh7p+T+USZ6DX/CYG5vX+TdOFNaNBnW29qnbl7eUIAcx6px4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=rivosinc.com; spf=pass smtp.mailfrom=rivosinc.com; dkim=pass (2048-bit key) header.d=rivosinc-com.20230601.gappssmtp.com header.i=@rivosinc-com.20230601.gappssmtp.com header.b=uHTrGo5J; arc=none smtp.client-ip=209.85.214.170 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pl1-f170.google.com with SMTP id d9443c01a7336-1e50a04c317so38826855ad.1 for ; Wed, 01 May 2024 10:11:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1714583461; x=1715188261; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=7VEcP2FdbTuUC3sLwg55sFZlBNkkI24Wn6q64j9hZkM=; b=uHTrGo5JLLGnMbH5QgPkVY/+HGVN/EW9HmjfcHJfWdHNiMD9EfsmVt92BilMOItN7l TIunE56JqNtp1LTYsTS2+euIEbOUa3FC2LZsL68xg7l0KN5xV14wRyiAITWf9kDTiYEj nm/69ibSGjrGNWevERGDxpyD89Lu6/AWfDnzM52bEDhaTzumf2+BnWVguziPTtSgre+X oDU47Zb746h5dkiobEzZ1Pq8SCE3e8dZHi1QriNiDToQ3TKbD4zyPSt477ZpTSXuqrj7 XaMjv1mT8A9LHzcZJDUo3ptTmJPwafhH5iqTMUZvzFksNfUqxWdffrDyUcMMzdjbczVe aJOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714583461; x=1715188261; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=7VEcP2FdbTuUC3sLwg55sFZlBNkkI24Wn6q64j9hZkM=; b=BAWV9cctbepp4xUR6rkplGy70AbZVmsyMzC8k/9HNDQiTbcrs3wsL/CvOKxktBRgvN uUkNSHn4v32ao8hZ2O4ufe+BYKOBRSC0d48DNDUOIUTJer/VrcKNONPrjILXIRPkpmpf jApBtll17GvtCQrYzZkmyJhT6h3UL8VE/ik5/x+JlRXj5UIcjIUj/1tNdHLYYbPLfiTR FlpZoOFqMrDprOJD45gKvu3STQsQt4X+Ru6SMDxP3y8pzebNkWy/R4iidjyWL4x4R3XA otJ3bG2SyGlpvLTIK4iYZR+erKS7QNb7wsOTVpYdgIiWNeIGebdj5Tah+thxbcx4z/hU fXZg== X-Forwarded-Encrypted: i=1; AJvYcCXjdYk4YYOuwNX5DTU1NpWTyOckMB+bWmB44HQC1p2TEguxFimuc6Hv9rbcwNCyIpePOgc5VpcJVwaGBk2b0HJj4Yl8MP4Wp6V1lV9X X-Gm-Message-State: AOJu0YzarW8ctp3GfDZaNeASC3vBLsRkYtGVYKvaye2vbuGkv5KAezTC 8PmIFElIF8L7OO2rEGzgn6M1KLp9sYGxwKQ3V5yp44PHQ9KtRoYEzlz2pFSlVWs= X-Received: by 2002:a17:902:6bca:b0:1e4:df0c:a570 with SMTP id m10-20020a1709026bca00b001e4df0ca570mr3014699plt.8.1714583461518; Wed, 01 May 2024 10:11:01 -0700 (PDT) Received: from ghost ([2601:647:5700:6860:1dcc:e03e:dc61:895d]) by smtp.gmail.com with ESMTPSA id mq8-20020a170902fd4800b001e23fcdebe9sm24447681plb.98.2024.05.01.10.10.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 May 2024 10:11:01 -0700 (PDT) Date: Wed, 1 May 2024 10:10:57 -0700 From: Charlie Jenkins To: Conor Dooley Cc: Rob Herring , Krzysztof Kozlowski , Paul Walmsley , Palmer Dabbelt , Albert Ou , Guo Ren , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Conor Dooley , Evan Green , =?iso-8859-1?Q?Cl=E9ment_L=E9ger?= , Jonathan Corbet , Shuah Khan , linux-riscv@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-doc@vger.kernel.org, linux-kselftest@vger.kernel.org Subject: Re: [PATCH v4 05/16] riscv: Extend cpufeature.c to detect vendor extensions Message-ID: References: <20240426-dev-charlie-support_thead_vector_6_9-v4-0-b692f3c516ec@rivosinc.com> <20240426-dev-charlie-support_thead_vector_6_9-v4-5-b692f3c516ec@rivosinc.com> <20240501-drivable-deviation-0a493511770c@spud> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240501-drivable-deviation-0a493511770c@spud> On Wed, May 01, 2024 at 12:40:38PM +0100, Conor Dooley wrote: > On Fri, Apr 26, 2024 at 02:29:19PM -0700, Charlie Jenkins wrote: > > Separate vendor extensions out into one struct per vendor > > instead of adding vendor extensions onto riscv_isa_ext. > > > > Add a hidden config RISCV_ISA_VENDOR_EXT to conditionally include this > > code. > > > > The xtheadvector vendor extension is added using these changes. > > > > Signed-off-by: Charlie Jenkins > > --- > > arch/riscv/Kconfig | 2 + > > arch/riscv/Kconfig.vendor | 19 ++++++ > > arch/riscv/include/asm/cpufeature.h | 18 ++++++ > > arch/riscv/include/asm/vendor_extensions.h | 26 ++++++++ > > arch/riscv/include/asm/vendor_extensions/thead.h | 19 ++++++ > > arch/riscv/kernel/Makefile | 2 + > > arch/riscv/kernel/cpufeature.c | 77 ++++++++++++++++++------ > > arch/riscv/kernel/vendor_extensions.c | 18 ++++++ > > arch/riscv/kernel/vendor_extensions/Makefile | 3 + > > arch/riscv/kernel/vendor_extensions/thead.c | 36 +++++++++++ > > I see no modifications to cpu.c here, is it intentional that vendor > stuff isn't gonna show up in /proc/cpuinfo? I wasn't sure if that's something we were wanting to support since hwprobe is the prefered api, but I can add that if it is desired. - Charlie