From: Andrew Morton <akpm@linux-foundation.org>
To: akpm@linux-foundation.org, geert@linux-m68k.org,
gerg@linux-m68k.org, linux-mm@kvack.org, lkp@intel.com,
mm-commits@vger.kernel.org, rppt@linux.ibm.com,
torvalds@linux-foundation.org
Subject: [patch 1/6] m68k: make __pfn_to_phys() and __phys_to_pfn() available for !MMU
Date: Fri, 12 Feb 2021 20:52:38 -0800 [thread overview]
Message-ID: <20210213045238.52VjY3l-i%akpm@linux-foundation.org> (raw)
In-Reply-To: <20210212205206.f99cbe2e7e368c802a385104@linux-foundation.org>
From: Mike Rapoport <rppt@linux.ibm.com>
Subject: m68k: make __pfn_to_phys() and __phys_to_pfn() available for !MMU
Recent changes that obsoleted DISCONTIGMEM on m68k switched the MMU
variant to use generic definitions of __pfn_to_phys() and __phys_to_pfn(),
but missed the !MMU variant which caused a build failure:
All errors (new ones prefixed by >>):
drivers/media/common/videobuf2/videobuf2-dma-contig.c: In function 'vb2_dc_get_userptr':
>> drivers/media/common/videobuf2/videobuf2-dma-contig.c:509:5: error: implicit declaration of function '__pfn_to_phys' [-Werror=implicit-function-declaration]
509 | __pfn_to_phys(nums[0]), size, buf->dma_dir, 0);
| ^~~~~~~~~~~~~
cc1: some warnings being treated as errors
Enable __pfn_to_phys() and __phys_to_pfn() on !MMU builds.
Link: https://lkml.kernel.org/r/20210211232202.GS299309@linux.ibm.com
Fixes: 4bfc848e0981 ("m68k/mm: enable use of generic memory_model.h for !DISCONTIGMEM")
Signed-off-by: Mike Rapoport <rppt@linux.ibm.com>
Reported-by: kernel test robot <lkp@intel.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Greg Ungerer <gerg@linux-m68k.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
arch/m68k/include/asm/page.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/arch/m68k/include/asm/page.h~m68k-make-__pfn_to_phys-and-__phys_to_pfn-available-for-mmu
+++ a/arch/m68k/include/asm/page.h
@@ -62,7 +62,7 @@ extern unsigned long _ramend;
#include <asm/page_no.h>
#endif
-#ifdef CONFIG_DISCONTIGMEM
+#if !defined(CONFIG_MMU) || defined(CONFIG_DISCONTIGMEM)
#define __phys_to_pfn(paddr) ((unsigned long)((paddr) >> PAGE_SHIFT))
#define __pfn_to_phys(pfn) PFN_PHYS(pfn)
#endif
_
next prev parent reply other threads:[~2021-02-13 4:53 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-13 4:52 incoming Andrew Morton
2021-02-13 4:52 ` Andrew Morton [this message]
2021-02-13 4:52 ` [patch 2/6] scripts/recordmcount.pl: support big endian for ARCH sh Andrew Morton
2021-02-13 4:52 ` [patch 3/6] MAINTAINERS: update KASAN file list Andrew Morton
2021-02-13 4:52 ` [patch 4/6] MAINTAINERS: update Andrey Konovalov's email address Andrew Morton
2021-02-13 4:52 ` [patch 5/6] MAINTAINERS: add Andrey Konovalov to KASAN reviewers Andrew Morton
2021-02-13 4:52 ` [patch 6/6] h8300: fix PREEMPTION build, TI_PRE_COUNT undefined Andrew Morton
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=20210213045238.52VjY3l-i%akpm@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=geert@linux-m68k.org \
--cc=gerg@linux-m68k.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lkp@intel.com \
--cc=mm-commits@vger.kernel.org \
--cc=rppt@linux.ibm.com \
--cc=torvalds@linux-foundation.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.