Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp356847rwr; Wed, 19 Apr 2023 07:26:11 -0700 (PDT) X-Google-Smtp-Source: AKy350YhyAjiE1d0uUlOZwU6Maa3DjRTEzSNf0WManC/y8rOA8Ao0MQUx9/5Ba00xlLeYVTEqxhP X-Received: by 2002:a17:90a:6002:b0:246:865d:419a with SMTP id y2-20020a17090a600200b00246865d419amr2771185pji.6.1681914371148; Wed, 19 Apr 2023 07:26:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681914371; cv=none; d=google.com; s=arc-20160816; b=e3mOVsj8ao1Nfgpl5gE1Bkse/A6k+eYablg8Ao1IftCp0A/FHcp/reS8NJ7HaiUW4l eYb/uzHEf1ys6SvgjfBjWm/YSxyTMQ1nVmbzRR7oCQ5xChZ4jVqQHpQqKnH32q5ZVy8w OqJ9KUT5ELpcX+dO0SHNKszl3AX503O/3zK2Ggc+fOGvA39alq/4xzSrSallUb5QstK1 0JeRD61wJthJsYjo86rVacZVb0OPUhtpQ0MZkDNCUehuaRIGwnuvfTT+bXx+zmRf8HSL hEOSSVrga3Lh6OGGaZESxytM37qGcxH7L7GvDHefp1ROT/4IPENkgF4264dMrRwo3rPN iJDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:from:content-transfer-encoding:mime-version :date:message-id:subject:references:in-reply-to:dkim-signature; bh=4QMI2Yn+3Tt8Q1/CbQZqi01Ckjh+S0S8nE0G1uS1/Is=; b=dHkl19rJJrqLWpbXQE0kk1K5z9QABuSQ10T6C7ZS2G4vk4gRlgQzPBfcRjVYA+VsSs ug4IVvoofLqwUR0x+wPQ6JPM7NvGPGFIQBcghi5GpQDgvORvypehcpC404AhbdN2/TUZ 9pvXL4q8v5mN7gyfC/u8TNX7M+iKgGWqf8Cn4gNrFOxb1Ou+mmJbZe9ZeKDROMuNVRFz ocV0tWwLrPR0/ImQ6sNb3FlaLWutfI4TpFT6DTT62vjpfk9I3VRbVq8skZ+Evt7+xafl /WygkxnOcdEVRQsUzi63cSAT6LsEegfCmGq2Gh7HZJb0HXB6KHT5j2NME3YeOLcUz+Q+ 8azw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20221208.gappssmtp.com header.s=20221208 header.b="T1EEo/1l"; 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 z9-20020a170903018900b0019e67626276si18121505plg.392.2023.04.19.07.25.59; Wed, 19 Apr 2023 07:26:11 -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.20221208.gappssmtp.com header.s=20221208 header.b="T1EEo/1l"; 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 S233141AbjDSOXB (ORCPT + 99 others); Wed, 19 Apr 2023 10:23:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51012 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232952AbjDSOWp (ORCPT ); Wed, 19 Apr 2023 10:22:45 -0400 Received: from mail-pf1-x436.google.com (mail-pf1-x436.google.com [IPv6:2607:f8b0:4864:20::436]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2034A59D7 for ; Wed, 19 Apr 2023 07:22:43 -0700 (PDT) Received: by mail-pf1-x436.google.com with SMTP id d2e1a72fcca58-63d4595d60fso7308860b3a.0 for ; Wed, 19 Apr 2023 07:22:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1681914162; x=1684506162; h=to:from:content-transfer-encoding:mime-version:date:message-id :subject:references:in-reply-to:from:to:cc:subject:date:message-id :reply-to; bh=4QMI2Yn+3Tt8Q1/CbQZqi01Ckjh+S0S8nE0G1uS1/Is=; b=T1EEo/1lNhWtIaj43BCGws+YmfqMTA6iMuWVagfEnT1xJA8qVwOPm1UGiTLe2NOFuM xMk7buI+T1c0Hf3+C2uqsQgEJHHaSuEgENbG5BOdgXzQw6qmKvjFm/lHzItwlc4j30pI v5SNg4zDHJJ59SreaJer2v7hZf5LQBP2OmSziT6uC7+pvGZBrGJz+CCb8kKTTjdQju9a kku5NeVrvk8S8WAibKcjPeWqbCmN/DAxVz0JiSKkYT179rZ/V1dOmkVPAKGqsIK5NZaW QXp9BfFBDt3hvjxhkTunOLMevN/GsODpZQqgxG1z5sdsJdhqmd9J2xXVcjSyZmaKNRaM NxGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681914162; x=1684506162; h=to:from:content-transfer-encoding:mime-version:date:message-id :subject:references:in-reply-to:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=4QMI2Yn+3Tt8Q1/CbQZqi01Ckjh+S0S8nE0G1uS1/Is=; b=P4csjtGZjyx3fxrnx/fUqvQ3ghQqD+VXnIkbFgg+XPBXERvxR5P7s0pjAWJOxUql63 0XSq+yMkO6huYKfd3WUlt4RoaXMSM+T+8GkRQ/21iNzoLC0ByEa/HhpQWzFr8+o6rO4s 4vL23djhQNcoUzOMTrfYRUdlPLiA3Jcii8fPHyWdv+imH/mWNhe5/WgrEbA7t3Wycu+V ZPj2sEzDpE2hSoO5aVKiZtuxpFVOz2K7kmvb9j4V4Um7+1vr2zM46PKVVMvR5b2Bxbc1 1xKhZZLIo3pQEVziK2i9IV2I7g/+XDe/XoNxgljkJcYrFlr/KK+xPfHV923D9Wuzx1OJ AQGg== X-Gm-Message-State: AAQBX9elmiV5UU1SL4sKhnPGzSiKYSvXucSVWks/ADC/HCZPfLIGSiAB EUZy1Dap6eyjc5Z+wDEBse2ERw== X-Received: by 2002:a17:90a:9285:b0:246:5787:6f5d with SMTP id n5-20020a17090a928500b0024657876f5dmr3052189pjo.10.1681914162496; Wed, 19 Apr 2023 07:22:42 -0700 (PDT) Received: from localhost ([135.180.227.0]) by smtp.gmail.com with ESMTPSA id q12-20020a631f4c000000b0051b8172fa68sm7616348pgm.38.2023.04.19.07.22.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Apr 2023 07:22:42 -0700 (PDT) In-Reply-To: <20230324155421.271544-1-alexghiti@rivosinc.com> References: <20230324155421.271544-1-alexghiti@rivosinc.com> Subject: Re: [PATCH v9 0/3] riscv: Use PUD/P4D/PGD pages for the linear mapping Message-Id: <168191414582.1929.5343150179757042159.b4-ty@rivosinc.com> Date: Wed, 19 Apr 2023 07:22:25 -0700 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Mailer: b4 0.13-dev-901c5 From: Palmer Dabbelt To: Paul Walmsley , Palmer Dabbelt , Albert Ou , Rob Herring , Frank Rowand , Andrew Jones , Anup Patel , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Alexandre Ghiti 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=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 Fri, 24 Mar 2023 16:54:18 +0100, Alexandre Ghiti wrote: > This patchset intends to improve tlb utilization by using hugepages for > the linear mapping. > > As reported by Anup in v6, when STRICT_KERNEL_RWX is enabled, we must > take care of isolating the kernel text and rodata so that they are not > mapped with a PUD mapping which would then assign wrong permissions to > the whole region: it is achieved the same way as arm64 by using the > memblock nomap API which isolates those regions and re-merge them afterwards > thus avoiding any issue with the system resources tree creation. > > [...] Applied, thanks! [1/3] riscv: Get rid of riscv_pfn_base variable https://git.kernel.org/palmer/c/a7407a1318a9 [2/3] riscv: Move the linear mapping creation in its own function https://git.kernel.org/palmer/c/8589e346bbb6 [3/3] riscv: Use PUD/P4D/PGD pages for the linear mapping https://git.kernel.org/palmer/c/3335068f8721 Best regards, -- Palmer Dabbelt