mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dan Williams <dan.j.williams@intel.com>
To: Arnd Bergmann <arnd@kernel.org>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	Dan Williams <dan.j.williams@intel.com>
Cc: Andy Lutomirski <luto@kernel.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
	<x86@kernel.org>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Nikolay Borisov <nik.borisov@suse.com>,
	<linux-kernel@vger.kernel.org>, Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH 1/3] x86/devmem: move range_is_allowed() to drivers/char/mem.c
Date: Wed, 21 May 2025 15:05:53 -0700	[thread overview]
Message-ID: <682e4e416f296_1626e1009c@dwillia2-xfh.jf.intel.com.notmuch> (raw)
In-Reply-To: <20250520152030.1499670-1-arnd@kernel.org>

Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> The global inline function in include/linux/io.h causes problems
> because of the unfortunate naming that is too generic, and because
> it reintroduces a dependency on the PAGE_SIZE definition that should
> not exist in this header file.

Ah, good point.

> Something I had not seen during the earlier review is how the
> x86 phys_mem_access_prot_allowed() is called directly after the
> generic check for range_is_allowed(), so checking it again actually
> has no effect at all, and the definition can be made local to
> drivers/char/mem.c with no other caller.

Oh, true.

> 
> Fixes: 1b3f2bd04d90 ("x86/devmem: Remove duplicate range_is_allowed() definition")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  arch/x86/mm/pat/memtype.c |  3 ---
>  drivers/char/mem.c        | 18 ++++++++++++++++++
>  include/linux/io.h        | 21 ---------------------
>  3 files changed, 18 insertions(+), 24 deletions(-)

Looks good to me.

Reviewed-by: Dan Williams <dan.j.williams@intel.com>

      parent reply	other threads:[~2025-05-21 22:06 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-20 15:20 Arnd Bergmann
2025-05-20 15:20 ` [PATCH 2/3] x86/devmem: remove phys_mem_access_prot_allowed() Arnd Bergmann
2025-05-21 22:08   ` Dan Williams
2025-05-20 15:20 ` [PATCH 3/3] [RFC] x86/devmem: remove low 1MB hack for x86-64 Arnd Bergmann
2025-05-21 22:14   ` Dan Williams
2025-05-22 12:24     ` Arnd Bergmann
2025-06-03 18:18       ` Dan Williams
2025-06-03 19:25         ` Arnd Bergmann
2025-06-03 19:36           ` Dan Williams
2025-06-11 14:18             ` Naveen N Rao
2025-05-21 22:05 ` Dan Williams [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=682e4e416f296_1626e1009c@dwillia2-xfh.jf.intel.com.notmuch \
    --to=dan.j.williams@intel.com \
    --cc=arnd@arndb.de \
    --cc=arnd@kernel.org \
    --cc=bp@alien8.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@kernel.org \
    --cc=mingo@redhat.com \
    --cc=nik.borisov@suse.com \
    --cc=peterz@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®