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 9296BC433EF for ; Thu, 21 Apr 2022 15:50:03 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id ED9C56B0072; Thu, 21 Apr 2022 11:50:02 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id EAC6E6B0073; Thu, 21 Apr 2022 11:50:02 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D4C986B0074; Thu, 21 Apr 2022 11:50:02 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.25]) by kanga.kvack.org (Postfix) with ESMTP id C78946B0072 for ; Thu, 21 Apr 2022 11:50:02 -0400 (EDT) Received: from smtpin19.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 9E3F122A6A for ; Thu, 21 Apr 2022 15:50:02 +0000 (UTC) X-FDA: 79381322244.19.688F43B Received: from mail-lf1-f49.google.com (mail-lf1-f49.google.com [209.85.167.49]) by imf25.hostedemail.com (Postfix) with ESMTP id 02DEDA002D for ; Thu, 21 Apr 2022 15:49:58 +0000 (UTC) Received: by mail-lf1-f49.google.com with SMTP id y32so9457969lfa.6 for ; Thu, 21 Apr 2022 08:50:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=GSC/5Oarouj/IhL754LRTmrVdMvDDrWtXfrr59Z4nhk=; b=PUkYGIZ7ik5E9H8lnQqVXvgb0eGPjMYQ3O+Z1xj74HOz3+1ncR35ixTv8UGZI5JWZA cs+cNoP3Yrf91evx+8ZuL6EnE7+dJ2Ia89gpjl/iQcdVzIiw7H6duMF7mHEZaWT4lWgt UrVcdYkaY9nTaKfvi4Xzp9b+c1qMCNNWfAVHk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=GSC/5Oarouj/IhL754LRTmrVdMvDDrWtXfrr59Z4nhk=; b=411fumXa21gcDJJYYdTcAkUAuqOb1yAUlLQ0FkVPGZK1Lsl/JNtDd3ieI89Vss/VSo IyFtlgc17tezmYjkXYK7zotuU0LWEv2s5YqeIg0j6a8hjD7pze5hpHQW/Ft4tlOqZgKj 6CRFgHgTygNKv1KxfLxIIhoGRKb2SZ+BCkfVre0rEUkD4VTW9LnNNWoos4iybatsp/n1 Inld4H1bHQTfGL79QPuitQMG+/3BEZ+IPw/S45k5mjNfcl+1kRriOHLuGa6X5Ha6eU+b czotXXT7w5ScmNEHMeAxII9aiaZgSAuEmGVWTr2tyUpmUn7jzwNsLKnkm5Ss7hi/Lr9g cyGg== X-Gm-Message-State: AOAM532kkL53rfcYw8vGZVIpil6yE4j5lU8PCBvW0kFwHPEaoePvuRVk dV7c5X3OXCaMGWhqu895GkHUC681Kfc/0KavzmY= X-Google-Smtp-Source: ABdhPJxPxUNrhM1RZBWEpSEqXQwrZA98hcixgPaZ/F74uK3ADQ5cIggEJJ8g9Vhemm18enhQQ+EtpA== X-Received: by 2002:a05:6512:3f29:b0:450:ac79:77dd with SMTP id y41-20020a0565123f2900b00450ac7977ddmr79796lfa.301.1650556200316; Thu, 21 Apr 2022 08:50:00 -0700 (PDT) Received: from mail-lf1-f49.google.com (mail-lf1-f49.google.com. [209.85.167.49]) by smtp.gmail.com with ESMTPSA id i26-20020a05651233ba00b0047104806fa8sm1622010lfg.48.2022.04.21.08.49.59 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 21 Apr 2022 08:50:00 -0700 (PDT) Received: by mail-lf1-f49.google.com with SMTP id x33so9480609lfu.1 for ; Thu, 21 Apr 2022 08:49:59 -0700 (PDT) X-Received: by 2002:a05:6512:3c93:b0:44b:4ba:c334 with SMTP id h19-20020a0565123c9300b0044b04bac334mr77831lfv.27.1650555890298; Thu, 21 Apr 2022 08:44:50 -0700 (PDT) MIME-Version: 1.0 References: <20220415164413.2727220-1-song@kernel.org> <4AD023F9-FBCE-4C7C-A049-9292491408AA@fb.com> <88eafc9220d134d72db9eb381114432e71903022.camel@intel.com> <1650511496.iys9nxdueb.astroid@bobo.none> <1650530694.evuxjgtju7.astroid@bobo.none> In-Reply-To: <1650530694.evuxjgtju7.astroid@bobo.none> From: Linus Torvalds Date: Thu, 21 Apr 2022 08:44:34 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v4 bpf 0/4] vmalloc: bpf: introduce VM_ALLOW_HUGE_VMAP To: Nicholas Piggin Cc: "akpm@linux-foundation.org" , "ast@kernel.org" , "bp@alien8.de" , "bpf@vger.kernel.org" , "daniel@iogearbox.net" , "dborkman@redhat.com" , "edumazet@google.com" , "hch@infradead.org" , "hpa@zytor.com" , "imbrenda@linux.ibm.com" , Kernel Team , "linux-kernel@vger.kernel.org" , "linux-mm@kvack.org" , "mbenes@suse.cz" , "mcgrof@kernel.org" , "pmladek@suse.com" , "Edgecombe, Rick P" , Mike Rapoport , "song@kernel.org" , Song Liu Content-Type: text/plain; charset="UTF-8" Authentication-Results: imf25.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=google header.b=PUkYGIZ7; dmarc=none; spf=pass (imf25.hostedemail.com: domain of torvalds@linuxfoundation.org designates 209.85.167.49 as permitted sender) smtp.mailfrom=torvalds@linuxfoundation.org X-Rspam-User: X-Rspamd-Server: rspam08 X-Rspamd-Queue-Id: 02DEDA002D X-Stat-Signature: qjdfs3dip48m75n155c1k48bckdyisd1 X-HE-Tag: 1650556198-906744 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 Thu, Apr 21, 2022 at 1:57 AM Nicholas Piggin wrote: > > Those were (AFAIKS) all in arch code though. No Nick, they really weren't. The bpf issue with VM_FLUSH_RESET_PERMS means that all your arguments are invalid, because this affected non-architecture code. So the bpf case had two independent issues: one was just bpf doing a really bad job at making sure the executable mapping was sanely initialized. But the other was an actual bug in that hugepage case for vmalloc. And that bug was an issue on power too. So your "this is purely an x86 issue" argument is simply wrong. Because I'm very much looking at that power code that says "oh, __module_alloc() needs more work". Notice? Can these be fixed? Yes. But they can't be fixed by saying "oh, let's disable it on x86". Although it's probably true that at that point, some of the issues would no longer be nearly as noticeable. Linus