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 A5478C433EF for ; Fri, 1 Jul 2022 23:00:08 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id EFA736B0071; Fri, 1 Jul 2022 19:00:07 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id EAA606B0073; Fri, 1 Jul 2022 19:00:07 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D991C6B0074; Fri, 1 Jul 2022 19:00:07 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id C828E6B0071 for ; Fri, 1 Jul 2022 19:00:07 -0400 (EDT) Received: from smtpin13.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay13.hostedemail.com (Postfix) with ESMTP id 9315A601D9 for ; Fri, 1 Jul 2022 23:00:07 +0000 (UTC) X-FDA: 79640050854.13.FA78155 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf16.hostedemail.com (Postfix) with ESMTP id 09A1018006C for ; Fri, 1 Jul 2022 23:00:06 +0000 (UTC) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 06F2D6243A; Fri, 1 Jul 2022 23:00:06 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 37CF4C3411E; Fri, 1 Jul 2022 23:00:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1656716405; bh=0fjv73lwJfV1ngPtvUkpp3iQv3yau1ql4ulI9o+pBx4=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Wp1pnmRLnerdZ7Tah7cMZJcnqo6Mt1GHmJS4cx220+7vE1Nzpg2857tAqFDc5TaNU zxaRBbXQYx2a/rBsMVJUUqqX/9gV3xcsflW/SLVYWDIYA19FKjktIkhoZcJi0F1mGr IA7J9tmvD5SIcS5vO9SBGzJtzd4JvB8inFh4xh1s= Date: Fri, 1 Jul 2022 16:00:04 -0700 From: Andrew Morton To: Linus Walleij Cc: linux-mm@kvack.org Subject: Re: [PATCH 0/5] mm: Pass pointers to page accessors Message-Id: <20220701160004.2ffff4e5ab59a55499f4c736@linux-foundation.org> In-Reply-To: <20220630084124.691207-1-linus.walleij@linaro.org> References: <20220630084124.691207-1-linus.walleij@linaro.org> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1656716407; a=rsa-sha256; cv=none; b=wnsQB5X+E7+zOei7S/BW9QXkwNrUt2ZVXvxwnrkkOp8ag+AntX73biOVX0y1Rc1Y+y1tdP 5J5lxdjm8alGKo+FtCNZeP2YN4QDWhfuZm+DYmu9aXhs7I7XRvOvM4igGxfLSQAvUWT9r5 Ck36727Qus+VNlPw9w60WlqLiHC3AMM= ARC-Authentication-Results: i=1; imf16.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=Wp1pnmRL; dmarc=none; spf=pass (imf16.hostedemail.com: domain of akpm@linux-foundation.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1656716407; h=from:from:sender: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:dkim-signature; bh=XRELYazhP5mbsYVJNz3yCXPi6+3kTjL+ZZjGuAkeStE=; b=QIdzdTPr0e9r8OBPwVKufyhgyYUsV1rrtCLPsFgBO7Pgc4vOicbrUT9OBYzTHsvQYz02w9 yGNZTsk0vZMECdPrFll18ctmAwN/UeL8+yDlYgieahVAJA9onbpwKdSOqyRM15v6jIMMBR prMzwaMsmUYh0HS1/vWrQw3viUgrIPM= Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=Wp1pnmRL; dmarc=none; spf=pass (imf16.hostedemail.com: domain of akpm@linux-foundation.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 09A1018006C X-Stat-Signature: jidpfxo3j3skztuwmdpk44asdihzpijq X-Rspam-User: X-HE-Tag: 1656716406-319932 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, 30 Jun 2022 10:41:19 +0200 Linus Walleij wrote: > In a recent change to the Arm architecture with the end goal > of removing highmem we need to convert virt_to_phys() and > virt_to_pfn() to static inline functions. > > This will make them strongly typed. > > However since virt_to_* is always implemented as macros they > have become polymorphic and accept both (void *) and > e.g. unsigned long as arguments. > > Other functions such as virt_to_page() simply wrap > virt_to_pfn() and get affected indirectly. > > To be able to proceed, patch mm to use (void *) as argument > to affected functions in all instances. It would be nice if someone were to teach x86 and others to use static inlines. Get rid of those stupid macros and improve coverage for your changes.