Hi Thomas,
kernel test robot noticed the following build errors:
[auto build test ERROR on tip/x86/core]
[also build test ERROR on deller-parisc/for-next arnd-asm-generic/master linus/master v6.8-rc5]
[cannot apply to next-20240222]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Thomas-Zimmermann/arch-Select-fbdev-helpers-with-CONFIG_VIDEO/20240222-001622
base: tip/x86/core
patch link: https://lore.kernel.org/r/20240221161431.8245-4-tzimmermann%40suse.de
patch subject: [PATCH 3/3] arch: Rename fbdev header and source files
config: um-randconfig-002-20240222 (https://download.01.org/0day-ci/archive/20240223/202402230737.e7gWpGUp-lkp@intel.com/config)
compiler: clang version 19.0.0git (https://github.com/llvm/llvm-project edd4aee4dd9b5b98b2576a6f783e4086173d902a)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240223/202402230737.e7gWpGUp-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202402230737.e7gWpGUp-lkp@intel.com/
All errors (new ones prefixed by >>):
/usr/bin/ld: warning: .tmp_vmlinux.kallsyms1 has a LOAD segment with RWX permissions
/usr/bin/ld: drivers/video/fbdev/core/fb_io_fops.o: in function `fb_io_mmap':
>> drivers/video/fbdev/core/fb_io_fops.c:164: undefined reference to `pgprot_framebuffer'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
vim +164 drivers/video/fbdev/core/fb_io_fops.c
6b180f66c0dd62 Thomas Zimmermann 2023-09-27 140
33253d9e01d405 Thomas Zimmermann 2023-11-27 141 int fb_io_mmap(struct fb_info *info, struct vm_area_struct *vma)
33253d9e01d405 Thomas Zimmermann 2023-11-27 142 {
33253d9e01d405 Thomas Zimmermann 2023-11-27 143 unsigned long start = info->fix.smem_start;
33253d9e01d405 Thomas Zimmermann 2023-11-27 144 u32 len = info->fix.smem_len;
33253d9e01d405 Thomas Zimmermann 2023-11-27 145 unsigned long mmio_pgoff = PAGE_ALIGN((start & ~PAGE_MASK) + len) >> PAGE_SHIFT;
33253d9e01d405 Thomas Zimmermann 2023-11-27 146
b3e8813773c568 Thomas Zimmermann 2023-11-27 147 if (info->flags & FBINFO_VIRTFB)
b3e8813773c568 Thomas Zimmermann 2023-11-27 148 fb_warn_once(info, "Framebuffer is not in I/O address space.");
b3e8813773c568 Thomas Zimmermann 2023-11-27 149
33253d9e01d405 Thomas Zimmermann 2023-11-27 150 /*
33253d9e01d405 Thomas Zimmermann 2023-11-27 151 * This can be either the framebuffer mapping, or if pgoff points
33253d9e01d405 Thomas Zimmermann 2023-11-27 152 * past it, the mmio mapping.
33253d9e01d405 Thomas Zimmermann 2023-11-27 153 */
33253d9e01d405 Thomas Zimmermann 2023-11-27 154 if (vma->vm_pgoff >= mmio_pgoff) {
33253d9e01d405 Thomas Zimmermann 2023-11-27 155 if (info->var.accel_flags)
33253d9e01d405 Thomas Zimmermann 2023-11-27 156 return -EINVAL;
33253d9e01d405 Thomas Zimmermann 2023-11-27 157
33253d9e01d405 Thomas Zimmermann 2023-11-27 158 vma->vm_pgoff -= mmio_pgoff;
33253d9e01d405 Thomas Zimmermann 2023-11-27 159 start = info->fix.mmio_start;
33253d9e01d405 Thomas Zimmermann 2023-11-27 160 len = info->fix.mmio_len;
33253d9e01d405 Thomas Zimmermann 2023-11-27 161 }
33253d9e01d405 Thomas Zimmermann 2023-11-27 162
33253d9e01d405 Thomas Zimmermann 2023-11-27 163 vma->vm_page_prot = vm_get_page_prot(vma->vm_flags);
33253d9e01d405 Thomas Zimmermann 2023-11-27 @164 vma->vm_page_prot = pgprot_framebuffer(vma->vm_page_prot, vma->vm_start,
33253d9e01d405 Thomas Zimmermann 2023-11-27 165 vma->vm_end, start);
33253d9e01d405 Thomas Zimmermann 2023-11-27 166
33253d9e01d405 Thomas Zimmermann 2023-11-27 167 return vm_iomap_memory(vma, start, len);
33253d9e01d405 Thomas Zimmermann 2023-11-27 168 }
33253d9e01d405 Thomas Zimmermann 2023-11-27 169 EXPORT_SYMBOL(fb_io_mmap);
33253d9e01d405 Thomas Zimmermann 2023-11-27 170
deleted file mode 100644
@@ -1,8 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
-
-#include <asm-generic/fb.h>
-
-#endif /* _ASM_FB_H_ */
new file mode 100644
@@ -0,0 +1,8 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
+
+#include <asm-generic/video.h>
+
+#endif /* _ASM_VIDEO_H_ */
deleted file mode 100644
@@ -1,6 +0,0 @@
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
-
-#include <asm-generic/fb.h>
-
-#endif /* _ASM_FB_H_ */
new file mode 100644
@@ -0,0 +1,6 @@
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
+
+#include <asm-generic/video.h>
+
+#endif /* _ASM_VIDEO_H_ */
deleted file mode 100644
@@ -1,10 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0-only */
-/*
- * Copyright (C) 2012 ARM Ltd.
- */
-#ifndef __ASM_FB_H_
-#define __ASM_FB_H_
-
-#include <asm-generic/fb.h>
-
-#endif /* __ASM_FB_H_ */
new file mode 100644
@@ -0,0 +1,10 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+/*
+ * Copyright (C) 2012 ARM Ltd.
+ */
+#ifndef __ASM_VIDEO_H_
+#define __ASM_VIDEO_H_
+
+#include <asm-generic/video.h>
+
+#endif /* __ASM_VIDEO_H_ */
similarity index 86%
rename from arch/loongarch/include/asm/fb.h
rename to arch/loongarch/include/asm/video.h
@@ -2,8 +2,8 @@
/*
* Copyright (C) 2020-2022 Loongson Technology Corporation Limited
*/
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
#include <linux/compiler.h>
#include <linux/string.h>
@@ -26,6 +26,6 @@ static inline void fb_memset_io(volatile void __iomem *addr, int c, size_t n)
}
#define fb_memset fb_memset_io
-#include <asm-generic/fb.h>
+#include <asm-generic/video.h>
-#endif /* _ASM_FB_H_ */
+#endif /* _ASM_VIDEO_H_ */
similarity index 86%
rename from arch/m68k/include/asm/fb.h
rename to arch/m68k/include/asm/video.h
@@ -1,6 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
#include <asm/page.h>
#include <asm/setup.h>
@@ -27,6 +27,6 @@ static inline pgprot_t pgprot_framebuffer(pgprot_t prot,
}
#define pgprot_framebuffer pgprot_framebuffer
-#include <asm-generic/fb.h>
+#include <asm-generic/video.h>
-#endif /* _ASM_FB_H_ */
+#endif /* _ASM_VIDEO_H_ */
similarity index 76%
rename from arch/mips/include/asm/fb.h
rename to arch/mips/include/asm/video.h
@@ -1,5 +1,5 @@
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
#include <asm/page.h>
@@ -13,8 +13,8 @@ static inline pgprot_t pgprot_framebuffer(pgprot_t prot,
/*
* MIPS doesn't define __raw_ I/O macros, so the helpers
- * in <asm-generic/fb.h> don't generate fb_readq() and
- * fb_write(). We have to provide them here.
+ * in <asm-generic/video.h> don't generate fb_readq() and
+ * fb_writeq(). We have to provide them here.
*
* TODO: Convert MIPS to generic I/O. The helpers below can
* then be removed.
@@ -33,6 +33,6 @@ static inline void fb_writeq(u64 b, volatile void __iomem *addr)
#define fb_writeq fb_writeq
#endif
-#include <asm-generic/fb.h>
+#include <asm-generic/video.h>
-#endif /* _ASM_FB_H_ */
+#endif /* _ASM_VIDEO_H_ */
similarity index 68%
rename from arch/parisc/include/asm/fb.h
rename to arch/parisc/include/asm/video.h
@@ -1,6 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
#include <linux/types.h>
@@ -11,6 +11,6 @@ bool video_is_primary_device(struct device *dev);
#define video_is_primary_device video_is_primary_device
#endif
-#include <asm-generic/fb.h>
+#include <asm-generic/video.h>
-#endif /* _ASM_FB_H_ */
+#endif /* _ASM_VIDEO_H_ */
@@ -1,3 +1,3 @@
# SPDX-License-Identifier: GPL-2.0-only
-obj-$(CONFIG_STI_CORE) += fbdev.o
+obj-$(CONFIG_STI_CORE) += video-sti.o
similarity index 96%
rename from arch/parisc/video/fbdev.c
rename to arch/parisc/video/video-sti.c
@@ -9,7 +9,7 @@
#include <video/sticore.h>
-#include <asm/fb.h>
+#include <asm/video.h>
bool video_is_primary_device(struct device *dev)
{
similarity index 76%
rename from arch/powerpc/include/asm/fb.h
rename to arch/powerpc/include/asm/video.h
@@ -1,6 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
#include <asm/page.h>
@@ -12,6 +12,6 @@ static inline pgprot_t pgprot_framebuffer(pgprot_t prot,
}
#define pgprot_framebuffer pgprot_framebuffer
-#include <asm-generic/fb.h>
+#include <asm-generic/video.h>
-#endif /* _ASM_FB_H_ */
+#endif /* _ASM_VIDEO_H_ */
@@ -517,7 +517,7 @@ int pci_iobar_pfn(struct pci_dev *pdev, int bar, struct vm_area_struct *vma)
}
/*
- * This one is used by /dev/mem and fbdev who have no clue about the
+ * This one is used by /dev/mem and video who have no clue about the
* PCI device, it tries to find the PCI device first and calls the
* above routine
*/
deleted file mode 100644
@@ -1,7 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _ASM_FB_H_
-#define _ASM_FB_H_
-
-#include <asm-generic/fb.h>
-
-#endif /* _ASM_FB_H_ */
new file mode 100644
@@ -0,0 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#ifndef _ASM_VIDEO_H_
+#define _ASM_VIDEO_H_
+
+#include <asm-generic/video.h>
+
+#endif /* _ASM_VIDEO_H_ */
similarity index 89%
rename from arch/sparc/include/asm/fb.h
rename to arch/sparc/include/asm/video.h
@@ -1,6 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _SPARC_FB_H_
-#define _SPARC_FB_H_
+#ifndef _SPARC_VIDEO_H_
+#define _SPARC_VIDEO_H_
#include <linux/io.h>
#include <linux/types.h>
@@ -40,6 +40,6 @@ static inline void fb_memset_io(volatile void __iomem *addr, int c, size_t n)
}
#define fb_memset fb_memset_io
-#include <asm-generic/fb.h>
+#include <asm-generic/video.h>
-#endif /* _SPARC_FB_H_ */
+#endif /* _SPARC_VIDEO_H_ */
@@ -1,3 +1,3 @@
# SPDX-License-Identifier: GPL-2.0-only
-obj-y += fbdev.o
+obj-y += video.o
similarity index 86%
rename from arch/sparc/video/fbdev.c
rename to arch/sparc/video/video.c
@@ -4,8 +4,8 @@
#include <linux/device.h>
#include <linux/module.h>
-#include <asm/fb.h>
#include <asm/prom.h>
+#include <asm/video.h>
bool video_is_primary_device(struct device *dev)
{
@@ -21,5 +21,5 @@ bool video_is_primary_device(struct device *dev)
}
EXPORT_SYMBOL(video_is_primary_device);
-MODULE_DESCRIPTION("Sparc fbdev helpers");
+MODULE_DESCRIPTION("Sparc video helpers");
MODULE_LICENSE("GPL");
similarity index 77%
rename from arch/x86/include/asm/fb.h
rename to arch/x86/include/asm/video.h
@@ -1,6 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _ASM_X86_FB_H
-#define _ASM_X86_FB_H
+#ifndef _ASM_X86_VIDEO_H
+#define _ASM_X86_VIDEO_H
#include <linux/types.h>
@@ -16,6 +16,6 @@ pgprot_t pgprot_framebuffer(pgprot_t prot,
bool video_is_primary_device(struct device *dev);
#define video_is_primary_device video_is_primary_device
-#include <asm-generic/fb.h>
+#include <asm-generic/video.h>
-#endif /* _ASM_X86_FB_H */
+#endif /* _ASM_X86_VIDEO_H */
@@ -1,3 +1,3 @@
# SPDX-License-Identifier: GPL-2.0-only
-obj-y += fbdev.o
+obj-y += video.o
similarity index 97%
rename from arch/x86/video/fbdev.c
rename to arch/x86/video/video.c
@@ -10,7 +10,8 @@
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/vgaarb.h>
-#include <asm/fb.h>
+
+#include <asm/video.h>
pgprot_t pgprot_framebuffer(pgprot_t prot,
unsigned long vm_start, unsigned long vm_end,
@@ -22,7 +22,6 @@ mandatory-y += dma-mapping.h
mandatory-y += dma.h
mandatory-y += emergency-restart.h
mandatory-y += exec.h
-mandatory-y += fb.h
mandatory-y += ftrace.h
mandatory-y += futex.h
mandatory-y += hardirq.h
@@ -62,5 +61,6 @@ mandatory-y += uaccess.h
mandatory-y += unaligned.h
mandatory-y += vermagic.h
mandatory-y += vga.h
+mandatory-y += video.h
mandatory-y += word-at-a-time.h
mandatory-y += xor.h
similarity index 96%
rename from include/asm-generic/fb.h
rename to include/asm-generic/video.h
@@ -1,7 +1,7 @@
/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef __ASM_GENERIC_FB_H_
-#define __ASM_GENERIC_FB_H_
+#ifndef __ASM_GENERIC_VIDEO_H_
+#define __ASM_GENERIC_VIDEO_H_
/*
* Only include this header file from your architecture's <asm/fb.h>.
@@ -133,4 +133,4 @@ static inline void fb_memset_io(volatile void __iomem *addr, int c, size_t n)
#define fb_memset fb_memset_io
#endif
-#endif /* __ASM_GENERIC_FB_H_ */
+#endif /* __ASM_GENERIC_VIDEO_H_ */
@@ -16,7 +16,7 @@
#include <linux/backlight.h>
#include <linux/slab.h>
-#include <asm/fb.h>
+#include <asm/video.h>
struct vm_area_struct;
struct fb_info;