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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id DD896C4332F for ; Tue, 5 Apr 2022 07:08:06 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 37AC36B0071; Tue, 5 Apr 2022 03:07:56 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 3055B6B0073; Tue, 5 Apr 2022 03:07:56 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1F2A26B0074; Tue, 5 Apr 2022 03:07:56 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0050.hostedemail.com [216.40.44.50]) by kanga.kvack.org (Postfix) with ESMTP id 0C0886B0071 for ; Tue, 5 Apr 2022 03:07:56 -0400 (EDT) Received: from smtpin31.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id B5CE0ACB47 for ; Tue, 5 Apr 2022 07:07:45 +0000 (UTC) X-FDA: 79321945290.31.6676B08 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) by imf15.hostedemail.com (Postfix) with ESMTP id 83080A002B for ; Tue, 5 Apr 2022 07:07:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=mb8LxTS7N1wZA6PGLOAHodUliQGXD2Gj4fJDPq7BY7I=; b=3vvYnrIhGjhGuytIlX1R63z5oZ 8HJzAlppnlhvbkRKwmatxzikLyz9TZOkhfA28ZKt/Gs2YURxe9o5MXYoIDosXLJAqXJo5/flGm66/ Yrpoxjf8eDN6iOgG8ODT+Bb5xtjO+HyjtLbPufSo37UVL6pKRATfVvAbh7mNJqhkcC+u3ZzKbUGI3 1FFD4vq1YsRD6Sb5ZAGaUdHXph/RR1nOeS/OsAz4D9q3/O8QHTiE66dIA3GSGLXTafFssuFeuhOWW E+yHFYMYCPzCeEKQVkwEueBksfkUyIUmnW6M9Fu2bW6aSBntwJyDaAF6gaYmwpDLu0SZ9G/rNgtU/ YvXyjZhA==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1nbdHq-00HOmb-7S; Tue, 05 Apr 2022 07:07:34 +0000 Date: Tue, 5 Apr 2022 00:07:34 -0700 From: Christoph Hellwig To: Song Liu Cc: Christoph Hellwig , "rick.p.edgecombe@intel.com" , Nicholas Piggin , Claudio Imbrenda , Song Liu , Linux Memory Management List , bpf , Networking , X86 ML , Alexei Starovoitov , Daniel Borkmann , "andrii@kernel.org" , Kernel Team , "akpm@linux-foundation.org" , "pmenzel@molgen.mpg.de" Subject: Re: [PATCH bpf 0/4] introduce HAVE_ARCH_HUGE_VMALLOC_FLAG for bpf_prog_pack Message-ID: References: <20220330225642.1163897-1-song@kernel.org> <6AA91984-7DF3-4820-91DF-DD6CA251B638@fb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6AA91984-7DF3-4820-91DF-DD6CA251B638@fb.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html X-Stat-Signature: y6gjcgenuiyjfzxonqd6ofaaaeic4x7p Authentication-Results: imf15.hostedemail.com; dkim=pass header.d=infradead.org header.s=bombadil.20210309 header.b=3vvYnrIh; spf=none (imf15.hostedemail.com: domain of BATV+9ca921a5852d5ad4edbc+6799+infradead.org+hch@bombadil.srs.infradead.org has no SPF policy when checking 198.137.202.133) smtp.mailfrom=BATV+9ca921a5852d5ad4edbc+6799+infradead.org+hch@bombadil.srs.infradead.org; dmarc=none X-Rspam-User: X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: 83080A002B X-HE-Tag: 1649142464-247473 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, Apr 01, 2022 at 10:22:00PM +0000, Song Liu wrote: > >> Please fix the underlying issues instead of papering over them and > >> creating a huge maintainance burden for others. > > After reading the code a little more, I wonder what would be best strategy. > IIUC, most of the kernel is not ready for huge page backed vmalloc memory. > For example, all the module_alloc cannot work with huge pages at the moment. > And the error Paul Menzel reported in drm_fb_helper.c will probably hit > powerpc with 5.17 kernel as-is? (trace attached below) > > Right now, we have VM_NO_HUGE_VMAP to let a user to opt out of huge pages. > However, given there are so many users of vmalloc, vzalloc, etc., we > probably do need a flag for the user to opt-in? > > Does this make sense? Any recommendations are really appreciated. I think there is multiple aspects here: - if we think that the kernel is not ready for hugepage backed vmalloc in general we need to disable it in powerpc for now. - if we think even in the longer run only some users can cope with hugepage backed vmalloc we need to turn it into an opt-in in general and not just for x86 - there still to appear various unresolved underlying x86 specific issues that need to be fixed either way