From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 74E2EC47258 for ; Tue, 5 May 2020 12:16:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 53E4F2073B for ; Tue, 5 May 2020 12:16:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728914AbgEEMQB (ORCPT ); Tue, 5 May 2020 08:16:01 -0400 Received: from verein.lst.de ([213.95.11.211]:35078 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728180AbgEEMQB (ORCPT ); Tue, 5 May 2020 08:16:01 -0400 Received: by verein.lst.de (Postfix, from userid 2407) id 68BE668C4E; Tue, 5 May 2020 14:15:57 +0200 (CEST) Date: Tue, 5 May 2020 14:15:57 +0200 From: Christoph Hellwig To: Jann Horn Cc: Christoph Hellwig , Andrew Morton , Linus Torvalds , kernel list , Linux-MM , linux-fsdevel , Alexander Viro , "Eric W . Biederman" , Oleg Nesterov , Russell King , Linux ARM , Mark Salter , Aurelien Jacquiot , linux-c6x-dev@linux-c6x.org, Yoshinori Sato , Rich Felker , Linux-sh list Subject: Re: [PATCH v2 1/5] binfmt_elf_fdpic: Stop using dump_emit() on user pointers on !MMU Message-ID: <20200505121557.GA24052@lst.de> References: <20200429214954.44866-1-jannh@google.com> <20200429214954.44866-2-jannh@google.com> <20200505104805.GA17400@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 05, 2020 at 01:42:12PM +0200, Jann Horn wrote: > On Tue, May 5, 2020 at 12:48 PM Christoph Hellwig wrote: > > On Wed, Apr 29, 2020 at 11:49:50PM +0200, Jann Horn wrote: > > > dump_emit() is for kernel pointers, and VMAs describe userspace memory. > > > Let's be tidy here and avoid accessing userspace pointers under KERNEL_DS, > > > even if it probably doesn't matter much on !MMU systems - especially given > > > that it looks like we can just use the same get_dump_page() as on MMU if > > > we move it out of the CONFIG_MMU block. > > > > Looks sensible. Did you get a chance to test this with a nommu setup? > > Nope. Do you happen to have a recommendation for a convenient > environment I can use with QEMU, or something like that? I'm guessing > that just running a standard armel Debian userspace with a !mmu ARM > kernel wouldn't work so well? Nommu generally needs special userspace either using uclibc-ng or musl. When I did the RISC-V nommu work I used buildroot for my root file systems. We haven't gotten elffdpic to work on RISC-V yet, so I can't use that setup for testing, but it should support ARM as well.