Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp1237354rdb; Wed, 6 Dec 2023 12:29:12 -0800 (PST) X-Google-Smtp-Source: AGHT+IE33tXYGeN6QLvNoNWa+97WudUk12wKCg8Y50oTvxsNDyYKUqsPA5xRn9Cb0nAhhOcQ6J95 X-Received: by 2002:a17:90a:3009:b0:286:6cc0:8859 with SMTP id g9-20020a17090a300900b002866cc08859mr1359759pjb.70.1701894552327; Wed, 06 Dec 2023 12:29:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701894552; cv=none; d=google.com; s=arc-20160816; b=OSy862yboY3EhzngJe2KaPjpTEzub6I0GBk4HPbrg+zaVsdYPD4nEE2B+okba9+zL2 4eJHoSg3mPsXwo4quiq0okncGX8+tGpZ1LLMMJfgA36Mw9KuWl0FfshjbIcL4dhId6fm Ap3ux6o5dWftgcVbDLubvcyUpijQ5Hdr0Hz3OU9y33er/hvu7Lhumb9p00MUA50LroBC HqoHXiFnE9LMr2pML6WAAM18IumgE+MvnO+x0YIkxB70R72fPRQR2c6nJmUzhzmc2YLK f3p+yiLHs3vqr1zrtC7DrizwdAwVaGbZJ4p8z9MSADC0Io7IHMgG+/EI4mDuHLpIyAOs DaCw== 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=XTBTLAqDXor1l6sg34c9kbUSBjJSEI8UiBBYr9CwL2Q=; fh=KCH/HFoblm1qM/E6Fb9EnQmRp9nNuy43PkFBWn5PgwM=; b=ewUNRmmOrVRYMMrNJp5/qs5I0iU+2WE/3MwnFpaxFezifkUNtbughnA6gOse43YnW5 BEonmfcnsJui7RrzsLvBstRS8pli3JX3Of/2ciUNiyf6qc6P6iaODiv2ux4RFq/50aaI dg+ewhTmFAh7c+zLihlvCl0NFHbWuU5NzvPymiO1CvobuRMX7zLsk4GG/tnkVhtnrzK2 HJ+Y+STdqIahptr6PaNCgR8oISrCN+GdbrCpzSTsdx7xK9w8Buh39+G3rrfiV6us/Bh0 B7++C72ElHPDBf/FUshZwTHJuPGMiYVvMKNvw/bu+z0wRmY908SWUi+02shkVAV+5RvQ iY2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=mBSvMCBn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id qe5-20020a17090b4f8500b00286aded8191si345250pjb.122.2023.12.06.12.29.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Dec 2023 12:29:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=mBSvMCBn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 5F1978039ECD; Wed, 6 Dec 2023 12:29:09 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1379511AbjLFU2r (ORCPT + 99 others); Wed, 6 Dec 2023 15:28:47 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44100 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1379405AbjLFU2q (ORCPT ); Wed, 6 Dec 2023 15:28:46 -0500 Received: from mail-pj1-x1034.google.com (mail-pj1-x1034.google.com [IPv6:2607:f8b0:4864:20::1034]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 946F012F for ; Wed, 6 Dec 2023 12:28:52 -0800 (PST) Received: by mail-pj1-x1034.google.com with SMTP id 98e67ed59e1d1-2851a2b30a2so197448a91.3 for ; Wed, 06 Dec 2023 12:28:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1701894532; x=1702499332; 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=XTBTLAqDXor1l6sg34c9kbUSBjJSEI8UiBBYr9CwL2Q=; b=mBSvMCBnLy7316/Qzf9Xd5nmH/+fsGN1n1j+8Fc1nUYVCrxpCr6MxloLVw01Wc9HQe 3IIobqpHYYGBZvVcvjlmukokNk7MbrHRonhcvwLh6vFndFxS166Ez8Ul+OLOSEgh7/to YYkDNXgbiFtLGGw7knY39odkVNoiK40VLKFjo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701894532; x=1702499332; 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=XTBTLAqDXor1l6sg34c9kbUSBjJSEI8UiBBYr9CwL2Q=; b=D3Y3ylcecCqTGkkpRI0N0gvPPBASevHg1V+gzzcUFKbgoZ9ulK7HV11emXr59WzLuz Nq35UjC93jGfQMPJelRs45XKtogIfhp8Jbrhs3765mfoOSkxMj9CJUwbL5vPxcFePM6C 9BhzpdoPD+hxDMHp9XwJTab8kBPi9k0ITJxtCWTTbR6cSk4VV3D6l893AB2m5aTsG8Hv TjBJtf4OwI8yjiU+nrIb25OA4tN6AbF0W2wyvAJq/0R/j/S2XB1QZG1i/w59Q1jOmEBW U21QNYCCqC0E/QqKzES+hnlklZjAAiQbNNoFGgvVw/vi9qEnVF8R8gJdDTrd+/uNDyLe nykg== X-Gm-Message-State: AOJu0Yzd53Z4bUfMwfa8Q3v1LawxDCY149Q5er/t1tQR4L6d5j9MQl9Z /71QzqSRMgnpr+/GFxlsW5kLrA== X-Received: by 2002:a17:90a:d796:b0:286:d42d:e7e with SMTP id z22-20020a17090ad79600b00286d42d0e7emr1213709pju.3.1701894532050; Wed, 06 Dec 2023 12:28:52 -0800 (PST) Received: from www.outflux.net (198-0-35-241-static.hfc.comcastbusiness.net. [198.0.35.241]) by smtp.gmail.com with ESMTPSA id fz20-20020a17090b025400b00280a2275e4bsm280195pjb.27.2023.12.06.12.28.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Dec 2023 12:28:51 -0800 (PST) Date: Wed, 6 Dec 2023 12:28:50 -0800 From: Kees Cook To: Palmer Dabbelt Cc: samitolvanen@google.com, Paul Walmsley , aou@eecs.berkeley.edu, akpm@linux-foundation.org, linux-mm@kvack.org, linux-riscv@lists.infradead.org, llvm@lists.linux.dev, linux-kernel@vger.kernel.org Subject: Re: [PATCH 0/2] riscv: Increase mmap_rnd_bits_max on Sv48/57 Message-ID: <202312061228.B953DE8CA@keescook> References: <20230929211155.3910949-4-samitolvanen@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,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 fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 06 Dec 2023 12:29:09 -0800 (PST) On Wed, Dec 06, 2023 at 05:14:26AM -0800, Palmer Dabbelt wrote: > On Fri, 29 Sep 2023 14:11:56 PDT (-0700), samitolvanen@google.com wrote: > > Hi all, > > > > We noticed that 64-bit RISC-V kernels limit mmap_rnd_bits to 24 > > even if the hardware supports a larger virtual address space size > > [1]. These two patches allow mmap_rnd_bits_max to be changed during > > init, and bumps up the maximum randomness if we end up setting up > > 4/5-level paging at boot. > > Sorry for missing this, I'm just poking through old stuff in patchwork. As > far as I can tell this is still relevant, the discussions are just on the > mmap() bits (but we'd already screwed that one up and have since fixed it). > > So > > Reviewed-by: Palmer Dabbelt > Acked-by: Palmer Dabbelt > > in case someone else wants to take it, but I'm OK taking that MM patch with > Kees' review. Yes, thanks! Please do. I already +1ed it: https://lore.kernel.org/all/202309291454.436E19663@keescook -Kees -- Kees Cook