Message ID | 20221217015435.73889-7-bhe@redhat.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp1304715wrn; Fri, 16 Dec 2022 17:58:44 -0800 (PST) X-Google-Smtp-Source: AMrXdXvS2uIRRpyJo3sPWwhT+Qq22I7lweuuBNxF1x/w5fOEOzfFlobiARGttGm3Der3cdSqBLRB X-Received: by 2002:a17:906:f14:b0:7f9:f8a7:731a with SMTP id z20-20020a1709060f1400b007f9f8a7731amr790799eji.38.1671242324252; Fri, 16 Dec 2022 17:58:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671242324; cv=none; d=google.com; s=arc-20160816; b=DgO6agRNDLmOmfeyIp5WHQbA5IPPZE/Xr0adKIbwPIfUb5pUuReAYhiu+WP8w7/Swt 20/Rq2wKWJm5Hjnz6Fdt/lYSIC2IIxcHS4WLyG9LxxThIPNi6jf+xvWo5aVfuoUCKtqm SYSMq43+E5axevMnxE0sZkCuj4Jzhlu9zp/1IBxCVGaq2ktWhW/ZAdbiIrxvyax0sce/ k5nBqM/9JJ+2K4JejyI3jqrMv9a4ZmMawV8uYQxzqNjuDBVQIY9IEOUCco5ynum55Inn FJgsdNow07iiaQYkid3keFIpWO7REKmC2UqXjjlVaKO1WpYQn3TrB0I4FAaGeqilt1mF qZAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Xv8gbdl7CL7K4MDV2oGJuvA/KR+O1Rw3H7q7uOHvZNc=; b=xYeuqRzJQ3fRvvKtg6kf31NnLF61bE4F3AHbuwP7g538yaRuiLccTtY5mwvctuDdHT CUpg5IAjEnXFVDCu500BeKVlxxJxzQZIer+s+3V2enBnFu4xg9unzPZv8d/tv9uT0wJF 3kNQqMERmXlR/e4jCR8A9HJ+utwyfy/GPljTWg82QjCyEZR6Yc9/vDj11Xxak42Hh8xL 3qnwqqFl3ZvCLmMkEjrPq5UyXtx6Iud87rEZnQIJfpD4/tkIwYC890ddM2cJzBGPKviS 4YbhXEez2yeQqxzAxxH8i0gTPT0GcFfyZ6zZLF5+1dcDmNKrizhFPjQkYxebU5sYuFSD WoCw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=UM8tINCv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id cs18-20020a170906dc9200b007c14afc0ecdsi4354690ejc.479.2022.12.16.17.58.21; Fri, 16 Dec 2022 17:58:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=UM8tINCv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230195AbiLQB4w (ORCPT <rfc822;jeantsuru.cumc.mandola@gmail.com> + 99 others); Fri, 16 Dec 2022 20:56:52 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33890 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230076AbiLQB4X (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 16 Dec 2022 20:56:23 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4C79C5C0F1 for <linux-kernel@vger.kernel.org>; Fri, 16 Dec 2022 17:55:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1671242123; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Xv8gbdl7CL7K4MDV2oGJuvA/KR+O1Rw3H7q7uOHvZNc=; b=UM8tINCvM9Fq5yXXuJjueUxDimQIovKvax802X4WX0dAv8agEHkrdzE3KSfpw6wNbvTd8y Uvk4nvByAOFE3vX2RwQEicb90PInciKv5Ya6W6DJfCuZ8q6rZ/OTHADn0fUBEGA59BM58i SGs8Htl3XqhjU1NvboZAYcf6nz3mh2k= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-674-kiSlyi0fPZqcsD2lk1KCCA-1; Fri, 16 Dec 2022 20:55:19 -0500 X-MC-Unique: kiSlyi0fPZqcsD2lk1KCCA-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 8CB3518A63EC; Sat, 17 Dec 2022 01:55:18 +0000 (UTC) Received: from MiWiFi-R3L-srv.redhat.com (ovpn-12-34.pek2.redhat.com [10.72.12.34]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4EE9C49BB6A; Sat, 17 Dec 2022 01:55:11 +0000 (UTC) From: Baoquan He <bhe@redhat.com> To: linux-kernel@vger.kernel.org Cc: linux-mm@kvack.org, urezki@gmail.com, stephen.s.brennan@oracle.com, willy@infradead.org, akpm@linux-foundation.org, hch@infradead.org, Baoquan He <bhe@redhat.com>, Michael Ellerman <mpe@ellerman.id.au>, Nicholas Piggin <npiggin@gmail.com>, Christophe Leroy <christophe.leroy@csgroup.eu>, "Pali Roh??r" <pali@kernel.org>, linuxppc-dev@lists.ozlabs.org Subject: [PATCH v2 6/7] powerpc: mm: add VM_IOREMAP flag to the vmalloc area Date: Sat, 17 Dec 2022 09:54:34 +0800 Message-Id: <20221217015435.73889-7-bhe@redhat.com> In-Reply-To: <20221217015435.73889-1-bhe@redhat.com> References: <20221217015435.73889-1-bhe@redhat.com> MIME-Version: 1.0 Content-type: text/plain Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752424591472819934?= X-GMAIL-MSGID: =?utf-8?q?1752424591472819934?= |
Series |
mm/vmalloc.c: allow vread() to read out vm_map_ram areas
|
|
Commit Message
Baoquan He
Dec. 17, 2022, 1:54 a.m. UTC
Currently, for vmalloc areas with flag VM_IOREMAP set, except of the
specific alignment clamping in __get_vm_area_node(), they will be
1) Shown as ioremap in /proc/vmallocinfo;
2) Ignored by /proc/kcore reading via vread()
So for the io mapping in ioremap_phb() of ppc, we should set VM_IOREMAP
in flag to make it handled correctly as above.
Signed-off-by: Baoquan He <bhe@redhat.com>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
Cc: "Pali Roh??r" <pali@kernel.org>
Cc: linuxppc-dev@lists.ozlabs.org
---
arch/powerpc/kernel/pci_64.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/powerpc/kernel/pci_64.c b/arch/powerpc/kernel/pci_64.c index 0c7cfb9fab04..fd42059ae2a5 100644 --- a/arch/powerpc/kernel/pci_64.c +++ b/arch/powerpc/kernel/pci_64.c @@ -132,7 +132,7 @@ void __iomem *ioremap_phb(phys_addr_t paddr, unsigned long size) * address decoding but I'd rather not deal with those outside of the * reserved 64K legacy region. */ - area = __get_vm_area_caller(size, 0, PHB_IO_BASE, PHB_IO_END, + area = __get_vm_area_caller(size, VM_IOREMAP, PHB_IO_BASE, PHB_IO_END, __builtin_return_address(0)); if (!area) return NULL;