Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp8624191rwb; Thu, 24 Nov 2022 02:00:53 -0800 (PST) X-Google-Smtp-Source: AA0mqf5Pk81nRyXNISz0lk8nyNkmBTW1hSY6dUpphX0qzOczqN/VtudwPS10Q4CFkSv1I4dc+4A8 X-Received: by 2002:a17:903:26c7:b0:186:e01d:8f2f with SMTP id jg7-20020a17090326c700b00186e01d8f2fmr12487468plb.40.1669284053492; Thu, 24 Nov 2022 02:00:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669284053; cv=none; d=google.com; s=arc-20160816; b=UO8qR1RPo8pjePkg3oNp8xPo7AsO3sSCH8HMsfzn4pLWQUr0sONkD/DG1+xiFQqNvP HNtBrJy1rQHGnMru4/OvITsVhTnFbsSUcEG7YAXExq6IwF5h5UXfE3to2KBj6vR5u9K6 /hRtOV5fHMDJk2bnu44MMaZEPtZTIIjWzOvRrAIpVt3X2jeTHlg0SvCfZmfyvuG7opeY RCcBxPxi239IvNV4W0woCTM4gToJEizA7b5MvKDIXG68c6JC4TuJocoPkUyomYP2ZeTJ 4OPEiZwxowjk0zakeyQJa+cqsis8xYV6OzB6gftSi3NSXlCANM+H2Qcf1JVYf2DlenqA O8eA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=CcInVSFUNn3V5gEBEwa46hG0c1UErYT5MY3Lep/oon4=; b=JnjO7jyOWQFoPEkCdx5DjPWxYrYHxCWwcBinw4IC8ZspMzVJ8uWIi0Y2eJQVq33kCl 5wjl5rqlNX2ges/Q8fxovAQ66BwoRXqg3Igu0WNEldObjcNuKrWw29795lng3SRJh3QL COc0jG0DEMOtEPK9r4lHCqTqsUEKF/0PyFBO9v2d+d6sZQbS823mDXZGinX8i5EHATLW X/8xbsOxKiyGcHEyJujN+lDmCZaWip+jv7x79/SIuySq0sxsKfmOwCjZOmsztBFpIAIg B8WUFaU2RZcLlH1A+kAxEiyf/Z8oJPurbCm+zAEy2Za9rqcKkEiVaTJadIEEvy/xcEGo s9Dg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b="3U8QF/Ix"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id pj3-20020a17090b4f4300b001ed40b70436si911581pjb.155.2022.11.24.02.00.37; Thu, 24 Nov 2022 02:00:53 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b="3U8QF/Ix"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229544AbiKXJaa (ORCPT + 87 others); Thu, 24 Nov 2022 04:30:30 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42676 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229612AbiKXJa2 (ORCPT ); Thu, 24 Nov 2022 04:30:28 -0500 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 32399122941 for ; Thu, 24 Nov 2022 01:30:27 -0800 (PST) Received: by mail-wm1-x32c.google.com with SMTP id j5-20020a05600c410500b003cfa9c0ea76so799339wmi.3 for ; Thu, 24 Nov 2022 01:30:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; 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=CcInVSFUNn3V5gEBEwa46hG0c1UErYT5MY3Lep/oon4=; b=3U8QF/IxWYVg6NG1OREUoIauxTEjXWySLivW3OoiK8D11df7Rh1iNX1uqA1lBUzNk/ ZZKzsDnzstwokJqPuVkX0A/kidsn3HFivPBhPNcQI1yvwjuMtTL9u82zvoepm70Tl4ir 4+RjclN95QEUehpDyItjE35OcZLndsYbjwItRQkgTd7KRkg8wOc3uN8LECUKIdeAGZAV bW0FFU2xAeSbzr1FohDjzLwPUBQMTu8RHGIEiMxtfk9c8AUcmU9luvWLkQQ6ZMtsoqbG Ygb1PLG82VSFdsp3VMSb7lAu9kGI5Cj3J5CGKFN8RW4f4JToQ8MKzaDWdVK0DzfTfnyp B7/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=CcInVSFUNn3V5gEBEwa46hG0c1UErYT5MY3Lep/oon4=; b=S39ZdpmQtMAR0zFJ0qrbhZ6B+VhrT3ByCqR5nuPXpalSF+2Op464f9oAMl4nsQ2nZp Jmk5LA1rAXPSovWbW7flFIPQKar9vJtL651fLR3YejiC/U5tmrGrnvd1iESrJ5Rr98rB EKyWDP+4pgsZZWMhXPHPNvHzn5MjyZlCkNStsznzFIZl4y/Mf5hqTufchd0h1Cg+Qv5t 8TNwG9VYzy4bRxtyvUQv54HISVOS620VEeB4pnZzlWueeS8Ly9IJmkc4oTDUrFB3uGRd z4PdDWBw/Led+cqnh1eRY8CCFC6ocjfDnd8t1KAabICSsaQyj2WYOn1odH9XVR0LuNld Eo6w== X-Gm-Message-State: ANoB5pnYUtaOSCoEy77EPBMWxT4CZVwHCjFGqSTUE43UJ5+U6LrCeAz8 Clgb0ZfYpDiAGDo4C/tz454jqQ== X-Received: by 2002:a05:600c:4e46:b0:3cf:8762:23d9 with SMTP id e6-20020a05600c4e4600b003cf876223d9mr10470781wmq.112.1669282225613; Thu, 24 Nov 2022 01:30:25 -0800 (PST) Received: from vermeer ([145.224.92.100]) by smtp.gmail.com with ESMTPSA id ba17-20020a0560001c1100b00236695ff94fsm885373wrb.34.2022.11.24.01.30.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 24 Nov 2022 01:30:25 -0800 (PST) Date: Thu, 24 Nov 2022 10:30:21 +0100 From: Samuel Ortiz To: "Hongren (Zenithal) Zheng" Cc: Palmer Dabbelt , Paul Walmsley , Albert Ou , Atish Patra , Anup Patel , Eric Biederman , Kees Cook , linux-mm@kvack.org, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, Michael Kerrisk , linux-man@vger.kernel.org, Jiatai He , Heiko Stuebner , Conor.Dooley@microchip.com Subject: Re: [PATCH v3 2/3] RISC-V: uapi: add HWCAP for Bitmanip/Scalar Crypto Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 13, 2022 at 02:46:35AM +0800, Hongren (Zenithal) Zheng wrote: > diff --git a/arch/riscv/include/uapi/asm/hwcap.h b/arch/riscv/include/uapi/asm/hwcap.h > index 46dc3f5ee99f..bfed3e5c338c 100644 > --- a/arch/riscv/include/uapi/asm/hwcap.h > +++ b/arch/riscv/include/uapi/asm/hwcap.h > @@ -22,4 +22,26 @@ > #define COMPAT_HWCAP_ISA_D (1 << ('D' - 'A')) > #define COMPAT_HWCAP_ISA_C (1 << ('C' - 'A')) > > +/* > + * HWCAP2 flags - for elf_hwcap2 (in kernel) and AT_HWCAP2 > + * > + * As only 32 bits of elf_hwcap (in kernel) could be used > + * and RISC-V has reserved 26 bits of it, other caps like > + * bitmanip and crypto can not be placed in AT_HWCAP > + */ Have we agreed that multi-letter ISA extensions would use hwcap to be exposed to userspace? With so many potential extensions, we could quickly run out of space on AT_HWCAP2 as well. Cheers, Samuel.