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 DBF58C433F5 for ; Tue, 12 Apr 2022 15:38:45 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 1797E6B0071; Tue, 12 Apr 2022 11:38:45 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 129A26B0073; Tue, 12 Apr 2022 11:38:45 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0182E6B0074; Tue, 12 Apr 2022 11:38:44 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0138.hostedemail.com [216.40.44.138]) by kanga.kvack.org (Postfix) with ESMTP id E76846B0071 for ; Tue, 12 Apr 2022 11:38:44 -0400 (EDT) Received: from smtpin29.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id 81ABC183A39B9 for ; Tue, 12 Apr 2022 15:38:44 +0000 (UTC) X-FDA: 79348634568.29.1AF74E4 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) by imf06.hostedemail.com (Postfix) with ESMTP id C8D75180009 for ; Tue, 12 Apr 2022 15:38:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=9PiloLG5jlTcO46ESKKigvFqoJS8Cciwgeir2CUSEZY=; b=lhiGFotIglWz3eWuatKV0A2rNX oGEepGqGbdtB7jamRHw+78FYJtRkD6cCYVIDbs7tCREBdQy/JlgHMR5Sfii2KassouNB4ixOBCqL3 mE+B5BV+q1OG0scp/OM8r/mrRkIlAxr+nuBKpKjXyMeLu2WOveGIQhRnN0/32qGL5jC9lPmrl+lYX awNwWmUztkuTfTY7JkQZM3vKr1QEQQeyQkUJfifuKg0CCSRr98wJpEj5lsbZyQABzR1TCi6Pqoixt L3oLGNT/or9iFwOmd3Gs2dSd6OVYXRxolNqio+pQ78XNLs4f2YEftUqq6wCUhhadTMXwkxdRqDi9w AZiXDTsQ==; Received: from mcgrof by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1neIbI-00EyA6-0b; Tue, 12 Apr 2022 15:38:40 +0000 Date: Tue, 12 Apr 2022 08:38:39 -0700 From: Luis Chamberlain To: Song Liu Cc: bpf@vger.kernel.org, netdev@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, ast@kernel.org, daniel@iogearbox.net, andrii@kernel.org, kernel-team@fb.com, akpm@linux-foundation.org, rick.p.edgecombe@intel.com, hch@infradead.org, imbrenda@linux.ibm.com Subject: Re: [PATCH v2 bpf 0/3] vmalloc: bpf: introduce VM_ALLOW_HUGE_VMAP Message-ID: References: <20220411231808.667073-1-song@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220411231808.667073-1-song@kernel.org> X-Stat-Signature: 9uxab6y41go535sy6pku9qmt3s3hfpae X-Rspamd-Server: rspam07 X-Rspamd-Queue-Id: C8D75180009 Authentication-Results: imf06.hostedemail.com; dkim=pass header.d=infradead.org header.s=bombadil.20210309 header.b=lhiGFotI; dmarc=fail reason="No valid SPF, DKIM not aligned (relaxed)" header.from=kernel.org (policy=none); spf=none (imf06.hostedemail.com: domain of mcgrof@infradead.org has no SPF policy when checking 198.137.202.133) smtp.mailfrom=mcgrof@infradead.org X-Rspam-User: X-HE-Tag: 1649777923-663026 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 Mon, Apr 11, 2022 at 04:18:05PM -0700, Song Liu wrote: > Changes v1 => v2: > 1. Add vmalloc_huge(). (Christoph Hellwig) > 2. Add module_alloc_huge(). (Christoph Hellwig) > 3. Add Fixes tag and Link tag. (Thorsten Leemhuis) > > Enabling HAVE_ARCH_HUGE_VMALLOC on x86_64 and use it for bpf_prog_pack has > caused some issues [1], as many users of vmalloc are not yet ready to > handle huge pages. To enable a more smooth transition to use huge page > backed vmalloc memory, this set replaces VM_NO_HUGE_VMAP flag with an new > opt-in flag, VM_ALLOW_HUGE_VMAP. More discussions about this topic can be > found at [2]. > > Patch 1 removes VM_NO_HUGE_VMAP and adds VM_ALLOW_HUGE_VMAP. > Patch 2 uses VM_ALLOW_HUGE_VMAP in bpf_prog_pack. > > [1] https://lore.kernel.org/lkml/20220204185742.271030-1-song@kernel.org/ > [2] https://lore.kernel.org/linux-mm/20220330225642.1163897-1-song@kernel.org/ > > Song Liu (3): > vmalloc: replace VM_NO_HUGE_VMAP with VM_ALLOW_HUGE_VMAP > module: introduce module_alloc_huge > bpf: use vmalloc with VM_ALLOW_HUGE_VMAP for bpf_prog_pack > > arch/Kconfig | 6 ++---- > arch/powerpc/kernel/module.c | 2 +- > arch/s390/kvm/pv.c | 2 +- > arch/x86/kernel/module.c | 21 +++++++++++++++++++ > include/linux/moduleloader.h | 5 +++++ > include/linux/vmalloc.h | 4 ++-- > kernel/bpf/core.c | 9 +++++---- > kernel/module.c | 8 ++++++++ Please use modules-next [0] as that has queued up changes which change kernel/module.c quite a bit. [0] https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git/log/?h=modules-next Luis