From patchwork Wed Apr 27 12:14:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kefeng Wang X-Patchwork-Id: 12828714 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 C2CBBC433EF for ; Wed, 27 Apr 2022 12:02:25 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 6D7046B0073; Wed, 27 Apr 2022 08:02:23 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 685DC6B0075; Wed, 27 Apr 2022 08:02:23 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 576F36B0078; Wed, 27 Apr 2022 08:02:23 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.28]) by kanga.kvack.org (Postfix) with ESMTP id 47E386B0073 for ; Wed, 27 Apr 2022 08:02:23 -0400 (EDT) Received: from smtpin03.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 1EF562946 for ; Wed, 27 Apr 2022 12:02:23 +0000 (UTC) X-FDA: 79402521366.03.2211219 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by imf19.hostedemail.com (Postfix) with ESMTP id 316741A0055 for ; Wed, 27 Apr 2022 12:02:18 +0000 (UTC) Received: from dggpemm500023.china.huawei.com (unknown [172.30.72.55]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4KpHLd2cYQzCsSQ; Wed, 27 Apr 2022 19:57:45 +0800 (CST) Received: from dggpemm500001.china.huawei.com (7.185.36.107) by dggpemm500023.china.huawei.com (7.185.36.83) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Wed, 27 Apr 2022 20:02:18 +0800 Received: from localhost.localdomain.localdomain (10.175.113.25) by dggpemm500001.china.huawei.com (7.185.36.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Wed, 27 Apr 2022 20:02:17 +0800 From: Kefeng Wang To: Catalin Marinas , Will Deacon , Andrew Morton , , CC: , Kefeng Wang Subject: [PATCH 1/4] mm: ioremap: Setup phys_addr of struct vm_struct Date: Wed, 27 Apr 2022 20:14:10 +0800 Message-ID: <20220427121413.168468-2-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20220427121413.168468-1-wangkefeng.wang@huawei.com> References: <20220427121413.168468-1-wangkefeng.wang@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.113.25] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpemm500001.china.huawei.com (7.185.36.107) X-CFilter-Loop: Reflected X-Rspamd-Queue-Id: 316741A0055 X-Stat-Signature: 6wboy9mq6e8oab358cork7pihu1tmurd Authentication-Results: imf19.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf19.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.189 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com X-Rspam-User: X-Rspamd-Server: rspam08 X-HE-Tag: 1651060938-684478 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: Show physical address in /proc/vmallocinfo. Signed-off-by: Kefeng Wang Acked-by: Andrew Morton Reviewed-by: Christoph Hellwig --- mm/ioremap.c | 1 + 1 file changed, 1 insertion(+) diff --git a/mm/ioremap.c b/mm/ioremap.c index 5fe598ecd9b7..522ef899c35f 100644 --- a/mm/ioremap.c +++ b/mm/ioremap.c @@ -32,6 +32,7 @@ void __iomem *ioremap_prot(phys_addr_t addr, size_t size, unsigned long prot) if (!area) return NULL; vaddr = (unsigned long)area->addr; + area->phys_addr = addr; if (ioremap_page_range(vaddr, vaddr + size, addr, __pgprot(prot))) { free_vm_area(area);