Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp312955rwd; Fri, 19 May 2023 21:11:15 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4XrlARgYM0pcnrGA+8UULjlQAy2aIPtlFlfo6w4DquOn/z06vReMmX5nx35nC/lgC4FbHq X-Received: by 2002:a17:90a:a611:b0:253:2dc5:4e12 with SMTP id c17-20020a17090aa61100b002532dc54e12mr4127730pjq.46.1684555874924; Fri, 19 May 2023 21:11:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684555874; cv=none; d=google.com; s=arc-20160816; b=l6bMfk1l4nLF18MMx1lSGbiUOdCLZkJBcyqsuFISULLbWl6IVsUO4jFUjFj4CzQk5L GIVRrV1ereNk6d3EvmDWsCohZg82KVZJT+kehLqJDSn6aqfHUeopTMeKNZiipMrpE20X Nhpfdrr8Ws1Ppn+F2rh0xXNFgQGrnyvmCJiCYftgOM4TIGwUtqIQxuBVapUIotvU2XcC Iz2Z8sJYlDZ7Wc5tb9l37ivNxHmE+DgrZjTML6kfu1MiuKvJdEan8ePK84uzrqQk1hHe 8Eiwx4tNxPbPWxRquDrzQ4qTZoJnY5GHLPJTIuqeVhZrHa0qhRcfOsjJCc+CwlTTeC/q Ku2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=xVZv6T/wRHC8aZPmUbolnwWkjCu5MdbG+ni9RcvouEs=; b=v4vKrDTjnJOz5OvQ/UQj5w7pBoFWm+OzQglNYwpZdWnELhDFfQ8o8fWN6/sxLn6Vz+ FnTdUvsbOECOtjzhQEHsAN5ewmW39ATjFMXIwrLEakIGxTKPR2IR/PPHLd0q9GPFFUC2 2f3/nCanI2oc2byh30H9I3rpFBItPy9h08G6NchXplAF9UmgHC1srLVa6gWX7B/085ga hZlHgQRS/I8RdzvDvg0Pi3Afiq43HotkNnD0JfObrx7D/p9gTmiOwSXWZEsHiURQLcr+ lMFRjVS8uGa19ttq3YnJmvHgvjyK1KBrmuV+m0ldTQYKgIzUiQhdQZ8x8SGbMWnUu9Kj w+ig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZSRC3mF2; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r14-20020a17090a454e00b002532c8283afsi2779063pjm.47.2023.05.19.21.11.01; Fri, 19 May 2023 21:11:14 -0700 (PDT) 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=ZSRC3mF2; 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 S230001AbjETDcC (ORCPT + 99 others); Fri, 19 May 2023 23:32:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43554 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229449AbjETDb7 (ORCPT ); Fri, 19 May 2023 23:31:59 -0400 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 F25DC18D for ; Fri, 19 May 2023 20:31:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1684553476; 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: in-reply-to:in-reply-to:references:references; bh=xVZv6T/wRHC8aZPmUbolnwWkjCu5MdbG+ni9RcvouEs=; b=ZSRC3mF27EoLtdHLsKaREIAUYSQQtwpA+n4CySFpPHaMFp6WeHswUyXz6wrNW0pMm6UXHE jSKNh+RAckrfYqx563KZyZTO9QP2dwwhzddl/90KNMZfdTLv7TeTsyhFT6T1JRpowIWsqE Xxu3uAhZXB9NNHd0fAI6O4Wd5VdwTS0= 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-574-vOufUwP5MSmvd1hYjrJ7nQ-1; Fri, 19 May 2023 23:31:10 -0400 X-MC-Unique: vOufUwP5MSmvd1hYjrJ7nQ-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 1520F8007D9; Sat, 20 May 2023 03:31:10 +0000 (UTC) Received: from localhost (ovpn-12-79.pek2.redhat.com [10.72.12.79]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3F537492B0A; Sat, 20 May 2023 03:31:08 +0000 (UTC) Date: Sat, 20 May 2023 11:31:04 +0800 From: Baoquan He To: Christoph Hellwig Cc: linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, linux-mm@kvack.org, arnd@arndb.de, christophe.leroy@csgroup.eu, agordeev@linux.ibm.com, wangkefeng.wang@huawei.com, schnelle@linux.ibm.com, David.Laight@aculab.com, shorne@gmail.com, willy@infradead.org, deller@gmx.de Subject: Re: [PATCH v5 RESEND 14/17] mm/ioremap: Consider IOREMAP space in generic ioremap Message-ID: References: <20230515090848.833045-1-bhe@redhat.com> <20230515090848.833045-15-bhe@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: 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,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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: X-Mailing-List: linux-kernel@vger.kernel.org On 05/16/23 at 11:44pm, Christoph Hellwig wrote: > On Tue, May 16, 2023 at 11:41:26PM -0700, Christoph Hellwig wrote: > > I think this would be cleaner if we'd just always use > > __get_vm_area_caller and at the top of the file add a: > > > > #ifndef IOREMAP_START > > #define IOREMAP_START VMALLOC_START > > #define IOREMAP_END VMALLOC_END > > #endif > > > > Together with a little comment that ioremap often, but not always > > uses the generic vmalloc area. > > .. and with that we can also simply is_ioremap_addr by moving it > to ioremap.c and making it always operate on the IOREMAP constants. Great idea too, will do. Put this into a separate patch?