linux-ia64.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matthew Wilcox <willy@infradead.org>
To: Mike Rapoport <rppt@kernel.org>
Cc: linux-mm@kvack.org, linux-arch@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-ia64@vger.kernel.org
Subject: Re: [PATCH v3 11/34] ia64: Implement the new page table range API
Date: Fri, 03 Mar 2023 14:36:10 +0000	[thread overview]
Message-ID: <ZAIF2t8HxjUm/45d@casper.infradead.org> (raw)
In-Reply-To: <ZAHgdEzqWk4Peyjh@kernel.org>

On Fri, Mar 03, 2023 at 01:56:36PM +0200, Mike Rapoport wrote:
> On Tue, Feb 28, 2023 at 09:37:14PM +0000, Matthew Wilcox (Oracle) wrote:
> >  void arch_dma_mark_clean(phys_addr_t paddr, size_t size)
> >  {
> > -	unsigned long pfn = PHYS_PFN(paddr);
> > +	struct folio *folio = page_folio(phys_to_page(paddr));
> > +	ssize_t left = size;
> > +	size_t offset = offset_in_folio(folio, paddr);
> 
> Build of defconfig failed miserably for me without this:
> 
> diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c
> index 12aef25944aa..0775e7870257 100644
> --- a/arch/ia64/mm/init.c
> +++ b/arch/ia64/mm/init.c
> @@ -69,7 +69,8 @@ __ia64_sync_icache_dcache (pte_t pte)
>   */
>  void arch_dma_mark_clean(phys_addr_t paddr, size_t size)
>  {
> -	struct folio *folio = page_folio(phys_to_page(paddr));
> +	unsigned long pfn = __phys_to_pfn(paddr);
> +	struct folio *folio = page_folio(pfn_to_page(pfn));

Huh, TIL that only some architectures have phys_to_page().  Thanks.
I'm going to use PHYS_PFN instead of __phys_to_pfn just to reduce the
diff.

      reply	other threads:[~2023-03-03 14:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20230228213738.272178-1-willy@infradead.org>
2023-02-28 21:37 ` [PATCH v3 11/34] ia64: Implement the new page table range API Matthew Wilcox (Oracle)
2023-03-03 11:56   ` Mike Rapoport
2023-03-03 14:36     ` Matthew Wilcox [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=ZAIF2t8HxjUm/45d@casper.infradead.org \
    --to=willy@infradead.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=rppt@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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).