Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp1561140ioo; Sun, 22 May 2022 19:07:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwJnYelXnXECgxwMmCq+3ezd0W3Dj+VZJ8tqNewaH05TN6FaupjFDErwPYFcCNQjoUe0L8a X-Received: by 2002:a05:6402:1e8d:b0:426:9:6ec with SMTP id f13-20020a0564021e8d00b00426000906ecmr21708016edf.55.1653271677404; Sun, 22 May 2022 19:07:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653271677; cv=none; d=google.com; s=arc-20160816; b=nji0646bATsxKCSBa3R5NCErx7eeQfzbhDUh5OvWf0gVeNUtRKJHBB50FTNbTn0Ary gv4rg/XSPF5LrblTHb8SpPe0+w3n5RXLMtQhtipwjTkEFNl7hnC/Y6D5dXw39RB0P5kj unWOWX3uq0nRxtfcOO2ut4b0pEWDPXR3En5guTxS4ASqWjtyNH7URKBji4+0VGShcgZI SmnmyKPMtG3LXAoSshtF+ZDaHxIDSmDx7Bw5NRAzqKLivpcigL++Vjj5TDexdxJjXGak SRowwNxlTGz66aE7pk/5rNlZZdNBCC4ZvogatjP3Zl8G43yT1ZlqazJKrKNFJV4NO55E b8Jg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:to:from:cc:in-reply-to:subject:date:dkim-signature; bh=jwrHtlvoewbRftN79d2AI6EqYNBZAOLiqwA2wLK3D6Q=; b=k9ivHDwrqun77OAiz+pxvEAATSJBeh5wg7D5VWF/dxVaOykgXSEMfaRSXhHdC+XCdq fHAlMJbKDAZaZEDFGbC5NnOTXdvA6G3dJjxOzHNDZichDaR1ibkXZHSaVQ1oGXtVo+sh ewm2VsI4JT/Wk7yXwswRQdKf6BoCCNCGPoGbHu1JHan6C0dvtbkVO8NLFmIjSJMCf8XR KHVqg+n8+ul0RsFbmBVhJx1nFKLL46KfmmEmzQyd4t26oMBAWUFL9O0fbE5j5pdKVPC6 ZOq/IngOAVG6z8jTdD2xrxTit9GicpDVqk/gvJT8J6UY10whDuJoAKuQScmp+YbesDiN Wn2A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b=yo8vdBEE; 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 hg6-20020a1709072cc600b006f3a8b079f6si14333491ejc.626.2022.05.22.19.07.32; Sun, 22 May 2022 19:07:57 -0700 (PDT) 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=yo8vdBEE; 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 S1345962AbiEUUqv (ORCPT + 99 others); Sat, 21 May 2022 16:46:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50374 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245130AbiEUUqn (ORCPT ); Sat, 21 May 2022 16:46:43 -0400 Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 04AC63CA77 for ; Sat, 21 May 2022 13:46:42 -0700 (PDT) Received: by mail-pj1-x1035.google.com with SMTP id z11so931677pjc.3 for ; Sat, 21 May 2022 13:46:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; h=date:subject:in-reply-to:cc:from:to:message-id:mime-version :content-transfer-encoding; bh=jwrHtlvoewbRftN79d2AI6EqYNBZAOLiqwA2wLK3D6Q=; b=yo8vdBEEiaXPv5TVCm0uGTi08S+UDkH4S3uyX9hcU/H+SJpdwMgG9PHXxNMH935f8p i6WWIGk0SNGhSfs9+xDFfvLPpCyMsN7BJOMKx+NydgVIrFWYPAl/cJq8TvoHYVSyenAV 3Sr5r9+2K9vLEva0N0rYD3b6SRPvMnmnYdvR6giHbX0V9JkXCEks1Tk992WQb3kHQuhq SHWeBGgkpxSuwi+4l6G2aU8i7VPrsS+kAkZerHVF2EIB3wqnUPvxvoA2Hhp4wW+C+Jhq WnJdklRqz1jR3uWC3DnY9EVCjhSdTtn3iMvzaTwu3cHwa7Ynpk2dzzILWv1JaPqHLeWv /MOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:subject:in-reply-to:cc:from:to:message-id :mime-version:content-transfer-encoding; bh=jwrHtlvoewbRftN79d2AI6EqYNBZAOLiqwA2wLK3D6Q=; b=6ePFGvBguSgGWwCfkcdCfGZFUKcsAapHyVT2AcJ/QXb7Hp2A/SYyE221UI4DpEoQPz 4LLObgAiFi0tHLcup0a8cNXBMhsgEySs7h30ASW6Frbj0lLQ+zJdlwNlTZRkvg3UMsaX GtOXvQNRSnuVi1tAY/IbiGtL9ADYZGqL/0SCT0OhExPCNxBgajRIrif+zdO/Kj4GmMVG 6mmfQ9n7QAE1HOcTbLrqAXdjaIn6mtBCgyxhhQM+xYm6wQrieQR8KS9YI4F9PIQli+/o 8ZYTkVq8b9nLp8z/K/2kh9331k5u3hfU77NqNbZixCBkZZ77iuW+a/udyflTaBqWRltF S+jw== X-Gm-Message-State: AOAM5339miQ5ZqaaefNZwKdKJu1hKv0Gdoo8ERUDYRFTTrxttqldA4EU Ij3T3bsQgq9Lx58cAfXePl1nXQ== X-Received: by 2002:a17:90b:4ac9:b0:1df:af66:1f3 with SMTP id mh9-20020a17090b4ac900b001dfaf6601f3mr18398951pjb.106.1653166001503; Sat, 21 May 2022 13:46:41 -0700 (PDT) Received: from localhost ([12.3.194.138]) by smtp.gmail.com with ESMTPSA id t13-20020a63b24d000000b003fa321e9463sm9039pgo.58.2022.05.21.13.46.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 May 2022 13:46:41 -0700 (PDT) Date: Sat, 21 May 2022 13:46:41 -0700 (PDT) X-Google-Original-Date: Sat, 21 May 2022 11:33:11 PDT (-0700) Subject: Re: [PATCH v2] RISC-V: Add CONFIG_{NON,}PORTABLE In-Reply-To: CC: Arnd Bergmann , linux-riscv@lists.infradead.org, Paul Walmsley , aou@eecs.berkeley.edu, linux-kernel@vger.kernel.org From: Palmer Dabbelt To: Niklas.Cassel@wdc.com Message-ID: Mime-Version: 1.0 (MHng) Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit 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, T_SCC_BODY_TEXT_LINE autolearn=ham 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 Thu, 14 Apr 2022 05:47:33 PDT (-0700), Niklas.Cassel@wdc.com wrote: > On Wed, Apr 13, 2022 at 06:40:10PM -0700, Palmer Dabbelt wrote: >> From: Palmer Dabbelt >> >> The RISC-V port has collected a handful of options that are >> fundamentally non-portable. To prevent users from shooting themselves >> in the foot, hide them all behind a config entry that explicitly calls >> out that non-portable binaries may be produced. >> >> Signed-off-by: Palmer Dabbelt >> >> --- >> >> Changes since v1: >> >> * Fix a bunch of spelling mistakes. >> * Move NONPORTABLE under the "Platform type" sub-heading. >> * Fix the rv32i dependency. >> --- >> arch/riscv/Kconfig | 28 ++++++++++++++++++++++++++-- >> 1 file changed, 26 insertions(+), 2 deletions(-) >> >> diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig >> index 5adcbd9b5e88..3d8eb44eb889 100644 >> --- a/arch/riscv/Kconfig >> +++ b/arch/riscv/Kconfig >> @@ -213,6 +213,21 @@ source "arch/riscv/Kconfig.erratas" >> >> menu "Platform type" >> >> +config NONPORTABLE >> + bool "Allow configurations that result in non-portable kernels" >> + help >> + RISC-V kernel binaries are compatible between all known systems >> + whenever possible, but there are some use cases that can only be >> + satisfied by configurations that result in kernel binaries that are >> + not portable between systems. >> + >> + Selecting N does not guarantee kernels will be portable to all knows > > nit: s/knows/known ? Thanks. Turns out I've got a bit of an issue here and this results in the defconfigs breaking, so I've got ahead and sent a v3 that includes the necessary bits to make those work along with this fixed up. > Kind regards, > Niklas