Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp131278ybi; Thu, 30 May 2019 22:06:44 -0700 (PDT) X-Google-Smtp-Source: APXvYqzlegpk4dyJIBVFFBEwAbf0jC+ZtrKJFx1av5fqz/OPmA6ta070cCnk4PO5aKkX/2czDrkN X-Received: by 2002:a17:90a:a789:: with SMTP id f9mr6799744pjq.20.1559279204236; Thu, 30 May 2019 22:06:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559279204; cv=none; d=google.com; s=arc-20160816; b=thmFR0HVorcxuPoqPndqFi4Jl6XhQ811UuScBjmNHiUSNVvA3OTd4ylY7SZJrQ2Ph3 8fRF4OjX9diBwwj8qjambfcXwG/JSvgf+YqmoqYtAuVX3OpM2y+BtDcG1hmtg5+q+x2h 9KVC0lAqoBfpsN03nG1xR6oSzog9XxExMjxMPkZPTWaB4o/Od6GZuhuaykCstE5mpGj/ VDka9V5JDC+gmGAZZFK+7z9zkRzp8bHYtBBMrFvtrl66tbDL6hY6ykVOUZBWM/SIuR1F pgdmWIcT3abF1rtiyLCirCP/e70v3/kurfj6dYrcT1wL0oaVlCK2RycepSLN8UO+x2Dn KimA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=jL83xFdD/aHxispjhU2AiV5rEgrDKtxgwM3aVYvmG4Q=; b=wImdnTAB/CbKPE7sGFz7XxVn52mPoD04ntVswz9lXqha0DaG4lMjJGe+D+6eoRsJdv dim+ZRSi2MdcgqBQfEBPXsoxGjn57hyDC1FI58qxG7g9Fmi+nMfI+XPMRTd44VXWYWSI 31H7S6Hb8ltfFL8kWYiBGwzVYarlTO9lPDrGyU7t3LUE6KrI/YDtMWUgNE5MGtjWWae3 KQbd84eRd/L7CeO7dK1uwt9MyxSoiZu+OQ7SpOUu0NWbyb46cbQTO+wqvTbYL8lQsNQh YDh3t703j2XyqbIgrbTbhTT+V4DNM6s5LVXH/SS/Ba3bYBif53+xo1dlBU76QiA8UwoE 5AUw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x8si4503288pjq.80.2019.05.30.22.06.26; Thu, 30 May 2019 22:06:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726421AbfEaFFR (ORCPT + 99 others); Fri, 31 May 2019 01:05:17 -0400 Received: from relay7-d.mail.gandi.net ([217.70.183.200]:33523 "EHLO relay7-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725955AbfEaFFQ (ORCPT ); Fri, 31 May 2019 01:05:16 -0400 X-Originating-IP: 79.86.19.127 Received: from [192.168.0.12] (127.19.86.79.rev.sfr.net [79.86.19.127]) (Authenticated sender: alex@ghiti.fr) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 6BA8020002; Fri, 31 May 2019 05:04:56 +0000 (UTC) Subject: Re: [PATCH v4 00/14] Provide generic top-down mmap layout functions To: Kees Cook Cc: Andrew Morton , Christoph Hellwig , Russell King , Catalin Marinas , Will Deacon , Ralf Baechle , Paul Burton , James Hogan , Palmer Dabbelt , Albert Ou , Alexander Viro , Luis Chamberlain , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org, linux-riscv@lists.infradead.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org References: <20190526134746.9315-1-alex@ghiti.fr> <201905291313.1E6BD2DFB@keescook> From: Alex Ghiti Message-ID: Date: Fri, 31 May 2019 01:04:55 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0 MIME-Version: 1.0 In-Reply-To: <201905291313.1E6BD2DFB@keescook> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Content-Language: sv-FI Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/29/19 4:16 PM, Kees Cook wrote: > On Sun, May 26, 2019 at 09:47:32AM -0400, Alexandre Ghiti wrote: >> This series introduces generic functions to make top-down mmap layout >> easily accessible to architectures, in particular riscv which was >> the initial goal of this series. >> The generic implementation was taken from arm64 and used successively >> by arm, mips and finally riscv. > As I've mentioned before, I think this is really great. Making this > common has long been on my TODO list. Thank you for the work! (I've sent > separate review emails for individual patches where my ack wasn't > already present...) Thanks :) >> - There is no common API to determine if a process is 32b, so I came up with >> !IS_ENABLED(CONFIG_64BIT) || is_compat_task() in [PATCH v4 12/14]. > Do we need a common helper for this idiom? (Note that I don't think it's > worth blocking the series for this.) Each architecture has its own way of finding that out, it might be interesting if there are other places in generic code to propose something in that sense. I will search for such places if they exist and come back with something. Thanks Kees for your time, Alex > > -Kees >